@xaui/native 0.0.21 → 0.0.24
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +195 -2
- package/dist/alert/index.js +1 -2
- package/dist/app-bar/index.cjs +217 -0
- package/dist/app-bar/index.d.cts +52 -0
- package/dist/app-bar/index.d.ts +52 -0
- package/dist/app-bar/index.js +142 -0
- package/dist/autocomplete/index.js +48 -36
- package/dist/avatar/index.js +1 -2
- package/dist/badge/index.js +1 -2
- package/dist/bottom-sheet/index.js +1 -2
- package/dist/bottom-tab-bar/index.cjs +571 -0
- package/dist/bottom-tab-bar/index.d.cts +211 -0
- package/dist/bottom-tab-bar/index.d.ts +211 -0
- package/dist/bottom-tab-bar/index.js +497 -0
- package/dist/button/index.d.cts +102 -5
- package/dist/button/index.d.ts +102 -5
- package/dist/button/index.js +2 -3
- package/dist/button.type-j1ZdkkSl.d.cts +4 -0
- package/dist/button.type-j1ZdkkSl.d.ts +4 -0
- package/dist/card/index.cjs +2 -0
- package/dist/card/index.d.cts +6 -1
- package/dist/card/index.d.ts +6 -1
- package/dist/card/index.js +4 -2
- package/dist/carousel/index.js +1 -1
- package/dist/chart/index.cjs +1067 -0
- package/dist/chart/index.d.cts +218 -0
- package/dist/chart/index.d.ts +218 -0
- package/dist/chart/index.js +1026 -0
- package/dist/checkbox/index.js +1 -2
- package/dist/chip/index.js +1 -2
- package/dist/chunk-3XSXTM3G.js +661 -0
- package/dist/chunk-4KSZLONZ.js +79 -0
- package/dist/{chunk-DXXNBF5P.js → chunk-CZFDZPAS.js} +0 -5
- package/dist/{chunk-LTKYHG5V.js → chunk-GHCVNQET.js} +12 -5
- package/dist/chunk-I4V5Y5GD.js +76 -0
- package/dist/{chunk-F7WH4DMG.js → chunk-UI5L26KD.js} +1 -1
- package/dist/{chunk-LUBWRVI2.js → chunk-ULJSCNPE.js} +1 -1
- package/dist/chunk-URBEEDFX.js +79 -0
- package/dist/core/index.js +3 -5
- package/dist/datepicker/index.js +1 -2
- package/dist/divider/index.js +2 -3
- package/dist/drawer/index.cjs +310 -0
- package/dist/drawer/index.d.cts +58 -0
- package/dist/drawer/index.d.ts +58 -0
- package/dist/drawer/index.js +236 -0
- package/dist/{accordion → expansion-panel}/index.cjs +45 -45
- package/dist/{accordion → expansion-panel}/index.d.cts +30 -30
- package/dist/{accordion → expansion-panel}/index.d.ts +30 -30
- package/dist/{accordion → expansion-panel}/index.js +40 -41
- package/dist/fab/index.d.cts +3 -3
- package/dist/fab/index.d.ts +3 -3
- package/dist/fab/index.js +3 -4
- package/dist/fab-menu/index.d.cts +2 -2
- package/dist/fab-menu/index.d.ts +2 -2
- package/dist/fab-menu/index.js +3 -4
- package/dist/{fab.type-Ba0QMprb.d.ts → fab.type-CgIYqQlT.d.ts} +1 -1
- package/dist/{fab.type-U09H8B7D.d.cts → fab.type-l2vjG8-p.d.cts} +1 -1
- package/dist/feature-discovery/index.cjs +531 -0
- package/dist/feature-discovery/index.d.cts +82 -0
- package/dist/feature-discovery/index.d.ts +82 -0
- package/dist/feature-discovery/index.js +464 -0
- package/dist/indicator/index.js +2 -3
- package/dist/input/index.cjs +258 -164
- package/dist/input/index.d.cts +15 -1
- package/dist/input/index.d.ts +15 -1
- package/dist/input/index.js +219 -126
- package/dist/list/index.js +1 -2
- package/dist/menu/index.js +2 -2
- package/dist/menubox/index.cjs +369 -0
- package/dist/menubox/index.d.cts +98 -0
- package/dist/menubox/index.d.ts +98 -0
- package/dist/menubox/index.js +296 -0
- package/dist/pager/index.cjs +243 -0
- package/dist/pager/index.d.cts +93 -0
- package/dist/pager/index.d.ts +93 -0
- package/dist/pager/index.js +205 -0
- package/dist/progress/index.js +1 -2
- package/dist/radio/index.cjs +537 -0
- package/dist/radio/index.d.cts +145 -0
- package/dist/radio/index.d.ts +145 -0
- package/dist/radio/index.js +464 -0
- package/dist/segment-button/index.js +2 -2
- package/dist/select/index.js +22 -10
- package/dist/skeleton/index.js +2 -2
- package/dist/slider/index.cjs +655 -0
- package/dist/slider/index.d.cts +171 -0
- package/dist/slider/index.d.ts +171 -0
- package/dist/slider/index.js +575 -0
- package/dist/stepper/index.cjs +624 -0
- package/dist/stepper/index.d.cts +137 -0
- package/dist/stepper/index.d.ts +137 -0
- package/dist/stepper/index.js +549 -0
- package/dist/switch/index.js +1 -2
- package/dist/tabs/index.cjs +523 -0
- package/dist/tabs/index.d.cts +176 -0
- package/dist/tabs/index.d.ts +176 -0
- package/dist/tabs/index.js +438 -0
- package/dist/timepicker/index.cjs +1280 -0
- package/dist/timepicker/index.d.cts +215 -0
- package/dist/timepicker/index.d.ts +215 -0
- package/dist/timepicker/index.js +1181 -0
- package/dist/toolbar/index.cjs +395 -0
- package/dist/toolbar/index.d.cts +100 -0
- package/dist/toolbar/index.d.ts +100 -0
- package/dist/toolbar/index.js +325 -0
- package/dist/typography/index.js +1 -2
- package/dist/view/index.cjs +16 -2
- package/dist/view/index.js +16 -2
- package/package.json +73 -8
- package/dist/button.type-D8tzEBo7.d.ts +0 -104
- package/dist/button.type-ikaWzhIg.d.cts +0 -104
- package/dist/chunk-GBHQCAKW.js +0 -19
- package/dist/chunk-JEGEPGVU.js +0 -287
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
|
+
import { ViewStyle, TextStyle } from 'react-native';
|
|
3
|
+
import { S as Size, T as ThemeColor, R as Radius } from '../index-BOw6tbkc.cjs';
|
|
4
|
+
|
|
5
|
+
type SliderOrientation = 'horizontal' | 'vertical';
|
|
6
|
+
type SliderMark = {
|
|
7
|
+
/**
|
|
8
|
+
* Value where the mark should be displayed.
|
|
9
|
+
*/
|
|
10
|
+
value: number;
|
|
11
|
+
/**
|
|
12
|
+
* Optional label for the mark.
|
|
13
|
+
*/
|
|
14
|
+
label?: ReactNode;
|
|
15
|
+
};
|
|
16
|
+
type SliderCustomAppearance = {
|
|
17
|
+
/**
|
|
18
|
+
* Custom style for the root container.
|
|
19
|
+
*/
|
|
20
|
+
container?: ViewStyle;
|
|
21
|
+
/**
|
|
22
|
+
* Custom style for the label row.
|
|
23
|
+
*/
|
|
24
|
+
header?: ViewStyle;
|
|
25
|
+
/**
|
|
26
|
+
* Custom style for the label text.
|
|
27
|
+
*/
|
|
28
|
+
label?: TextStyle;
|
|
29
|
+
/**
|
|
30
|
+
* Custom style for the value text.
|
|
31
|
+
*/
|
|
32
|
+
value?: TextStyle;
|
|
33
|
+
/**
|
|
34
|
+
* Custom style for track container.
|
|
35
|
+
*/
|
|
36
|
+
trackContainer?: ViewStyle;
|
|
37
|
+
/**
|
|
38
|
+
* Custom style for track background.
|
|
39
|
+
*/
|
|
40
|
+
track?: ViewStyle;
|
|
41
|
+
/**
|
|
42
|
+
* Custom style for filled track.
|
|
43
|
+
*/
|
|
44
|
+
fill?: ViewStyle;
|
|
45
|
+
/**
|
|
46
|
+
* Custom style for thumb.
|
|
47
|
+
*/
|
|
48
|
+
thumb?: ViewStyle;
|
|
49
|
+
/**
|
|
50
|
+
* Custom style for step dots.
|
|
51
|
+
*/
|
|
52
|
+
step?: ViewStyle;
|
|
53
|
+
/**
|
|
54
|
+
* Custom style for active step dots.
|
|
55
|
+
*/
|
|
56
|
+
activeStep?: ViewStyle;
|
|
57
|
+
/**
|
|
58
|
+
* Custom style for mark container.
|
|
59
|
+
*/
|
|
60
|
+
mark?: ViewStyle;
|
|
61
|
+
/**
|
|
62
|
+
* Custom style for mark label.
|
|
63
|
+
*/
|
|
64
|
+
markLabel?: TextStyle;
|
|
65
|
+
};
|
|
66
|
+
type SliderProps = {
|
|
67
|
+
/**
|
|
68
|
+
* Controlled slider value.
|
|
69
|
+
*/
|
|
70
|
+
value?: number;
|
|
71
|
+
/**
|
|
72
|
+
* Default value in uncontrolled mode.
|
|
73
|
+
*/
|
|
74
|
+
defaultValue?: number;
|
|
75
|
+
/**
|
|
76
|
+
* Minimum allowed value.
|
|
77
|
+
* @default 0
|
|
78
|
+
*/
|
|
79
|
+
minValue?: number;
|
|
80
|
+
/**
|
|
81
|
+
* Maximum allowed value.
|
|
82
|
+
* @default 100
|
|
83
|
+
*/
|
|
84
|
+
maxValue?: number;
|
|
85
|
+
/**
|
|
86
|
+
* Value step increment.
|
|
87
|
+
* @default 1
|
|
88
|
+
*/
|
|
89
|
+
step?: number;
|
|
90
|
+
/**
|
|
91
|
+
* Slider label.
|
|
92
|
+
*/
|
|
93
|
+
label?: ReactNode;
|
|
94
|
+
/**
|
|
95
|
+
* Whether to show the numeric value text.
|
|
96
|
+
* @default false
|
|
97
|
+
*/
|
|
98
|
+
showValueLabel?: boolean;
|
|
99
|
+
/**
|
|
100
|
+
* Number formatting options for value label.
|
|
101
|
+
*/
|
|
102
|
+
formatOptions?: Intl.NumberFormatOptions;
|
|
103
|
+
/**
|
|
104
|
+
* Optional static marks.
|
|
105
|
+
*/
|
|
106
|
+
marks?: SliderMark[];
|
|
107
|
+
/**
|
|
108
|
+
* Show one step dot per step.
|
|
109
|
+
* @default false
|
|
110
|
+
*/
|
|
111
|
+
showSteps?: boolean;
|
|
112
|
+
/**
|
|
113
|
+
* Slider orientation.
|
|
114
|
+
* @default 'horizontal'
|
|
115
|
+
*/
|
|
116
|
+
orientation?: SliderOrientation;
|
|
117
|
+
/**
|
|
118
|
+
* Size of track and thumb.
|
|
119
|
+
* @default 'md'
|
|
120
|
+
*/
|
|
121
|
+
size?: Size;
|
|
122
|
+
/**
|
|
123
|
+
* Theme color for fill/thumb.
|
|
124
|
+
* @default 'primary'
|
|
125
|
+
*/
|
|
126
|
+
color?: ThemeColor;
|
|
127
|
+
/**
|
|
128
|
+
* Border radius for track.
|
|
129
|
+
* @default 'full'
|
|
130
|
+
*/
|
|
131
|
+
radius?: Radius;
|
|
132
|
+
/**
|
|
133
|
+
* Optional content before track.
|
|
134
|
+
*/
|
|
135
|
+
startContent?: ReactNode;
|
|
136
|
+
/**
|
|
137
|
+
* Optional content after track.
|
|
138
|
+
*/
|
|
139
|
+
endContent?: ReactNode;
|
|
140
|
+
/**
|
|
141
|
+
* Whether interactions are disabled.
|
|
142
|
+
* @default false
|
|
143
|
+
*/
|
|
144
|
+
isDisabled?: boolean;
|
|
145
|
+
/**
|
|
146
|
+
* Whether value is read-only.
|
|
147
|
+
* @default false
|
|
148
|
+
*/
|
|
149
|
+
isReadOnly?: boolean;
|
|
150
|
+
/**
|
|
151
|
+
* Optional track length in pixels.
|
|
152
|
+
* When omitted, the slider uses available layout size.
|
|
153
|
+
*/
|
|
154
|
+
trackLength?: number;
|
|
155
|
+
/**
|
|
156
|
+
* Callback fired on value changes.
|
|
157
|
+
*/
|
|
158
|
+
onChange?: (value: number) => void;
|
|
159
|
+
/**
|
|
160
|
+
* Callback fired when interaction ends.
|
|
161
|
+
*/
|
|
162
|
+
onChangeEnd?: (value: number) => void;
|
|
163
|
+
/**
|
|
164
|
+
* Custom style overrides.
|
|
165
|
+
*/
|
|
166
|
+
customAppearance?: SliderCustomAppearance;
|
|
167
|
+
};
|
|
168
|
+
|
|
169
|
+
declare const Slider: React.FC<SliderProps>;
|
|
170
|
+
|
|
171
|
+
export { Slider, type SliderMark, type SliderOrientation, type SliderProps };
|
|
@@ -0,0 +1,171 @@
|
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
|
+
import { ViewStyle, TextStyle } from 'react-native';
|
|
3
|
+
import { S as Size, T as ThemeColor, R as Radius } from '../index-BOw6tbkc.js';
|
|
4
|
+
|
|
5
|
+
type SliderOrientation = 'horizontal' | 'vertical';
|
|
6
|
+
type SliderMark = {
|
|
7
|
+
/**
|
|
8
|
+
* Value where the mark should be displayed.
|
|
9
|
+
*/
|
|
10
|
+
value: number;
|
|
11
|
+
/**
|
|
12
|
+
* Optional label for the mark.
|
|
13
|
+
*/
|
|
14
|
+
label?: ReactNode;
|
|
15
|
+
};
|
|
16
|
+
type SliderCustomAppearance = {
|
|
17
|
+
/**
|
|
18
|
+
* Custom style for the root container.
|
|
19
|
+
*/
|
|
20
|
+
container?: ViewStyle;
|
|
21
|
+
/**
|
|
22
|
+
* Custom style for the label row.
|
|
23
|
+
*/
|
|
24
|
+
header?: ViewStyle;
|
|
25
|
+
/**
|
|
26
|
+
* Custom style for the label text.
|
|
27
|
+
*/
|
|
28
|
+
label?: TextStyle;
|
|
29
|
+
/**
|
|
30
|
+
* Custom style for the value text.
|
|
31
|
+
*/
|
|
32
|
+
value?: TextStyle;
|
|
33
|
+
/**
|
|
34
|
+
* Custom style for track container.
|
|
35
|
+
*/
|
|
36
|
+
trackContainer?: ViewStyle;
|
|
37
|
+
/**
|
|
38
|
+
* Custom style for track background.
|
|
39
|
+
*/
|
|
40
|
+
track?: ViewStyle;
|
|
41
|
+
/**
|
|
42
|
+
* Custom style for filled track.
|
|
43
|
+
*/
|
|
44
|
+
fill?: ViewStyle;
|
|
45
|
+
/**
|
|
46
|
+
* Custom style for thumb.
|
|
47
|
+
*/
|
|
48
|
+
thumb?: ViewStyle;
|
|
49
|
+
/**
|
|
50
|
+
* Custom style for step dots.
|
|
51
|
+
*/
|
|
52
|
+
step?: ViewStyle;
|
|
53
|
+
/**
|
|
54
|
+
* Custom style for active step dots.
|
|
55
|
+
*/
|
|
56
|
+
activeStep?: ViewStyle;
|
|
57
|
+
/**
|
|
58
|
+
* Custom style for mark container.
|
|
59
|
+
*/
|
|
60
|
+
mark?: ViewStyle;
|
|
61
|
+
/**
|
|
62
|
+
* Custom style for mark label.
|
|
63
|
+
*/
|
|
64
|
+
markLabel?: TextStyle;
|
|
65
|
+
};
|
|
66
|
+
type SliderProps = {
|
|
67
|
+
/**
|
|
68
|
+
* Controlled slider value.
|
|
69
|
+
*/
|
|
70
|
+
value?: number;
|
|
71
|
+
/**
|
|
72
|
+
* Default value in uncontrolled mode.
|
|
73
|
+
*/
|
|
74
|
+
defaultValue?: number;
|
|
75
|
+
/**
|
|
76
|
+
* Minimum allowed value.
|
|
77
|
+
* @default 0
|
|
78
|
+
*/
|
|
79
|
+
minValue?: number;
|
|
80
|
+
/**
|
|
81
|
+
* Maximum allowed value.
|
|
82
|
+
* @default 100
|
|
83
|
+
*/
|
|
84
|
+
maxValue?: number;
|
|
85
|
+
/**
|
|
86
|
+
* Value step increment.
|
|
87
|
+
* @default 1
|
|
88
|
+
*/
|
|
89
|
+
step?: number;
|
|
90
|
+
/**
|
|
91
|
+
* Slider label.
|
|
92
|
+
*/
|
|
93
|
+
label?: ReactNode;
|
|
94
|
+
/**
|
|
95
|
+
* Whether to show the numeric value text.
|
|
96
|
+
* @default false
|
|
97
|
+
*/
|
|
98
|
+
showValueLabel?: boolean;
|
|
99
|
+
/**
|
|
100
|
+
* Number formatting options for value label.
|
|
101
|
+
*/
|
|
102
|
+
formatOptions?: Intl.NumberFormatOptions;
|
|
103
|
+
/**
|
|
104
|
+
* Optional static marks.
|
|
105
|
+
*/
|
|
106
|
+
marks?: SliderMark[];
|
|
107
|
+
/**
|
|
108
|
+
* Show one step dot per step.
|
|
109
|
+
* @default false
|
|
110
|
+
*/
|
|
111
|
+
showSteps?: boolean;
|
|
112
|
+
/**
|
|
113
|
+
* Slider orientation.
|
|
114
|
+
* @default 'horizontal'
|
|
115
|
+
*/
|
|
116
|
+
orientation?: SliderOrientation;
|
|
117
|
+
/**
|
|
118
|
+
* Size of track and thumb.
|
|
119
|
+
* @default 'md'
|
|
120
|
+
*/
|
|
121
|
+
size?: Size;
|
|
122
|
+
/**
|
|
123
|
+
* Theme color for fill/thumb.
|
|
124
|
+
* @default 'primary'
|
|
125
|
+
*/
|
|
126
|
+
color?: ThemeColor;
|
|
127
|
+
/**
|
|
128
|
+
* Border radius for track.
|
|
129
|
+
* @default 'full'
|
|
130
|
+
*/
|
|
131
|
+
radius?: Radius;
|
|
132
|
+
/**
|
|
133
|
+
* Optional content before track.
|
|
134
|
+
*/
|
|
135
|
+
startContent?: ReactNode;
|
|
136
|
+
/**
|
|
137
|
+
* Optional content after track.
|
|
138
|
+
*/
|
|
139
|
+
endContent?: ReactNode;
|
|
140
|
+
/**
|
|
141
|
+
* Whether interactions are disabled.
|
|
142
|
+
* @default false
|
|
143
|
+
*/
|
|
144
|
+
isDisabled?: boolean;
|
|
145
|
+
/**
|
|
146
|
+
* Whether value is read-only.
|
|
147
|
+
* @default false
|
|
148
|
+
*/
|
|
149
|
+
isReadOnly?: boolean;
|
|
150
|
+
/**
|
|
151
|
+
* Optional track length in pixels.
|
|
152
|
+
* When omitted, the slider uses available layout size.
|
|
153
|
+
*/
|
|
154
|
+
trackLength?: number;
|
|
155
|
+
/**
|
|
156
|
+
* Callback fired on value changes.
|
|
157
|
+
*/
|
|
158
|
+
onChange?: (value: number) => void;
|
|
159
|
+
/**
|
|
160
|
+
* Callback fired when interaction ends.
|
|
161
|
+
*/
|
|
162
|
+
onChangeEnd?: (value: number) => void;
|
|
163
|
+
/**
|
|
164
|
+
* Custom style overrides.
|
|
165
|
+
*/
|
|
166
|
+
customAppearance?: SliderCustomAppearance;
|
|
167
|
+
};
|
|
168
|
+
|
|
169
|
+
declare const Slider: React.FC<SliderProps>;
|
|
170
|
+
|
|
171
|
+
export { Slider, type SliderMark, type SliderOrientation, type SliderProps };
|