AsterUIDocsv1.0.2

Docs / Component reference

Slider

Choose one value on a continuous track. Marks and a value badge help the reader place the selection.

Slider example

Install

sh
npx @fierst/ui@1.0.2 add slider

Registry dependencies: theme.

Exports from ./ui/slider: Slider.

Download the registry source for slider 1.0.2.

API contracts

ts
export function* Slider(
  props: {
    id?: string;
    label?: string;
    value?: number;
    defaultValue?: number;
    min?: number;
    max?: number;
    step?: number;
    unit?: string;
    showMarks?: boolean;
    disabled?: boolean;
    onChange?: (value: number) => void;
    class?: string;
  },
  ctx: Ctx,
)