Summary
Extend the shared usage metric view model so menu rows and provider detail rows can carry forecast information and forecast copy without overloading pace fields.
This issue consumes the projection contract and exposes forecast data to shared UI models. It must not compute forecast itself or decide whether forecast is shown on real rows.
Scope
- Extend
UsageMenuCardView.Model.Metric and any shared row structs so they can carry:
- raw forecast percent for display
- overflow state
- preformatted or format-ready forecast text
- Add forecast text formatting helpers only.
- Consume the projection contract produced by
#6; do not derive forecast from RateWindow here.
- Keep forecast semantics clearly separate from existing pace labels (
On pace, X% in deficit, Runs out in ...).
Non-goals
- No forecast math from
RateWindow.
- No provider gating or row visibility policy.
- No end-to-end wiring into live usage rows.
Files likely involved
Sources/CodexBar/MenuCardView.swift
Sources/CodexBar/PreferencesProviderDetailView.swift
Sources/CodexBar/UsagePaceText.swift or a nearby formatter helper
Acceptance Criteria
- Shared metric/view-model code can represent forecast independently of pace.
- Forecast formatting preserves values over
100% in text.
- This issue does not compute forecast math from
RateWindow.
- This issue does not decide when forecast appears on a real row; that remains in
#3.
Summary
Extend the shared usage metric view model so menu rows and provider detail rows can carry forecast information and forecast copy without overloading pace fields.
This issue consumes the projection contract and exposes forecast data to shared UI models. It must not compute forecast itself or decide whether forecast is shown on real rows.
Scope
UsageMenuCardView.Model.Metricand any shared row structs so they can carry:#6; do not derive forecast fromRateWindowhere.On pace,X% in deficit,Runs out in ...).Non-goals
RateWindow.Files likely involved
Sources/CodexBar/MenuCardView.swiftSources/CodexBar/PreferencesProviderDetailView.swiftSources/CodexBar/UsagePaceText.swiftor a nearby formatter helperAcceptance Criteria
100%in text.RateWindow.#3.