docs: update

This commit is contained in:
Benjamin Canac
2024-06-26 19:09:05 +02:00
parent c63b3cec6a
commit 0b3ce24eb6
64 changed files with 798 additions and 5258 deletions

View File

@@ -1,96 +1,18 @@
---
description: Display a checkbox field.
links:
- label: Radix Vue
icon: i-custom-radix-vue
to: https://www.radix-vue.com/components/checkbox.html
- label: GitHub
icon: i-simple-icons-github
to: https://github.com/nuxt/ui/blob/dev/src/runtime/components/forms/Checkbox.vue
to: https://github.com/nuxt/ui/blob/dev/src/runtime/components/Checkbox.vue
---
## Usage
Use a `v-model` to make the Checkbox reactive.
## Examples
:component-example{component="checkbox-example"}
:component-api
### Label
Use the `label` prop to display a label on the right.
::component-card
---
props:
label: 'Label'
---
::
### Style
Use the `color` prop to change the style of the Checkbox.
::component-card
---
baseProps:
label: 'Label'
props:
color: 'primary'
---
::
### Required
Use the `required` prop to display a red star next to the label of the Checkbox.
::component-card
---
props:
label: 'Label'
required: true
---
::
### Help
Use the `help` prop to display some text under the Checkbox.
::component-card
---
props:
label: 'Label'
help: 'Please check this box'
---
::
### Disabled
Use the `disabled` prop to disable the Checkbox.
::component-card
---
props:
disabled: true
---
::
## Slots
### `label`
Use the `#label` slot to override the content of the label.
::component-card
---
slots:
label: <span class="italic">Label</span>
---
#label
[Label]{.italic}
::
## Props
:component-props
## Config
:component-preset
:component-theme