Files
ani-search-enhancer/ani-search-enhancer.user.js
Marvin Lehmann 0d32d250d2 Fixed text color of buttons
.. and reformatted the code.
2017-02-02 19:44:45 +01:00

31 lines
1.5 KiB
JavaScript

// ==UserScript==
// @name aniSearch Enhancer
// @namespace http://github.com/marvinl97/ani-search-enhancer
// @version 1.01
// @description Adds buttons to the info site of an anime on aniSearch which links you directly to various streaming portals.
// @author Marvin Lehmann (marvinl97)
// @grant none
// @include http://www.anisearch.de/anime/*
// @require http://code.jquery.com/jquery-latest.js
// @downloadURL http://raw.githubusercontent.com/marvinl97/ani-search-enhancer/master/ani-search-enhancer.user.js
// @supportURL http://github.com/marvinl97/ani-search-enhancer/issues
// ==/UserScript==
this.$ = this.jQuery = jQuery.noConflict(true);
$(document).ready(function()
{
$('head').append('<style>#page-action #page-action-search:before{content:"\\f002";}</style>');
var animeTitleElem = document.getElementById('htitle');
if (animeTitleElem !== null)
{
var animeTitle = animeTitleElem.innerText;
if (animeTitle)
{
$('#page-action').append('<li id="page-action-search"><a href="http://kissanime.ru/Search/Anime?keyword=' + animeTitle + '" target="_blank">KissAnime</a></li>');
$('#page-action').append('<li id="page-action-search"><a href="https://proxer.me/search?s=search&name=' + animeTitle + '&typ=all-anime#top" target="_blank">Proxer</a></li>');
$('#page-action').append('<li id="page-action-search"><a href="http://9anime.to/search?keyword=' + animeTitle + '" target="_blank">9Anime</a></li>');
$('li#page-action-search a').css("color", $('li#page-action-search').css("color"));
}
}
});