feat(ui): Model Usage pilot on the shared design system (U5 B2)#443
Conversation
Fifth and final B2 slice — closes the batch. Reuses the generic AnalyticsDashboard (KPIs + trend charts + BarList + rail) with no new libs/ui component: - Electron: pure model-usage-ui mappers (shortModelName strips the provider prefix + date suffix; buildModelKpis/Charts/BarLists/Sections from ModelUsageSummary + ModelUsageTrendPoint, reusing analytics-ui's formatCount/formatCost/shortDate/sampleLabels; 8 tests) + ModelUsagePilotView over getModelUsageSummary + getModelUsageTrends. Mounted as "Model Usage (new UI)". - i18n: model-usage:modelUsagePilot.* keys (en+fr), navigation.modelUsageNext; also imports the Cpu icon for the nav item. The dashboard shows token/cost trend charts + AI-call/token/cost/model KPIs with sparklines, a "tokens by model" BarList ranked by usage, and an input/output token-split + provider-count rail card. This exercises all four AnalyticsDashboard slots (kpis/charts/barLists/sections) at once, confirming the generic screen serves every B2 view. Co-Authored-By: Claude Fable 5 <noreply@anthropic.com>
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
|
Warning Review limit reached
Next review available in: 32 minutes Enable usage-based reviews in Billing to review now. Otherwise, wait until the next included review is available. How can I continue?After more reviews become available, a review can be triggered using the To avoid repeated limits, reduce automatic review volume by pausing incremental auto-reviews earlier, using label-based review opt-in, excluding WIP or generated PR titles, or requesting reviews manually when the PR is ready. If your team needs uninterrupted high-volume reviews, an organization admin can enable usage-based reviews. How do review limits work?CodeRabbit enforces per-developer PR review limits for each organization. Most developers receive the normal plan review availability. For paid Pro and Pro+ PR reviews, CodeRabbit uses adaptive limits for sustained high-volume activity. When a developer's recent PR review activity reaches the 95th percentile or higher among CodeRabbit users, additional reviews become available more gradually as earlier reviews age out of the rolling window. Please refer docs for additional details. Review details⚙️ Run configurationConfiguration used: Path: .coderabbit.yaml Review profile: ASSERTIVE Plan: Pro Plus Run ID: 📒 Files selected for processing (9)
✨ Finishing Touches🧪 Generate unit tests (beta)
Thanks for using CodeRabbit! It's free for OSS, and your support helps us grow. If you like it, consider giving us a shout-out. Comment |
|


Summary
Fifth and final B2 slice — closes the "Analytics & usage" batch. Reuses the generic
AnalyticsDashboardwith no new libs/ui component, and exercises all four of its slots (KPIs / charts / barLists / sections) at once.Electron
model-usage-uimappers:shortModelName(strips provider prefix + date suffix so bars read as short model names);buildModelKpis/buildModelCharts/buildModelBarLists/buildModelSectionsfromModelUsageSummary+ModelUsageTrendPoint, reusinganalytics-ui'sformatCount/formatCost/shortDate/sampleLabels. 8 tests.ModelUsagePilotViewovergetModelUsageSummary+getModelUsageTrends, mounted as "Model Usage (new UI)" beside the legacy P5 dashboard (export flow stays there).i18n
model-usage:modelUsagePilot.*(en+fr),navigation:items.modelUsageNext; adds theCpunav icon.What it renders
Verification
libs/ui+ Electron tsc clean; i18n parity confirmed (22 keys en+fr); no nested ternaries. No new UI component —AnalyticsDashboard(verified through feat(ui): Analytics dashboard pilot on the shared design system (U5 B2) #439/feat(ui): Merge Analytics pilot on the shared design system (U5 B2) #442, all four slots covered by its stories) renders it.B2 done
All four B2 screens (Analytics, Productivity, Merge Analytics, Model Usage) now pilot on the shared design system, built on two new primitives (chart set + BarList) and one generic
AnalyticsDashboard. That's 10 of 24 sidebar views migrated.Next
B3 "Extension & infra" (Agent Tools, Plugins, Scheduler, Webhooks, Feedback) — pending your call on whether B5 GitLab is in scope.
🤖 Generated with Claude Code