您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Sort serials in alphabetic order on myshows.ru
当前为
// ==UserScript== // @name MyShows: sort serials // @namespace https://github.com/powerman/userjs-myshows // @description Sort serials in alphabetic order on myshows.ru // @include http://myshows.ru/profile/ // @match http://myshows.ru/profile/ // @version 2.3 // @grant none // ==/UserScript== window.addEventListener('load', function(){ 'use strict'; function sort_shows(){ // sort lists at left panel $('div.lside ul').html(function(){ return $(this).children().sort(function(a,b){ return $(a).text() < $(b).text() ? -1 : 1; }); }); // sort main content $('div.bserial').html(function(){ return $(this).children('h4').map(function(){ return $(this).nextUntil('h4').andSelf(); }).sort(function(a,b){ return a.first().text() < b.first().text() ? -1 : 1; }).map(function(){ return this.get(); }); }); } sort_shows(); $('.watch-episode').live('click', function(){ $('#content-inner').one('DOMNodeInserted', sort_shows); }); }, false);