{"_id":"@alexandroheredia/opencode-last-activity","_rev":"2-f5d5b876f0737a4b740fdc03b3aa670c","name":"@alexandroheredia/opencode-last-activity","dist-tags":{"latest":"0.1.1"},"versions":{"0.1.0":{"name":"@alexandroheredia/opencode-last-activity","version":"0.1.0","keywords":["opencode","opencode-plugin","tui","activity","status"],"author":{"name":"Alexandro"},"license":"MIT","_id":"@alexandroheredia/opencode-last-activity@0.1.0","maintainers":[{"name":"ahere","email":"npm@heredia.fi"}],"homepage":"https://github.com/alexandroheredia/opencode-last-activity#readme","bugs":{"url":"https://github.com/alexandroheredia/opencode-last-activity/issues"},"dist":{"shasum":"bc506007bd6c346dc04d01ed5bdd35a4049d0188","tarball":"https://registry.npmjs.org/@alexandroheredia/opencode-last-activity/-/opencode-last-activity-0.1.0.tgz","fileCount":4,"integrity":"sha512-PMg4y6Ot3e2ZXzNGksUq8P8P5YWovJFLMudUCWgORWlNNLo/TYFAFeDh8mMUVPqBweceC1ZrYDli+x8O9ph2mw==","signatures":[{"sig":"MEUCIAn7t4i96gZpXy+uRyX/xBuKFcRJzN887MHzcEuattpUAiEAjyJkqwENNSA0WtzrUcCzeGhXxA3xu1eQO0K6zDPwLBM=","keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U"}],"unpackedSize":12090},"type":"module","$schema":"https://json.schemastore.org/package.json","engines":{"node":">=20","opencode":">=1.15.0"},"exports":{"./tui":{"config":{"compact":false,"activeWindowMs":5000,"stalledWindowMs":60000},"import":"./src/tui.tsx"}},"gitHead":"72d2b5dc4c4bd7e9217c9750de95c093d6fc7448","scripts":{"build":"tsc --noEmit","typecheck":"tsc --noEmit","prepublishOnly":"npm run typecheck"},"_npmUser":{"name":"ahere","email":"npm@heredia.fi"},"repository":{"url":"git+https://github.com/alexandroheredia/opencode-last-activity.git","type":"git"},"_npmVersion":"11.12.1","description":"OpenCode TUI plugin that shows relative last-activity status for the current session.","directories":{},"_nodeVersion":"26.0.0","dependencies":{"solid-js":"^1.9.12","@opentui/solid":"^0.2.15","@opencode-ai/plugin":"^1.15.10"},"publishConfig":{"access":"public"},"_hasShrinkwrap":false,"devDependencies":{"typescript":"^5.8.3","@types/node":"^22.10.2"},"_npmOperationalInternal":{"tmp":"tmp/opencode-last-activity_0.1.0_1779836147571_0.028964288043452635","host":"s3://npm-registry-packages-npm-production"}},"0.1.1":{"$schema":"https://json.schemastore.org/package.json","name":"@alexandroheredia/opencode-last-activity","version":"0.1.1","description":"OpenCode TUI plugin that shows relative last-activity status for the current session.","author":{"name":"Alexandro"},"license":"MIT","type":"module","repository":{"type":"git","url":"git+https://github.com/alexandroheredia/opencode-last-activity.git"},"homepage":"https://github.com/alexandroheredia/opencode-last-activity#readme","bugs":{"url":"https://github.com/alexandroheredia/opencode-last-activity/issues"},"publishConfig":{"access":"public"},"exports":{"./tui":{"import":"./src/tui.tsx","config":{"compact":false,"activeWindowMs":5000,"inactivityNoticeMs":30000,"stalledWindowMs":60000,"visibility":"always"}}},"engines":{"node":">=20","opencode":">=1.18.0"},"scripts":{"typecheck":"tsc --noEmit","build":"tsc --noEmit","prepublishOnly":"npm run typecheck"},"keywords":["opencode","opencode-plugin","tui","activity","status"],"dependencies":{"@opencode-ai/plugin":"^1.18.16","@opentui/core":"^0.4.5","@opentui/solid":"^0.4.5","solid-js":"^1.9.12"},"devDependencies":{"@types/node":"^22.10.2","typescript":"^5.8.3"},"gitHead":"398b4c046f75127aee8563a1070e7b259f704892","_id":"@alexandroheredia/opencode-last-activity@0.1.1","_nodeVersion":"26.0.0","_npmVersion":"11.12.1","dist":{"integrity":"sha512-1G6YeE8txExcaxDT0xb2CPZEukZM4Ev1/R9wkU3MVOC6kF4URF2mp4P7UbLlFqmFSXGlBbiP5rxXECmD8NrGIA==","shasum":"070b0d89b36b602cacd273e3bae3c491d2a29339","tarball":"https://registry.npmjs.org/@alexandroheredia/opencode-last-activity/-/opencode-last-activity-0.1.1.tgz","fileCount":4,"unpackedSize":15121,"signatures":[{"keyid":"SHA256:DhQ8wR5APBvFHLF/+Tc+AYvPOdTpcIDqOhxsBHRwC7U","sig":"MEUCIDjAOs3qI7FbNVZHoIMfTJsLC8AShtkRqzMV6N/ucOg6AiEAoII/7auuLZFsy4DFBYhhHU1TM7Sv0x1KbLOxcmxEuCQ="}]},"_npmUser":{"name":"ahere","email":"npm@heredia.fi"},"directories":{},"maintainers":[{"name":"ahere","email":"npm@heredia.fi"}],"_npmOperationalInternal":{"host":"s3://npm-registry-packages-npm-production","tmp":"tmp/opencode-last-activity_0.1.1_1786564243073_0.9753038311885405"},"_hasShrinkwrap":false}},"time":{"created":"2026-05-26T22:55:47.349Z","modified":"2026-08-12T19:50:43.415Z","0.1.0":"2026-05-26T22:55:47.714Z","0.1.1":"2026-08-12T19:50:43.210Z"},"bugs":{"url":"https://github.com/alexandroheredia/opencode-last-activity/issues"},"author":{"name":"Alexandro"},"license":"MIT","homepage":"https://github.com/alexandroheredia/opencode-last-activity#readme","keywords":["opencode","opencode-plugin","tui","activity","status"],"repository":{"type":"git","url":"git+https://github.com/alexandroheredia/opencode-last-activity.git"},"description":"OpenCode TUI plugin that shows relative last-activity status for the current session.","maintainers":[{"name":"ahere","email":"npm@heredia.fi"}],"readme":"# opencode-last-activity\n\nOpenCode TUI plugin that shows a relative last-activity indicator in `session_prompt_right` so you can tell whether the current session is active, waiting, retrying, or possibly stalled.\n\n## Demo\n\nhttps://github.com/user-attachments/assets/8dccc64a-ed73-4582-b981-beead5537dc5\n\n## Features\n\n- shows `active now` while work is happening\n- shows `last activity 8s ago` when the session is idle\n- shows `waiting on permission` and `waiting on question` when input is blocked\n- shows `possibly stalled 2m ago` when the session stays busy without recent activity\n- optional inactivity-only mode that stays hidden until the session goes quiet\n- optional compact mode for tighter prompt layouts\n\n## Install\n\nInstall the package with OpenCode:\n\n```sh\nopencode plugin @alexandroheredia/opencode-last-activity\n```\n\nThen quit and restart OpenCode.\n\n## Manual Config\n\nIf you prefer to edit `tui.json` directly:\n\n```json\n{\n  \"$schema\": \"https://opencode.ai/tui.json\",\n  \"plugin\": [\n    [\n      \"@alexandroheredia/opencode-last-activity\",\n      {\n        \"compact\": false,\n        \"activeWindowMs\": 5000,\n        \"inactivityNoticeMs\": 30000,\n        \"stalledWindowMs\": 60000,\n        \"visibility\": \"always\"\n      }\n    ]\n  ]\n}\n```\n\n## Options\n\n| Option               | Type                                   | Default    | Description                                                           |\n| -------------------- | -------------------------------------- | ---------- | --------------------------------------------------------------------- |\n| `compact`            | `boolean`                              | `false`    | Uses shorter labels such as `active`, `2m ago`, and `stalled 2m ago`. |\n| `visibility`         | `\"always\" \\| \"inactivity-only\"`     | `\"always\"` | Controls whether the indicator is always visible or only after inactivity. |\n| `activeWindowMs`     | `number`                               | `5000`     | Age threshold that still counts as active.                            |\n| `inactivityNoticeMs` | `number`                               | `30000`    | In inactivity-only mode, how long to wait before showing quiet sessions. |\n| `stalledWindowMs`    | `number`                               | `60000`    | Age threshold for switching a busy session to stalled.                |\n\nIf `inactivityNoticeMs` is set lower than `activeWindowMs`, the plugin raises it to match the active window. If `stalledWindowMs` is set lower than `inactivityNoticeMs`, the plugin pushes it above the inactivity threshold so labels stay sane.\n\n## Inactivity-Only Example\n\nIf you only want to see the indicator when OpenCode has gone quiet for a while:\n\n```json\n{\n  \"$schema\": \"https://opencode.ai/tui.json\",\n  \"plugin\": [\n    [\n      \"@alexandroheredia/opencode-last-activity\",\n      {\n        \"visibility\": \"inactivity-only\",\n        \"inactivityNoticeMs\": 30000,\n        \"stalledWindowMs\": 60000\n      }\n    ]\n  ]\n}\n```\n\nIn this mode, active sessions stay hidden until there has been no output for at least `inactivityNoticeMs`. Permission prompts, questions, and retries still show immediately.\n\n## Label Examples\n\nFull mode:\n\n- `active now`\n- `last activity just now`\n- `waiting on permission`\n- `waiting on question`\n- `retrying 12s ago`\n- `possibly stalled 3m ago`\n\nCompact mode:\n\n- `active`\n- `just now`\n- `permission`\n- `question`\n- `retry 12s ago`\n- `stalled 3m ago`\n\n## Contributing\n\nDevelopment setup and local testing notes live in [`CONTRIBUTING.md`](./CONTRIBUTING.md).\n","readmeFilename":"README.md"}