@xaui/native 0.9.1-alpha.41 → 0.9.1-alpha.43

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.
Files changed (105) hide show
  1. package/dist/{chunk-TJ74XVZN.cjs → chunk-3JXI2IHV.cjs} +8 -8
  2. package/dist/{chunk-C5YLPCFC.cjs → chunk-4KSKQD37.cjs} +5 -5
  3. package/dist/{chunk-DA3OKXHV.cjs → chunk-54CWXA34.cjs} +59 -59
  4. package/dist/{chunk-XV735BSA.cjs → chunk-66FOASTP.cjs} +6 -6
  5. package/dist/{chunk-UFTCTTKK.js → chunk-6CO6FM67.js} +15 -15
  6. package/dist/{chunk-RU7JCMWC.cjs → chunk-76XDVA24.cjs} +6 -6
  7. package/dist/{chunk-G7P3ERYF.cjs → chunk-7KLBTMXV.cjs} +5 -5
  8. package/dist/{chunk-NWGLP6JX.cjs → chunk-7TOG4TVU.cjs} +15 -15
  9. package/dist/{chunk-ZFOOJK37.cjs → chunk-AAVCMCJ3.cjs} +2 -2
  10. package/dist/{chunk-T5FV5F7A.cjs → chunk-C5LONNXT.cjs} +6 -6
  11. package/dist/{chunk-XFPQFCEK.js → chunk-DY3SUG5P.js} +6 -6
  12. package/dist/{chunk-KCMYU7WF.js → chunk-EYD4H4X6.js} +1 -1
  13. package/dist/{chunk-DHGLGSH6.js → chunk-FBCWNXZC.js} +58 -58
  14. package/dist/{chunk-2XPG2243.js → chunk-GJSFKH4L.js} +16 -16
  15. package/dist/{chunk-DD4276RF.js → chunk-HA6BFY3A.js} +6 -6
  16. package/dist/{chunk-GFUZ3MUT.cjs → chunk-HOI5425P.cjs} +6 -6
  17. package/dist/chunk-J5WXI5NU.js +520 -0
  18. package/dist/{chunk-LRN3RNDO.js → chunk-JKP4TPIL.js} +16 -16
  19. package/dist/{chunk-6UEZJRVI.js → chunk-LIUO6D3D.js} +75 -75
  20. package/dist/{chunk-DIBUQ46Y.js → chunk-MXGER5PI.js} +5 -5
  21. package/dist/{chunk-EZEYMLO3.js → chunk-N5AEXTUM.js} +4 -4
  22. package/dist/chunk-NA262TF2.js +724 -0
  23. package/dist/{chunk-R73XQK7X.cjs → chunk-NCCRQK3P.cjs} +5 -5
  24. package/dist/{chunk-5VKYNBNA.js → chunk-NHZRQM5J.js} +4 -4
  25. package/dist/chunk-P2GKAAA3.cjs +442 -0
  26. package/dist/{chunk-VLKBESEV.cjs → chunk-QWMVMLSU.cjs} +5 -5
  27. package/dist/{chunk-GA6PBWNT.js → chunk-QZ24MZRX.js} +1 -1
  28. package/dist/{chunk-YVHT2UVW.js → chunk-R7BU4CPS.js} +1 -1
  29. package/dist/{chunk-6DOLGZVV.cjs → chunk-S4QUM4EE.cjs} +4 -4
  30. package/dist/{chunk-DG2I4PJG.js → chunk-SACDOFGF.js} +15 -15
  31. package/dist/{chunk-ABAGZTXZ.cjs → chunk-SIP5J7HU.cjs} +15 -15
  32. package/dist/{chunk-3E7CDKFO.cjs → chunk-TGMVEHV7.cjs} +61 -61
  33. package/dist/{chunk-YGYYJ3LQ.js → chunk-TRETQZEW.js} +5 -5
  34. package/dist/{chunk-UAWBAD4E.cjs → chunk-URA25DU4.cjs} +5 -5
  35. package/dist/{chunk-BRRXFOBY.js → chunk-USF6EWYR.js} +7 -7
  36. package/dist/{chunk-5R26NM4M.cjs → chunk-VPQPFLT5.cjs} +6 -6
  37. package/dist/{chunk-G3CCT4EY.js → chunk-VT34G7RT.js} +16 -16
  38. package/dist/{chunk-7YF5NAHQ.cjs → chunk-VZK3NLBH.cjs} +7 -7
  39. package/dist/{chunk-N3KTZMPG.js → chunk-XNMZQSY5.js} +5 -5
  40. package/dist/chunk-ZTBA7CNK.cjs +510 -0
  41. package/dist/components/accordion/index.cjs +5 -5
  42. package/dist/components/accordion/index.js +4 -4
  43. package/dist/components/alert/index.cjs +6 -6
  44. package/dist/components/alert/index.js +5 -5
  45. package/dist/components/avatar/index.cjs +4 -4
  46. package/dist/components/avatar/index.js +3 -3
  47. package/dist/components/badge/index.cjs +4 -4
  48. package/dist/components/badge/index.js +3 -3
  49. package/dist/components/bottom-sheet/index.cjs +37 -0
  50. package/dist/components/bottom-sheet/index.d.cts +230 -0
  51. package/dist/components/bottom-sheet/index.d.ts +230 -0
  52. package/dist/components/bottom-sheet/index.js +37 -0
  53. package/dist/components/button/index.cjs +5 -5
  54. package/dist/components/button/index.js +4 -4
  55. package/dist/components/card/index.cjs +5 -5
  56. package/dist/components/card/index.js +4 -4
  57. package/dist/components/checkbox/index.cjs +5 -5
  58. package/dist/components/checkbox/index.js +4 -4
  59. package/dist/components/chip/index.cjs +6 -6
  60. package/dist/components/chip/index.js +5 -5
  61. package/dist/components/divider/index.cjs +4 -4
  62. package/dist/components/divider/index.js +3 -3
  63. package/dist/components/field-group/index.cjs +5 -5
  64. package/dist/components/field-group/index.js +4 -4
  65. package/dist/components/input-otp/index.cjs +4 -4
  66. package/dist/components/input-otp/index.js +3 -3
  67. package/dist/components/menu/index.cjs +5 -5
  68. package/dist/components/menu/index.js +4 -4
  69. package/dist/components/popover/index.cjs +5 -5
  70. package/dist/components/popover/index.js +4 -4
  71. package/dist/components/radio/index.cjs +5 -5
  72. package/dist/components/radio/index.js +4 -4
  73. package/dist/components/select/index.cjs +5 -5
  74. package/dist/components/select/index.js +4 -4
  75. package/dist/components/slider/index.cjs +33 -0
  76. package/dist/components/slider/index.d.cts +284 -0
  77. package/dist/components/slider/index.d.ts +284 -0
  78. package/dist/components/slider/index.js +33 -0
  79. package/dist/components/spinner/index.cjs +1 -1
  80. package/dist/components/spinner/index.js +1 -1
  81. package/dist/components/switch/index.cjs +5 -5
  82. package/dist/components/switch/index.js +4 -4
  83. package/dist/components/tabs/index.cjs +5 -5
  84. package/dist/components/tabs/index.js +4 -4
  85. package/dist/components/text-area/index.cjs +5 -5
  86. package/dist/components/text-area/index.js +4 -4
  87. package/dist/components/text-field/index.cjs +4 -4
  88. package/dist/components/text-field/index.js +3 -3
  89. package/dist/components/typography/index.cjs +4 -4
  90. package/dist/components/typography/index.js +3 -3
  91. package/dist/index.cjs +85 -37
  92. package/dist/index.d.cts +2 -0
  93. package/dist/index.d.ts +2 -0
  94. package/dist/index.js +132 -84
  95. package/dist/system/index.cjs +11 -11
  96. package/dist/system/index.js +13 -13
  97. package/package.json +21 -1
  98. package/dist/{chunk-4CUZZWFW.js → chunk-26OGEFQI.js} +3 -3
  99. package/dist/{chunk-H7DS4IO7.js → chunk-346QBNUD.js} +4 -4
  100. package/dist/{chunk-J3MB4PI5.cjs → chunk-A7YB7YWX.cjs} +3 -3
  101. package/dist/{chunk-AMCSSOJT.cjs → chunk-BNFIFRQA.cjs} +3 -3
  102. package/dist/{chunk-6L2TS2R3.cjs → chunk-KSUV74BE.cjs} +3 -3
  103. package/dist/{chunk-HDVVZG4S.cjs → chunk-RKCWYUGA.cjs} +3 -3
  104. package/dist/{chunk-2NRZKJG7.js → chunk-S2WNWMNT.js} +4 -4
  105. package/dist/{chunk-73RKQC5X.js → chunk-SZLXPF3G.js} +3 -3
