Add AnimeBytes script for displaying anime names

Only applies to collage pages.
This commit is contained in:
Lukáš Kucharczyk 2021-05-24 10:11:13 +02:00
parent 03e7fbd781
commit 27d1f6a4bc
No known key found for this signature in database
GPG Key ID: 65524498C0196B64
1 changed files with 17 additions and 0 deletions

View File

@ -0,0 +1,17 @@
// ==UserScript==
// @name Display anime names in collages
// @namespace Violentmonkey Scripts
// @match https://animebytes.tv/collage.php
// @grant none
// @version 1.0
// @author Lukáš Kucharczyk
// @description Displays anime titles underneath posters on the collage page.
// ==/UserScript==
let r = document.querySelectorAll('#collage_table tbody tr td')
r.forEach((element) => {
let anime_title = element.querySelector('a img').attributes['alt'].value
let anime_title_div = document.createElement('div')
anime_title_div.style = 'width: 125px; height: 50px;'
element.appendChild(anime_title_div)
anime_title_div.innerText = anime_title
})