npm package discovery and stats viewer.

Discover Tips

  • General search

    [free text search, go nuts!]

  • Package details

    pkg:[package-name]

  • User packages

    @[username]

Sponsor

Optimize Toolset

I’ve always been into building performant and accessible sites, but lately I’ve been taking it extremely seriously. So much so that I’ve been building a tool to help me optimize and monitor the sites that I build to make sure that I’m making an attempt to offer the best experience to those who visit them. If you’re into performant, accessible and SEO friendly sites, you might like it too! You can check it out at Optimize Toolset.

About

Hi, 👋, I’m Ryan Hefner  and I built this site for me, and you! The goal of this site was to provide an easy way for me to check the stats on my npm packages, both for prioritizing issues and updates, and to give me a little kick in the pants to keep up on stuff.

As I was building it, I realized that I was actually using the tool to build the tool, and figured I might as well put this out there and hopefully others will find it to be a fast and useful way to search and browse npm packages as I have.

If you’re interested in other things I’m working on, follow me on Twitter or check out the open source projects I’ve been publishing on GitHub.

I am also working on a Twitter bot for this site to tweet the most popular, newest, random packages from npm. Please follow that account now and it will start sending out packages soon–ish.

Open Software & Tools

This site wouldn’t be possible without the immense generosity and tireless efforts from the people who make contributions to the world and share their work via open source initiatives. Thank you 🙏

© 2026 – Pkg Stats / Ryan Hefner

@capybearista/opencode-double-tap-timeline

v1.0.0

Published

Double-tap Escape key to open the timeline modal, inspired by Claude Code's /rewind feature

Downloads

395

Readme

opencode-double-tap-timeline


Why?

Inspired by Claude Code's double-tap-to-invoke-/rewind feature. Instead of typing /timeline or reaching for the mouse, just double-tap Escape while in a session to open the timeline modal instantly.

Philosophy: Extending OpenCode

OpenCode's TUI plugin system enables keyboard-driven UI extensions. This plugin hooks into the app slot to listen for Escape key presses globally, detects a double-tap within 800ms, and triggers the timeline command. It cleanly disposes of its timers on deactivation.

Architecture

src/index.ts
    └── tui hook
        ├── lifecycle.onDispose() — cleanup
        └── slots.register({ app() })
            └── useKeyboard() — Escape key listener
                └── double-tap detection (800ms window)
                    └── api.command.trigger("session.timeline")

Features

  • Global Escape key listener via the app slot — works regardless of which screen is active
  • 800ms double-tap window, matching Claude Code's behavior
  • Only triggers timeline when in a session with a valid session ID
  • Single Escape still works normally (closes modals, cancels operations)
  • Proper timer cleanup on plugin deactivation
  • Skips trigger if a dialog is already open

Install

Add the plugin to tui.json or tui.jsonc:

{
  "plugin": ["@capybearista/opencode-double-tap-timeline"]
}

You can also install it through the CLI:

opencode plugin -g @capybearista/opencode-double-tap-timeline    # global install
opencode plugin @capybearista/opencode-double-tap-timeline       # project-local install

Usage

  1. Open a session in OpenCode
  2. Double-tap Escape quickly (within 800ms)
  3. The timeline modal opens

Note: Hitting Escape two times in quick succession to interrupt a running prompt will also invoke the timeline modal. Hit Escape again to quickly exit.

Configuration

This plugin requires no manual configuration.

Troubleshooting

  • If double-tap doesn't work, ensure you're in a session screen (not the home screen)
  • If a dialog is open, the timeline won't trigger — close any open dialogs first
  • The plugin uses OpenTUI's useKeyboard hook, which requires @opentui/solid installed

Contributing

This package lives in the opencode-plugins monorepo.

  • Run bun run build, bun run typecheck, bun run lint, and bun test before opening a PR.
  • Keep the plugin focused on the double-tap timeline trigger.
  • Prefer small, direct changes.

Please open an issue or check for existing ones before creating a pull request.

License

MPL-2.0