mithril-materialized
    Preparing search index...

    Interface SwitchAttrs

    interface SwitchAttrs {
        checked?: boolean;
        className?: string;
        disabled?: boolean;
        id?: string;
        isMandatory?: boolean;
        label?: string;
        left?: string;
        newRow?: boolean;
        onchange?: (value: boolean, maxValue?: boolean) => void;
        right?: string;
    }

    Hierarchy

    • Pick<
          InputAttrs<boolean>,

              | "label"
              | "disabled"
              | "id"
              | "className"
              | "onchange"
              | "newRow"
              | "isMandatory",
      >
      • SwitchAttrs
    Index

    Properties

    checked?: boolean

    If checked is true, the switch is set in the right position.

    className?: string

    The class name(s) for this virtual element, as a space-separated list.

    disabled?: boolean

    Sets the input field to disabled.

    id?: string

    Optional ID.

    isMandatory?: boolean

    If true, add a mandatory * after the label (if any), and add the required and aria-required attributes to the input element.

    label?: string

    Optional label.

    left?: string

    Left text label

    newRow?: boolean

    If true, break to a new row

    onchange?: (value: boolean, maxValue?: boolean) => void

    Invoked when the input looses focus. For range sliders with minmax, second parameter is maxValue.

    right?: string

    Right text label