UX: Toggle collapse/uncollapse of sidebars
@nortonandreev is already working on this.
Since May 9, 2025.
Assessment
This issue has not been assessed yet.
Description
When the sidebars are collapsed (or uncollapsed), their state is not saved like a toggle, which means that these sections will be collapsed (or uncollapsed) again if you go to pages outside the section in question.
Desired Behavior
The sidebar collapse behaviour should be more like a toggle, remembering the state set by one user even if the user navigates to pages outside that section.
Additional Context
Anyways, this seems to be default Starlight's configuration: the sidebar remains expanded if the user is on a page within the expanded tree; if not, the sidebar gets collapsed, allowing the user to focus on a clear structure.
If we really feel the need to have the sidebar acting like a toggle, we will need to have to implement a state management for the sidebar.
Potentially, a quite naive (but also perhaps the simplest) implementation would be to append a class name to the expanded list(s) and tweak the SidebarSublist.astro component to take into account that.
Anyways, we need to understand if there is a solid reason to do so. Overriding built-in components and implementing custom business logic makes the codebase more bugs-prone, also potentially harder to maintain.
- Dominant language
- MDX
- Stars
- 8
- Forks
- 4
- Avg merge
- 2h 34m
- Merged PRs (30d)
- 6
Getting set up
- No Dockerfile or Docker Compose file
- No pull request template
- Read the contributing guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
More from dusk-network/docs
-
Content: Add ITN2 Eligibility & Reward CheckerPossibly taken @HDauven claimed this 419 days ago. Open
dusk-network/docs#96 · 1 assignee ·
-
Content: Review description of rewards and slashingMay be free again @fed-franz claimed this 480 days ago, and no pull request is open. Open
dusk-network/docs#73 · 1 assignee ·
-
section:node-operator
Difficulty 5/5 Over a week Newbie friendliness 35/100
dusk-network/docs#67 ·
-
Content: Review cryptography sectionsMay be free again @moCello claimed this 523 days ago, and no pull request is open. Opensection:learn type:docs
dusk-network/docs#33 · 2 assignees ·
-
section:developer
Difficulty 3/5 1-2 days Newbie friendliness 35/100
dusk-network/docs#29 · 1 comment ·