Give the home page a quiet health section - #184
Open
injoon5 wants to merge 1 commit into
Open
Conversation
- Add HomeHealth.svelte between the marquee and photos: today's score ring plus four metric tiles, subscribing to the same healthPublic.page window /health already caches - Add Sparkline.svelte, a lightweight two-path SVG line+wash so the home page doesn't pull in layerchart just to draw four 36px trends - Give PAGE_METRICS a `short` label so "Walking + running distance" fits a narrow column - Ignore locally installed third-party agent skills in .gitignore Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
|
Bugbot is not enabled for your account, so this pull request was not reviewed. Enable Bugbot in the Cursor dashboard to get automatic reviews on future PRs. |
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Adds a Health section to
/, between Now Listening and Photos.What it is
The quiet, typographic beat between two image-heavy sections — four numbers and four thin orange lines, rather than a third block of imagery.
/health, then a 44px score ring with the band word and the day —40 · Fair · Aug 6 · 3 of 4.bg-neutral-100surface the blog and project cards use, each with a label, a large tabular number + unit, and a 30-day sparkline in/health's exact visual language (accent line, six-stop wash, end dot).See the full history →, same treatment as the other sections' links.Deliberately not interactive: the section title and the trailing link are the two affordances, same count as Photos. Four tiles all linking to
/healthwould have put six links to one destination in one section.Performance
+2.25 kB gzip on the home page bundle (10.70 kB, up from 8.45 kB), measured before/after against
main.No layerchart, no d3 —
Sparklineis two path strings in a stretched unit-square viewBox withvector-effect="non-scaling-stroke".MetricChartis the right shape for a page whose whole subject is the chart; it is the wrong one for four 36px trends on the page that has to paint first. Verified layerchart never enters the home page's module graph.The subscription asks for
{ days: 30, endDate: UTC-today+1 }— byte-identical to what/health's server render already requests, so it lands on a Convex cache entry that is already warm rather than opening a second one. The home page is prerendered, so the window resolves at hydration from the visitor's clock;dateKeyis UTC, so every visitor asks for the same window.The four tile labels ship in the prerendered HTML and every box reserves its height, so the section paints its own shape before a socket is open and the numbers drop into a layout that already exists — no CLS.
Verified in a browser
Local
.envhas a placeholder Convex URL, so nothing loads there (Now Listening is stuck on "Loading…" too). Checked against a temporary 30-day fixture, fully reverted afterward.Aug 6, 2026 · 3 of 4wrapped in the 122px label column and orphaned the final4onto its own line. NowAug 6 · 3 of 4— one line at every width, with non-breaking spaces so3 of 4can never split.122,431is 84px in 124px available. The grid breaks 2→4 atmd, notsm, because that is where the numbers actually stop fitting.neutral-900and the dot's punched ring resolve to the identical value; line and dot follow--chart-accenttoorange-400.—, its sparkline stops short of the right edge (96.4% vs 100%) on a shared x domain, and it drops out of the score — which is what makes the caption read3 of 4.animation-durationbut notanimation-delay.svelte-check0 errors · eslint clean · prettier clean · 408/408 tests pass ·vite buildprerendersid="health"intoindex.htmlwith RSS intact.Note for review
The last bullet of the commit adds
.claude/skills/to.gitignore— locally installed third-party agent skills, unrelated to the feature. Happy to drop it if you would rather keep the PR to the section alone.🤖 Generated with Claude Code