Class: SwitchOqt

.Components.Input.SwitchOqt(namenon-null, idnullable, checkedopt, optionsopt)

new SwitchOqt(namenon-null, idnullable, checkedopt, optionsopt)

Componente que renderiza un switch

Parameters:
Name Type Attributes Default Description
name string

Identificador del componente en el form

id string <nullable>

Identificador único de componente (si no se pasa este parámetro se genera uno automáticamente)

checked "true" | "false" <optional>
"false"

Establece el estado del switch

options string <optional>
"{}"

Json string con parámetros que se pueden enviar al input en formato React (className, style, etc)

Source:
Example
<div class="flex-grow-1 align-self-center" style="width: 20px;">
  <div class="form-switch android-switch switch-green switch-xs">      
    <switch name="{{switchId}}" checked="{{switchChecked}}"/>
  </div>
</div >