您需要先安装一个扩展,例如 篡改猴、Greasemonkey 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 暴力猴,之后才能安装此脚本。
您需要先安装一个扩展,例如 篡改猴 或 Userscripts ,之后才能安装此脚本。
您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey,才能安装此脚本。
您需要先安装用户脚本管理器扩展后才能安装此脚本。
Moves focus to "Episodes Watched" after you selected "Status"
当前为
// ==UserScript== // @name MAL Status to Episodes Focus // @namespace MAL // @include *myanimelist.net/panel.php?go=add&selected_series_id=* // @include *myanimelist.net/panel.php?go=addmanga&selected_manga_id=* // @include *myanimelist.net/editlist.php?type=anime&id=* // @include *myanimelist.net/panel.php?go=editmanga&id=* // @description Moves focus to "Episodes Watched" after you selected "Status" // @version 1 // ==/UserScript== function xpath(query, object) { if(!object) var object = document; return document.evaluate(query, object, null, XPathResult.UNORDERED_NODE_SNAPSHOT_TYPE, null); } selectStatus = xpath("//select[@id='status']"); episodesWatched = xpath("//input[@id='completedEpsID'] | " + "//input[@id='chap_read']"); episodesWatchedSnap = episodesWatched.snapshotItem(0); selectStatus.snapshotItem(0).addEventListener('change', function() { episodesWatchedSnap.focus(); episodesWatchedSnap.setSelectionRange(0, episodesWatchedSnap.value.length); }, false);