From 27d1f6a4bc4c09e87de3f79090cb1fc3d1141f21 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Luk=C3=A1=C5=A1=20Kucharczyk?= Date: Mon, 24 May 2021 10:11:13 +0200 Subject: [PATCH] Add AnimeBytes script for displaying anime names Only applies to collage pages. --- .../display_anime_names.js | 17 +++++++++++++++++ 1 file changed, 17 insertions(+) create mode 100644 animebytes_display_anime_names/display_anime_names.js diff --git a/animebytes_display_anime_names/display_anime_names.js b/animebytes_display_anime_names/display_anime_names.js new file mode 100644 index 0000000..4406cf9 --- /dev/null +++ b/animebytes_display_anime_names/display_anime_names.js @@ -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 +}) \ No newline at end of file