No description
Three coupled fixes to the route's geometry: - computeRouteLayout's width calculation flipped to Math.max(viewport * 0.80, itemCount * minSpacing + padding * 2). On a wide screen with few items the 80% target wins and the path stretches across the page; once item count makes the data-driven width exceed 80% (the carousel case), the data-driven value wins and the track extends past the viewport unchanged. - .rr-scroll horizontal padding 140 → 60 each side. The previous 140 was overcompensating; with the new 80% target the milestones already sit inside their own breathing room. 60 is card-half + 30px buffer, enough for a 220px card centred under a dot 60px from the edge. scroll-padding kept in sync at 60 for snap-stop landings. - trackHeight default 580 → 420; midY 290 → 210. The 580 was bandaging the vertical-clipping issue — that fix lands in the next commit. With the clip properly addressed, 420 fits the path's amplitude 120 swing cleanly with no wasted vertical space. Tests rewritten to match the new width semantics: 1 item @ 1000 → 920px (0.8 * 1000 + 120); 3 items @ 1400 → 1240px; 20 items @ 800 → 6200px (data-driven wins). midY assertion 290 → 210. Co-Authored-By: Claude Opus 4.7 (1M context) <noreply@anthropic.com> |
||
|---|---|---|
| .claude | ||
| content | ||
| design | ||
| migrations | ||
| public | ||
| scripts | ||
| src | ||
| tests | ||
| .env.example | ||
| .gitignore | ||
| astro.config.mjs | ||
| CLAUDE.md | ||
| DECISIONS.md | ||
| HANDOVER.md | ||
| KNOWN_ISSUES.md | ||
| package.json | ||
| pnpm-lock.yaml | ||
| SPEC.md | ||
| todo.md | ||
| tsconfig.json | ||
| vitest.config.ts | ||