feat(Form): add validate-on error-input

Adds `error-input` option to the validate on prop to validate on input
only when the field has an error.

Resolves #2599
This commit is contained in:
Romain Hamel
2025-06-14 18:09:02 +02:00
parent 59c26ec123
commit d8f29e019d
16 changed files with 47 additions and 29 deletions

View File

@@ -4,7 +4,7 @@ import ComponentRender from '../component-render'
import theme from '#build/ui/input'
import { renderForm } from '../utils/form'
import { flushPromises, mount } from '@vue/test-utils'
import type { FormInputEvents } from '~/src/module'
import type { FormValidateOn } from '~/src/module'
import { expectEmitPayloadType } from '../utils/types'
describe('InputMenu', () => {
@@ -110,7 +110,7 @@ describe('InputMenu', () => {
})
describe('form integration', async () => {
async function createForm(validateOn?: FormInputEvents[]) {
async function createForm(validateOn?: FormValidateOn[]) {
const wrapper = await renderForm({
props: {
validateOn,