Skip to content

fix: Issue with accordion requiring two clicks to close#2834

Open
Allaoua9 wants to merge 1 commit intoChainlit:mainfrom
Allaoua9:fix/step-accordion-not-closing
Open

fix: Issue with accordion requiring two clicks to close#2834
Allaoua9 wants to merge 1 commit intoChainlit:mainfrom
Allaoua9:fix/step-accordion-not-closing

Conversation

@Allaoua9
Copy link
Contributor

@Allaoua9 Allaoua9 commented Mar 9, 2026

Accordion was not closing on the first click. it required two clicks to close.

This issue was that the controlled accordion was incorrectly handled.


Summary by cubic

Fixes the step accordion so it closes on the first click by standardizing the controlled value to a string. The closed state now uses '' instead of undefined, and onValueChange sets the value directly, making user toggles and auto-collapse work reliably.

Written for commit d3fbc94. Summary will update on new commits.

@dosubot dosubot bot added size:XS This PR changes 0-9 lines, ignoring generated files. bug Something isn't working frontend Pertains to the frontend. labels Mar 9, 2026
Copy link
Contributor

@cubic-dev-ai cubic-dev-ai bot left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

No issues found across 1 file

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

bug Something isn't working frontend Pertains to the frontend. size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant