Repository navigation
Align the cost history model scrollbar - #5116
soohanpark wants to merge 1 commit into
Conversation
|
🦞👀 Pull request received. I will update this pull request when review starts. ClawSweeper review completeClawSweeper finished reviewing this revision. The review result is being finalized. |
Codex Review Summary: ✅ CompletedThis comment shows the latest Codex review activity on this pull request.
ℹ️ About Codex in GitHubYour team has set up Codex to review pull requests in this repo. Reviews are triggered when you
Codex reacts with 👀 while any review is running, comments if it has suggestions, and reacts with 👍 once all reviews finish with no findings. |
|
Codex review: needs maintainer review before merge. What this changesExpand the cost-history model stack to the available width and add a native layout regression test. Example: A 320-point cost-history view displays five models with short names.
Review scores
ProductKind: Bug fix · Worth it: Yes · Fix scope: Complete Merge readiness✅ Ready for maintainer review This PR is a focused, correct layout fix that current main still needs; the added packaged-app screenshot clears the earlier proof blocker. Priority: P3 Before mergeNone. FindingsNone. Agent review detailsHow this fits togetherProvider daily usage enters a SwiftUI cost chart hosted in an AppKit submenu, which renders per-model costs and tokens in a bounded scrolling list. flowchart LR
A[Daily usage snapshot] --> B[Submenu controller]
B --> C[Menu hosting view]
C --> D[Cost history chart]
D --> E[Model detail stack]
E --> F[Scrollable model list]
Technical reviewBest possible solution: Keep the single width constraint and focused geometry regression in the existing chart owner. Do we have a high-confidence way to reproduce the issue? Current main leaves the model stack intrinsically sized, and the supplied before render demonstrates the short-name overflow case; this review did not execute target code. Is this the best way to solve the issue? The constraint fixes the layout directly at its existing owner while preserving scrolling, row heights, and data behavior. AGENTS.md: found and applied where relevant. Codex review notes: model internal, reasoning medium; reviewed against 1f6da9bec444. Provenance checked
TestingProof path: shipped entry point. SecurityNone. EvidenceWhat I checked:
Likely related people:
Preflight sourceSource unknown. Source comparison at the observed PR snapshot only. Completion is self-reported; body, policy, tests, execution, and report bytes are not verified. Review metrics
LabelsLabel changes:
Label justifications:
Rating scale6/6 🦀 challenger crab · 5/6 🦞 diamond lobster · 4/6 🐚 platinum hermit · 3/6 🦐 gold shrimp · 2/6 🦪 silver shellfish · 1/6 🧂 unranked krab. Overall follows the weaker of proof and patch quality; ✨ marks media proof (a screenshot, video, or linked artifact) that directly shows the changed behavior. WorkflowClawSweeper edits this one comment on every review. Comment HistoryReview history (1 earlier review cycle)
Reviewed November 18, 2026, 10:15 AM ET / 15:15 UTC (Revision 2). |
|
@clawsweeper re-review |
|
🦞👀 Re-review progress:
|
When a day's cost breakdown exceeds four rows, short model names and values can shrink the list to its intrinsic width. That places its scrollbar inside the submenu and can squeeze the token count.
Give the model-row stack the full available width so the scrollbar lines up with the submenu's trailing content edge. Add a regression that measures the native scroll view inside the hosted cost menu.
Verification
make checkpassed. The local SwiftPM test run was blocked by existing type-check errors inSpendDashboardModelTests.swiftandPiSessionCostBreakdownTests.swiftunder Xcode 26.4. The regression's geometry assertions were exercised directly against both revisions.Packaged app proof
Built and launched the signed debug bundle from
a6ca9c80fon macOS 26.5.2. I opened CodexBar menu bar icon → Cost with local synthetic session history containing seven models on the selected day. The live submenu shows the scrollbar aligned with the trailing content edge and the full token values beside each visible model.The proof instance uses separate preferences, with network and Keychain access disabled. It has no live quota account. The capture masks the desktop outside the menu windows and the debug status item.
Before and after
Both renders use synthetic usage and visible scrollbars.