Skip to content

Input

Get user Input. Use with Field to access all functionalities

Examples

Base

Show code

Variants

Show code

Sizes

Show code

With Icons

Show code

Class props

'Classes applied to the element'

Input component

Get user Input. Use with Field to access all functionalities

html
<o-input></o-input>

Props

Prop nameDescriptionTypeValuesDefault
autocomplete-
From config:
input: {
  autocomplete: "off"
}
autosize-false
clearIcon-
From config:
input: {
  clearIcon: "close-circle"
}
clearable-
From config:
input: {
  clearable: false
}
counter-
From config:
input: {
  counter: false
}
customValidity-""
debounce-
From config:
autocomplete: {
  debounce: 400
}
disabled-false
expanded-false
icon-
From config:
input: {
  icon: undefined
}
iconClickable-false
iconPack-
From config:
input: {
  iconPack: undefined
}
iconRight-
From config:
input: {
  iconRight: undefined
}
iconRightClickable-false
iconRightVariant-
id-Default function (see source code)
maxlength-
v-model-
override-
passwordReveal-false
placeholder-
rounded-false
size-
From config:
input: {
  size: undefined
}
statusIcon-
From config:
{
  statusIcon: true
}
type-"text"
useHtml5Validation-
From config:
{
  useHtml5Validation: true
}
variant-
From config:
input: {
  variant: undefined
}

Events

Event namePropertiesDescription
update:modelValuevalue string | number - updated modelValue propmodelValue prop two-way binding
inputvalue string | number - input value
event Event - native event
on input change event
focusevent Event - native eventon input focus event
blurevent Event - native eventon input blur event
invalidevent Event - native eventon input invalid event
icon-clickevent Event - native eventon icon click event
icon-right-clickevent Event - native eventon icon right click event

Sass variables

Current theme ➜ Oruga

SASS VariableDefault
$input-background-color#ffffff
$input-border-colorvar(--#{$prefix}grey-lighter)
$input-border-stylesolid
$input-border-width1px
$input-border-radiusvar(--#{$prefix}base-border-radius)
$input-rounded-border-radiusvar( --#{$prefix}base-border-radius-rounded)
$input-box-shadow$control-box-shadow
$input-color#363636
$input-icon-zindex4
$input-height$control-height
$input-line-heightvar(--#{$prefix}base-line-height)
$input-margin0
$input-padding$control-padding-vertical $control-padding-horizontal
$input-counter-font-size0.75rem
$input-counter-margin0.25rem 0 0 0.5rem
$input-textarea-max-height600px
$input-textarea-min-height120px
$input-textarea-padding0.625em

See ➜ 📄 Full scss file

Current theme ➜ Bulma

The theme does not have any custom variables for this component.

Current theme ➜ Bootstrap

SASS VariableDefault
$input-icon-color$input-color
$input-icon-spacer0.75rem
$input-icon-padding-sm2rem
$input-icon-padding2.5rem
$input-icon-padding-lg3rem

See ➜ 📄 Full scss file

Released under the MIT License.