Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make navigation bar in charts example sticky #4879

Open
wants to merge 12 commits into
base: main
Choose a base branch
from

Conversation

sokhuong-uon
Copy link

@sokhuong-uon sokhuong-uon commented Sep 17, 2024

When scroll to a new section, the active link won't update. However, I think this update provides a better experience for navigating examples.
image

Copy link

vercel bot commented Sep 17, 2024

@sokhuong-uon is attempting to deploy a commit to the shadcn-pro Team on Vercel.

A member of the Team first needs to authorize it.

Copy link

vercel bot commented Sep 23, 2024

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Skipped Deployment
Name Status Preview Updated (UTC)
ui ⬜️ Ignored (Inspect) Visit Preview Sep 23, 2024 7:43am

Copy link
Collaborator

@shadcn shadcn left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@sokhuong-uon Thanks for taking this one. I found two issues:

  • the active state is not updating on scroll.
  • it breaks the layout on mobile.

Any change you can take a look?

@shadcn shadcn added the postpone: more info or changes requested maintainers asked a question or needs more info label Sep 23, 2024
@sokhuong-uon
Copy link
Author

will update.
thank you for review

@sokhuong-uon
Copy link
Author

sokhuong-uon commented Oct 28, 2024

I've made some changes:

  • fix overflow on mobile screen.
  • update active link on scroll.
  • scroll active link into view if not visible (when the width of scroll area is small on mobile screen).

please have a look.

shadcn-website-update.mp4

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
area: charts area: www enhancement New feature or request postpone: more info or changes requested maintainers asked a question or needs more info
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants