Skip to content

fix(web): remember usage page selection - #10189

Open
extoci wants to merge 1 commit into
pingdotgg:mainfrom
extoci:t3code/remember-usage-page-selection
Open

fix(web): remember usage page selection#10189
extoci wants to merge 1 commit into
pingdotgg:mainfrom
extoci:t3code/remember-usage-page-selection

Conversation

@extoci

@extoci extoci commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

The Usage page forgot the selected metric and time range whenever you navigated away.

This persists both choices in browser storage so returning to Usage restores the last view. This now lets people use the Usage page to quickly view their Usage Limits without too many clicks.

Implemented with GPT 6 in T3 Code with the Codex harness.

Note

Persist UsagePage metric and window selections in local storage

  • UsagePage now restores the selected usage metric and reporting period from persisted preferences on mount, falling back to defaults when no preference exists.
  • Added isUsageWindowDays type guard and a schema restricting stored metric and window-period values to configured options.
  • selectWindow and selectMetric handlers now write through the useLocalStorage preference setter; invalid window values are ignored.
  • Tests mock useLocalStorage to supply metric and window preferences to UsagePage.

Macroscope summarized 4c0d6b0.

@cursor

cursor Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Bugbot is paused — on-demand spend limit reached

Bugbot uses usage-based billing for this team and has hit its on-demand spend limit.

A team admin can raise the spend limit in the Cursor dashboard, or wait for the next billing cycle to continue.

@github-actions github-actions Bot added vouch:trusted PR author is trusted by repo permissions or the VOUCHED list. size:M 30-99 changed lines (additions + deletions). labels Sep 5, 2026
@macroscopeapp

macroscopeapp Bot commented Sep 5, 2026

Copy link
Copy Markdown
Contributor

Approvability

Verdict: Approved at f70c64a

Macroscope's review found this PR approvable — This is a focused Usage page fix that persists user-selected metric and time-window options while preserving the existing defaults and supported query behavior. The production impact is limited to local preference storage and page initialization, with no broader API, infrastructure, security, or billing changes.

You can add or adjust custom eligibility rules. Learn more.

@extoci
extoci force-pushed the t3code/remember-usage-page-selection branch from f70c64a to 4c0d6b0 Compare September 5, 2026 19:33
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

size:M 30-99 changed lines (additions + deletions). vouch:trusted PR author is trusted by repo permissions or the VOUCHED list.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant