Aria API

This page provides an overview of the Aria component API, detailing its props, emits, slots, and exposed methods/states.

Props

The Aria component accepts the following props:

PropDefaultTypeDescription
placeholder""string or undefinedPlaceholder text for the input field.
autocomplete"on""on" or "off" or undefinedAutocomplete behavior for the input field.
wrap"soft""soft" or "hard" or "off" or undefinedText wrapping behavior for the input field.
rows3number or undefinedNumber of visible rows for text input (applies to textarea elements).
maxLength9999number or undefinedMaximum allowed length of the input field's value.
classInput""StyleClass or undefinedCustom CSS class for the input element.
idundefinedstring or undefinedUnique identifier for the input element.
modelValueundefinedstring or number or null or undefinedThe current value of the input field.

Emits

The Aria component emits the following events:

EmitPayloadDescription
focusFocusEventEmitted when the input field gains focus.
blurFocusEventEmitted when the input field loses focus.
update:modelValuestringEmitted when the modelValue is updated.
change:modelValuestringEmitted when the modelValue changes.
update:isInvalidbooleanEmitted when the invalid state of the input is updated.

Slots

The Aria component provides the following slots:

SlotPayloadDescription
defaultVNode[]Default slot for custom content inside the input component.
beforeVNode[]Slot for content to be displayed before the input field.
afterVNode[]Slot for content to be displayed after the input field.

Expose

The Aria component exposes the following methods and states via ref:

ExposeValueDescription
layoutInputLayoutExpose or undefinedReference to the input layout state.
inputRefHTMLElement or undefinedReference to the input HTML element.
idAriaProps["id"]Current id value of the input field.
modelValueAriaProps["modelValue"]Current modelValue of the input field.
placeholderAriaProps["placeholder"]Current placeholder of the input field.
autocompleteAriaProps["autocomplete"]Current autocomplete setting for the input field.
wrapAriaProps["wrap"]Current wrapping behavior for the input field.
rowsAriaProps["rows"]Current number of rows for the input field.
maxLengthAriaProps["maxLength"]Current maximum length for the input field.
isValueInputLayoutProps["isValue"]Indicates whether the input has a value.
modeAriaProps["mode"]Current mode of the input field.
isDisabledAriaProps["disabled"]Indicates whether the input is disabled.
isLoadingAriaProps["loading"]Indicates whether the input is in a loading state.
isInvalidAriaProps["isInvalid"]Indicates whether the input is invalid.
messageInvalidAriaProps["messageInvalid"]Validation error message for the input field.
classStyleAriaProps["class"]CSS class for the input container.

Methods:

  • clear(): void - Clears the input field value and resets the invalid state.
  • focus(env: FocusEvent): void - Focuses the input field and sets the active state.
  • blur(env: FocusEvent): void - Removes focus from the input field and resets the active state.
© 2025 FishtVue by Egoka