suiss/ui · Block
Nav Local
A sticky product sub-navigation that highlights the section in view, shown on a dark product page.
Nav Local is an open-source block from suiss/ui for React. The @esuiss/ui CLI copies its source into your project, so you own the code.
A sticky product sub-navigation with the product name on the left and section links and a Buy button on the right, underlining the link for the section in view. The bar gains a blurred background once the page scrolls, and the links collapse into a full-screen menu when space runs out. It renders dark and comes with a sample page of three sections. Use it under a global nav on long product or feature pages.
Installation
CLI
Works in any project with a components.json. See Installation for the one-line registry setup. Or use the suiss/ui CLI:
Manual
- Update the import paths to match your project.
Usage
Edit sections; each id must match an element on your page, because an IntersectionObserver picks the active link from the section in view. Replace the sample sections, highlights and images with your own content, and give Buy a handler.
Notes
Images are Unsplash placeholders.