Skip to content

menubar: fix Codex plan tab copy, show model-scoped weekly limits (Fable)#598

Merged
iamtoruk merged 1 commit into
mainfrom
fix/menubar-plan-quota
Jul 2, 2026
Merged

menubar: fix Codex plan tab copy, show model-scoped weekly limits (Fable)#598
iamtoruk merged 1 commit into
mainfrom
fix/menubar-plan-quota

Conversation

@iamtoruk

@iamtoruk iamtoruk commented Jul 2, 2026

Copy link
Copy Markdown
Member

What

Two fixes in the menubar plan/quota views.

Codex plan tab showed Claude wording. The empty states (connect, no credentials, reconnect) were shared views with hardcoded Claude copy, so the Codex tab prompted "Connect Claude subscription". The no-credentials "Try Again" button also always re-ran the Claude bootstrap, even on the Codex tab. The three views now take their title, message and retry action from the call site; Codex gets ChatGPT/Codex wording and the right bootstrap.

Fable quota was missing. The oauth usage endpoint now returns a limits array with model-scoped weekly buckets (claude.ai shows this as the "Fable" weekly bar). CodeBurn only read the named windows, so the bucket never appeared. The parser now maps weekly_scoped entries by their scope.model.display_name, so the Claude hover popover gets a "Weekly · Fable" row and the Plan tab a "7-day Fable" bar with the usual pace projection. Future model buckets show up without a client change.

Testing

  • swift test: 70 tests pass, including a new suite for the usage parser fed with the captured live response shape (scoped bucket parsed, named windows unaffected, old responses without limits still decode, session/weekly_all not duplicated).
  • swift build clean.
  • Verified against the live endpoint: the response carries weekly_scoped / Fable at 94% matching the claude.ai usage page.

…ekly limits

The Codex plan tab reused the shared connect, no-credentials and reconnect
views whose copy was hardcoded for Claude, so the Codex tab showed Connect
Claude subscription. Worse, the no-credentials Try Again button always
re-ran the Claude bootstrap. The three views now take title, message and
action from the call site.

The oauth usage endpoint gained a limits array carrying model-scoped
weekly buckets (currently Fable). Parse weekly_scoped entries generically
by their display name and show them in the Claude hover popover and the
plan tab, with the usual pace projection. Parser now has test coverage
using the captured live response shape.
@iamtoruk iamtoruk merged commit 8e55b5f into main Jul 2, 2026
3 checks passed
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.

1 participant