Reddit Snap Scroll

Keyboard navigation (W/S), highlight, open (E), hide previous post

K instalaci tototo skriptu si budete muset nainstalovat rozšíření jako Tampermonkey, Greasemonkey nebo Violentmonkey.

You will need to install an extension such as Tampermonkey to install this script.

K instalaci tohoto skriptu si budete muset nainstalovat rozšíření jako Tampermonkey nebo Violentmonkey.

K instalaci tohoto skriptu si budete muset nainstalovat rozšíření jako Tampermonkey nebo Userscripts.

You will need to install an extension such as Tampermonkey to install this script.

K instalaci tohoto skriptu si budete muset nainstalovat manažer uživatelských skriptů.

(Už mám manažer uživatelských skriptů, nechte mě ho nainstalovat!)

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install an extension such as Stylus to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

You will need to install a user style manager extension to install this style.

(Už mám manažer uživatelských stylů, nechte mě ho nainstalovat!)

Autor
Farid Ismailov
Denně instalací
0
Celkem instalací
3
Hodnocení
0 0 0
Verze
2025.09.04.3
Vytvořeno
04. 09. 2025
Aktualizováno
04. 09. 2025
Size
17,5 KB
Licence
Personal
Spustit na
  • Script name: reddit-snap-scroll.user.js
  • Scope: Enhances browsing on Reddit with keyboard navigation, focus highlight, and optional post hiding.
  • Key features:
    • Keyboard navigation: W = previous post, S = next post
    • Open post: E (also works on RU layout: У) opens the focused post in a background tab
    • Carousel control: A = previous slide, D = next slide (where applicable)
    • Highlight: The focused article is visually outlined
    • Hide previous on S: When moving down, the previously focused post is hidden
  • How hiding works:
    • Primary: calls Reddit’s GraphQL endpoint (/svc/shreddit/graphql) with the existing csrf_token cookie and postId (t3_*) extracted from the DOM
    • Fallback: opens the post overflow menu and clicks “Hide” (handles Shadow DOM and localized labels)
  • Installation:
    • Install Tampermonkey
    • Add the script reddit-snap-scroll.user.js to Tampermonkey and enable it
    • Open Reddit and use W/S to navigate
  • Configuration (inside script):
    • HIDE_PREVIOUS_ON_NEXT: hide the previously focused post on S (enabled)
    • AUTO_HIDE_ENABLED: auto-hide based on scrolling (disabled by default)
    • You can adjust highlight style and center offset if needed
  • Compatibility:
    • Designed for the new Reddit UI (shreddit-* components)
    • Requires being logged in for hiding to work (uses your existing cookies)
  • Privacy and safety:
    • Uses only your browser session and Reddit’s own endpoints
    • No data is sent to third parties; no storage beyond in-memory flags
  • Troubleshooting:
    • Ensure you are on new Reddit, logged in, and have a csrf_token cookie
    • If “Hide” text is localized, the script already matches common variants; report unusual labels to refine
    • If nothing hides on S, check the Tampermonkey console for errors and refresh the page