@@ -0,0 +1,520 @@
1
+ import { Portal } from "./chunk-2PMXMKS5.js";
2
+ import { overlayEntering, overlayExiting } from "./chunk-64MXEVT3.js";
3
+ import { useControllableState } from "./chunk-F6W3JQ7K.js";
4
+ import { PressableFeedback } from "./chunk-LIUO6D3D.js";
5
+ import { usePressState } from "./chunk-423RQBOX.js";
6
+ import { createSlotContext } from "./chunk-K72UDPVN.js";
7
+ import { createRecipe } from "./chunk-4GTAZM2C.js";
8
+ import { useXAUITheme } from "./chunk-A3EGFI6T.js";
9
+ import { useStyleProps } from "./chunk-M63GFNKV.js";
10
+
11
+ // src/components/bottom-sheet/bottom-sheet-close.tsx
12
+ import { forwardRef, useCallback } from "react";
13
+
14
+ // src/components/bottom-sheet/bottom-sheet.context.ts
15
+ var [BottomSheetProvider, useBottomSheet] = createSlotContext("BottomSheet");
16
+
17
+ // src/components/bottom-sheet/bottom-sheet-close.tsx
18
+ import { jsx } from "react/jsx-runtime";
19
+ var BottomSheetClose = forwardRef(function BottomSheetClose2({
20
+ children,
21
+ asChild = false,
22
+ accessibilityRole = "button",
23
+ style,
24
+ onPress,
25
+ onPressIn,
26
+ onPressOut,
27
+ ...props
28
+ }, ref) {
29
+ const {
30
+ close
31
+ } = useBottomSheet();
32
+ const [styleProps, rest] = useStyleProps(props);
33
+ const [isPressed, press] = usePressState({
34
+ onPressIn,
35
+ onPressOut
36
+ });
37
+ const handlePress = useCallback(event => {
38
+ onPress?.(event);
39
+ close();
40
+ }, [close, onPress]);
41
+ return /* @__PURE__ */jsx(PressableFeedback, {
42
+ ref,
43
+ isPressed,
44
+ asChild,
45
+ accessibilityRole,
46
+ ...rest,
47
+ style: [styleProps, typeof style === "function" ? style({
48
+ pressed: isPressed
49
+ }) : style],
50
+ onPress: handlePress,
51
+ onPressIn: press.onPressIn,
52
+ onPressOut: press.onPressOut,
53
+ children
54
+ });
55
+ });
56
+ BottomSheetClose.displayName = "XAUI.BottomSheet.Close";
57
+
58
+ // src/components/bottom-sheet/bottom-sheet-content.tsx
59
+ import { useCallback as useCallback2, useEffect, useState } from "react";
60
+ import { Gesture, GestureDetector } from "react-native-gesture-handler";
61
+ import Animated, { runOnJS, useAnimatedStyle, useSharedValue, withSpring } from "react-native-reanimated";
62
+
63
+ // src/components/bottom-sheet/bottom-sheet.animation.ts
64
+ var SHEET_SPRING = {
65
+ damping: 28,
66
+ stiffness: 260,
67
+ mass: 0.9
68
+ };
69
+ var DISMISS_VELOCITY = 900;
70
+
71
+ // src/components/bottom-sheet/bottom-sheet-content.tsx
72
+ import { jsx as jsx2 } from "react/jsx-runtime";
73
+ const _worklet_77790971326_init_data = {
74
+ code: "function chunkJ5WXI5NUJs1(event){const{height,dismissThreshold,DISMISS_VELOCITY,offset,withSpring,SHEET_SPRING,runOnJS,close}=this.__closure;const farEnough=event.translationY>height*dismissThreshold;const fastEnough=event.velocityY>DISMISS_VELOCITY;if(farEnough||fastEnough){offset.set(withSpring(height,SHEET_SPRING));runOnJS(close)();return;}offset.set(withSpring(0,SHEET_SPRING));}",
75
+ location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-J5WXI5NU.js",
76
+ sourceMap: "{\"version\":3,\"names\":[\"chunkJ5WXI5NUJs1\",\"event\",\"height\",\"dismissThreshold\",\"DISMISS_VELOCITY\",\"offset\",\"withSpring\",\"SHEET_SPRING\",\"runOnJS\",\"close\",\"__closure\",\"farEnough\",\"translationY\",\"fastEnough\",\"velocityY\",\"set\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-J5WXI5NU.js\"],\"mappings\":\"AA0HY,SAAAA,gBAAUA,CAAAC,KAAA,QAAAC,MAAA,CAAAC,gBAAA,CAAAC,gBAAA,CAAAC,MAAA,CAAAC,UAAA,CAAAC,YAAA,CAAAC,OAAA,CAAAC,KAAA,OAAAC,SAAA,CAClB,KAAM,CAAAC,SAAS,CAAGV,KAAK,CAACW,YAAY,CAAGV,MAAM,CAAGC,gBAAgB,CAChE,KAAM,CAAAU,UAAU,CAAGZ,KAAK,CAACa,SAAS,CAAGV,gBAAgB,CACrD,GAAIO,SAAS,EAAIE,UAAU,CAAE,CAC3BR,MAAM,CAACU,GAAG,CAACT,UAAU,CAACJ,MAAM,CAAEK,YAAY,CAAC,CAAC,CAC5CC,OAAO,CAACC,KAAK,CAAC,CAAC,CAAC,CAChB,OACF,CACAJ,MAAM,CAACU,GAAG,CAACT,UAAU,CAAC,CAAC,CAAEC,YAAY,CAAC,CAAC,CACzC\",\"ignoreList\":[]}"
77
+ };
78
+ const _worklet_12195044952804_init_data = {
79
+ code: "function chunkJ5WXI5NUJs2(event){const{offset}=this.__closure;offset.set(Math.max(event.translationY,0));}",
80
+ location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-J5WXI5NU.js",
81
+ sourceMap: "{\"version\":3,\"names\":[\"chunkJ5WXI5NUJs2\",\"event\",\"offset\",\"__closure\",\"set\",\"Math\",\"max\",\"translationY\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-J5WXI5NU.js\"],\"mappings\":\"AAwH2D,SAAAA,gBAAUA,CAAAC,KAAA,QAAAC,MAAA,OAAAC,SAAA,CACjED,MAAM,CAACE,GAAG,CAACC,IAAI,CAACC,GAAG,CAACL,KAAK,CAACM,YAAY,CAAE,CAAC,CAAC,CAAC,CAC7C\",\"ignoreList\":[]}"
82
+ };
83
+ const _worklet_15404457517253_init_data = {
84
+ code: "function chunkJ5WXI5NUJs3(){const{offset}=this.__closure;return{transform:[{translateY:offset.get()}]};}",
85
+ location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-J5WXI5NU.js",
86
+ sourceMap: "{\"version\":3,\"names\":[\"chunkJ5WXI5NUJs3\",\"offset\",\"__closure\",\"transform\",\"translateY\",\"get\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-J5WXI5NU.js\"],\"mappings\":\"AAoIiC,SAAAA,iBAAA,QAAAC,MAAA,OAAAC,SAAA,OAAO,CACpCC,SAAS,CAAE,CAAC,CAAEC,UAAU,CAAEH,MAAM,CAACI,GAAG,CAAC,CAAE,CAAC,CAC1C,CAAC\",\"ignoreList\":[]}"
87
+ };
88
+ function BottomSheetContent({
89
+ children,
90
+ isSwipeable = true,
91
+ accessibilityViewIsModal = true,
92
+ style,
93
+ onLayout,
94
+ ...props
95
+ }) {
96
+ const context = useBottomSheet();
97
+ const {
98
+ contentStyle,
99
+ isOpen,
100
+ dismissThreshold,
101
+ close
102
+ } = context;
103
+ const [styleProps, rest] = useStyleProps(props);
104
+ const [height, setHeight] = useState(0);
105
+ const offset = useSharedValue(OFFSCREEN);
106
+ const measure = useCallback2(event => {
107
+ onLayout?.(event);
108
+ setHeight(event.nativeEvent.layout.height);
109
+ }, [onLayout]);
110
+ useEffect(() => {
111
+ if (height === 0) return;
112
+ offset.set(withSpring(isOpen ? 0 : height, SHEET_SPRING));
113
+ }, [height, isOpen, offset]);
114
+ const pan = Gesture.Pan().enabled(isSwipeable).onUpdate(function chunkJ5WXI5NUJs2Factory({
115
+ _worklet_12195044952804_init_data,
116
+ offset
117
+ }) {
118
+ const _e = [new global.Error(), -2, -27];
119
+ const chunkJ5WXI5NUJs2 = function (event) {
120
+ offset.set(Math.max(event.translationY, 0));
121
+ };
122
+ chunkJ5WXI5NUJs2.__closure = {
123
+ offset
124
+ };
125
+ chunkJ5WXI5NUJs2.__workletHash = 12195044952804;
126
+ chunkJ5WXI5NUJs2.__pluginVersion = "0.7.4";
127
+ chunkJ5WXI5NUJs2.__initData = _worklet_12195044952804_init_data;
128
+ chunkJ5WXI5NUJs2.__stackDetails = _e;
129
+ return chunkJ5WXI5NUJs2;
130
+ }({
131
+ _worklet_12195044952804_init_data,
132
+ offset
133
+ })).onEnd(function chunkJ5WXI5NUJs1Factory({
134
+ _worklet_77790971326_init_data,
135
+ height,
136
+ dismissThreshold,
137
+ DISMISS_VELOCITY,
138
+ offset,
139
+ withSpring,
140
+ SHEET_SPRING,
141
+ runOnJS,
142
+ close
143
+ }) {
144
+ const _e = [new global.Error(), -9, -27];
145
+ const chunkJ5WXI5NUJs1 = function (event) {
146
+ const farEnough = event.translationY > height * dismissThreshold;
147
+ const fastEnough = event.velocityY > DISMISS_VELOCITY;
148
+ if (farEnough || fastEnough) {
149
+ offset.set(withSpring(height, SHEET_SPRING));
150
+ runOnJS(close)();
151
+ return;
152
+ }
153
+ offset.set(withSpring(0, SHEET_SPRING));
154
+ };
155
+ chunkJ5WXI5NUJs1.__closure = {
156
+ height,
157
+ dismissThreshold,
158
+ DISMISS_VELOCITY,
159
+ offset,
160
+ withSpring,
161
+ SHEET_SPRING,
162
+ runOnJS,
163
+ close
164
+ };
165
+ chunkJ5WXI5NUJs1.__workletHash = 77790971326;
166
+ chunkJ5WXI5NUJs1.__pluginVersion = "0.7.4";
167
+ chunkJ5WXI5NUJs1.__initData = _worklet_77790971326_init_data;
168
+ chunkJ5WXI5NUJs1.__stackDetails = _e;
169
+ return chunkJ5WXI5NUJs1;
170
+ }({
171
+ _worklet_77790971326_init_data,
172
+ height,
173
+ dismissThreshold,
174
+ DISMISS_VELOCITY,
175
+ offset,
176
+ withSpring,
177
+ SHEET_SPRING,
178
+ runOnJS,
179
+ close
180
+ }));
181
+ const slide = useAnimatedStyle(function chunkJ5WXI5NUJs3Factory({
182
+ _worklet_15404457517253_init_data,
183
+ offset
184
+ }) {
185
+ const _e = [new global.Error(), -2, -27];
186
+ const chunkJ5WXI5NUJs3 = () => ({
187
+ transform: [{
188
+ translateY: offset.get()
189
+ }]
190
+ });
191
+ chunkJ5WXI5NUJs3.__closure = {
192
+ offset
193
+ };
194
+ chunkJ5WXI5NUJs3.__workletHash = 15404457517253;
195
+ chunkJ5WXI5NUJs3.__pluginVersion = "0.7.4";
196
+ chunkJ5WXI5NUJs3.__initData = _worklet_15404457517253_init_data;
197
+ chunkJ5WXI5NUJs3.__stackDetails = _e;
198
+ return chunkJ5WXI5NUJs3;
199
+ }({
200
+ _worklet_15404457517253_init_data,
201
+ offset
202
+ }));
203
+ if (!isOpen) return null;
204
+ return /* @__PURE__ */jsx2(Portal, {
205
+ children: /* @__PURE__ */jsx2(BottomSheetProvider, {
206
+ value: context,
207
+ children: /* @__PURE__ */jsx2(GestureDetector, {
208
+ gesture: pan,
209
+ children: /* @__PURE__ */jsx2(Animated.View, {
210
+ accessibilityViewIsModal,
211
+ onLayout: measure,
212
+ ...rest,
213
+ style: [contentStyle, slide, styleProps, style],
214
+ children
215
+ })
216
+ })
217
+ })
218
+ });
219
+ }
220
+ var OFFSCREEN = 2e3;
221
+ BottomSheetContent.displayName = "XAUI.BottomSheet.Content";
222
+
223
+ // src/components/bottom-sheet/bottom-sheet-description.tsx
224
+ import { forwardRef as forwardRef2 } from "react";
225
+ import { Text } from "react-native";
226
+ import { jsx as jsx3 } from "react/jsx-runtime";
227
+ var BottomSheetDescription = forwardRef2(function BottomSheetDescription2({
228
+ children,
229
+ style,
230
+ ...props
231
+ }, ref) {
232
+ const {
233
+ descriptionStyle
234
+ } = useBottomSheet();
235
+ const [styleProps, rest] = useStyleProps(props);
236
+ return /* @__PURE__ */jsx3(Text, {
237
+ ref,
238
+ ...rest,
239
+ style: [descriptionStyle, styleProps, style],
240
+ children
241
+ });
242
+ });
243
+ BottomSheetDescription.displayName = "XAUI.BottomSheet.Description";
244
+
245
+ // src/components/bottom-sheet/bottom-sheet-handle.tsx
246
+ import { forwardRef as forwardRef3 } from "react";
247
+ import { View } from "react-native";
248
+ import { jsx as jsx4 } from "react/jsx-runtime";
249
+ var BottomSheetHandle = forwardRef3(function BottomSheetHandle2({
250
+ style,
251
+ ...props
252
+ }, ref) {
253
+ const {
254
+ handleStyle
255
+ } = useBottomSheet();
256
+ const [styleProps, rest] = useStyleProps(props);
257
+ return /* @__PURE__ */jsx4(View, {
258
+ ref,
259
+ accessibilityElementsHidden: true,
260
+ importantForAccessibility: "no-hide-descendants",
261
+ ...rest,
262
+ style: [handleStyle, styleProps, style]
263
+ });
264
+ });
265
+ BottomSheetHandle.displayName = "XAUI.BottomSheet.Handle";
266
+
267
+ // src/components/bottom-sheet/bottom-sheet-overlay.tsx
268
+ import { forwardRef as forwardRef4 } from "react";
269
+ import { Pressable } from "react-native";
270
+ import Animated2 from "react-native-reanimated";
271
+ import { jsx as jsx5 } from "react/jsx-runtime";
272
+ var AnimatedPressable = Animated2.createAnimatedComponent(Pressable);
273
+ var BottomSheetOverlay = forwardRef4(function BottomSheetOverlay2({
274
+ children,
275
+ isDismissable = true,
276
+ style,
277
+ ...props
278
+ }, ref) {
279
+ const context = useBottomSheet();
280
+ const {
281
+ overlayStyle,
282
+ isOpen,
283
+ close
284
+ } = context;
285
+ const [styleProps, rest] = useStyleProps(props);
286
+ if (!isOpen) return null;
287
+ return /* @__PURE__ */jsx5(Portal, {
288
+ children: /* @__PURE__ */jsx5(BottomSheetProvider, {
289
+ value: context,
290
+ children: /* @__PURE__ */jsx5(AnimatedPressable, {
291
+ ref,
292
+ entering: overlayEntering,
293
+ exiting: overlayExiting,
294
+ accessibilityRole: "none",
295
+ importantForAccessibility: "no",
296
+ onPress: isDismissable ? close : void 0,
297
+ ...rest,
298
+ style: [overlayStyle, styleProps, style],
299
+ children
300
+ })
301
+ })
302
+ });
303
+ });
304
+ BottomSheetOverlay.displayName = "XAUI.BottomSheet.Overlay";
305
+
306
+ // src/components/bottom-sheet/bottom-sheet-title.tsx
307
+ import { forwardRef as forwardRef5 } from "react";
308
+ import { Text as Text2 } from "react-native";
309
+ import { jsx as jsx6 } from "react/jsx-runtime";
310
+ var BottomSheetTitle = forwardRef5(function BottomSheetTitle2({
311
+ children,
312
+ accessibilityRole = "header",
313
+ style,
314
+ ...props
315
+ }, ref) {
316
+ const {
317
+ titleStyle
318
+ } = useBottomSheet();
319
+ const [styleProps, rest] = useStyleProps(props);
320
+ return /* @__PURE__ */jsx6(Text2, {
321
+ ref,
322
+ accessibilityRole,
323
+ ...rest,
324
+ style: [titleStyle, styleProps, style],
325
+ children
326
+ });
327
+ });
328
+ BottomSheetTitle.displayName = "XAUI.BottomSheet.Title";
329
+
330
+ // src/components/bottom-sheet/bottom-sheet-trigger.tsx
331
+ import { forwardRef as forwardRef6, useCallback as useCallback3 } from "react";
332
+ import { jsx as jsx7 } from "react/jsx-runtime";
333
+ var BottomSheetTrigger = forwardRef6(function BottomSheetTrigger2({
334
+ children,
335
+ asChild = false,
336
+ accessibilityRole = "button",
337
+ accessibilityState,
338
+ style,
339
+ onPress,
340
+ onPressIn,
341
+ onPressOut,
342
+ ...props
343
+ }, ref) {
344
+ const {
345
+ isOpen,
346
+ isDisabled,
347
+ toggle
348
+ } = useBottomSheet();
349
+ const [styleProps, rest] = useStyleProps(props);
350
+ const [isPressed, press] = usePressState({
351
+ onPressIn,
352
+ onPressOut
353
+ });
354
+ const handlePress = useCallback3(event => {
355
+ onPress?.(event);
356
+ toggle();
357
+ }, [onPress, toggle]);
358
+ return /* @__PURE__ */jsx7(PressableFeedback, {
359
+ ref,
360
+ isPressed,
361
+ isDisabled,
362
+ asChild,
363
+ accessibilityRole,
364
+ accessibilityState: {
365
+ disabled: isDisabled,
366
+ expanded: isOpen,
367
+ ...accessibilityState
368
+ },
369
+ ...rest,
370
+ style: [styleProps, typeof style === "function" ? style({
371
+ pressed: isPressed
372
+ }) : style],
373
+ onPress: handlePress,
374
+ onPressIn: press.onPressIn,
375
+ onPressOut: press.onPressOut,
376
+ children
377
+ });
378
+ });
379
+ BottomSheetTrigger.displayName = "XAUI.BottomSheet.Trigger";
380
+
381
+ // src/components/bottom-sheet/bottom-sheet.tsx
382
+ import { useCallback as useCallback4, useMemo } from "react";
383
+
384
+ // src/components/bottom-sheet/bottom-sheet.recipe.ts
385
+ var SLOTS = ["overlay", "content", "handle", "title", "description"];
386
+ var HANDLE = {
387
+ width: 36,
388
+ height: 4
389
+ };
390
+ function topCorners(radius) {
391
+ return theme => ({
392
+ content: {
393
+ borderTopStartRadius: theme.radius[radius],
394
+ borderTopEndRadius: theme.radius[radius]
395
+ }
396
+ });
397
+ }
398
+ var RADII = ["xs", "sm", "md", "lg", "xl", "2xl", "3xl", "4xl", "field", "full"];
399
+ var bottomSheetRecipe = createRecipe({
400
+ slots: SLOTS,
401
+ base: theme => ({
402
+ overlay: {
403
+ position: "absolute",
404
+ top: 0,
405
+ bottom: 0,
406
+ start: 0,
407
+ end: 0,
408
+ backgroundColor: theme.colors.backdrop
409
+ },
410
+ content: {
411
+ position: "absolute",
412
+ start: 0,
413
+ end: 0,
414
+ bottom: 0,
415
+ backgroundColor: theme.colors.overlay,
416
+ padding: theme.spacing(5),
417
+ gap: theme.spacing(2),
418
+ // HeroUI's `--radius-4xl` on a base of 8 is 32 points; the nearest on our base of 12
419
+ // is `3xl` at 36. A sheet's corner is the largest in the library because it is the
420
+ // only edge of it you can see.
421
+ borderTopStartRadius: theme.radius["3xl"],
422
+ borderTopEndRadius: theme.radius["3xl"],
423
+ borderCurve: "continuous",
424
+ ...theme.shadows.overlay
425
+ },
426
+ /**
427
+ * The grab bar. It is the only thing telling a reader the sheet can be dragged — the
428
+ * gesture has no other affordance, and a sheet without one reads as a panel that
429
+ * happens to have arrived from below.
430
+ */
431
+ handle: {
432
+ alignSelf: "center",
433
+ width: HANDLE.width,
434
+ height: HANDLE.height,
435
+ borderRadius: HANDLE.height / 2,
436
+ backgroundColor: theme.colors.separator
437
+ },
438
+ title: {
439
+ fontFamily: theme.fontFamilies.body,
440
+ fontWeight: theme.fontWeights.medium,
441
+ fontSize: theme.fontSizes.lg,
442
+ lineHeight: theme.lineHeights.lg,
443
+ color: theme.colors.overlayForeground
444
+ },
445
+ description: {
446
+ fontFamily: theme.fontFamilies.body,
447
+ fontSize: theme.fontSizes.md,
448
+ lineHeight: theme.lineHeights.md,
449
+ color: theme.colors.muted
450
+ }
451
+ }),
452
+ /** One variant: a sheet is the theme's floating surface, with no emphasis to report. */
453
+ variantTokens: {
454
+ default: {}
455
+ },
456
+ variants: {
457
+ radius: Object.fromEntries(RADII.map(r => [r, topCorners(r)]))
458
+ },
459
+ defaultVariants: {
460
+ variant: "default"
461
+ }
462
+ });
463
+
464
+ // src/components/bottom-sheet/bottom-sheet.tsx
465
+ import { jsx as jsx8 } from "react/jsx-runtime";
466
+ function BottomSheet({
467
+ children,
468
+ radius,
469
+ isOpen: controlledOpen,
470
+ defaultOpen = false,
471
+ onOpenChange,
472
+ isDisabled = false,
473
+ dismissThreshold = 0.35
474
+ }) {
475
+ const theme = useXAUITheme();
476
+ const [isOpen, setOpen] = useControllableState({
477
+ value: controlledOpen,
478
+ defaultValue: defaultOpen,
479
+ onChange: onOpenChange
480
+ });
481
+ const styles = bottomSheetRecipe.resolve({
482
+ theme,
483
+ selection: {
484
+ radius
485
+ }
486
+ });
487
+ const open = useCallback4(() => setOpen(true), [setOpen]);
488
+ const close = useCallback4(() => setOpen(false), [setOpen]);
489
+ const toggle = useCallback4(() => setOpen(current => !current), [setOpen]);
490
+ const context = useMemo(() => ({
491
+ overlayStyle: styles.overlay,
492
+ contentStyle: styles.content,
493
+ handleStyle: styles.handle,
494
+ titleStyle: styles.title,
495
+ descriptionStyle: styles.description,
496
+ isOpen,
497
+ isDisabled,
498
+ dismissThreshold,
499
+ open,
500
+ close,
501
+ toggle
502
+ }), [styles, isOpen, isDisabled, dismissThreshold, open, close, toggle]);
503
+ return /* @__PURE__ */jsx8(BottomSheetProvider, {
504
+ value: context,
505
+ children
506
+ });
507
+ }
508
+ BottomSheet.displayName = "XAUI.BottomSheet.Root";
509
+
510
+ // src/components/bottom-sheet/index.ts
511
+ var BottomSheet2 = Object.assign(BottomSheet, {
512
+ Trigger: BottomSheetTrigger,
513
+ Overlay: BottomSheetOverlay,
514
+ Content: BottomSheetContent,
515
+ Handle: BottomSheetHandle,
516
+ Title: BottomSheetTitle,
517
+ Description: BottomSheetDescription,
518
+ Close: BottomSheetClose
519
+ });
520
+ export { useBottomSheet, BottomSheetClose, BottomSheetContent, BottomSheetDescription, BottomSheetHandle, BottomSheetOverlay, BottomSheetTitle, BottomSheetTrigger, bottomSheetRecipe, BottomSheet, BottomSheet2 };
@@ -4,11 +4,11 @@ import { INDICATOR_ROTATION, INDICATOR_SPRING, anchoredEntering, anchoredExiting
4
4
  import { useMergedRef } from "./chunk-NCTOTTVW.js";
5
5
  import { ChevronDownIcon, Icon, IconContext } from "./chunk-FHUYHV6J.js";
6
6
  import { useControllableState } from "./chunk-F6W3JQ7K.js";
7
- import { PressableFeedback } from "./chunk-6UEZJRVI.js";
7
+ import { PressableFeedback } from "./chunk-LIUO6D3D.js";
8
8
  import { usePressState } from "./chunk-423RQBOX.js";
9
+ import { childrenToString, createSlotContext } from "./chunk-K72UDPVN.js";
9
10
  import { createRecipe, radiusAxis } from "./chunk-4GTAZM2C.js";
10
11
  import { useXAUITheme } from "./chunk-A3EGFI6T.js";
11
- import { childrenToString, createSlotContext } from "./chunk-K72UDPVN.js";
12
12
  import { useStyleProps } from "./chunk-M63GFNKV.js";
13
13
 
14
14
  // src/components/select/select-content.tsx
@@ -230,10 +230,10 @@ SelectContent.displayName = "XAUI.Select.Content";
230
230
  import { useEffect as useEffect3 } from "react";
231
231
  import Animated2, { interpolate, useAnimatedStyle, useSharedValue, withSpring } from "react-native-reanimated";
232
232
  import { jsx as jsx4 } from "react/jsx-runtime";
233
- const _worklet_16740975826468_init_data = {
234
- code: "function chunkLRN3RNDOJs1(){const{interpolate,progress,INDICATOR_ROTATION}=this.__closure;return{transform:[{rotate:interpolate(progress.get(),[0,1],[INDICATOR_ROTATION[0],INDICATOR_ROTATION[1]])+\"deg\"}]};}",
235
- location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-LRN3RNDO.js",
236
- sourceMap: "{\"version\":3,\"names\":[\"chunkLRN3RNDOJs1\",\"interpolate\",\"progress\",\"INDICATOR_ROTATION\",\"__closure\",\"transform\",\"rotate\",\"get\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-LRN3RNDO.js\"],\"mappings\":\"AAgRoC,SAAAA,iBAAA,QAAAC,WAAA,CAAAC,QAAA,CAAAC,kBAAA,OAAAC,SAAA,OAAO,CACvCC,SAAS,CAAE,CACT,CACEC,MAAM,CAAKL,WAAW,CAACC,QAAQ,CAACK,GAAG,CAAC,CAAC,CAAE,CAAC,CAAC,CAAE,CAAC,CAAC,CAAE,CAACJ,kBAAkB,CAAC,CAAC,CAAC,CAAEA,kBAAkB,CAAC,CAAC,CAAC,CAAC,CAAC,MAChG,CAAC,CAEL,CAAC\",\"ignoreList\":[]}"
233
+ const _worklet_11125272119572_init_data = {
234
+ code: "function chunkJKP4TPILJs1(){const{interpolate,progress,INDICATOR_ROTATION}=this.__closure;return{transform:[{rotate:interpolate(progress.get(),[0,1],[INDICATOR_ROTATION[0],INDICATOR_ROTATION[1]])+\"deg\"}]};}",
235
+ location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-JKP4TPIL.js",
236
+ sourceMap: "{\"version\":3,\"names\":[\"chunkJKP4TPILJs1\",\"interpolate\",\"progress\",\"INDICATOR_ROTATION\",\"__closure\",\"transform\",\"rotate\",\"get\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-JKP4TPIL.js\"],\"mappings\":\"AAgRoC,SAAAA,iBAAA,QAAAC,WAAA,CAAAC,QAAA,CAAAC,kBAAA,OAAAC,SAAA,OAAO,CACvCC,SAAS,CAAE,CACT,CACEC,MAAM,CAAKL,WAAW,CAACC,QAAQ,CAACK,GAAG,CAAC,CAAC,CAAE,CAAC,CAAC,CAAE,CAAC,CAAC,CAAE,CAACJ,kBAAkB,CAAC,CAAC,CAAC,CAAEA,kBAAkB,CAAC,CAAC,CAAC,CAAC,CAAC,MAChG,CAAC,CAEL,CAAC\",\"ignoreList\":[]}"
237
237
  };
238
238
  function SelectIndicator({
239
239
  as = ChevronDownIcon,
@@ -247,30 +247,30 @@ function SelectIndicator({
247
247
  useEffect3(() => {
248
248
  progress.set(withSpring(isOpen ? 1 : 0, INDICATOR_SPRING));
249
249
  }, [isOpen, progress]);
250
- const rotation = useAnimatedStyle(function chunkLRN3RNDOJs1Factory({
251
- _worklet_16740975826468_init_data,
250
+ const rotation = useAnimatedStyle(function chunkJKP4TPILJs1Factory({
251
+ _worklet_11125272119572_init_data,
252
252
  interpolate,
253
253
  progress,
254
254
  INDICATOR_ROTATION
255
255
  }) {
256
256
  const _e = [new global.Error(), -4, -27];
257
- const chunkLRN3RNDOJs1 = () => ({
257
+ const chunkJKP4TPILJs1 = () => ({
258
258
  transform: [{
259
259
  rotate: `${interpolate(progress.get(), [0, 1], [INDICATOR_ROTATION[0], INDICATOR_ROTATION[1]])}deg`
260
260
  }]
261
261
  });
262
- chunkLRN3RNDOJs1.__closure = {
262
+ chunkJKP4TPILJs1.__closure = {
263
263
  interpolate,
264
264
  progress,
265
265
  INDICATOR_ROTATION
266
266
  };
267
- chunkLRN3RNDOJs1.__workletHash = 16740975826468;
268
- chunkLRN3RNDOJs1.__pluginVersion = "0.7.4";
269
- chunkLRN3RNDOJs1.__initData = _worklet_16740975826468_init_data;
270
- chunkLRN3RNDOJs1.__stackDetails = _e;
271
- return chunkLRN3RNDOJs1;
267
+ chunkJKP4TPILJs1.__workletHash = 11125272119572;
268
+ chunkJKP4TPILJs1.__pluginVersion = "0.7.4";
269
+ chunkJKP4TPILJs1.__initData = _worklet_11125272119572_init_data;
270
+ chunkJKP4TPILJs1.__stackDetails = _e;
271
+ return chunkJKP4TPILJs1;
272
272
  }({
273
- _worklet_16740975826468_init_data,
273
+ _worklet_11125272119572_init_data,
274
274
  interpolate,
275
275
  progress,
276
276
  INDICATOR_ROTATION