Fix Textarea validator
This commit is contained in:
parent
3eb63e9b49
commit
acdaf54a91
|
@ -19,12 +19,12 @@ const emit = defineEmits(['update:modelValue']);
|
||||||
const props = defineProps({
|
const props = defineProps({
|
||||||
modelValue: {
|
modelValue: {
|
||||||
required: true,
|
required: true,
|
||||||
validator: (value) => typeof value === 'string',
|
validator: (value) => value === null || typeof value === 'string',
|
||||||
},
|
},
|
||||||
field: {
|
field: {
|
||||||
required: true,
|
required: true,
|
||||||
validator: (value) =>
|
validator: (value) =>
|
||||||
hasKeys(value, ['required', 'type', 'key', 'columns', 'name', 'default']) &&
|
hasKeys(value, ['required', 'type', 'key', 'columns', 'name', 'default', 'rows']) &&
|
||||||
typeof value.required === 'boolean' &&
|
typeof value.required === 'boolean' &&
|
||||||
typeof value.key === 'string' &&
|
typeof value.key === 'string' &&
|
||||||
value.key.length > 0 &&
|
value.key.length > 0 &&
|
||||||
|
|
Loading…
Reference in New Issue