Skip to content

Desktop: the chat header shows context use as a bar, not token numbers - #344

Merged
Khoality-dev merged 1 commit into
mainfrom
feat/343-context-usage-bar
Sep 28, 2026
Merged

Khoality-dev merged 1 commit into
mainfrom
feat/343-context-usage-bar

Conversation

@Khoality-dev

Copy link
Copy Markdown
Owner

Closes #343

What changed

  • Header: the chat header's "1,234 / 8,192 tokens" is now a small progress bar, ContextUsageBar, showing the share of the context used.
  • Warnings: the bar keeps the old warnings, orange past 80% and red past 90%.
  • Hover: it says the percentage ("Context 25% used"), which is also its accessible name.
  • Exact numbers: they stay in the context breakdown dialog beside it, unchanged.
  • Docs: updated in docs/chat.md.

Tests

New ContextUsageBar.test.tsx, run first against the missing component and failing, then 3/3. It checks:

  • that the bar shows the share with no token numbers;
  • the warning and full levels;
  • that it never runs past 100% when the context overflows.

npm run typecheck is clean. I also checked the look with one screenshot of the header in the built app.

🤖 Generated with Claude Code

https://claude.ai/code/session_014L9pxjp1MTSJe5DZG9A9sv

…numbers (#343)

"1,234 / 8,192 tokens" becomes a small bar for the share of the context
used. It warns as it fills, orange past 80% and red past 90% as the
numbers did, and says the percentage on hover. The exact counts stay in
the context breakdown beside it.

Co-Authored-By: Claude Opus 5.5 (1M context) <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_014L9pxjp1MTSJe5DZG9A9sv
@Khoality-dev
Khoality-dev merged commit fd0468f into main Sep 28, 2026
3 checks passed
@Khoality-dev
Khoality-dev deleted the feat/343-context-usage-bar branch September 28, 2026 07:13
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.

Desktop: the chat header shows context use as a progress bar, not token numbers

2 participants