key listener ESC
当前为
// ==UserScript==
// @name mashibing next episode control
// @namespace http://tampermonkey.net/
// @version 2024年8月25日22点15分
// @description key listener ESC
// @license MIT
// @author onionycs
// @match https://www.mashibing.com/*
// @icon https://www.google.com/s2/favicons?sz=64&domain=mashibing.com
// @grant none
// ==/UserScript==
(function() {
'use strict';
// Your code here...
document.addEventListener('keydown', function(event) {
if (event.key === 'Escape') {
document.getElementsByClassName('next-btn')[1].click();
}
if (event.key === ']') {
document.getElementsByClassName('next-btn')[0].click();
}
});
})();