Created
December 8, 2025 06:58
-
-
Save av1d/792daa3d260b443805ae4ddd75b0886c to your computer and use it in GitHub Desktop.
Disable the popup / hover window pane accessibility disaster on archive.org for individual items in collections. Tampermonkey
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| // ==UserScript== | |
| // @name Archive.org kill tile hover pane | |
| // @match https://archive.org/details/* | |
| // @run-at document-start | |
| // ==/UserScript== | |
| (function() { | |
| 'use strict'; | |
| const origDefine = customElements.define.bind(customElements); | |
| customElements.define = function(name, ctor, options) { | |
| if (name === 'tile-dispatcher') { | |
| // Wrap the original class | |
| class NoHoverTile extends ctor { | |
| connectedCallback() { | |
| // Call original lifecycle, if it exists | |
| if (super.connectedCallback) { | |
| super.connectedCallback(); | |
| } | |
| // After setup, kill any hover handler it might use | |
| this.addEventListener('mouseenter', e => { | |
| e.stopImmediatePropagation(); | |
| }, true); | |
| } | |
| } | |
| return origDefine(name, NoHoverTile, options); | |
| } | |
| return origDefine(name, ctor, options); | |
| }; | |
| })(); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment