Skip to content

Commit 24bc7f4

Browse files
committed
Fix TOC anchors sometimes not working (e.g. /control-panel/dashboard#overview) by prefixing nav disclosure ids.
The problem here was that there were multiple IDs on the same page rather than unique IDs for the TOC anchors to work with
1 parent 99ea144 commit 24bc7f4

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

resources/views/partials/nav_contents.antlers.html

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@
3838
<label class="o-toggle-subnav c-nav-sidebar-with-popover-api-category-heading{{ if is_current || is_parent }} o-current-menu-item{{ /if }}">
3939
<div class="c-nav-sidebar-with-popover-api__disclosure">{{ svg src='chevron' }}</div>
4040
{{ title }}
41-
<input id="{{ title | slugify }}" type="checkbox" {{ unless is_current || is_parent || (current_uri == '/' && first) }}checked{{ /unless }}>
41+
<input id="nav-{{ title | slugify }}" type="checkbox" {{ unless is_current || is_parent || (current_uri == '/' && first) }}checked{{ /unless }}>
4242
</label>
4343
<ul>
4444
{{# Make sure we output the homepage for the 'Getting Started' disclosure #}}

0 commit comments

Comments
 (0)