IInlineEditProps

interface
Form & Input

Props contract for OrigamInlineEdit — the edit-in-place component. Controls validation rules, auto-focus, select-on-focus, confirm/cancel triggers, multiline mode, and built-in action buttons.

TypeScript

Definition

The TypeScript interface definition as found in the origam source. Click the copy icon to copy the snippet.

typescript

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.

modelValue
required
string | number
Current value (v-model target). Accepts string or number.
placeholder
string
Placeholder shown on the input and in the default display slot when the value is empty.
rules
Array<TInlineEditRule>
Array of validation rules evaluated on confirm. First failure blocks the commit.
validate
TInlineEditValidator
Sync or async validation callback. Runs after rules pass. Returns true or an error message.
autoFocus
boolean
true
Auto-focus the input when entering edit mode.
selectOnFocus
boolean
true
Select all text when the input gains focus on edit entry.
confirmOnBlur
boolean
true
Confirm the draft when the input loses focus.
confirmOnEnter
boolean
true
Confirm on Enter. Disable for multiline mode where Enter should insert a newline.
cancelOnEscape
boolean
true
Cancel (revert) the draft on Escape.
disabled
boolean
false
Disables the component. The display affordance becomes non-interactive.
multiline
boolean
false
Render a <textarea> instead of <input> in edit mode.
trim
boolean
true
Strip surrounding whitespace before emitting and validating.
inputType
TInlineEditInputType
'text'
Native HTML input type when not in multiline mode.
loadingOnConfirm
boolean
false
Surface a loading affordance (CSS class hook) while an async validator is in flight.
showActions
boolean
false
Render built-in Edit / Confirm / Cancel icon buttons next to the component.

Ecosystem

Used by

Components and composables that extend or consume this interface.

Usage

Examples

Ready-to-paste code snippets using this interface.

Edit-in-place title with async validation

vue