fix(web,mobile): usage-limit recovery banner updates copy after reset passes #39889
Mergedcharlesbine(GitHub profile, opens in a new tab)merged 3 commits into
main fromrefs/pull/39889/headmerged by juliusmarminge View on GitHubgithub-actions[bot](GitHub profile, opens in a new tab) added labelsvouch:unvouched
tanstack-source added labelsbug
- @@ -192,4 +199,8 @@192199 {canSchedule ? (193200 <>194201 <RecoveryAction195- label={scheduled ? gt("Cancel auto-resume") : gt("Resume at reset")}202+ label={203+ scheduled204+ ? gt("Cancel auto-resume")205+ : resetPassed206+ ? gt("Resume now")@@ -175,4 +195,9 @@175195 return (176196 <span className="flex flex-wrap items-center gap-x-3 gap-y-1 px-1">177197 <InlineButton touchTarget="padded" disabled={pending} onClick={() => void toggle("resume")}>178- {pending ? gt("Saving...") : scheduled ? gt("Cancel auto-resume") : gt("Resume at reset")}198+ {pending199+ ? gt("Saving...")200+ : scheduled201+ ? gt("Cancel auto-resume")202+ : resetPassed203+ ? gt("Resume now")
juliusmarminge added labelstakeover:in-progress
Pushedb88faaf
- @@ -28,10 +28,17 @@2828 ] as const)("formats a same-day reset with the %s setting", (timestampFormat, expected) => {2929 using _now = vi.spyOn(Date, "now").mockReturnValue(stoppedAt.getTime());30- expect(bannerDescription(new Date(2026, 9, 20, 17, 30), timestampFormat)).toBe(expected);30+ expect(bannerItem(new Date(2026, 9, 20, 17, 30), timestampFormat).description).toBe(expected);3131 });32323333 it("names the day when the reset is tomorrow", () => {3434 using _now = vi.spyOn(Date, "now").mockReturnValue(stoppedAt.getTime());35- expect(bannerDescription(new Date(2026, 9, 21, 17, 30), "24-hour")).toBe(36- "Resets tomorrow at 17:30",37- );35+ expect(bannerItem(new Date(2026, 9, 21, 17, 30)).description).toBe("Resets tomorrow at 17:30");36+ });37+38+ it("uses past-tense copy after the reset time has passed", () => {39+ const resetAt = new Date(2026, 9, 20, 15, 0);40+ {41+ using _before = vi42+ .spyOn(Date, "now")43+ .mockReturnValue(new Date(2026, 9, 20, 14, 57).getTime());44+ expect(bannerItem(resetAt).description).toBe("Resets 15:00");
juliusmarminge added labelstakeover:ready
juliusmarminge removed labelstakeover:in-progress
juliusmarminge merged this8d37736
juliusmarminge closed this
juliusmarminge removed labelstakeover:ready
Sign in to join this conversation.












Walkthrough
Mobile and web usage-limit recovery notices now distinguish upcoming recovery times from reset times that have passed. The notices update their text and resume actions accordingly. Translations and tests cover the revised states.
Changes: Usage limit recovery notices
apps/mobile/src/features/threads/UsageLimitRecoveryCard.tsx,apps/mobile/src/features/threads/UsageLimitRecoveryCard.test.tsx,apps/mobile/src/i18n/translations/*apps/web/src/components/chat/UsageLimitRecoveryBanner.tsx,apps/web/src/components/chat/UsageLimitRecoveryBanner.test.tsx,apps/web/src/i18n/translations/*apps/web/src/components/ChatView.tsxEstimated code review effort: 3 (Moderate) | ~20 minutes
Change: Bug fix
Possibly related issues
pingdotgg/t3code#36405— The changes address the reported past-reset banner wording and resume action. The issue’s stated root cause, a replayed Claude adapter frame, is not addressed.Suggested reviewers:
maria-rcks,shivamhwp,juliusmarmingeMerge Risk:
Low · up to
b88faThe usage-limit recovery notices now update their wording after the reset time passes. In the narrow case where a later snooze is still active, "Resume now" may not resume immediately. A new test could also fail in unusual locale environments. Both are minor and bounded, so the change is low risk to merge.
Pre-merge checks:
4
Full details: Title check
Explanation
The title names the main change: the usage-limit recovery banner (web) and recovery card (mobile) now update their copy after the reset time passes. It follows the conventional commit form and matches the objectives and the file-level summaries, which cover the banner, card, ChatView hook, and translations.
Full details: Description check
Explanation
The description follows the template's sections: Problem, Change, Scope, and Verification. The Problem section states the stale future-tense copy and the missing live update. The Change section covers web, mobile, and i18n. Scope explains why no issue is linked. Verification lists the focused tests, the before/after failures, and the checks that could not run, including the missing Playwright tests and screenshots. The template asks for before/after screenshots for UI changes. The description does not include them and gives a reason, so this is a gap. The agent/model line is present, though its value is unusual. Overall the description is mostly complete.
Finishing Touches
Generate unit tests (beta)