You're looking to create an active or current state for link blocks that updates when a section is clicked or scrolled into view—similar to a scroll-based navigation menu.
Here’s how to implement this behavior in Webflow:
---
1. Use Section-Based Scroll Navigation
- Structure each main part of your page as a distinct section (
Section elements in Webflow). - Assign each section a unique ID (e.g.,
#about, #services, #contact). - Set up a nav menu or list of link blocks where each links to one of these section IDs using
/#section-id format.
---
2. Set the Webflow Native "Current" State
- Webflow automatically applies a "Current" class to a link when its target section is in view via anchor linking.
- For this to work:
- Links must point to internal element IDs (e.g., link to
#about). - Target sections must be on the same page and must have an ID exactly matching the link's target.
You can style the "Current" state by selecting your link, navigating to the States dropdown, and styling the Current version.
---
3. Enable Smooth Scroll Into View (Optional)
- Webflow has built-in smooth scrolling when using on-page anchor links.
- To ensure links scroll properly:
- Use a fixed/sticky navbar to avoid scroll-offset issues.
- If needed, use custom scroll offset with code (like JavaScript
scroll-margin or custom script).
---
4. Simulate Active Links on Scroll (for Advanced “List Change” Behavior)
If you're looking for more dynamic behavior (e.g., highlighting links as you scroll through page sections), use Webflow Interactions:
- Add a scroll interaction on each section.
- When a section scrolls into view:
- Apply a class (like "active") to the associated nav link.
- Remove that class from other links.
- Use Element Trigger → Scroll into View, configured to run a custom interaction.
Alternatively, use custom JavaScript (only if needed) to add/remove classes based on scroll position—but Webflow's native tools cover most use cases.
---
5. Preview and Adjust
- Test scrolling through the page in Preview mode.
- Check that the "Current" state or custom active class is being correctly triggered based on scroll position or link clicks.
- Adjust section heights, padding, and anchor offsets to get accurate detection.
---
Summary
To replicate list-style active links that change on click or scroll:
- Use on-page anchor links with section IDs.
- Leverage Webflow’s native "Current" state for auto-highlighting.
- For scroll-based activation, use scroll interactions to manage custom active class states for each link.
Let me know if you'd like help setting up the scroll interaction method step by step.