Skip to content

feat: status bar utilization sparkline and ${bar5h}/${bar7d} placeholders - #41

Open
long-910 wants to merge 1 commit into
mainfrom
claude/feat-statusbar-sparkline-y9ahrw
Open

feat: status bar utilization sparkline and ${bar5h}/${bar7d} placeholders#41
long-910 wants to merge 1 commit into
mainfrom
claude/feat-statusbar-sparkline-y9ahrw

Conversation

@long-910

@long-910 long-910 commented Jul 7, 2026

Copy link
Copy Markdown
Owner

Summary

Adds a compact utilization meter to the status bar so remaining 5h capacity is readable at a glance without opening the dashboard:

🤖 5h:▰▰▰▱▱ 62% 7d:41%

Based on main; independent of the other open PRs.

Changes

  • buildUtilizationBar(utilization, width = 5) in statusBar.ts — 5-cell meter using /, clamped to [0, 1], rounded to the nearest cell.
  • New setting claudeStatus.statusBar.showSparkline (boolean, default false — opt-in so existing users' labels don't change). When enabled, the meter renders next to the 5h percentage in percent mode (Claude.ai provider only; cost mode and denied state are unchanged).
  • Custom status bar formats gain ${bar5h} / ${bar7d} placeholders, e.g. "claudeStatus.statusBar.format": "${bar5h} ${usage5h}%".
  • l10n: setting description in EN / JA / ZH.
  • Docs: docs/SETTINGS.md (schema + placeholder table), README settings tables (EN / JA / ZH), CHANGELOG.

Tests

New buildUtilizationBar suite: empty/partial/full rendering, nearest-cell rounding, out-of-range clamping, custom width. npm run lint ✅, npm run compile ✅. The suite lives in statusBar.test.ts (extension-host) — please rely on CI, since @vscode/test-electron cannot download VS Code in this sandbox.

🤖 Generated with Claude Code

https://claude.ai/code/session_012ZLCLQeudf1LQBnBSyyr4f


Generated by Claude Code

Add a compact utilization meter so remaining 5h capacity is visible at
a glance without opening the dashboard.

- buildUtilizationBar(): 5-cell meter using U+25B0/U+25B1 with clamping
- New setting claudeStatus.statusBar.showSparkline (default false) shows
  the meter next to the 5h percentage in percent mode (Claude.ai only)
- Custom formats gain ${bar5h} / ${bar7d} placeholders
- l10n: EN/JA/ZH setting description
- Docs: SETTINGS.md schema + placeholder table, README settings tables
  (EN/JA/ZH), CHANGELOG
- Tests: boundary/rounding/clamping/width cases

Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_012ZLCLQeudf1LQBnBSyyr4f
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants