Skip to content

feat(web,mobile): choose whether usage meters count up or down - #27363

Open
davisonio wants to merge 1 commit into
pingdotgg:mainfrom
davisonio:usage-used-or-left
Open

davisonio wants to merge 1 commit into
pingdotgg:mainfrom
davisonio:usage-used-or-left

Conversation

@davisonio

@davisonio davisonio commented Oct 30, 2026 •

Copy link
Copy Markdown
Contributor

Adds Settings → Appearance → Usage meters: % left (the default, unchanged) or % used. On mobile it's a Show % used switch under Appearance.

Usage limits only count down today. People arrive with different habits: Claude Code counts up ("Current session: 8% used") and Codex counts down ("5h limit: 28% left"). "Usage" names consumption, so counting up to 100% at the limit reads naturally for many people. The thread details Context row now fills up as context is used (#27892), so with "% used" every meter in the card counts the same way. This PR keeps "% left" as the default.

Scope. This is a focused configuration option for an established capability: the existing usage limit meters. The option only changes which way they count. Same data, same windows, same warning points, no new workflow, no server change, and the default stays "% left". Context window meters are not affected; they always fill up.

In "% used" mode

  • Limits, /usage-limits, the thread details limit rows and the iOS and Android widgets read "N% used", and bars fill as usage grows.
  • The pace tick marks time elapsed, the reset hatch covers the used fill, and the refill hint reads "↻ −19%".
  • Warning colours still change at the same real points.

The setting is client-only (web client settings, desktop settings file, mobile preferences) and never reaches the server, so there is no version skew. Older stored settings decode to "% left", and a widget snapshot published by an older app shows "% left" until the app republishes it.

How I checked it. vp run dev on macOS with real Claude Max and Codex accounts. Web in the T3 browser panel, iOS on an iPhone simulator (iOS 27), Android on a Pixel 9 emulator (Android 16). On each, I flipped the setting, then opened Usage → Limits, sent /usage-limits in a Claude thread, and checked the widget (iOS widget gallery, Android home screen). After merging current main, I checked the thread details limit rows again on web in both modes ("Monthly: 100% used" with a full bar, "Monthly: 0% left" with an empty one). In "% left" mode everything matches main; in "% used" mode every label, bar, pace tick and hatch counts up as listed above.

vp run check:changed upstream/main passes: format, lint, knip, typecheck of affected packages, 149 tests in 8 files, and the React compiler check. The tests cover the meter, pace and hatch helpers in both directions, the settings default and unknown values, the widget snapshot and settings search.

Not checked: the Electron desktop shell (it runs the same web UI and stores the value through ClientSettingsSchema, covered by the schema test) and the iOS lock screen widget family.

Before / after (web)

limits before

limits after

iOS: Limits before and after, the switch, /usage-limits, and the widget

Android: Limits before and after, the switch, /usage-limits, and the widget

Built with Claude Opus 5.5 (Claude Code) in T3 Code.

Loading
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:L 100-499 changed lines (additions + deletions). vouch:unvouched PR author is not yet trusted in the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants