You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have read the console error message carefully (if applicable).
Description
In the sidebar, is there any way to make the accordions collapsible on clicking label? It's possible to expand the accordion on first click, but on clicking an expanded accordion should collapse it. Currently, the user has to click on the accordion arrow to collapse it.
In the following video, I've attached the docusaurus docs page where the bug can be seen. I'm not sure if this is an intended thing, but seems odd UX-wise.
Screen.Recording.2025-01-21.at.2.22.15.PM.mov
Reproducible demo
No response
Steps to reproduce
1. Open the Docusaurus docs page in a browser.
2. Navigate to the sidebar containing accordions.
3. Click on the label of an accordion to expand it.
4. Click on the same accordion label again to attempt to collapse it.
Expected behavior
Clicking on an expanded accordion’s label should collapse it, providing a toggle behavior directly through the label.
Actual behavior
Clicking on the label of an expanded accordion does not collapse it. The user must click on the accordion arrow to collapse it, which results in inconsistent user experience.
This is a design decision we made in the past, but I agree that it could be convenient to collapse on label click, and many other docs frameworks have implemented it that way.
If the community thinks it's a better default behavior, I'm happy to revisit our past design decision.
Have you read the Contributing Guidelines on issues?
Prerequisites
npm run clear
oryarn clear
command.rm -rf node_modules yarn.lock package-lock.json
and re-installing packages.Description
In the sidebar, is there any way to make the accordions collapsible on clicking label? It's possible to expand the accordion on first click, but on clicking an expanded accordion should collapse it. Currently, the user has to click on the accordion arrow to collapse it.
In the following video, I've attached the docusaurus docs page where the bug can be seen. I'm not sure if this is an intended thing, but seems odd UX-wise.
Screen.Recording.2025-01-21.at.2.22.15.PM.mov
Reproducible demo
No response
Steps to reproduce
Expected behavior
Clicking on an expanded accordion’s label should collapse it, providing a toggle behavior directly through the label.
Actual behavior
Clicking on the label of an expanded accordion does not collapse it. The user must click on the accordion arrow to collapse it, which results in inconsistent user experience.
Your environment
Self-service
The text was updated successfully, but these errors were encountered: