@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,137 @@
|
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
|
+
import { StyleProp, ViewStyle, TextStyle } from 'react-native';
|
|
3
|
+
import { T as ThemeColor, S as Size } from '../index-BOw6tbkc.cjs';
|
|
4
|
+
|
|
5
|
+
type StepperDirection = 'horizontal' | 'vertical';
|
|
6
|
+
type StepperLineDisplayMode = 'progress' | 'all';
|
|
7
|
+
type StepperSize = Exclude<Size, 'xs'>;
|
|
8
|
+
type StepperItemIndicatorState = {
|
|
9
|
+
index: number;
|
|
10
|
+
isActive: boolean;
|
|
11
|
+
isCompleted: boolean;
|
|
12
|
+
isLocked: boolean;
|
|
13
|
+
isDisabled: boolean;
|
|
14
|
+
};
|
|
15
|
+
type StepperCustomAppearance = {
|
|
16
|
+
container?: StyleProp<ViewStyle>;
|
|
17
|
+
itemContainer?: StyleProp<ViewStyle>;
|
|
18
|
+
line?: StyleProp<ViewStyle>;
|
|
19
|
+
activeLine?: StyleProp<ViewStyle>;
|
|
20
|
+
};
|
|
21
|
+
type StepperItemCustomAppearance = {
|
|
22
|
+
container?: StyleProp<ViewStyle>;
|
|
23
|
+
indicator?: StyleProp<ViewStyle>;
|
|
24
|
+
activeIndicator?: StyleProp<ViewStyle>;
|
|
25
|
+
completedIndicator?: StyleProp<ViewStyle>;
|
|
26
|
+
lockedIndicator?: StyleProp<ViewStyle>;
|
|
27
|
+
title?: StyleProp<TextStyle>;
|
|
28
|
+
description?: StyleProp<TextStyle>;
|
|
29
|
+
};
|
|
30
|
+
type StepperProps = {
|
|
31
|
+
/**
|
|
32
|
+
* StepperItem children.
|
|
33
|
+
*/
|
|
34
|
+
children: ReactNode;
|
|
35
|
+
/**
|
|
36
|
+
* Direction of the stepper layout.
|
|
37
|
+
* @default 'horizontal'
|
|
38
|
+
*/
|
|
39
|
+
direction?: StepperDirection;
|
|
40
|
+
/**
|
|
41
|
+
* Whether connector lines between steps are shown.
|
|
42
|
+
* @default true
|
|
43
|
+
*/
|
|
44
|
+
showLines?: boolean;
|
|
45
|
+
/**
|
|
46
|
+
* Controls connector line visibility.
|
|
47
|
+
* - `progress`: only progress to current step is shown.
|
|
48
|
+
* - `all`: all connectors are shown with progress highlight.
|
|
49
|
+
* @default 'progress'
|
|
50
|
+
*/
|
|
51
|
+
lineDisplayMode?: StepperLineDisplayMode;
|
|
52
|
+
/**
|
|
53
|
+
* Controlled active step key.
|
|
54
|
+
*/
|
|
55
|
+
activeKey?: string;
|
|
56
|
+
/**
|
|
57
|
+
* Uncontrolled default active step key.
|
|
58
|
+
*/
|
|
59
|
+
defaultActiveKey?: string;
|
|
60
|
+
/**
|
|
61
|
+
* Callback fired when active step changes.
|
|
62
|
+
*/
|
|
63
|
+
onStepChange?: (key: string) => void;
|
|
64
|
+
/**
|
|
65
|
+
* Shared theme color.
|
|
66
|
+
* @default 'primary'
|
|
67
|
+
*/
|
|
68
|
+
themeColor?: ThemeColor;
|
|
69
|
+
/**
|
|
70
|
+
* Shared stepper size.
|
|
71
|
+
* @default 'md'
|
|
72
|
+
*/
|
|
73
|
+
size?: StepperSize;
|
|
74
|
+
/**
|
|
75
|
+
* Whether all steps are disabled.
|
|
76
|
+
* @default false
|
|
77
|
+
*/
|
|
78
|
+
isDisabled?: boolean;
|
|
79
|
+
/**
|
|
80
|
+
* Stepper container style.
|
|
81
|
+
*/
|
|
82
|
+
style?: StyleProp<ViewStyle>;
|
|
83
|
+
/**
|
|
84
|
+
* Custom appearance styles.
|
|
85
|
+
*/
|
|
86
|
+
customAppearance?: StepperCustomAppearance;
|
|
87
|
+
};
|
|
88
|
+
type StepperItemProps = {
|
|
89
|
+
/**
|
|
90
|
+
* Unique key for this step.
|
|
91
|
+
*/
|
|
92
|
+
itemKey: string;
|
|
93
|
+
/**
|
|
94
|
+
* Main title/label.
|
|
95
|
+
*/
|
|
96
|
+
title?: ReactNode;
|
|
97
|
+
/**
|
|
98
|
+
* Optional secondary description.
|
|
99
|
+
*/
|
|
100
|
+
description?: ReactNode;
|
|
101
|
+
/**
|
|
102
|
+
* Custom indicator content or indicator render function.
|
|
103
|
+
*/
|
|
104
|
+
indicator?: ReactNode | ((state: StepperItemIndicatorState) => ReactNode);
|
|
105
|
+
/**
|
|
106
|
+
* Locks this step from interaction.
|
|
107
|
+
* @default false
|
|
108
|
+
*/
|
|
109
|
+
isLocked?: boolean;
|
|
110
|
+
/**
|
|
111
|
+
* Disables this step from interaction.
|
|
112
|
+
* @default false
|
|
113
|
+
*/
|
|
114
|
+
isDisabled?: boolean;
|
|
115
|
+
/**
|
|
116
|
+
* Additional content rendered below title/description.
|
|
117
|
+
*/
|
|
118
|
+
children?: ReactNode;
|
|
119
|
+
/**
|
|
120
|
+
* Callback fired when this item is pressed.
|
|
121
|
+
*/
|
|
122
|
+
onPress?: (itemKey: string) => void;
|
|
123
|
+
/**
|
|
124
|
+
* Custom style for this item.
|
|
125
|
+
*/
|
|
126
|
+
style?: StyleProp<ViewStyle>;
|
|
127
|
+
/**
|
|
128
|
+
* Custom appearance styles.
|
|
129
|
+
*/
|
|
130
|
+
customAppearance?: StepperItemCustomAppearance;
|
|
131
|
+
};
|
|
132
|
+
|
|
133
|
+
declare const Stepper: React.FC<StepperProps>;
|
|
134
|
+
|
|
135
|
+
declare const StepperItem: React.FC<StepperItemProps>;
|
|
136
|
+
|
|
137
|
+
export { Stepper, type StepperDirection, StepperItem, type StepperItemIndicatorState, type StepperItemProps, type StepperLineDisplayMode, type StepperProps, type StepperSize };
|
|
@@ -0,0 +1,137 @@
|
|
|
1
|
+
import React, { ReactNode } from 'react';
|
|
2
|
+
import { StyleProp, ViewStyle, TextStyle } from 'react-native';
|
|
3
|
+
import { T as ThemeColor, S as Size } from '../index-BOw6tbkc.js';
|
|
4
|
+
|
|
5
|
+
type StepperDirection = 'horizontal' | 'vertical';
|
|
6
|
+
type StepperLineDisplayMode = 'progress' | 'all';
|
|
7
|
+
type StepperSize = Exclude<Size, 'xs'>;
|
|
8
|
+
type StepperItemIndicatorState = {
|
|
9
|
+
index: number;
|
|
10
|
+
isActive: boolean;
|
|
11
|
+
isCompleted: boolean;
|
|
12
|
+
isLocked: boolean;
|
|
13
|
+
isDisabled: boolean;
|
|
14
|
+
};
|
|
15
|
+
type StepperCustomAppearance = {
|
|
16
|
+
container?: StyleProp<ViewStyle>;
|
|
17
|
+
itemContainer?: StyleProp<ViewStyle>;
|
|
18
|
+
line?: StyleProp<ViewStyle>;
|
|
19
|
+
activeLine?: StyleProp<ViewStyle>;
|
|
20
|
+
};
|
|
21
|
+
type StepperItemCustomAppearance = {
|
|
22
|
+
container?: StyleProp<ViewStyle>;
|
|
23
|
+
indicator?: StyleProp<ViewStyle>;
|
|
24
|
+
activeIndicator?: StyleProp<ViewStyle>;
|
|
25
|
+
completedIndicator?: StyleProp<ViewStyle>;
|
|
26
|
+
lockedIndicator?: StyleProp<ViewStyle>;
|
|
27
|
+
title?: StyleProp<TextStyle>;
|
|
28
|
+
description?: StyleProp<TextStyle>;
|
|
29
|
+
};
|
|
30
|
+
type StepperProps = {
|
|
31
|
+
/**
|
|
32
|
+
* StepperItem children.
|
|
33
|
+
*/
|
|
34
|
+
children: ReactNode;
|
|
35
|
+
/**
|
|
36
|
+
* Direction of the stepper layout.
|
|
37
|
+
* @default 'horizontal'
|
|
38
|
+
*/
|
|
39
|
+
direction?: StepperDirection;
|
|
40
|
+
/**
|
|
41
|
+
* Whether connector lines between steps are shown.
|
|
42
|
+
* @default true
|
|
43
|
+
*/
|
|
44
|
+
showLines?: boolean;
|
|
45
|
+
/**
|
|
46
|
+
* Controls connector line visibility.
|
|
47
|
+
* - `progress`: only progress to current step is shown.
|
|
48
|
+
* - `all`: all connectors are shown with progress highlight.
|
|
49
|
+
* @default 'progress'
|
|
50
|
+
*/
|
|
51
|
+
lineDisplayMode?: StepperLineDisplayMode;
|
|
52
|
+
/**
|
|
53
|
+
* Controlled active step key.
|
|
54
|
+
*/
|
|
55
|
+
activeKey?: string;
|
|
56
|
+
/**
|
|
57
|
+
* Uncontrolled default active step key.
|
|
58
|
+
*/
|
|
59
|
+
defaultActiveKey?: string;
|
|
60
|
+
/**
|
|
61
|
+
* Callback fired when active step changes.
|
|
62
|
+
*/
|
|
63
|
+
onStepChange?: (key: string) => void;
|
|
64
|
+
/**
|
|
65
|
+
* Shared theme color.
|
|
66
|
+
* @default 'primary'
|
|
67
|
+
*/
|
|
68
|
+
themeColor?: ThemeColor;
|
|
69
|
+
/**
|
|
70
|
+
* Shared stepper size.
|
|
71
|
+
* @default 'md'
|
|
72
|
+
*/
|
|
73
|
+
size?: StepperSize;
|
|
74
|
+
/**
|
|
75
|
+
* Whether all steps are disabled.
|
|
76
|
+
* @default false
|
|
77
|
+
*/
|
|
78
|
+
isDisabled?: boolean;
|
|
79
|
+
/**
|
|
80
|
+
* Stepper container style.
|
|
81
|
+
*/
|
|
82
|
+
style?: StyleProp<ViewStyle>;
|
|
83
|
+
/**
|
|
84
|
+
* Custom appearance styles.
|
|
85
|
+
*/
|
|
86
|
+
customAppearance?: StepperCustomAppearance;
|
|
87
|
+
};
|
|
88
|
+
type StepperItemProps = {
|
|
89
|
+
/**
|
|
90
|
+
* Unique key for this step.
|
|
91
|
+
*/
|
|
92
|
+
itemKey: string;
|
|
93
|
+
/**
|
|
94
|
+
* Main title/label.
|
|
95
|
+
*/
|
|
96
|
+
title?: ReactNode;
|
|
97
|
+
/**
|
|
98
|
+
* Optional secondary description.
|
|
99
|
+
*/
|
|
100
|
+
description?: ReactNode;
|
|
101
|
+
/**
|
|
102
|
+
* Custom indicator content or indicator render function.
|
|
103
|
+
*/
|
|
104
|
+
indicator?: ReactNode | ((state: StepperItemIndicatorState) => ReactNode);
|
|
105
|
+
/**
|
|
106
|
+
* Locks this step from interaction.
|
|
107
|
+
* @default false
|
|
108
|
+
*/
|
|
109
|
+
isLocked?: boolean;
|
|
110
|
+
/**
|
|
111
|
+
* Disables this step from interaction.
|
|
112
|
+
* @default false
|
|
113
|
+
*/
|
|
114
|
+
isDisabled?: boolean;
|
|
115
|
+
/**
|
|
116
|
+
* Additional content rendered below title/description.
|
|
117
|
+
*/
|
|
118
|
+
children?: ReactNode;
|
|
119
|
+
/**
|
|
120
|
+
* Callback fired when this item is pressed.
|
|
121
|
+
*/
|
|
122
|
+
onPress?: (itemKey: string) => void;
|
|
123
|
+
/**
|
|
124
|
+
* Custom style for this item.
|
|
125
|
+
*/
|
|
126
|
+
style?: StyleProp<ViewStyle>;
|
|
127
|
+
/**
|
|
128
|
+
* Custom appearance styles.
|
|
129
|
+
*/
|
|
130
|
+
customAppearance?: StepperItemCustomAppearance;
|
|
131
|
+
};
|
|
132
|
+
|
|
133
|
+
declare const Stepper: React.FC<StepperProps>;
|
|
134
|
+
|
|
135
|
+
declare const StepperItem: React.FC<StepperItemProps>;
|
|
136
|
+
|
|
137
|
+
export { Stepper, type StepperDirection, StepperItem, type StepperItemIndicatorState, type StepperItemProps, type StepperLineDisplayMode, type StepperProps, type StepperSize };
|