Skip to content

Add a 📊 stats dialog with a 14-day runs chart - #40

Merged
Necromancervbh merged 30 commits into
mainfrom
claude/game-automation-ideas-d97rgk
Sep 29, 2026
Merged

Necromancervbh merged 30 commits into
mainfrom
claude/game-automation-ideas-d97rgk

Conversation

@Necromancervbh

Copy link
Copy Markdown
Owner

A new 📊 button in the header opens a stats dialog:

Stats dialog

  • Tiles: successful runs, success rate, manual work saved, best streak (and the current one), and how many different cards you've used
  • Runs over the last 14 days: a bar chart.
    • Hover or point at a day for "Sun 27 Sep: 11 runs, 3m saved" (failures are included when there are any).
    • Only today's bar and the tallest bar carry a number, so the chart stays readable.
    • Show as a table lists the same numbers for screen readers or copying.
  • Busiest combos: your top 5 by runs, as horizontal bars

Engine

  • recordDaily counts runs, failures and seconds saved per local day. It keeps only the last 60 days, so the save file stays small.
  • dailySeries fills days without runs with zeros.
  • The snapshot includes player.daily. Older saves are upgraded automatically.

Design checks

  • The bar color was checked with a palette validator for lightness and contrast against the panel in both themes: #d9661f on dark and #d9621b on light.
  • Bars are thin, rounded at the top and sit on the baseline. The gridlines are faint.
  • The hover area covers the whole day column, including its label.
  • The chart is drawn at its real width, so labels stay 12px on phones. On narrow screens "Today" becomes a bold day letter so it doesn't collide.

Testing: npm test passes 49 tests, including a new test for daily counting, pruning and zero-filling. Checked in the browser in dark and light at 1100px and in dark at 390px: no horizontal scroll, tooltips work, and the console has no errors. The README has a new stats screenshot.

🤖 Generated with Claude Code

https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf


Generated by Claude Code

Three quests a day, picked with a per-day seed, pay bonus XP once each.
Progress comes from combo runs and forging, and shows in a new panel.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
A one-page site in docs/ (how it works, features, screenshots, download
steps). Serve it with Settings > Pages > main, /docs.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
The quests panel shows the time until local midnight and reloads the new
set when the day changes.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
A rare IF card (level 3) that lets a combo continue only N% of the time.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
Same change as Dependabot's #31, which conflicted after #30 landed.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
Tidy Up moves files older than N days out of a folder without
overwriting. Snapshot saves a screenshot (screencapture, PowerShell, or
grim/gnome-screenshot/spectacle/scrot/import) and hands it to later cards.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
Fires once when you've been idle N minutes, or when you come back after
that long. Idle time comes from ioreg (macOS), GetLastInputInfo
(Windows), or GNOME's IdleMonitor / xprintidle (Linux).

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
A THEN card that runs another combo by name, passing the trigger's file
along. Loops (A -> B -> A) are refused and chains stop at 5 combos. The
forge suggests existing combo names.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
Synthesized with Web Audio (no audio files): a coin per run, a low note
on failure, chimes for achievements and quests, a fanfare on level-up.
The header's speaker button mutes it and the choice is remembered.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
The engine counts runs, failures and time saved per day (60 days kept).
The new stats button shows totals, a bar chart with hover details and a
table view, and the busiest combos.

Co-Authored-By: Claude Opus 5.5 <noreply@anthropic.com>
Claude-Session: https://claude.ai/code/session_01Wm8TE3zwYDLddBccTdRBqf
@coderabbitai

coderabbitai Bot commented Sep 29, 2026

Copy link
Copy Markdown

Important

  • 🔍 Trigger review

This repository does not receive automatic reviews because it has fewer than 10 stars.

⚙️ Run configuration

Configuration used: Organization UI

Review profile: CHILL

Plan: Advanced

Run ID: af55f9d8-b80f-4f2d-bb24-25c974bff1ea


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.

❤️ Share

Comment @coderabbitai help to get the list of available commands.

@Necromancervbh
Necromancervbh merged commit 5a1fcbb into main Sep 29, 2026
7 checks 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.

2 participants