Add root property to tabs to designate a landing page #5114
rkhoriander
started this conversation in
Feature Requests
Replies: 0 comments
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Uh oh!
There was an error while loading. Please reload this page.
Uh oh!
There was an error while loading. Please reload this page.
-
Currently, root is supported on groups to designate a main page that the group title navigates to. Tabs have no equivalent; clicking a tab always navigates to the first page Mintlify finds in the tab's navigation structure.
Our use case
Every tab in our docs has a standalone overview/landing page that should appear when the tab is clicked, with the tab's groups organized beneath it as subsections. This is a common and semantically correct IA pattern.
What currently works (but blocks $ref splitting)
A
pagesarray on the tab with the overview page as the first entry works correctly for navigation:The overview page renders correctly and the tab lands on it when clicked. However, because
pagesis an array, we can't use$refto split the tab's content into per-section files;$refdoesn't support inline array splicing (See one of my other feature requests). This forces us to maintain a custom assembly script instead of using native$ref.Other approaches we tried that didn't work
$refas an element within thepagesarray, with the section file as a bare array ofgroupobjects:Result: no error, but nav disappeared entirely.
$refreplacing the entirepageskey, with the section file wrapped in{ "pages": [...] }:Result: same — nav disappeared entirely.
$refreplacing thetabobject, with the section file wrapped in{ "groups": [...] }:Result: nav renders correctly, but there is no way to place the overview page outside a group, which breaks the IA.
Empty
groupwithrootas a workaround for the landing page:Result: overview page and nav render, but an expand/collapse icon appears in the sidebar with nothing beneath it, which is a confusing UI artifact for users. Omitting
pagesentirely made no difference. Using an empty string forgroupbroke the nav entirely.i confirmed with Mintlify support that these are all current limitations.
Requested behavior
Support a
rootproperty on tabs, equivalent to the existing group behavior:Clicking the tab would navigate to the root page. The root page could appear in the sidebar above the groups with no expand icon (or not appear at all).
Beta Was this translation helpful? Give feedback.
All reactions