Skip to content

fix: rewrite pill indicator to track horizontal card scroll#7

Open
jaredgoldman wants to merge 1 commit intomainfrom
worktree-agent-ae377047fec2bae84
Open

fix: rewrite pill indicator to track horizontal card scroll#7
jaredgoldman wants to merge 1 commit intomainfrom
worktree-agent-ae377047fec2bae84

Conversation

@jaredgoldman
Copy link
Copy Markdown
Owner

Summary

  • Pill indicator was listening to window.scroll / window.scrollY, both always 0 because html,body is position:fixed
  • Rewrote to listen to #container scroll events and compute scrollLeft / (scrollWidth - clientWidth) percentage
  • Dot now moves correctly as the user navigates between cards (top = first card, bottom = last card)
  • Skips redundant forced reflow when indicator is already visible (minor perf fix)

Test plan

  • Load the portfolio — pill indicator appears in top right
  • Navigate between cards — dot moves proportionally through the pill
  • Indicator fades after 3s of inactivity, reappears on next navigation

🤖 Generated with Claude Code

Pill indicator was listening to window.scroll and reading window.scrollY,
both permanently 0 because html/body is position:fixed. Now listens to
#container scroll events and tracks scrollLeft percentage so the dot
correctly reflects which card the user is on.

Also skips redundant forced reflow when indicator is already visible.

Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
@netlify
Copy link
Copy Markdown

netlify Bot commented May 5, 2026

Deploy Preview for jared-goldman-portfolio ready!

Name Link
🔨 Latest commit 8bef605
🔍 Latest deploy log https://app.netlify.com/projects/jared-goldman-portfolio/deploys/69f97d32e25af50008c5c297
😎 Deploy Preview https://deploy-preview-7--jared-goldman-portfolio.netlify.app
📱 Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

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