NOTICE: By continued use of this site you understand and agree to the binding Terms of Service and Privacy Policy.
// ==UserScript==
// @name AnimeGo
// @namespace https://openuserjs.org/users/OhSenpai1337
// @version 0.1.3
// @description Добавление кнопки AnimeGo для Shikimori
// @author Oh, Senpai
// @match https://shikimori.one/*
// @match http://shikimori.one/*
// @grant none
// @copyright 2020, OhSenpai1337 (https://openuserjs.org/users/OhSenpai1337)
// @license MIT
// ==/UserScript==
function start(){
if (window.location.href.indexOf("https://shikimori.one/animes/") !== -1) {
setTimeout(function () {
if (!$(".watch-online-placeholer").length) {
$(".c-info-right").append("<div class='watch-online-placeholer'></div>");
}
if ($(".watch-online-placeholer .block:last-child")) {
$(".watch-online-placeholer .block:last-child").remove();
}
if (!$(".watch_link").length) {
if (!$(".AnimeGo").length) {
let name = $('.head > h1').text().split("/")[1];
$(".watch-online-placeholer").append(
"<div class='block AnimeGo'><a href='https://animego.org/search/all?q=" + name + "' class='b-link_button dark watch_link '>Найти на AnimeGo</a></div>"
);
}
}
}, 200);
}
}
$(document).ready(start);
$(document).on('page:load', start);
$(document).on('turbolinks:load', start);