Skip to content

Design and build WidgetKit usage glance #6

@cbusillo

Description

@cbusillo

Objective

Design and build the beautiful macOS WidgetKit glance surface for Context Panel.

Finish Line

The widget presents multi-provider, multi-account usage status with compact visualizations that make remaining capacity, reset time, and degraded/stale states easy to understand at a glance.

Current Status

State: Large widget layout was tightened after live crop review. It now fits in the visible widget area, leads with OpenAI weekly as the primary signal, keeps 5-hour as a secondary guardrail, uses a compact provider strip, and shows four key main-limit rows without clipping. Commit gate and diff check pass.
Next action: Add a reset-aware capacity/runway forecast model so weekly OpenAI decisions are based on per-account reset timing rather than simple pooled remaining.
Blocked by: Need product decision on exact wording for accounts with staggered reset times, but implementation can start with simulation semantics.
Last verified: 2026-05-07.

Scope

  • WidgetKit extension target.
  • Small/medium/large layout strategy as appropriate for macOS.
  • Provider/account grouping.
  • Compact charts: rings, bars, sparklines, reset countdowns, or other suitable widgets.
  • Stale/error/unknown states.
  • Tap target/deep-link behavior into app details.

Acceptance Criteria

  • Widget renders from local normalized snapshots without network work in the extension.
  • Visual states are legible in supported sizes and macOS appearances.
  • Empty/setup-needed state opens the app setup path.
  • Screenshots or visual evidence are attached to the implementation PR.

Relationships

Validation

  • scripts/commit-gate.sh passed locally with 43 tests.
  • swift build compiled the ContextPanelWidget SwiftPM target.
  • Widget snapshot tests cover setup-needed, stale cached limits, and provider summaries.
  • PR Add OpenAI limit probe prototype #14 CI passed on commit 0e81b79.
  • PR Add OpenAI limit probe prototype #14 CodeQL passed on commit 0e81b79.
  • Visual screenshot still needed from a real WidgetKit extension host after Xcode target packaging.

Decisions

  • Use Quiet Instrument as the visual direction.
  • Use Concept A - Instrument as the primary widget direction.
  • Use Concept B - Ledger as the dense-list treatment inside the app and as a fallback large-widget layout.
  • Widgets remain read-only and deep-link into the app for setup/detail.
  • Status must use color plus shape/text, not color alone.
  • Preserve last-good data for stale/loading/failure states instead of blanking the whole widget.

Open Questions

  • Which visual vocabulary best balances beauty and dense provider/account state?

Metadata

Metadata

Assignees

No one assigned

    Labels

    planDurable planning issue

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions