Commit 466db49
authored
update nav dropdown behavior (docker#23436)
<!--Delete sections as needed -->
## Description
Change how the section drop-down arrows are rendered in the side-nav.
Currently, they generate for any folder, even if it just contains an
index. To not generate the arrow, the index would have to be taken out
of the folder and renamed as the folder.
This change now counts how many children under the index, and only
generates the arrow if it has children (that aren't hidden from the
nav).
For example, see how there is an arrow for the mcp gateway, but it
expands to nothing.
Current: https://docs.docker.com/ai/mcp-gateway/
Updated:
https://deploy-preview-23436--docsdocker.netlify.app/ai/mcp-gateway/
## Related issues or tickets
<!-- Related issues, pull requests, or Jira tickets -->
## Reviews
<!-- Notes for reviewers here -->
<!-- List applicable reviews (optionally @tag reviewers) -->
- [ ] Editorial review
Signed-off-by: Craig <[email protected]>1 parent 2c0d6fd commit 466db49
1 file changed
+4
-0
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
79 | 79 | | |
80 | 80 | | |
81 | 81 | | |
| 82 | + | |
| 83 | + | |
| 84 | + | |
82 | 85 | | |
83 | 86 | | |
84 | 87 | | |
| |||
97 | 100 | | |
98 | 101 | | |
99 | 102 | | |
| 103 | + | |
100 | 104 | | |
101 | 105 | | |
102 | 106 | | |
| |||
0 commit comments