Old Reddit Auto Expander

Automatically expands posts, optionally manages collapsed comments, and controls video autoplay

目前为 2025-03-25 提交的版本。查看 最新版本

作者
TwilightAlicorn
评分
0 0 0
版本
3.2
创建于
2024-10-22
更新于
2025-03-25
大小
27.2 KB
许可证
MIT
适用于

🔄 Old Reddit Auto Expander

A little userscript that automatically expands stuff on old.reddit.com, compatible with Reddit Enhancement Suite.

🔍 About

This userscript automatically expands these things on old.reddit.com:

  • Text posts
  • Images and videos
  • Crossposts
  • Collapsed comments (Disabled by default)

It can also disable auto-playing videos (set manageVideoPlayback to true to enable this).

🚀 Installation

  1. Get any userscript engine (currently this userscript is tested on Violentmonkey, but if you find any bugs on any other engine please report it)
  2. Click here to install the script
  3. Done!

🛠️ Configuration

Just edit these values at the top of the script:

const CONFIG = {
    // Set to true to automatically expand collapsed comments
    expandComments: false,

    // Set to true to manage video autoplay and pause when scrolling
    // Only enable this if you're using Reddit's internal player! If you use other players (like RES, that has its internal player), configure them separately.
    manageVideoPlayback: false,

    // [manageVideoPlayback] Video visibility threshold (0.0 to 1.0)
    videoVisibilityThreshold: 0.1,

    // [manageVideoPlayback] Advanced video control settings
    pauseCheckInterval: 1000,        // Check ALL videos every X milliseconds
    videoWatchDuration: 5000,        // Keep watching new videos closely for this long
    videoWatcherInterval: 300,       // Extra frequent checks for videos that just appeared
    respectUserInteraction: true,    // Don't interfere with videos the user has played manually
    pauseWhenOutOfView: true,        // Pause all videos when scrolled out of view, even user-played ones
    gracePeriodAfterPlay: 500,       // Grace period (ms) after user plays video to prevent immediate re-pause

    // Interval in ms for checking content to expand
    checkInterval: 1000,

    // Maximum attempts to find collapsed items before giving up
    maxAttempts: 10,

    // Enable logging
    enableLogging: false
};

💖 Credits

Made with the help of Claude 3.5/3.7 Sonnet and OpenAI o3-mini

📝 License

MIT License

QingJ © 2025

镜像随时可能失效,请加Q群300939539或关注我们的公众号极客氢云获取最新地址