Skip to content

TextareaOptions

Defined in: components/textarea.ts:6

Options for textarea.

optional attrs?: string

Defined in: components/field.ts:14

Aberdeen attr/style string applied to the field’s wrapper element.

FieldOptions.attrs


optional label?: Slot

Defined in: components/field.ts:16

Visible label, associated with the control via for/id for a11y.

FieldOptions.label


optional help?: Slot

Defined in: components/field.ts:18

Helper text shown beneath the control.

FieldOptions.help


optional error?: string

Defined in: components/field.ts:23

Error message shown beneath the control. When set, the control is marked aria-invalid and styled accordingly. May be reactive.

FieldOptions.error


optional disabled?: boolean

Defined in: components/field.ts:25

Disables the control.

FieldOptions.disabled


optional required?: boolean

Defined in: components/field.ts:27

Marks the field required (adds a * and the aria-required attribute).

FieldOptions.required


optional name?: string

Defined in: components/field.ts:29

The name attribute, for native form submission.

FieldOptions.name


optional id?: string

Defined in: components/field.ts:31

Explicit id for the control; auto-generated when omitted.

FieldOptions.id


optional inputAttrs?: string

Defined in: components/field.ts:33

Aberdeen attr/style string applied to the control (input) element itself.

FieldOptions.inputAttrs


optional placeholder?: string

Defined in: components/textarea.ts:8

Placeholder text.


optional bind?: Bindable<string>

Defined in: components/textarea.ts:10

Two-way binding target.


optional value?: string

Defined in: components/textarea.ts:12

Static initial value.


optional rows?: number

Defined in: components/textarea.ts:14

Visible number of text rows. Defaults to 4. Ignored when autoGrow is enabled.


optional resize?: "none" | "vertical" | "horizontal" | "both"

Defined in: components/textarea.ts:16

Whether the textarea may be resized by the user. Defaults to "vertical". Ignored when autoGrow is enabled.


optional autoGrow?: boolean

Defined in: components/textarea.ts:18

Auto-grow the textarea to fit its content. Defaults to true.


optional input?: (event) => void

Defined in: components/textarea.ts:20

Fired on every input event.

Event

void


optional change?: (event) => void

Defined in: components/textarea.ts:22

Fired on change (commit).

Event

void