Scrollspy
Track the visible section and navigate a long document using anchor links.
Installation
Import from @gaudi/design-system. Load @gaudi/design-system/global.css once and add transpilePackages: ['@gaudi/design-system'] in Next.js.
Copy an example into your project with the shadcn CLI: npx shadcn@latest add https://design.gaudi.site/r/scrollspy-top-navigation.json.
Usage
Examples
Top navigation
API
9 props
Accessibility
Use real links with valid targets. Preserve focus and allow navigation without motion.
Related
ScrollAreaContained scrolling with themed scrollbars and optional smooth wheel motion for article reading.2 examplesBreadcrumbBreadcrumb renders hierarchical page trails for navigation context.5 examplesFloatingMenuA compact, inverted pill of destinations that floats over the page once the reader scrolls away from the header, with an optional Back to top button. LayoutContainer renders it for the site; pass targetRef and position sticky to use it inside a scroll container.NavigationMenuNavigationMenu renders grouped site navigation with dropdown panels for categories, sections, and related destinations.2 examplesPaginationPagination renders blog-style previous/status/next navigation. Hovering or focusing the center status reveals direct page shortcuts.4 examplesStepperShow progress through a sequence of labelled steps.6 examples