Skip to content

Commit 4bfe227

Browse files
authored
fix(VisuallyHidden): required validation not working for undefined/null (#2026)
1 parent 3a3990b commit 4bfe227

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

packages/core/src/VisuallyHidden/VisuallyHiddenInput.vue

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -21,7 +21,7 @@ const isFormArrayEmptyAndRequired = computed(() =>
2121
2222
const parsedValue = computed(() => {
2323
// if primitive value
24-
if (typeof props.value === 'string' || typeof props.value === 'number' || typeof props.value === 'boolean') {
24+
if (typeof props.value === 'string' || typeof props.value === 'number' || typeof props.value === 'boolean' || props.value === null || props.value === undefined) {
2525
return [{ name: props.name, value: props.value }]
2626
}
2727

0 commit comments

Comments
 (0)