UNPKG

1.15 kBTypeScriptView Raw
1/// <reference types="react" />
2import { AbstractPureComponent } from "../../common";
3import { HandleHtmlProps } from "./handleProps";
4import { SliderBaseProps } from "./multiSlider";
5export type NumberRange = [number, number];
6export interface RangeSliderProps extends SliderBaseProps {
7 /**
8 * Range value of slider. Handles will be rendered at each position in the range.
9 *
10 * @default [0, 10]
11 */
12 value?: NumberRange;
13 /** Callback invoked when the range value changes. */
14 onChange?(value: NumberRange): void;
15 /** Callback invoked when a handle is released. */
16 onRelease?(value: NumberRange): void;
17 /** HTML props to apply to the slider Handles */
18 handleHtmlProps?: {
19 start?: HandleHtmlProps;
20 end?: HandleHtmlProps;
21 };
22}
23/**
24 * Range slider component.
25 *
26 * @see https://blueprintjs.com/docs/#core/components/sliders.range-slider
27 */
28export declare class RangeSlider extends AbstractPureComponent<RangeSliderProps> {
29 static defaultProps: RangeSliderProps;
30 static displayName: string;
31 render(): JSX.Element;
32 protected validateProps(props: RangeSliderProps): void;
33}