Fix SideNavCollapseButton properties preview with collapsible fixture - #5913
Conversation
…view (facebook#5901) Provide a minimal controlled collapsible fixture so the component renders visibly in the properties preview tab without requiring a SideNav context. The fixture demonstrates the toggle behavior with default expanded state.
|
The latest updates on your projects. Learn more about Vercel for GitHub.
|
|
Hi @Alif416! Thank you for your pull request and welcome to our community. Action RequiredIn order to merge any pull request (code, docs, etc.), we require contributors to sign our Contributor License Agreement, and we don't seem to have one on file for you. ProcessIn order for us to review and merge your suggested changes, please sign at https://code.facebook.com/cla. If you are contributing on behalf of someone else (eg your employer), the individual CLA may not be sufficient and your employer may need to sign the corporate CLA. Once the CLA is signed, our tooling will perform checks and validations. Afterwards, the pull request will be tagged with If you have received this in error or have any questions, please contact us at cla@meta.com. Thanks! |
|
Thank you for signing our Contributor License Agreement. We can now accept your code for this (and any) Meta Open Source project. Thanks! |
cixzhang
left a comment
There was a problem hiding this comment.
Thanks, this looks good!
PR Analysis Report📚 Storybook PreviewView Storybook for this PR 🧪 Sandbox PreviewView Sandbox for this PR Modified ComponentsSideNav (@astryxdesign/core) · View in Storybook
Bundle Size Summary
Accessibility AuditStatus: No accessibility violations detected. Generated by PR Enrichment workflow | Storybook | Sandbox | View full report |
Head branch was pushed to by a user without write access
8e1efa2 to
116f514
Compare
Summary
Add a playground fixture to SideNavCollapseButton's documentation to enable the component to render visibly in the Properties preview tab.
Problem
The SideNavCollapseButton Properties preview was rendering empty because the component requires either:
collapsibleprop (controlled collapse state), ORWithout either of these, the component correctly returns
null, making the preview invisible.Solution
Added a
playgroundobject with defaultcollapsiblestate toSideNavCollapseButton.doc.mjs. This provides a minimal fixture that:collapsibleprop withisCollapsed: falseAcceptance Criteria
Fixes #5901