mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-14 20:19:34 +01:00
feat(Radio/Checkbox/Toggle)!: handle color prop for form elements (#323)
Co-authored-by: Benjamin Canac <canacb1@gmail.com>
This commit is contained in:
committed by
Benjamin Canac
parent
97a1c86433
commit
ffb312d34d
@@ -14,7 +14,7 @@ Use a `v-model` to make the Checkbox reactive.
|
||||
#code
|
||||
```vue
|
||||
<script setup>
|
||||
const selected = ref(false)
|
||||
const selected = ref(true)
|
||||
</script>
|
||||
|
||||
<template>
|
||||
@@ -36,6 +36,20 @@ props:
|
||||
---
|
||||
::
|
||||
|
||||
### Style
|
||||
|
||||
Use the `color` prop to change the style of the Checkbox.
|
||||
|
||||
::component-card
|
||||
---
|
||||
baseProps:
|
||||
name: 'checkbox2'
|
||||
label: 'Label'
|
||||
props:
|
||||
color: 'primary'
|
||||
---
|
||||
::
|
||||
|
||||
### Required
|
||||
|
||||
Use the `required` prop to display a red star next to the label.
|
||||
@@ -43,7 +57,7 @@ Use the `required` prop to display a red star next to the label.
|
||||
::component-card
|
||||
---
|
||||
baseProps:
|
||||
name: 'checkbox2'
|
||||
name: 'checkbox3'
|
||||
props:
|
||||
label: 'Label'
|
||||
required: true
|
||||
@@ -57,7 +71,7 @@ Use the `help` prop to display some text under the Checkbox.
|
||||
::component-card
|
||||
---
|
||||
baseProps:
|
||||
name: 'checkbox3'
|
||||
name: 'checkbox4'
|
||||
props:
|
||||
label: 'Label'
|
||||
help: 'Please check this box'
|
||||
|
||||
Reference in New Issue
Block a user