daisy-ui-kit 5.0.0-pre.16 → 5.0.0-pre.18
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/app/components/Input.vue
CHANGED
|
@@ -51,7 +51,7 @@ function setValue(val: string | number | null) {
|
|
|
51
51
|
emit('update:modelValue', val)
|
|
52
52
|
}
|
|
53
53
|
|
|
54
|
-
const labelCtx = inject('labelCtx')
|
|
54
|
+
const labelCtx = inject('labelCtx', null)
|
|
55
55
|
|
|
56
56
|
function handleInput(event: Event) {
|
|
57
57
|
let val: string | number | null
|
|
@@ -62,16 +62,6 @@ function handleInput(event: Event) {
|
|
|
62
62
|
val = (event.target as HTMLInputElement).value
|
|
63
63
|
}
|
|
64
64
|
emit('update:modelValue', val)
|
|
65
|
-
|
|
66
|
-
// Sync checked only on input if it's a checkbox
|
|
67
|
-
if (
|
|
68
|
-
props.type === 'checkbox' &&
|
|
69
|
-
labelCtx &&
|
|
70
|
-
Object.prototype.hasOwnProperty.call(labelCtx, 'checked') &&
|
|
71
|
-
typeof labelCtx.checked.value === 'boolean'
|
|
72
|
-
) {
|
|
73
|
-
labelCtx.checked.value = Boolean(event.target.checked)
|
|
74
|
-
}
|
|
75
65
|
}
|
|
76
66
|
|
|
77
67
|
const inputAttrs = computed(() => {
|