diff --git a/content/components/alert-dialog.md b/content/components/alert-dialog.md index e80d23e0d..697c84ea2 100644 --- a/content/components/alert-dialog.md +++ b/content/components/alert-dialog.md @@ -35,6 +35,31 @@ description: Presents critical information or prompts to the user, typically req ``` +## 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. + +```svelte + + + + + + + + + + + + + + + +``` + 🚧 **UNDER CONSTRUCTION** 🚧 diff --git a/content/components/checkbox.md b/content/components/checkbox.md index 31b87b9d0..1f8d6cde4 100644 --- a/content/components/checkbox.md +++ b/content/components/checkbox.md @@ -27,6 +27,23 @@ description: Allow users to mark options as checked, unchecked, or indeterminate ``` +## Controlled Usage + +If you want to control or be aware of the `checked` state of the checkbox from outside of the component, you can bind to the `checked` prop. + +```svelte + + +

Checked: {myChecked}

+ + + + +``` + 🚧 **UNDER CONSTRUCTION** 🚧 diff --git a/content/components/collapsible.md b/content/components/collapsible.md index d55e6a4ec..063cfe46d 100644 --- a/content/components/collapsible.md +++ b/content/components/collapsible.md @@ -27,6 +27,23 @@ description: An interactive component which expands and collapses content. ``` +## Controlled Usage + +Sometimes, you want to either control or be aware of the `open` state of the collapsible from outside of the component. To do so, you can bind to the `open` prop. + +```svelte + + + + + + + +``` + 🚧 **UNDER CONSTRUCTION** 🚧 diff --git a/content/components/dialog.md b/content/components/dialog.md index 241a56231..927ad0329 100644 --- a/content/components/dialog.md +++ b/content/components/dialog.md @@ -34,6 +34,30 @@ description: A window overlaid on either the primary window or another dialog wi ``` +## 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. + +```svelte + + + + + + + + + + + + + + +``` + 🚧 **UNDER CONSTRUCTION** 🚧 diff --git a/content/components/popover.md b/content/components/popover.md index a6e07e730..952f8a894 100644 --- a/content/components/popover.md +++ b/content/components/popover.md @@ -30,6 +30,26 @@ description: Displays content in a floating container that appears above the sur ``` +## Controlled Usage + +If you want to control or be aware of the `open` state of the popover from outside of the component, you can bind to the `open` prop. + +```svelte + + + + + + + + + + +``` + 🚧 **UNDER CONSTRUCTION** 🚧