mirror of
https://github.com/ArthurDanjou/ui.git
synced 2026-01-22 07:50:36 +01:00
chore: uniformize defineModel placement and emits
This commit is contained in:
@@ -40,11 +40,11 @@ import { useId, useAppConfig, useFormField } from '#imports'
|
||||
const props = defineProps<SwitchProps>()
|
||||
defineSlots<SwitchSlots>()
|
||||
|
||||
const modelValue = defineModel<boolean | undefined>({ default: undefined })
|
||||
|
||||
const appConfig = useAppConfig()
|
||||
const rootProps = useForwardProps(reactivePick(props, 'as', 'required', 'value'))
|
||||
|
||||
const modelValue = defineModel<boolean | undefined>({ default: undefined })
|
||||
|
||||
const { inputId: _inputId, emitFormChange, size, color, name, disabled } = useFormField<SwitchProps>(props)
|
||||
const inputId = _inputId.value ?? useId()
|
||||
|
||||
|
||||
Reference in New Issue
Block a user