base-ui icon indicating copy to clipboard operation
base-ui copied to clipboard

[docs] Accordion props reference

Open mj12albert opened this issue 5 months ago • 7 comments

Preview: https://deploy-preview-2120--base-ui.netlify.app/react/components/toggle

Testing an Accordion implementation for https://github.com/mui/base-ui/issues/1752

mj12albert avatar Jun 17 '25 04:06 mj12albert

Open in StackBlitz

npm i https://pkg.pr.new/@base-ui-components/react@2120

commit: 2d22933

pkg-pr-new[bot] avatar Jun 17 '25 04:06 pkg-pr-new[bot]

Bundle size report

@base-ui-components/reactparsed: 0B(0.00%) gzip: 0B(0.00%)

Show details for 39 more bundles

@base-ui-components/react/accordionparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/alert-dialogparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/avatarparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/checkboxparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/checkbox-groupparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/collapsibleparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/context-menuparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/dialogparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/direction-providerparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/fieldparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/fieldsetparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/formparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/inputparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/menuparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/menubarparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/merge-propsparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/meterparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/navigation-menuparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/number-fieldparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/popoverparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/preview-cardparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/progressparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/radioparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/radio-groupparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/scroll-areaparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/selectparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/separatorparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/sliderparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/switchparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/tabsparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/toastparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/toggleparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/toggle-groupparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/toolbarparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/tooltipparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/unstable-no-ssrparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/unstable-use-media-queryparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/use-renderparsed: 0B(0.00%) gzip: 0B(0.00%) @base-ui-components/react/utilsparsed: 0B(0.00%) gzip: 0B(0.00%)

Details of bundle changes

Generated by :no_entry_sign: dangerJS against 2d2293338953bb1f5c9d0cc4cb7e1b4a4a553b69

mui-bot avatar Jun 17 '25 04:06 mui-bot

Deploy Preview for base-ui ready!

Name Link
Latest commit 2d2293338953bb1f5c9d0cc4cb7e1b4a4a553b69
Latest deploy log https://app.netlify.com/projects/base-ui/deploys/6853e43df140470008edc0a6
Deploy Preview https://deploy-preview-2120--base-ui.netlify.app
Preview on mobile
Toggle QR Code...

QR Code

Use your smartphone camera to open QR code link.

To edit notification comments on pull requests, go to your Netlify project configuration.

netlify[bot] avatar Jun 17 '25 04:06 netlify[bot]

A transparent outline box-shadow on the Panel part prevents muddying from the adjacent borders (below):

Screenshot 2025-06-17 at 2 36 47 pm Screenshot 2025-06-17 at 2 39 15 pm

In the above SS, it's combined with the inset shadow on the Content element.

Question is how to visually connect the panel better with its trigger. Darkening its background makes it look like a header. A border wrapping around the entire thing looks a bit off too though

atomiks avatar Jun 17 '25 04:06 atomiks

IF jsdoc @examples are extracted the existing docs components handle it well, added a fake one to Toggle (the deploy preview is stuck on an older cached json though)

Screenshot 2025-06-18 at 3 06 37 AM

mj12albert avatar Jun 17 '25 19:06 mj12albert

If the Default is undefined we can simply remove that whole row in the expanded form

atomiks avatar Jun 18 '25 11:06 atomiks

In the above SS, it's combined with the inset shadow on the Content element.

Question is how to visually connect the panel better with its trigger. Darkening its background makes it look like a header. A border wrapping around the entire thing looks a bit off too though

I added all of this, what do you think @colmtuite ?

Here's the image I was referencing:

Frame 1 (10)

mj12albert avatar Jun 20 '25 14:06 mj12albert

Closing this as we're going with the details/summary version

mj12albert avatar Jul 08 '25 04:07 mj12albert