EnhanceSliderOptions: {
    defaultValue?: number;
    format?: (value: number) => string;
    onValueChange?: (value: number) => void;
    unit?: string;
}

Options for enhanceSlider.

Type declaration

  • OptionaldefaultValue?: number

    Initial value; falls back to the input's own value.

  • Optionalformat?: (value: number) => string

    Format the value for the <output> and aria-valuetext. Defaults to the number followed by unit.

  • OptionalonValueChange?: (value: number) => void

    Called with the new value on every change while dragging.

  • Optionalunit?: string

    Text appended to the displayed value, e.g. %.