AlphaKaikin

Enables range selection and context menu display in the body of the Alphapolis novel

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Greasemonkey 油猴子Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Violentmonkey 暴力猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴Userscripts ,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展,例如 Tampermonkey 篡改猴,才能安装此脚本。

您需要先安装一款用户脚本管理器扩展后才能安装此脚本。

(我已经安装了用户脚本管理器,让我安装!)

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展,比如 Stylus,才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

您需要先安装一款用户样式管理器扩展后才能安装此样式。

(我已经安装了用户样式管理器,让我安装!)

// ==UserScript==
// @name            AlphaKaikin
// @name:ja         α解禁
// @namespace       https://furyutei.work
// @license         MIT
// @version         0.0.1
// @description     Enables range selection and context menu display in the body of the Alphapolis novel
// @description:ja  アルファポリス小説本文の範囲選択やコンテキストメニュー表示等を可能に
// @author          furyu
// @match           https://www.alphapolis.co.jp/novel/*
// @grant           none
// @compatible      chrome
// @compatible      firefox
// @supportURL      https://github.com/furyutei/AlphaKaikin/issues
// @contributionURL https://memo.furyutei.work/about#%E6%B0%97%E3%81%AB%E5%85%A5%E3%81%A3%E3%81%9F%E5%BD%B9%E3%81%AB%E7%AB%8B%E3%81%A3%E3%81%9F%E3%81%AE%E3%81%8A%E6%B0%97%E6%8C%81%E3%81%A1%E3%81%AF%E3%82%AE%E3%83%95%E3%83%88%E5%88%B8%E3%81%A7
// ==/UserScript==

( () => {
const
    remove_copyguard = () => {
        $( window ).on( 'focusout', ( event ) => event.stopImmediatePropagation() );
        let handlers = $._data( window ).events.focusout;
        handlers.unshift( handlers.pop() );
        $( '#novelBoby' ).css( 'user-select', '' );
        delete document.oncopy;
        delete document.onselectstart;
        delete document.oncontextmenu;
        document.addEventListener( 'copy', ( event ) => event.stopPropagation(), true );
        document.addEventListener( 'selectstart', ( event ) => event.stopPropagation(), true );
        document.addEventListener( 'contextmenu', ( event ) => event.stopPropagation(), true );
    },
    script = document.createElement( 'script' );

script.async = false;
script.textContent = '(' + remove_copyguard.toString() +')();';
document.documentElement.appendChild( script );
} )();