26 lines
757 B
JavaScript
26 lines
757 B
JavaScript
// ==UserScript==
|
|
// @name human
|
|
// @version 1.0
|
|
// @description :p
|
|
// @match https://humanbenchmark.com/tests/reactiontime
|
|
// @grant none
|
|
// @run-at document-start
|
|
// ==/UserScript==
|
|
|
|
(function() {
|
|
'use strict';
|
|
|
|
const CLICK_DELAY_MS = 100;
|
|
|
|
const observer = new MutationObserver(() => {
|
|
const greenScreen = document.querySelector('.view-go');
|
|
if (greenScreen) {
|
|
setTimeout(() => {
|
|
const event = new MouseEvent('mousedown', { bubbles: true, cancelable: true, view: window });
|
|
greenScreen.dispatchEvent(event);
|
|
}, CLICK_DELAY_MS);
|
|
}
|
|
});
|
|
|
|
observer.observe(document.documentElement, { childList: true, subtree: true });
|
|
})(); |