JPDB Link Remover

If you're using JPDBreader to review from the a vocab page in JPDB on mobile, tapping on a word to bring up the overlay causes the link to be followed. This script removes links from all JPDB deck pages. If you only want links removed from the All Vocab page, replace "https://jpdb.io/deck*" on line 6 with "https://jpdb.io/deck?id=gloabl"

スクリプトをインストールするには、Tampermonkey, GreasemonkeyViolentmonkey のような拡張機能のインストールが必要です。

スクリプトをインストールするには、TampermonkeyViolentmonkey のような拡張機能のインストールが必要です。

スクリプトをインストールするには、TampermonkeyViolentmonkey のような拡張機能のインストールが必要です。

スクリプトをインストールするには、TampermonkeyUserscripts のような拡張機能のインストールが必要です。

このスクリプトをインストールするには、Tampermonkeyなどの拡張機能をインストールする必要があります。

このスクリプトをインストールするには、ユーザースクリプト管理ツールの拡張機能をインストールする必要があります。

(ユーザースクリプト管理ツールは設定済みなのでインストール!)

このスタイルをインストールするには、Stylusなどの拡張機能をインストールする必要があります。

このスタイルをインストールするには、Stylus などの拡張機能をインストールする必要があります。

このスタイルをインストールするには、Stylus tなどの拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

このスタイルをインストールするには、ユーザースタイル管理用の拡張機能をインストールする必要があります。

(ユーザースタイル管理ツールは設定済みなのでインストール!)

このスクリプトの質問や評価の投稿はこちら通報はこちらへお寄せください
// ==UserScript==
// @name         JPDB Link Remover
// @namespace    uchisen.com
// @version      2024-11-04
// @description  If you're using JPDBreader to review from the a vocab page in JPDB on mobile, tapping on a word to bring up the overlay causes the link to be followed. This script removes links from all JPDB deck pages. If you only want links removed from the All Vocab page, replace "https://jpdb.io/deck*" on line 6 with "https://jpdb.io/deck?id=gloabl"
// @author       Togeffet
// @match        https://jpdb.io/deck*
// @icon         https://www.google.com/s2/favicons?sz=64&domain=jpdb.io
// @grant        none
// @license      MIT
// ==/UserScript==

(function() {
    'use strict';

    const vocabulary = document.getElementsByClassName('vocabulary-spelling');

    for (let i = 0; i < vocabulary.length; i++) {
        const link = vocabulary[i].getElementsByTagName('a')[0];

        link.removeAttribute('href'); // Remove link
        link.style.cursor = "default"; // Change cursor to default (just felt better imo)
        link.style.borderBottom = 'none'; // Remove link border on hover, since it's not a link anymore
    }
})();