Skip to content

feat: show exact usage in recap chart tooltips - #368

Merged
chattymin merged 1 commit into
chattymin:mainfrom
heli-os:feature/recap-chart-tooltips
Oct 5, 2026
Merged

chattymin merged 1 commit into
chattymin:mainfrom
heli-os:feature/recap-chart-tooltips

Conversation

@heli-os

@heli-os heli-os commented Sep 27, 2026 •

Copy link
Copy Markdown
Contributor

Summary

Add native macOS hover tooltips to the usage recap chart, covering each bucket's meter and label. Reuse the existing accessibility description so the selected language, exact grouped token count, and date/month name stay consistent with VoiceOver. Known zero usage remains 0; future or unrecorded buckets say no data in the selected language.

Type of change

  • Bug fix
  • New feature
  • Refactor / cleanup
  • Documentation
  • Other:

UI changes

Before After
Hovering over a recap meter does not reveal its exact usage. A native tooltip shows the date (or month in Year view) and precise token count, or the localized no-data label.

The chart layout and existing accessibility labels are unchanged.

Native SwiftUI/AppKit captures with isolated fixture data. The after image shows the actual macOS tooltip over September 17, a known zero-usage day.

Before After hover
recap-tooltip-before recap-tooltip-after

Validation

  • GitHub CI passed: build, test + coverage gate, and secret scan. The suite ran 1,381 tests with 14 skipped and zero failures, including the new regression test.

  • swift build passed locally.

  • In a native SwiftUI/AppKit host with an isolated save and UserDefaults suite, inspected the actual bucket accessibility help and triggered the native macOS tooltip panel with a hover event.

  • Native accessibility help checks passed all 21 language/scope combinations, including exact positive counts, known zero, and no-data labels.

  • Added tests for positive usage, known zero, future/unrecorded buckets, yearly month labels, and all seven languages across Week/Month/Year.

  • ./scripts/test-gate.sh was attempted but this Mac's Command Line Tools cannot import XCTest; CI must run the full suite.

  • git diff --check passed.

Checklist

  • swift build and swift test pass locally
  • PR title and description are written in English
  • UI changes are described above (before/after — images optional)
  • No copyrighted assets, secrets, or private tooling references are committed
  • Tests were added or updated for this change

@chattymin
chattymin merged commit 5afeb2a into chattymin:main Oct 5, 2026
2 checks passed
LuceteYang added a commit to LuceteYang/PikaTokenBar that referenced this pull request Oct 6, 2026
… for 1.10.0

- READMEs (en/ko/ja): the daily trend stacks by tool with a named legend
  (chattymin#348); "Also in the box" gains the menu bar right-click menu (chattymin#373),
  bulk shop purchases and the empty-Bag shop shortcut (chattymin#371, chattymin#366), type
  badges, wheel paging and sprite-to-entry (chattymin#391, chattymin#393, chattymin#394), exact numbers
  on hover (chattymin#392, chattymin#368), and the Russian UI (chattymin#372)
- Daily trend shots render three tools stacked; pace and recap shots redrawn
- Settings shots: labeled difficulty slider ends (chattymin#398) and the menu bar
  percent-color row; footer bumped to 1.10.0

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
donky-ey pushed a commit to donky-ey/PokeDexBar that referenced this pull request Oct 15, 2026
Hovering a recap bar shows the same sentence VoiceOver reads: exact
grouped tokens, a real zero, or 'no data' for days before recording.
Strongorange added a commit to Strongorange/PokeTokenBar-windows that referenced this pull request Oct 19, 2026
Port macOS chattymin#332 core: UsageLedger keeps day-by-day totals across months
with monotonic-max merges (a rotated log cannot erase a day that really
happened) and covered-since semantics that separate a real zero from an
unrecorded day. RecapPeriod models whole calendar weeks/months/years —
weeks start on Sunday, the same rule as the week totals and the year
heatmap grid, exposed as one named culture so all three switch together.
UsageRecap.Make computes buckets (days, or months in the year view),
totals, the same-days comparison for running periods, best day, streaks,
active/counted days, in-period graduations and the canGoBack bound.
Recap strings ported for the seven app languages (chattymin#367/chattymin#368 included).
Strongorange added a commit to Strongorange/PokeTokenBar-windows that referenced this pull request Oct 19, 2026
The refresh background path merges the 365-day series into the ledger
(single-flight serialized, mutated under the service gate; the recap
reads a copy), prunes to this year plus last year for the year-over-year
comparison, and writes usage-ledger.json atomically only when the merge
changed anything. A corrupt ledger is moved to .corrupt and recording
starts fresh. RecapQuery turns a ledger snapshot into the window's view
model: period titles and bucket labels per scope and language, the chattymin#368
tooltips (exact tokens / a real zero / no data), the same-days compare
note, current-period label (chattymin#367), stats lines and in-period graduates.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants