Skip to content

TokenStep 0.2.16: compact popover, faster quota refresh - #22

Merged
Backtthefuture merged 5 commits into
mainfrom
feature/compact-popover
Sep 26, 2026
Merged

Backtthefuture merged 5 commits into
mainfrom
feature/compact-popover

Conversation

@Backtthefuture

Copy link
Copy Markdown
Owner

Summary

  • The popover is now one 340pt column (quotas, today's tokens, rank) instead of a 900pt panel that got cut off on 13-inch screens.
  • The notch island opens the same popover; the card follows the content height and stays open while its "..." menu is showing.
  • Quota refreshes at most every 5 minutes while a window is open, and Refresh/⌘R refreshes quota too. Before this, quota could be up to ~25 minutes old because the Claude and Cursor caches stacked on the app's own interval. A transient failure keeps the last good reading.
  • CLI-only Claude Code users get the Claude mark on the quota row. Rank shows "未上榜" instead of a bare dash, and the chase headline is smaller. Quota rows explain the time tick on hover.
  • Release prep for 0.2.16: release notes, CHANGELOG, README, default version.

Test plan

  • script/test_all.sh: all fixture checks pass, including the new compact popover check and the 0.2.16 release contract. swift test was skipped locally because this machine has no full Xcode, so CI covers it.
  • Ran the app on a notched MacBook Air: island card, Claude quota, rank, and refresh checked by hand.

🤖 Generated with Claude Code

Backtthefuture and others added 5 commits September 25, 2026 06:35
The popover was 900pt wide and macOS centers it under the menu bar item,
so on a 13-inch screen with the item left of center its left side was cut
off. It is now one 340pt column with the three things worth a glance:

- Quotas: one row per window with used percent and reset time, sorted by
  the most used provider. A marker shows how much of the window has passed,
  and a badge warns when the current pace runs out before the reset. Beyond
  two providers the calm ones fold into one row; warnings never fold.
- Today: total tokens with the lap ring, and the top three models.
- Rank: own rank, the top three with their lead, and how many tokens it
  takes to pass the next rank, with an estimate at the last hour's pace.
  Local vs board comparisons only show when both count the same day.

Provider icons come from the installed desktop app when present, else a
monogram. Share, screenshot, motion mode and quit move into a "..." menu.
The client breakdown and full model list stay in the dashboard. The old
column cards are removed.

Content rules live in CompactPopoverModel, covered by a new fixture check.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
The notch island still opened its own older card (big ring, two tool rows,
three buttons), so on notched Macs the new single column never showed. The
island card now hosts PopoverPanelView, so both entry points show the same
content.

The card window follows the content height with its top edge fixed, since
quota rows and the rank section come and go. While a menu is tracking (the
"..." menu opens outside the card) leaving the card no longer collapses it.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
- Claude quota shows the Claude symbol when the desktop app is not
  installed (CLI-only users), drawn from its SVG path in ProviderMark so no
  resource file is needed. Installed app icons still win.
- Not on today's board shows "未上榜" instead of a bare dash, which read
  as a thick bar. A short board lists everyone, so the caption says no
  upload today; a full board still says "not in the top N".
- The chase headline ("再跑 …") drops from 18pt heavy to 13pt bold so it
  no longer outweighs the rank.
- Quota rows explain the tick on hover (time passed vs used), and the row
  that runs out early tints its title to match the warning badge.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Quota could be up to about 25 minutes old: the app checked every 15
minutes, and the Claude and Cursor services kept their own 10-minute file
caches on top. The refresh button never refreshed quota at all.

- An open window checks quota at most every 5 minutes. Background floors
  (15 min on AC, 30 on battery) are unchanged.
- Claude and Cursor file caches drop to 4 minutes so they no longer stack
  on the app's interval.
- Refresh and Cmd-R refresh quota too, skipping those caches.
- A transient failure (rate limit, network) keeps the last good reading
  instead of hiding the row; login and key errors still replace it.

PRIVACY.md lists the new timing.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Add release notes, the CHANGELOG entry, README download links, and the
default build version.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
@Backtthefuture
Backtthefuture merged commit 948dd2f into main Sep 26, 2026
1 check passed
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.

1 participant