Nav sections: independent sidebar islands and dynamic top bar#3133
Nav sections: independent sidebar islands and dynamic top bar#3133theletterf wants to merge 19 commits intonav-v2from
Conversation
Introduces the `section:` YAML item type in navigation-v2.yml. Each section owns an independent sidebar tree and optionally appears as a tab in the secondary nav bar. Sections marked `isolated: true` render with a back arrow instead of a top bar tab. Key changes: - SectionNavV2Item record + YAML parsing in NavV2FileYamlConverter - SectionNavigationNode nav type + NavigationSection data carrier - SiteNavigationV2 builds sections, URL-to-section lookup - GlobalNavigationHtmlWriter renders per-section sidebar (cached) - NavigationRenderResult carries section metadata - _SecondaryNav.cshtml is now data-driven (falls back to static V1) - _TocTree.cshtml shows back arrow for isolated sections - PlaceholderPageWriter groups by section for per-section nav Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Converts the 4 top-level label: entries in navigation-v2.yml to the new section: format with explicit url: fields. Each section becomes an independent nav island with its own sidebar and top bar tab. Sections: - Elasticsearch fundamentals → /get-started/ - Install, deploy, and administer → /deploy-manage/deploy/ - The Elasticsearch Platform → /manage-data/ingest/ - Solutions and project types → /solutions/ Nested label: items within sections are unchanged. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…oubleshoot, Reference Restructures navigation-v2.yml so all existing labels are children of a single "Docs" section (full V2 tree in one sidebar). Adds Release notes, Troubleshoot, and Reference as separate section tabs. Secondary nav bar is now left-aligned, compact, and fully data-driven from section metadata. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…to-expand - Wrap all V2 content in a single "Docs" section; add Release notes, Troubleshoot, Reference as separate section tabs - Secondary nav: left-aligned, 55px height, restored md:text-base font - Skip current-page highlighting on section root pages via data-section-url attribute (includes site prefix) - Auto-expand top-level folders on section root pages so content is visible without a specific page being marked current Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…ove back arrow Adds two isolated nav sections (not shown in top bar): - Extension points (extend + kibana/logstash/beats/elasticsearch/integrations) - Account and preferences (cloud-account) Removes the back arrow from isolated sections — the UX for returning from an island is still under design review. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
8485b1d to
7fed2c5
Compare
Absolute URLs (http/https) in section url: fields render as plain links without HTMX swap or Model.Link() prefix. Sections with no children work as external navigation targets. Adds "API reference" tab pointing to https://www.elastic.co/docs/api Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Islands are subtrees within a section that get their own focused sidebar
when a user navigates into their pages. A back arrow points to the
parent section's landing page (known at build time, no history.back).
YAML format:
- section: Reference
url: /reference/
children:
- toc: docs-content://reference
- island: Logstash plugins
toc: logstash-docs-md://lsr
Key changes:
- IslandNavV2Item record + YAML parsing for island: key
- IslandNavigationNode wraps an existing toc node
- NavigationIsland data carrier with ParentSection reference
- SiteNavigationV2 builds island list + URL-to-island lookup
(islands take priority over sections in URL resolution)
- GlobalNavigationHtmlWriter renders island sidebar with back arrow
- Back arrow uses HTMX navigation to parent section URL
Adds Logstash plugins and versioned plugins as islands in Reference.
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
KOTungseth
left a comment
There was a problem hiding this comment.
Now that Docs, Release notes, Troubleshoot, API reference, and Reference are grouped together, we need to find a solution for the Docs label.
Release notes, Troubleshoot, API reference, and Reference are content types and help users navigate to a specific kind of documentation. Docs is not a content type, but is the parent context to everything else that lives inside of Docs. By grouping Docs, Release notes, Troubleshoot, API reference, and Reference together, we have mixed together wayfinding and content-type navigation.
The cleanest fix right now is to handle the "back to landing page" behavior through a separate, persistent element, like a logo or a breadcrumb. That way, the secondary nav becomes a coherent, single-purpose set of content-type links and the navigation to the landing page exists independently.
We could also change the Docs label. Something like Home or Overview signals intent a bit more clearly than Docs, through is still doesn't fully resolve the category mismatch.
| children: | ||
| - toc: docs-content://troubleshoot | ||
|
|
||
| - section: API reference |
There was a problem hiding this comment.
The API reference link creates a classic navigation trap. When users enter the Bump.sh site, they lose their wayfinding back to our elastic.co/docs canonical site.
Some options:
- Open the API reference docs site in a new tab to allows users to keep the Elastic Docs tab and return to it naturally.
- Label the API reference link with a
API reference ↗visual treatment to clearly set user expectations that when they click the link, they'll be leaving elastic.co/docs. - Negotiate a
Back to Elastic Docslink with Bump.sh that easily points users back to elastic.co/docs.
There was a problem hiding this comment.
I would go for
Negotiate a Back to Elastic Docs link with Bump.sh that easily points users back to elastic.co/docs.
Can we add it?
There was a problem hiding this comment.
A combination of all of these 3 options would be best
There was a problem hiding this comment.
API reference ↗ and opening in new tab has my vote, until we have a clear vision of whats going to ship first API Explorer or v2.
Moves Account and preferences from a top-level isolated section to an island: entry under "Deployment and administration tools" in the Docs section. This gives it: - An entry point visible in the main Docs sidebar - A back arrow pointing to the Docs section root (via the existing island mechanism) Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The island's toc root URL was not being collected in the URL-to-island lookup, so navigating to the root page (e.g. /cloud-account/) fell through to the section lookup and showed the full Docs sidebar instead of the island sidebar. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
…atching URL-based island lookup breaks across path prefixes (dev vs preview vs production). The nav system already knows which toc root owns the current page via currentRootNavigation — use that identity to resolve islands instead. Replaces _urlToIsland dictionary with _tocRootToIsland keyed by the toc root's Id. GetIslandForTocRoot takes the root navigation item directly, matching by nav ownership rather than URL strings. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The 16px/24px vertical padding on top-level <li> inside the nav tree was intended for label section separators but applied to all items, making island sidebars with flat leaf links overly spaced. Scope the rule to li:has(> .docs-sidebar-nav-v2__label) so only label sections get the extra padding. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The back arrow used GetNavHxAttributes which only swaps content areas, leaving the sidebar stuck on the island. Use GetHxAttributes with #main-container,#secondary-nav swap targets (same as section tabs) so the sidebar, content, and top bar all update on back navigation. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
External section URLs (like API reference → Bump.sh) now open in a new tab (target="_blank" rel="noopener") with a small external-link icon (↗) to set user expectations that they're leaving elastic.co/docs. Prevents the navigation trap where users lose their wayfinding back to the docs site. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Guides better signals task-based narrative content alongside the content-type tabs. APIs is shorter and eliminates the repetition with Reference. Tabs: Guides | Release notes | Troubleshoot | APIs ↗ | Reference Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
Guides → APIs → Reference → Troubleshoot → Release notes Groups building tabs together, situational tabs at the end. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
The previous label 'Build search queries with APIs and query languages and search templates' wrapped to three lines in the sidebar. Co-Authored-By: Claude Opus 4.6 (1M context) <noreply@anthropic.com>
|
@Mpdreamz Right now we have |

Summary
section:andisland:item types innavigation-v2.ymlthat create independent nav trees ("nav islands"). Each section owns its own sidebar HTML — pages in one section never include another section's nav links in the DOM.isolated: true) do not appear in the top bar.GlobalNavigationHtmlWriterreplaces the single "nav-v2" blob — each section's sidebar is rendered and cached independently.url:fields open in a new tab with a ↗ indicator to signal users they're leaving elastic.co/docs.island:item type) are intra-section subtrees that get their own focused sidebar when entered, with a back arrow pointing to the parent section. Island detection uses toc root identity (nav ownership model), not URL matching, so it works across all path prefixes.Tab ordering
Tabs follow a task-flow logic — building tabs grouped together, situational tabs at the end:
Guides | APIs ↗ | Reference | Troubleshoot | Release notes
Sections (top bar tabs)
Isolated sections (not in top bar)
Nav islands (intra-section, with back arrow)
YAML format
🤖 Generated with Claude Code