diff --git a/content/components/accordion.md b/content/components/accordion.md index adb3253aa..53e3d8d4c 100644 --- a/content/components/accordion.md +++ b/content/components/accordion.md @@ -32,3 +32,40 @@ description: Organizes content into collapsible sections, allowing users to focu ``` + +## Examples + +### Multiple + +Multiple accordion items open at the same time using the `multiple` prop. + +```svelte showLineNumbers {1} + + + +``` + +### Controlled + +You can programmatically control the active of the accordion item(s) using the `value` prop. + +```svelte showLineNumbers + + + + + + + + + + + + + + + + +``` diff --git a/content/components/alert-dialog.md b/content/components/alert-dialog.md index da3848d6c..b309b91e2 100644 --- a/content/components/alert-dialog.md +++ b/content/components/alert-dialog.md @@ -35,11 +35,15 @@ description: A modal window that alerts users with important information and awa ``` -## Controlled Usage + -If you want to control or be aware of the `open` state of the dialog from outside of the component, you can bind to the `open` prop. +## Examples -```svelte +### Controlled + +If you want to control or be aware of the `open` state of the dialog from outside of the component, bind to the `open` prop. + +```svelte showLineNumbers