IValidationProps
interface
Form & Validation
Complete validation surface for form-control components — extends IFocusProps with rules, error state, error messages, disabled/readonly flags, label and the validateOn trigger.
TypeScript
Definition
The TypeScript interface definition as found in the origam source. Click the copy icon to copy the snippet.
Inheritance
Extends
Parent interfaces this one inherits from. Their properties are available on every consumer of this interface.
API
Properties
Every property declared by this interface, with its type, optionality and default.
- disabledboolean
- Disables the field — prevents interaction and validation.
- errorstring | boolean
- Forces the field into an error state regardless of rule results.
- errorMessagesArray<string> | string
- Static error message(s) shown alongside rule-produced errors.
- maxErrorsnumber | string
- Maximum number of error messages to display simultaneously.
- namestring
- HTML name attribute and validation identifier for the field.
- labelstring
- Label text displayed above or inside the field.
- readonlyboolean
- Makes the field non-editable while keeping it focusable and validatable.
- rulesArray<any>
- Array of validation rule functions. Each receives the current value and returns true (valid) or an error string.
- modelValueany
- The v-model value of the field, forwarded to rule functions during validation.
- validateOnTValidateOn
- When validation runs — e.g. "input", "blur", "submit", or combinations thereof.
- validationValueany
- Override the value passed to rule functions (useful when the internal representation differs from modelValue).
Ecosystem
Used by
Components and composables that extend or consume this interface.
Usage
Examples
Ready-to-paste code snippets using this interface.
Declaring a typed form-field component