@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
|
@@ -1,104 +0,0 @@
|
|
|
1
|
-
import { ReactNode } from 'react';
|
|
2
|
-
import { ViewStyle, TextStyle, GestureResponderEvent } from 'react-native';
|
|
3
|
-
import { T as ThemeColor, S as Size } from './index-BOw6tbkc.cjs';
|
|
4
|
-
|
|
5
|
-
type ButtonVariant = 'solid' | 'outlined' | 'flat' | 'light' | 'faded';
|
|
6
|
-
type ButtonRadius = 'none' | 'sm' | 'md' | 'lg' | 'full';
|
|
7
|
-
type SpinnerPlacement = 'start' | 'end';
|
|
8
|
-
type ElevationLevel = 0 | 1 | 2 | 3 | 4;
|
|
9
|
-
type ButtonCustomAppearance = {
|
|
10
|
-
/**
|
|
11
|
-
* Custom styles for the outer container
|
|
12
|
-
*/
|
|
13
|
-
container?: ViewStyle;
|
|
14
|
-
/**
|
|
15
|
-
* Custom styles for the button
|
|
16
|
-
*/
|
|
17
|
-
button?: ViewStyle;
|
|
18
|
-
/**
|
|
19
|
-
* Custom styles for the button text
|
|
20
|
-
*/
|
|
21
|
-
text?: TextStyle;
|
|
22
|
-
};
|
|
23
|
-
type ButtonProps = {
|
|
24
|
-
/**
|
|
25
|
-
* The content to display in the button.
|
|
26
|
-
*/
|
|
27
|
-
children: ReactNode;
|
|
28
|
-
/**
|
|
29
|
-
* The theme color of the button.
|
|
30
|
-
* @default 'default'
|
|
31
|
-
*/
|
|
32
|
-
themeColor?: ThemeColor;
|
|
33
|
-
/**
|
|
34
|
-
* The variant of the button.
|
|
35
|
-
* @default 'solid'
|
|
36
|
-
*/
|
|
37
|
-
variant?: ButtonVariant;
|
|
38
|
-
/**
|
|
39
|
-
* The size of the button.
|
|
40
|
-
* @default 'md'
|
|
41
|
-
*/
|
|
42
|
-
size?: Size;
|
|
43
|
-
/**
|
|
44
|
-
* The border radius of the button.
|
|
45
|
-
* @default 'md'
|
|
46
|
-
*/
|
|
47
|
-
radius?: ButtonRadius;
|
|
48
|
-
/**
|
|
49
|
-
* Content to display at the start of the button.
|
|
50
|
-
*/
|
|
51
|
-
startContent?: ReactNode;
|
|
52
|
-
/**
|
|
53
|
-
* Content to display at the end of the button.
|
|
54
|
-
*/
|
|
55
|
-
endContent?: ReactNode;
|
|
56
|
-
/**
|
|
57
|
-
* The placement of the spinner when isLoading is true.
|
|
58
|
-
* @default 'start'
|
|
59
|
-
*/
|
|
60
|
-
spinnerPlacement?: SpinnerPlacement;
|
|
61
|
-
/**
|
|
62
|
-
* Whether the button should take the full width of its container.
|
|
63
|
-
* @default false
|
|
64
|
-
*/
|
|
65
|
-
fullWidth?: boolean;
|
|
66
|
-
/**
|
|
67
|
-
* Whether the button is disabled.
|
|
68
|
-
* @default false
|
|
69
|
-
*/
|
|
70
|
-
isDisabled?: boolean;
|
|
71
|
-
/**
|
|
72
|
-
* Whether the button is in a loading state.
|
|
73
|
-
* @default false
|
|
74
|
-
*/
|
|
75
|
-
isLoading?: boolean;
|
|
76
|
-
/**
|
|
77
|
-
* Android elevation level from 0 to 4.
|
|
78
|
-
* Does not apply to `outlined` and `light` variants.
|
|
79
|
-
* @default 0
|
|
80
|
-
*/
|
|
81
|
-
elevation?: ElevationLevel;
|
|
82
|
-
/**
|
|
83
|
-
* Custom appearance styles for button parts
|
|
84
|
-
*/
|
|
85
|
-
customAppearance?: ButtonCustomAppearance;
|
|
86
|
-
/**
|
|
87
|
-
* Callback fired when the button is pressed.
|
|
88
|
-
*/
|
|
89
|
-
onPress?: (event: GestureResponderEvent) => void;
|
|
90
|
-
/**
|
|
91
|
-
* Callback fired when the button is long pressed.
|
|
92
|
-
*/
|
|
93
|
-
onLongPress?: (event: GestureResponderEvent) => void;
|
|
94
|
-
/**
|
|
95
|
-
* Callback fired when the button press starts.
|
|
96
|
-
*/
|
|
97
|
-
onPressIn?: (event: GestureResponderEvent) => void;
|
|
98
|
-
/**
|
|
99
|
-
* Callback fired when the button press ends.
|
|
100
|
-
*/
|
|
101
|
-
onPressOut?: (event: GestureResponderEvent) => void;
|
|
102
|
-
};
|
|
103
|
-
|
|
104
|
-
export type { ButtonRadius as B, ElevationLevel as E, SpinnerPlacement as S, ButtonProps as a, ButtonVariant as b };
|
package/dist/chunk-GBHQCAKW.js
DELETED
|
@@ -1,19 +0,0 @@
|
|
|
1
|
-
// src/components/select/checkmark-icon.tsx
|
|
2
|
-
import React from "react";
|
|
3
|
-
import Svg, { Polyline } from "react-native-svg";
|
|
4
|
-
function CheckmarkIcon({ color, size }) {
|
|
5
|
-
return /* @__PURE__ */ React.createElement(Svg, { width: size, height: size, viewBox: "0 0 17 18", fill: "none" }, /* @__PURE__ */ React.createElement(
|
|
6
|
-
Polyline,
|
|
7
|
-
{
|
|
8
|
-
points: "1 9 7 14 15 4",
|
|
9
|
-
stroke: color,
|
|
10
|
-
strokeWidth: 2,
|
|
11
|
-
strokeLinecap: "round",
|
|
12
|
-
strokeLinejoin: "round"
|
|
13
|
-
}
|
|
14
|
-
));
|
|
15
|
-
}
|
|
16
|
-
|
|
17
|
-
export {
|
|
18
|
-
CheckmarkIcon
|
|
19
|
-
};
|
package/dist/chunk-JEGEPGVU.js
DELETED
|
@@ -1,287 +0,0 @@
|
|
|
1
|
-
import {
|
|
2
|
-
ActivityIndicator
|
|
3
|
-
} from "./chunk-F7WH4DMG.js";
|
|
4
|
-
import {
|
|
5
|
-
useXUITheme
|
|
6
|
-
} from "./chunk-LTKYHG5V.js";
|
|
7
|
-
|
|
8
|
-
// src/components/fab/fab.tsx
|
|
9
|
-
import React from "react";
|
|
10
|
-
import { Pressable, Text, View, Animated as Animated2 } from "react-native";
|
|
11
|
-
|
|
12
|
-
// src/components/fab/fab.style.ts
|
|
13
|
-
import { StyleSheet } from "react-native";
|
|
14
|
-
var styles = StyleSheet.create({
|
|
15
|
-
container: {
|
|
16
|
-
alignSelf: "flex-start"
|
|
17
|
-
},
|
|
18
|
-
fab: {
|
|
19
|
-
flexDirection: "row",
|
|
20
|
-
alignItems: "center",
|
|
21
|
-
justifyContent: "center",
|
|
22
|
-
overflow: "hidden"
|
|
23
|
-
},
|
|
24
|
-
contentContainer: {
|
|
25
|
-
flexDirection: "row",
|
|
26
|
-
alignItems: "center",
|
|
27
|
-
justifyContent: "center",
|
|
28
|
-
gap: 12
|
|
29
|
-
},
|
|
30
|
-
label: {
|
|
31
|
-
fontWeight: "500"
|
|
32
|
-
},
|
|
33
|
-
disabled: {
|
|
34
|
-
opacity: 0.5
|
|
35
|
-
}
|
|
36
|
-
});
|
|
37
|
-
|
|
38
|
-
// src/components/fab/fab.hook.ts
|
|
39
|
-
import { useMemo } from "react";
|
|
40
|
-
import { getSafeThemeColor } from "@xaui/core";
|
|
41
|
-
function useFabSizeStyles(size) {
|
|
42
|
-
const theme = useXUITheme();
|
|
43
|
-
const sizeStyles = useMemo(() => {
|
|
44
|
-
const sizes = {
|
|
45
|
-
sm: {
|
|
46
|
-
width: 40,
|
|
47
|
-
height: 40,
|
|
48
|
-
borderRadius: theme.borderRadius.lg,
|
|
49
|
-
iconSize: 24,
|
|
50
|
-
fontSize: theme.fontSizes.sm
|
|
51
|
-
},
|
|
52
|
-
md: {
|
|
53
|
-
width: 56,
|
|
54
|
-
height: 56,
|
|
55
|
-
borderRadius: theme.borderRadius.xl,
|
|
56
|
-
iconSize: 24,
|
|
57
|
-
fontSize: theme.fontSizes.md
|
|
58
|
-
},
|
|
59
|
-
lg: {
|
|
60
|
-
width: 96,
|
|
61
|
-
height: 96,
|
|
62
|
-
borderRadius: theme.borderRadius["2xl"],
|
|
63
|
-
iconSize: 36,
|
|
64
|
-
fontSize: theme.fontSizes.lg
|
|
65
|
-
}
|
|
66
|
-
};
|
|
67
|
-
return sizes[size];
|
|
68
|
-
}, [size, theme]);
|
|
69
|
-
const extendedSizeStyles = useMemo(() => {
|
|
70
|
-
const sizes = {
|
|
71
|
-
sm: {
|
|
72
|
-
height: 40,
|
|
73
|
-
borderRadius: theme.borderRadius.lg,
|
|
74
|
-
paddingHorizontal: theme.spacing.md,
|
|
75
|
-
iconSize: 20,
|
|
76
|
-
fontSize: theme.fontSizes.sm
|
|
77
|
-
},
|
|
78
|
-
md: {
|
|
79
|
-
height: 56,
|
|
80
|
-
borderRadius: theme.borderRadius.xl,
|
|
81
|
-
paddingHorizontal: theme.spacing.lg,
|
|
82
|
-
iconSize: 24,
|
|
83
|
-
fontSize: theme.fontSizes.md
|
|
84
|
-
},
|
|
85
|
-
lg: {
|
|
86
|
-
height: 80,
|
|
87
|
-
borderRadius: theme.borderRadius["2xl"],
|
|
88
|
-
paddingHorizontal: theme.spacing.xl,
|
|
89
|
-
iconSize: 28,
|
|
90
|
-
fontSize: theme.fontSizes.lg
|
|
91
|
-
}
|
|
92
|
-
};
|
|
93
|
-
return sizes[size];
|
|
94
|
-
}, [size, theme]);
|
|
95
|
-
return { sizeStyles, extendedSizeStyles };
|
|
96
|
-
}
|
|
97
|
-
function useFabVariantStyles(themeColor, variant, elevation = 0) {
|
|
98
|
-
const theme = useXUITheme();
|
|
99
|
-
const safeThemeColor = getSafeThemeColor(themeColor);
|
|
100
|
-
const colorScheme = theme.colors[safeThemeColor];
|
|
101
|
-
const variantStyles = useMemo(() => {
|
|
102
|
-
const variantMap = {
|
|
103
|
-
solid: {
|
|
104
|
-
backgroundColor: colorScheme.main,
|
|
105
|
-
borderWidth: 0
|
|
106
|
-
},
|
|
107
|
-
flat: {
|
|
108
|
-
backgroundColor: colorScheme.background,
|
|
109
|
-
borderWidth: 0
|
|
110
|
-
},
|
|
111
|
-
outlined: {
|
|
112
|
-
backgroundColor: "transparent",
|
|
113
|
-
borderWidth: theme.borderWidth.md,
|
|
114
|
-
borderColor: colorScheme.main
|
|
115
|
-
}
|
|
116
|
-
};
|
|
117
|
-
const baseStyle = variantMap[variant];
|
|
118
|
-
const shouldApplyElevation = variant !== "outlined";
|
|
119
|
-
const shadowStyles = elevation === 0 ? {} : elevation === 1 ? theme.shadows.sm : elevation === 2 ? theme.shadows.md : elevation === 3 ? theme.shadows.lg : theme.shadows.xl;
|
|
120
|
-
return {
|
|
121
|
-
...baseStyle,
|
|
122
|
-
...shouldApplyElevation ? shadowStyles : {},
|
|
123
|
-
...shouldApplyElevation && elevation > 0 ? { elevation } : {}
|
|
124
|
-
};
|
|
125
|
-
}, [variant, colorScheme, theme, elevation]);
|
|
126
|
-
return variantStyles;
|
|
127
|
-
}
|
|
128
|
-
function useFabIconColor(themeColor, variant) {
|
|
129
|
-
const theme = useXUITheme();
|
|
130
|
-
const safeThemeColor = getSafeThemeColor(themeColor);
|
|
131
|
-
const colorScheme = theme.colors[safeThemeColor];
|
|
132
|
-
const iconColor = useMemo(() => {
|
|
133
|
-
if (variant === "solid") {
|
|
134
|
-
return colorScheme.foreground;
|
|
135
|
-
}
|
|
136
|
-
return colorScheme.main;
|
|
137
|
-
}, [variant, colorScheme]);
|
|
138
|
-
return { iconColor };
|
|
139
|
-
}
|
|
140
|
-
function useFabRadiusValue(radius, fallback) {
|
|
141
|
-
const theme = useXUITheme();
|
|
142
|
-
return useMemo(() => {
|
|
143
|
-
if (!radius) return fallback;
|
|
144
|
-
const radiusMap = {
|
|
145
|
-
none: theme.borderRadius.none,
|
|
146
|
-
sm: theme.borderRadius.sm,
|
|
147
|
-
md: theme.borderRadius.md,
|
|
148
|
-
lg: theme.borderRadius.lg,
|
|
149
|
-
full: theme.borderRadius.full
|
|
150
|
-
};
|
|
151
|
-
return radiusMap[radius];
|
|
152
|
-
}, [fallback, radius, theme]);
|
|
153
|
-
}
|
|
154
|
-
|
|
155
|
-
// src/components/fab/fab.animation.ts
|
|
156
|
-
import { Animated } from "react-native";
|
|
157
|
-
var runFabPressInAnimation = (animatedScale, animatedOpacity) => {
|
|
158
|
-
Animated.parallel([
|
|
159
|
-
Animated.spring(animatedScale, {
|
|
160
|
-
toValue: 0.92,
|
|
161
|
-
useNativeDriver: true,
|
|
162
|
-
speed: 50,
|
|
163
|
-
bounciness: 0
|
|
164
|
-
}),
|
|
165
|
-
Animated.timing(animatedOpacity, {
|
|
166
|
-
toValue: 0.85,
|
|
167
|
-
duration: 100,
|
|
168
|
-
useNativeDriver: true
|
|
169
|
-
})
|
|
170
|
-
]).start();
|
|
171
|
-
};
|
|
172
|
-
var runFabPressOutAnimation = (animatedScale, animatedOpacity) => {
|
|
173
|
-
Animated.parallel([
|
|
174
|
-
Animated.spring(animatedScale, {
|
|
175
|
-
toValue: 1,
|
|
176
|
-
useNativeDriver: true,
|
|
177
|
-
speed: 50,
|
|
178
|
-
bounciness: 0
|
|
179
|
-
}),
|
|
180
|
-
Animated.timing(animatedOpacity, {
|
|
181
|
-
toValue: 1,
|
|
182
|
-
duration: 100,
|
|
183
|
-
useNativeDriver: true
|
|
184
|
-
})
|
|
185
|
-
]).start();
|
|
186
|
-
};
|
|
187
|
-
|
|
188
|
-
// src/components/fab/fab.tsx
|
|
189
|
-
var Fab = ({
|
|
190
|
-
icon,
|
|
191
|
-
label,
|
|
192
|
-
themeColor = "primary",
|
|
193
|
-
variant = "solid",
|
|
194
|
-
size = "md",
|
|
195
|
-
radius,
|
|
196
|
-
isDisabled = false,
|
|
197
|
-
isLoading = false,
|
|
198
|
-
elevation = 0,
|
|
199
|
-
customAppearance,
|
|
200
|
-
onPress,
|
|
201
|
-
onLongPress,
|
|
202
|
-
onPressIn,
|
|
203
|
-
onPressOut
|
|
204
|
-
}) => {
|
|
205
|
-
const animatedScale = React.useRef(new Animated2.Value(1)).current;
|
|
206
|
-
const animatedOpacity = React.useRef(new Animated2.Value(1)).current;
|
|
207
|
-
const { sizeStyles, extendedSizeStyles } = useFabSizeStyles(size);
|
|
208
|
-
const variantStyles = useFabVariantStyles(themeColor, variant, elevation);
|
|
209
|
-
const { iconColor } = useFabIconColor(themeColor, variant);
|
|
210
|
-
const isExtended = !!label;
|
|
211
|
-
const resolvedRadius = useFabRadiusValue(
|
|
212
|
-
radius,
|
|
213
|
-
isExtended ? extendedSizeStyles.borderRadius : sizeStyles.borderRadius
|
|
214
|
-
);
|
|
215
|
-
const handlePressIn = (event) => {
|
|
216
|
-
if (!isDisabled && !isLoading) {
|
|
217
|
-
runFabPressInAnimation(animatedScale, animatedOpacity);
|
|
218
|
-
}
|
|
219
|
-
onPressIn?.(event);
|
|
220
|
-
};
|
|
221
|
-
const handlePressOut = (event) => {
|
|
222
|
-
if (!isDisabled && !isLoading) {
|
|
223
|
-
runFabPressOutAnimation(animatedScale, animatedOpacity);
|
|
224
|
-
}
|
|
225
|
-
onPressOut?.(event);
|
|
226
|
-
};
|
|
227
|
-
const fabDimensionStyles = isExtended ? {
|
|
228
|
-
height: extendedSizeStyles.height,
|
|
229
|
-
borderRadius: resolvedRadius,
|
|
230
|
-
paddingHorizontal: extendedSizeStyles.paddingHorizontal
|
|
231
|
-
} : {
|
|
232
|
-
width: sizeStyles.width,
|
|
233
|
-
height: sizeStyles.height,
|
|
234
|
-
borderRadius: resolvedRadius
|
|
235
|
-
};
|
|
236
|
-
return /* @__PURE__ */ React.createElement(View, { style: [styles.container, customAppearance?.container] }, /* @__PURE__ */ React.createElement(
|
|
237
|
-
Pressable,
|
|
238
|
-
{
|
|
239
|
-
onPress: isDisabled || isLoading ? void 0 : onPress,
|
|
240
|
-
onLongPress: isDisabled || isLoading ? void 0 : onLongPress,
|
|
241
|
-
onPressIn: handlePressIn,
|
|
242
|
-
onPressOut: handlePressOut,
|
|
243
|
-
disabled: isDisabled || isLoading
|
|
244
|
-
},
|
|
245
|
-
/* @__PURE__ */ React.createElement(
|
|
246
|
-
Animated2.View,
|
|
247
|
-
{
|
|
248
|
-
style: [
|
|
249
|
-
styles.fab,
|
|
250
|
-
fabDimensionStyles,
|
|
251
|
-
variantStyles,
|
|
252
|
-
isDisabled && styles.disabled,
|
|
253
|
-
{
|
|
254
|
-
transform: [{ scale: animatedScale }],
|
|
255
|
-
opacity: animatedOpacity
|
|
256
|
-
},
|
|
257
|
-
customAppearance?.fab
|
|
258
|
-
]
|
|
259
|
-
},
|
|
260
|
-
isLoading ? /* @__PURE__ */ React.createElement(
|
|
261
|
-
ActivityIndicator,
|
|
262
|
-
{
|
|
263
|
-
variant: "circular",
|
|
264
|
-
themeColor: variant === "solid" ? void 0 : themeColor,
|
|
265
|
-
color: variant === "solid" ? iconColor : void 0,
|
|
266
|
-
size: isExtended ? extendedSizeStyles.iconSize : sizeStyles.iconSize
|
|
267
|
-
}
|
|
268
|
-
) : /* @__PURE__ */ React.createElement(View, { style: styles.contentContainer }, icon, isExtended && /* @__PURE__ */ React.createElement(
|
|
269
|
-
Text,
|
|
270
|
-
{
|
|
271
|
-
style: [
|
|
272
|
-
styles.label,
|
|
273
|
-
{
|
|
274
|
-
fontSize: isExtended ? extendedSizeStyles.fontSize : sizeStyles.fontSize,
|
|
275
|
-
color: iconColor
|
|
276
|
-
}
|
|
277
|
-
]
|
|
278
|
-
},
|
|
279
|
-
label
|
|
280
|
-
))
|
|
281
|
-
)
|
|
282
|
-
));
|
|
283
|
-
};
|
|
284
|
-
|
|
285
|
-
export {
|
|
286
|
-
Fab
|
|
287
|
-
};
|