Which virtual keyboard to raise on touch devices. Distinct from `type`: `type="text" inputmode="decimal"` keeps free-form input while still opening a numeric pad, which is what amount and phone fields want. `inputMode` is also a global HTMLElement property, so this deliberately overrides it: on the host it is inert (the host is not editable), and the value only does anything once forwarded to the inner `` below.
invalid
—
boolean
false
label
—
string
''
loading
—
boolean
false
max
—
string | undefined
—
Upper bound for `type="number"` / `type="date"` and friends.
maxlength
—
number | undefined
—
min
—
string | undefined
—
Lower bound for `type="number"` / `type="date"` and friends.
minlength
—
number | undefined
—
name
—
string
''
pattern
—
string | undefined
—
Regular expression the value must match, per native constraint validation.
placeholder
—
string
''
readonly
—
boolean
false
required
—
boolean
false
size
—
'xs' | 'sm' | 'md' | 'lg'
'md'
step
—
string | undefined
—
Granularity of the accepted value; `any` disables stepping.
type
—
HTMLInputElement['type']
'text'
value
—
string
''
Events
Event
Description
nana-input
Fired on every keystroke (`detail.value`)
nana-change
Fired when the value is committed (`detail.value`)
nana-clear
Fired when the clear button or Escape empties the field