mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-17 05:28:09 +01:00
fix(Toggle): missing disabled prop
This commit is contained in:
@@ -26,6 +26,18 @@ excludedProps:
|
||||
---
|
||||
::
|
||||
|
||||
### Disabled
|
||||
|
||||
Use the `disabled` prop to disable the Toggle.
|
||||
|
||||
::component-card
|
||||
---
|
||||
props:
|
||||
disabled: true
|
||||
---
|
||||
::
|
||||
|
||||
|
||||
## Props
|
||||
|
||||
:component-props
|
||||
|
||||
@@ -2,6 +2,7 @@
|
||||
<Switch
|
||||
v-model="active"
|
||||
:name="name"
|
||||
:disabled="disabled"
|
||||
:class="[active ? ui.active : ui.inactive, ui.base]"
|
||||
>
|
||||
<span :class="[active ? ui.container.active : ui.container.inactive, ui.container.base]">
|
||||
@@ -43,6 +44,10 @@ export default defineComponent({
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
disabled: {
|
||||
type: Boolean,
|
||||
default: false
|
||||
},
|
||||
onIcon: {
|
||||
type: String,
|
||||
default: () => appConfig.ui.toggle.default.onIcon
|
||||
|
||||
Reference in New Issue
Block a user