-
Notifications
You must be signed in to change notification settings - Fork 10
/
Copy pathtypes.ts
59 lines (54 loc) · 1.42 KB
/
types.ts
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
import { NativeSyntheticEvent } from 'react-native';
export type RangeSliderChangeEvent = NativeSyntheticEvent<{
min: number;
max: number;
target?: any;
fromUser?: boolean;
}>;
export interface CommonRangeSliderProps {
min: number;
max: number;
onChange?: (min: number, max: number) => void;
tintColor?: string;
tintColorBetweenHandles?: string;
step?: number;
handleColor?: string;
style?: object;
prefix?: string;
suffix?: string;
}
export interface IOSOnlyRangeSliderProps {
type?: 'slider' | 'range';
selectedMinimum: number;
selectedMaximum: number;
handleBorderColor?: string;
handleBorderWidth?: number;
minLabelColor?: string;
maxLabelColor?: string;
handleDiameter?: number;
lineHeight?: number;
hideLabels?: boolean;
minLabelFont?: string;
maxLabelFont?: string;
minLabelFontSize?: number;
maxLabelFontSize?: number;
labelPadding?: number;
minDistance?: number;
maxDistance?: number;
lineBorderWidth?: number;
lineBorderColor?: string;
}
export interface AndroidOnlyRangeSliderProps {
leftHandleColor?: string;
rightHandleColor?: string;
leftHandlePressedColor?: string;
rightHandlePressedColor?: string;
handlePressedColor?: string;
minStartValue?: number;
maxStartValue?: number;
fixGap?: number;
cornerRadius?: number;
}
export type RangeSliderProps = CommonRangeSliderProps &
Partial<IOSOnlyRangeSliderProps> &
Partial<AndroidOnlyRangeSliderProps>;