Hentairead.com - Spacebar/Enter to go next panel

Enables clicking `spacebar` (or `enter`) to go to next panel, and shift+spacebar (of shift+enter) to go to previous

Dovrai installare un'estensione come Tampermonkey, Greasemonkey o Violentmonkey per installare questo script.

Dovrai installare un'estensione come Tampermonkey o Violentmonkey per installare questo script.

Dovrai installare un'estensione come Tampermonkey o Violentmonkey per installare questo script.

Dovrai installare un'estensione come Tampermonkey o Userscripts per installare questo script.

Dovrai installare un'estensione come ad esempio Tampermonkey per installare questo script.

Dovrai installare un gestore di script utente per installare questo script.

(Ho già un gestore di script utente, lasciamelo installare!)

Dovrai installare un'estensione come ad esempio Stylus per installare questo stile.

Dovrai installare un'estensione come ad esempio Stylus per installare questo stile.

Dovrai installare un'estensione come ad esempio Stylus per installare questo stile.

Dovrai installare un'estensione per la gestione degli stili utente per installare questo stile.

Dovrai installare un'estensione per la gestione degli stili utente per installare questo stile.

Dovrai installare un'estensione per la gestione degli stili utente per installare questo stile.

(Ho già un gestore di stile utente, lasciamelo installare!)

// ==UserScript==
// @name         Hentairead.com - Spacebar/Enter to go next panel
// @version      1.1
// @description  Enables clicking `spacebar` (or `enter`) to go to next panel, and shift+spacebar (of shift+enter) to go to previous
// @namespace    wierd4life
// @author       wierd4life
// @license      public
// @grant        none
// @match        *://hentairead.com/hentai/*
// ==/UserScript==
(function(){
    window.addEventListener('keydown', function (e) {
        if(e.key == 'Spacebar' || e.key == ' ' || e.key == 'Enter') {
            e.shiftKey ? unsafeWindow.readingNav?.goPrevPage?.() : unsafeWindow.readingNav?.goNextPage?.();
        }
    }, false);
})();