Skip to content

Commit

Permalink
build: fix form types
Browse files Browse the repository at this point in the history
  • Loading branch information
m0ksem committed Nov 26, 2023
1 parent 5c08b24 commit 7a6f4df
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions packages/ui/src/composables/useForm/useForm.ts
Original file line number Diff line number Diff line change
Expand Up @@ -28,6 +28,7 @@ export const useForm = <Names extends string = string>(ref: string | Ref<typeof

return {
isValid: computed(() => form.value?.isValid || false),
immediate: computed(() => form.value?.immediate || false),
isLoading: computed(() => form.value?.isLoading || false),
isDirty: computed(() => form.value?.isDirty || false),
fields: computed(() => form.value?.fields ?? []),
Expand All @@ -37,9 +38,7 @@ export const useForm = <Names extends string = string>(ref: string | Ref<typeof
errorMessages: computed(() => form.value?.errorMessages || []),
errorMessagesNamed: computed(() => form.value?.errorMessagesNamed || {}),
validate: () => form.value?.validate(),
reset: () => {
form.value?.reset()
},
reset: () => form.value?.reset(),
resetValidation: () => form.value?.resetValidation(),
focus: () => form.value?.focus(),
focusInvalidField: () => form.value?.focusInvalidField(),
Expand Down

0 comments on commit 7a6f4df

Please sign in to comment.