New to Kendo UI for VueStart a free 30-day trial

SwitchProps

Interface

Represents the props of the Kendo UI for Vue Switch component.

Definition

Package:@progress/kendo-vue-inputs

Properties

Specifies the accessKey of the Switch.

Identifies the element(s) which will describe the component, similar to HTML aria-describedby attribute. For example these elements could contain error or hint message.

Identifies the element(s) which will label the component.

checked?

boolean

Sets the current value of the Switch (see example).

Sets the className of the wrapping element of the Switch.

Sets the value of the Switch when it is initially displayed (see example).

Sets the default value of the Switch.

dir?

string

Sets the dir property of the wrapping element of the Switch.

disabled?

boolean

Disables the Switch when set to true (see example).

id?

string

Sets the id of the Switch.

modelValue?

string | number | boolean | string[]

name?

string

Specifies the name of the Switch.

offLabel?

string

Changes the Off label(see example).

onBlur?

(event: any) => void

Fires each time the Switch gets blurred.

Parameters:eventany

Fires each time the user selects a new value (see example).

Parameters:eventSwitchChangeEvent

onFocus?

(event: any) => void

Fires each time the Switch component gets focused.

Parameters:eventany

onLabel?

string

Changes the On label (see example).

required?

boolean

Specifies if null is a valid value for the component.

size?

"small" | "medium" | "large"

Configures the size of the Switch.

The available options are:

  • small
  • medium
  • large
Default:

undefined

tabIndex?

number

Specifies the tabIndex of the component.

thumbRounded?

"small" | "medium" | "large" | "none" | "full"

Configures the thumbRounded of the Switch.

The available options are:

  • none
  • small
  • medium
  • large
  • full
Default:

undefined

trackRounded?

"small" | "medium" | "large" | "none" | "full"

Configures the trackRounded of the Switch.

The available options are:

  • none
  • small
  • medium
  • large
  • full
Default:

undefined

valid?

boolean

Overrides the validity state of the component. If valid is set, the required property will be ignored.

Controls the form error message of the component. If set to an empty string, no error will be thrown.

If set to false, no visual representation of the invalid state of the component will be applied.

value?

string | number | boolean | string[]

Sets the value of the Switch. It can either be of the primitive (string, number, boolean) or of the complex (array) type.