@xaui/native 0.9.1-alpha.37 → 0.9.1-alpha.38
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/dist/{chunk-OULTSBKU.js → chunk-26OGEFQI.js} +1 -1
- package/dist/{chunk-TJHYSSBZ.js → chunk-346QBNUD.js} +1 -1
- package/dist/{chunk-PPWXLZGL.js → chunk-3GFRSZYR.js} +15 -23
- package/dist/{chunk-DKH6BNPF.cjs → chunk-3JXI2IHV.cjs} +13 -13
- package/dist/{chunk-7B3UBUC6.cjs → chunk-4KFKWBN5.cjs} +23 -2
- package/dist/{chunk-IGLKACSR.cjs → chunk-4KSKQD37.cjs} +5 -5
- package/dist/{chunk-UBOXW5WO.cjs → chunk-54CWXA34.cjs} +61 -61
- package/dist/{chunk-ZJWEVFAO.cjs → chunk-66FOASTP.cjs} +9 -9
- package/dist/{chunk-5PPNDKRX.js → chunk-6CO6FM67.js} +16 -16
- package/dist/{chunk-54FJOKAN.cjs → chunk-7GHM4GKL.cjs} +25 -25
- package/dist/{chunk-AP6RVIIK.cjs → chunk-7TOG4TVU.cjs} +21 -21
- package/dist/{chunk-LEWW24RQ.cjs → chunk-A7YB7YWX.cjs} +3 -3
- package/dist/{chunk-3P6M2R4S.cjs → chunk-AAVCMCJ3.cjs} +4 -4
- package/dist/{chunk-VFTT3Q4B.cjs → chunk-BNFIFRQA.cjs} +3 -3
- package/dist/{chunk-JXNFOOKC.js → chunk-DY3SUG5P.js} +5 -5
- package/dist/{chunk-EOJ5MYAQ.js → chunk-EYD4H4X6.js} +4 -4
- package/dist/{chunk-RGKWNK4T.js → chunk-FBCWNXZC.js} +58 -58
- package/dist/{chunk-HXW4ANVB.js → chunk-FHUYHV6J.js} +25 -4
- package/dist/{chunk-6G3XWPNP.js → chunk-HA6BFY3A.js} +3 -3
- package/dist/{chunk-FTQHDJYL.cjs → chunk-HOI5425P.cjs} +9 -9
- package/dist/{chunk-YXPYOOHU.js → chunk-K72UDPVN.js} +27 -27
- package/dist/{chunk-NTD3NPRX.cjs → chunk-KSUV74BE.cjs} +2 -2
- package/dist/{chunk-UGF35NSE.js → chunk-LIUO6D3D.js} +75 -75
- package/dist/{chunk-E3X5ODKQ.js → chunk-LTX6TB5I.js} +1 -1
- package/dist/{chunk-BORJJYDW.js → chunk-MXGER5PI.js} +2 -2
- package/dist/{chunk-GTT4NHS2.cjs → chunk-NCCRQK3P.cjs} +11 -11
- package/dist/chunk-NCTOTTVW.js +13 -0
- package/dist/chunk-Q3MQ7S2D.cjs +476 -0
- package/dist/{chunk-NKPTXTTS.js → chunk-QZ24MZRX.js} +3 -3
- package/dist/{chunk-7LSY4WFL.js → chunk-R7BU4CPS.js} +2 -2
- package/dist/{chunk-DVDQSW7U.cjs → chunk-RAWGK2XK.cjs} +25 -60
- package/dist/{chunk-JB5LGQ54.cjs → chunk-RKCWYUGA.cjs} +3 -3
- package/dist/{chunk-SMW6ZWMH.js → chunk-S2WNWMNT.js} +1 -1
- package/dist/{chunk-WVLSQO6K.cjs → chunk-S4QUM4EE.cjs} +9 -9
- package/dist/{chunk-SO5UAGIU.js → chunk-SACDOFGF.js} +15 -15
- package/dist/{chunk-CUQTAPBU.cjs → chunk-SIP5J7HU.cjs} +17 -17
- package/dist/{chunk-O3A3DBSZ.js → chunk-SZLXPF3G.js} +1 -1
- package/dist/{chunk-437QULXO.cjs → chunk-TDTUAIFF.cjs} +5 -5
- package/dist/{chunk-DRMT346W.cjs → chunk-TGMVEHV7.cjs} +64 -64
- package/dist/{chunk-TDYPY2J7.js → chunk-TRETQZEW.js} +7 -7
- package/dist/{chunk-ITURCQMQ.cjs → chunk-URA25DU4.cjs} +5 -5
- package/dist/{chunk-4PTWZCOK.js → chunk-USF6EWYR.js} +7 -7
- package/dist/{chunk-P747CRAY.cjs → chunk-VZK3NLBH.cjs} +9 -9
- package/dist/chunk-WFEMJCXO.cjs +13 -0
- package/dist/{chunk-RVRVGG73.js → chunk-XNMZQSY5.js} +2 -2
- package/dist/{chunk-K4TWKF5U.cjs → chunk-XSQPVDFH.cjs} +15 -25
- package/dist/{chunk-JDSE4TQL.js → chunk-XTC2SLFT.js} +1 -1
- package/dist/{chunk-C5VDFRAD.cjs → chunk-XWNG2U4K.cjs} +2 -2
- package/dist/chunk-ZF6KIHXH.js +591 -0
- package/dist/{chunk-XWY4DF37.js → chunk-ZNZ7HVRW.js} +51 -88
- package/dist/components/accordion/index.cjs +34 -0
- package/dist/components/accordion/index.d.cts +299 -0
- package/dist/components/accordion/index.d.ts +299 -0
- package/dist/components/accordion/index.js +34 -0
- package/dist/components/alert/index.cjs +7 -7
- package/dist/components/alert/index.d.cts +2 -2
- package/dist/components/alert/index.d.ts +2 -2
- package/dist/components/alert/index.js +6 -6
- package/dist/components/avatar/index.cjs +4 -4
- package/dist/components/avatar/index.d.cts +3 -3
- package/dist/components/avatar/index.d.ts +3 -3
- package/dist/components/avatar/index.js +3 -3
- package/dist/components/badge/index.cjs +3 -3
- package/dist/components/badge/index.d.cts +1 -1
- package/dist/components/badge/index.d.ts +1 -1
- package/dist/components/badge/index.js +2 -2
- package/dist/components/button/index.cjs +8 -7
- package/dist/components/button/index.d.cts +204 -204
- package/dist/components/button/index.d.ts +204 -204
- package/dist/components/button/index.js +7 -6
- package/dist/components/card/index.cjs +5 -5
- package/dist/components/card/index.d.cts +206 -206
- package/dist/components/card/index.d.ts +206 -206
- package/dist/components/card/index.js +4 -4
- package/dist/components/checkbox/index.cjs +5 -5
- package/dist/components/checkbox/index.d.cts +408 -408
- package/dist/components/checkbox/index.d.ts +408 -408
- package/dist/components/checkbox/index.js +4 -4
- package/dist/components/chip/index.cjs +7 -7
- package/dist/components/chip/index.d.cts +205 -205
- package/dist/components/chip/index.d.ts +205 -205
- package/dist/components/chip/index.js +6 -6
- package/dist/components/divider/index.cjs +3 -3
- package/dist/components/divider/index.d.cts +3 -3
- package/dist/components/divider/index.d.ts +3 -3
- package/dist/components/divider/index.js +2 -2
- package/dist/components/field-group/index.cjs +5 -5
- package/dist/components/field-group/index.d.cts +8 -8
- package/dist/components/field-group/index.d.ts +8 -8
- package/dist/components/field-group/index.js +4 -4
- package/dist/components/input-otp/index.cjs +3 -3
- package/dist/components/input-otp/index.d.cts +2 -2
- package/dist/components/input-otp/index.d.ts +2 -2
- package/dist/components/input-otp/index.js +2 -2
- package/dist/components/radio/index.cjs +5 -5
- package/dist/components/radio/index.d.cts +419 -419
- package/dist/components/radio/index.d.ts +419 -419
- package/dist/components/radio/index.js +4 -4
- package/dist/components/select/index.cjs +8 -7
- package/dist/components/select/index.d.cts +12 -22
- package/dist/components/select/index.d.ts +12 -22
- package/dist/components/select/index.js +7 -6
- package/dist/components/skeleton/index.d.cts +1 -1
- package/dist/components/skeleton/index.d.ts +1 -1
- package/dist/components/spinner/index.cjs +5 -4
- package/dist/components/spinner/index.d.cts +1 -1
- package/dist/components/spinner/index.d.ts +1 -1
- package/dist/components/spinner/index.js +4 -3
- package/dist/components/switch/index.cjs +5 -5
- package/dist/components/switch/index.d.cts +409 -409
- package/dist/components/switch/index.d.ts +409 -409
- package/dist/components/switch/index.js +4 -4
- package/dist/components/text-area/index.cjs +4 -4
- package/dist/components/text-area/index.js +3 -3
- package/dist/components/text-field/index.cjs +3 -3
- package/dist/components/text-field/index.d.cts +3 -3
- package/dist/components/text-field/index.d.ts +3 -3
- package/dist/components/text-field/index.js +2 -2
- package/dist/components/typography/index.cjs +3 -3
- package/dist/components/typography/index.d.cts +5 -5
- package/dist/components/typography/index.d.ts +5 -5
- package/dist/components/typography/index.js +2 -2
- package/dist/components/view/index.cjs +3 -3
- package/dist/components/view/index.d.cts +8 -8
- package/dist/components/view/index.d.ts +8 -8
- package/dist/components/view/index.js +2 -2
- package/dist/index.cjs +51 -27
- package/dist/index.d.cts +3 -2
- package/dist/index.d.ts +3 -2
- package/dist/index.js +69 -45
- package/dist/system/index.cjs +9 -7
- package/dist/system/index.d.cts +46 -33
- package/dist/system/index.d.ts +46 -33
- package/dist/system/index.js +10 -8
- package/package.json +11 -1
|
@@ -1,9 +1,10 @@
|
|
|
1
1
|
import { Portal, PortalContext } from "./chunk-2PMXMKS5.js";
|
|
2
|
-
import {
|
|
3
|
-
import {
|
|
2
|
+
import { useMergedRef } from "./chunk-NCTOTTVW.js";
|
|
3
|
+
import { ChevronDownIcon, Icon, IconContext } from "./chunk-FHUYHV6J.js";
|
|
4
|
+
import { useControllableState } from "./chunk-F6W3JQ7K.js";
|
|
5
|
+
import { PressableFeedback } from "./chunk-LIUO6D3D.js";
|
|
4
6
|
import { usePressState } from "./chunk-423RQBOX.js";
|
|
5
|
-
import { childrenToString, createSlotContext } from "./chunk-
|
|
6
|
-
import { mergeRefs } from "./chunk-36PRYGAM.js";
|
|
7
|
+
import { childrenToString, createSlotContext } from "./chunk-K72UDPVN.js";
|
|
7
8
|
import { createRecipe, radiusAxis } from "./chunk-4GTAZM2C.js";
|
|
8
9
|
import { useXAUITheme } from "./chunk-A3EGFI6T.js";
|
|
9
10
|
import { useStyleProps } from "./chunk-M63GFNKV.js";
|
|
@@ -394,36 +395,11 @@ SelectContent.displayName = "XAUI.Select.Content";
|
|
|
394
395
|
// src/components/select/select-indicator.tsx
|
|
395
396
|
import { useEffect as useEffect3 } from "react";
|
|
396
397
|
import Animated2, { interpolate, useAnimatedStyle, useSharedValue, withSpring } from "react-native-reanimated";
|
|
397
|
-
|
|
398
|
-
// src/components/select/chevron-down-icon.tsx
|
|
399
|
-
import { Path, Svg } from "react-native-svg";
|
|
400
398
|
import { jsx as jsx4 } from "react/jsx-runtime";
|
|
401
|
-
|
|
402
|
-
|
|
403
|
-
|
|
404
|
-
|
|
405
|
-
return /* @__PURE__ */jsx4(Svg, {
|
|
406
|
-
width: size,
|
|
407
|
-
height: size,
|
|
408
|
-
viewBox: "0 0 24 24",
|
|
409
|
-
fill: "none",
|
|
410
|
-
children: /* @__PURE__ */jsx4(Path, {
|
|
411
|
-
d: "m6 9 6 6 6-6",
|
|
412
|
-
stroke: color,
|
|
413
|
-
strokeWidth: 2,
|
|
414
|
-
strokeLinecap: "round",
|
|
415
|
-
strokeLinejoin: "round"
|
|
416
|
-
})
|
|
417
|
-
});
|
|
418
|
-
}
|
|
419
|
-
ChevronDownIcon.displayName = "XAUI.Select.ChevronDownIcon";
|
|
420
|
-
|
|
421
|
-
// src/components/select/select-indicator.tsx
|
|
422
|
-
import { jsx as jsx5 } from "react/jsx-runtime";
|
|
423
|
-
const _worklet_11336077885044_init_data = {
|
|
424
|
-
code: "function chunkXWY4DF37Js1(){const{interpolate,progress,INDICATOR_ROTATION}=this.__closure;return{transform:[{rotate:interpolate(progress.get(),[0,1],[INDICATOR_ROTATION[0],INDICATOR_ROTATION[1]])+\"deg\"}]};}",
|
|
425
|
-
location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-XWY4DF37.js",
|
|
426
|
-
sourceMap: "{\"version\":3,\"names\":[\"chunkXWY4DF37Js1\",\"interpolate\",\"progress\",\"INDICATOR_ROTATION\",\"__closure\",\"transform\",\"rotate\",\"get\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-XWY4DF37.js\"],\"mappings\":\"AA4XoC,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\":[]}"
|
|
399
|
+
const _worklet_1818497961394_init_data = {
|
|
400
|
+
code: "function chunkZNZ7HVRWJs1(){const{interpolate,progress,INDICATOR_ROTATION}=this.__closure;return{transform:[{rotate:interpolate(progress.get(),[0,1],[INDICATOR_ROTATION[0],INDICATOR_ROTATION[1]])+\"deg\"}]};}",
|
|
401
|
+
location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-ZNZ7HVRW.js",
|
|
402
|
+
sourceMap: "{\"version\":3,\"names\":[\"chunkZNZ7HVRWJs1\",\"interpolate\",\"progress\",\"INDICATOR_ROTATION\",\"__closure\",\"transform\",\"rotate\",\"get\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-ZNZ7HVRW.js\"],\"mappings\":\"AA0WoC,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\":[]}"
|
|
427
403
|
};
|
|
428
404
|
function SelectIndicator({
|
|
429
405
|
as = ChevronDownIcon,
|
|
@@ -437,37 +413,37 @@ function SelectIndicator({
|
|
|
437
413
|
useEffect3(() => {
|
|
438
414
|
progress.set(withSpring(isOpen ? 1 : 0, INDICATOR_SPRING));
|
|
439
415
|
}, [isOpen, progress]);
|
|
440
|
-
const rotation = useAnimatedStyle(function
|
|
441
|
-
|
|
416
|
+
const rotation = useAnimatedStyle(function chunkZNZ7HVRWJs1Factory({
|
|
417
|
+
_worklet_1818497961394_init_data,
|
|
442
418
|
interpolate,
|
|
443
419
|
progress,
|
|
444
420
|
INDICATOR_ROTATION
|
|
445
421
|
}) {
|
|
446
422
|
const _e = [new global.Error(), -4, -27];
|
|
447
|
-
const
|
|
423
|
+
const chunkZNZ7HVRWJs1 = () => ({
|
|
448
424
|
transform: [{
|
|
449
425
|
rotate: `${interpolate(progress.get(), [0, 1], [INDICATOR_ROTATION[0], INDICATOR_ROTATION[1]])}deg`
|
|
450
426
|
}]
|
|
451
427
|
});
|
|
452
|
-
|
|
428
|
+
chunkZNZ7HVRWJs1.__closure = {
|
|
453
429
|
interpolate,
|
|
454
430
|
progress,
|
|
455
431
|
INDICATOR_ROTATION
|
|
456
432
|
};
|
|
457
|
-
|
|
458
|
-
|
|
459
|
-
|
|
460
|
-
|
|
461
|
-
return
|
|
433
|
+
chunkZNZ7HVRWJs1.__workletHash = 1818497961394;
|
|
434
|
+
chunkZNZ7HVRWJs1.__pluginVersion = "0.7.4";
|
|
435
|
+
chunkZNZ7HVRWJs1.__initData = _worklet_1818497961394_init_data;
|
|
436
|
+
chunkZNZ7HVRWJs1.__stackDetails = _e;
|
|
437
|
+
return chunkZNZ7HVRWJs1;
|
|
462
438
|
}({
|
|
463
|
-
|
|
439
|
+
_worklet_1818497961394_init_data,
|
|
464
440
|
interpolate,
|
|
465
441
|
progress,
|
|
466
442
|
INDICATOR_ROTATION
|
|
467
443
|
}));
|
|
468
|
-
return /* @__PURE__ */
|
|
444
|
+
return /* @__PURE__ */jsx4(Animated2.View, {
|
|
469
445
|
style: [indicatorStyle, rotation],
|
|
470
|
-
children: /* @__PURE__ */
|
|
446
|
+
children: /* @__PURE__ */jsx4(Icon, {
|
|
471
447
|
as,
|
|
472
448
|
...props
|
|
473
449
|
})
|
|
@@ -478,7 +454,7 @@ SelectIndicator.displayName = "XAUI.Select.Indicator";
|
|
|
478
454
|
// src/components/select/select-item-description.tsx
|
|
479
455
|
import { forwardRef as forwardRef4 } from "react";
|
|
480
456
|
import { Text as Text2 } from "react-native";
|
|
481
|
-
import { jsx as
|
|
457
|
+
import { jsx as jsx5 } from "react/jsx-runtime";
|
|
482
458
|
var SelectItemDescription = forwardRef4(function SelectItemDescription2({
|
|
483
459
|
children,
|
|
484
460
|
style,
|
|
@@ -488,7 +464,7 @@ var SelectItemDescription = forwardRef4(function SelectItemDescription2({
|
|
|
488
464
|
itemDescriptionStyle
|
|
489
465
|
} = useSelect();
|
|
490
466
|
const [styleProps, rest] = useStyleProps(props);
|
|
491
|
-
return /* @__PURE__ */
|
|
467
|
+
return /* @__PURE__ */jsx5(Text2, {
|
|
492
468
|
ref,
|
|
493
469
|
...rest,
|
|
494
470
|
style: [itemDescriptionStyle, styleProps, style],
|
|
@@ -501,18 +477,18 @@ SelectItemDescription.displayName = "XAUI.Select.ItemDescription";
|
|
|
501
477
|
import { View } from "react-native";
|
|
502
478
|
|
|
503
479
|
// src/components/select/check-icon.tsx
|
|
504
|
-
import { Path
|
|
505
|
-
import { jsx as
|
|
480
|
+
import { Path, Svg } from "react-native-svg";
|
|
481
|
+
import { jsx as jsx6 } from "react/jsx-runtime";
|
|
506
482
|
function CheckIcon({
|
|
507
483
|
size = 20,
|
|
508
484
|
color = "currentColor"
|
|
509
485
|
}) {
|
|
510
|
-
return /* @__PURE__ */
|
|
486
|
+
return /* @__PURE__ */jsx6(Svg, {
|
|
511
487
|
width: size,
|
|
512
488
|
height: size,
|
|
513
489
|
viewBox: "0 0 24 24",
|
|
514
490
|
fill: "none",
|
|
515
|
-
children: /* @__PURE__ */
|
|
491
|
+
children: /* @__PURE__ */jsx6(Path, {
|
|
516
492
|
d: "m20 6-11 11-5-5",
|
|
517
493
|
stroke: color,
|
|
518
494
|
strokeWidth: 2,
|
|
@@ -524,7 +500,7 @@ function CheckIcon({
|
|
|
524
500
|
CheckIcon.displayName = "XAUI.Select.CheckIcon";
|
|
525
501
|
|
|
526
502
|
// src/components/select/select-item-indicator.tsx
|
|
527
|
-
import { jsx as
|
|
503
|
+
import { jsx as jsx7 } from "react/jsx-runtime";
|
|
528
504
|
function SelectItemIndicator({
|
|
529
505
|
as = CheckIcon,
|
|
530
506
|
color,
|
|
@@ -537,9 +513,9 @@ function SelectItemIndicator({
|
|
|
537
513
|
const {
|
|
538
514
|
isSelected
|
|
539
515
|
} = useSelectItem();
|
|
540
|
-
return /* @__PURE__ */
|
|
516
|
+
return /* @__PURE__ */jsx7(View, {
|
|
541
517
|
style: itemIndicatorStyle,
|
|
542
|
-
children: isSelected ? /* @__PURE__ */
|
|
518
|
+
children: isSelected ? /* @__PURE__ */jsx7(Icon, {
|
|
543
519
|
as,
|
|
544
520
|
color: color ?? checkColor,
|
|
545
521
|
...props
|
|
@@ -551,7 +527,7 @@ SelectItemIndicator.displayName = "XAUI.Select.ItemIndicator";
|
|
|
551
527
|
// src/components/select/select-label.tsx
|
|
552
528
|
import { forwardRef as forwardRef5 } from "react";
|
|
553
529
|
import { Text as Text3 } from "react-native";
|
|
554
|
-
import { jsx as
|
|
530
|
+
import { jsx as jsx8 } from "react/jsx-runtime";
|
|
555
531
|
var SelectLabel = forwardRef5(function SelectLabel2({
|
|
556
532
|
children,
|
|
557
533
|
accessibilityRole = "header",
|
|
@@ -562,7 +538,7 @@ var SelectLabel = forwardRef5(function SelectLabel2({
|
|
|
562
538
|
labelStyle
|
|
563
539
|
} = useSelect();
|
|
564
540
|
const [styleProps, rest] = useStyleProps(props);
|
|
565
|
-
return /* @__PURE__ */
|
|
541
|
+
return /* @__PURE__ */jsx8(Text3, {
|
|
566
542
|
ref,
|
|
567
543
|
accessibilityRole,
|
|
568
544
|
...rest,
|
|
@@ -576,7 +552,7 @@ SelectLabel.displayName = "XAUI.Select.Label";
|
|
|
576
552
|
import { forwardRef as forwardRef6 } from "react";
|
|
577
553
|
import { Pressable } from "react-native";
|
|
578
554
|
import Animated3 from "react-native-reanimated";
|
|
579
|
-
import { jsx as
|
|
555
|
+
import { jsx as jsx9 } from "react/jsx-runtime";
|
|
580
556
|
var AnimatedPressable = Animated3.createAnimatedComponent(Pressable);
|
|
581
557
|
var SelectOverlay = forwardRef6(function SelectOverlay2({
|
|
582
558
|
children,
|
|
@@ -592,10 +568,10 @@ var SelectOverlay = forwardRef6(function SelectOverlay2({
|
|
|
592
568
|
} = context;
|
|
593
569
|
const [styleProps, rest] = useStyleProps(props);
|
|
594
570
|
if (!isOpen) return null;
|
|
595
|
-
return /* @__PURE__ */
|
|
596
|
-
children: /* @__PURE__ */
|
|
571
|
+
return /* @__PURE__ */jsx9(Portal, {
|
|
572
|
+
children: /* @__PURE__ */jsx9(SelectProvider, {
|
|
597
573
|
value: context,
|
|
598
|
-
children: /* @__PURE__ */
|
|
574
|
+
children: /* @__PURE__ */jsx9(AnimatedPressable, {
|
|
599
575
|
ref,
|
|
600
576
|
entering: overlayEntering,
|
|
601
577
|
exiting: overlayExiting,
|
|
@@ -612,8 +588,8 @@ var SelectOverlay = forwardRef6(function SelectOverlay2({
|
|
|
612
588
|
SelectOverlay.displayName = "XAUI.Select.Overlay";
|
|
613
589
|
|
|
614
590
|
// src/components/select/select-trigger.tsx
|
|
615
|
-
import { forwardRef as forwardRef7, useCallback as useCallback2, useEffect as useEffect4,
|
|
616
|
-
import { jsx as
|
|
591
|
+
import { forwardRef as forwardRef7, useCallback as useCallback2, useEffect as useEffect4, useRef } from "react";
|
|
592
|
+
import { jsx as jsx10 } from "react/jsx-runtime";
|
|
617
593
|
var SelectTrigger = forwardRef7(function SelectTrigger2({
|
|
618
594
|
children,
|
|
619
595
|
asChild = false,
|
|
@@ -642,7 +618,7 @@ var SelectTrigger = forwardRef7(function SelectTrigger2({
|
|
|
642
618
|
onPressOut
|
|
643
619
|
});
|
|
644
620
|
const node = useRef(null);
|
|
645
|
-
const refs =
|
|
621
|
+
const refs = useMergedRef(node, ref);
|
|
646
622
|
const measure = useCallback2(() => {
|
|
647
623
|
node.current?.measureInWindow((x, y, width, height) => {
|
|
648
624
|
setAnchor({
|
|
@@ -665,9 +641,9 @@ var SelectTrigger = forwardRef7(function SelectTrigger2({
|
|
|
665
641
|
measure();
|
|
666
642
|
toggle();
|
|
667
643
|
}, [measure, onPress, toggle]);
|
|
668
|
-
return /* @__PURE__ */
|
|
644
|
+
return /* @__PURE__ */jsx10(IconContext.Provider, {
|
|
669
645
|
value: glyph,
|
|
670
|
-
children: /* @__PURE__ */
|
|
646
|
+
children: /* @__PURE__ */jsx10(PressableFeedback, {
|
|
671
647
|
ref: refs,
|
|
672
648
|
isPressed,
|
|
673
649
|
isDisabled,
|
|
@@ -696,7 +672,7 @@ SelectTrigger.displayName = "XAUI.Select.Trigger";
|
|
|
696
672
|
// src/components/select/select-value.tsx
|
|
697
673
|
import { forwardRef as forwardRef8 } from "react";
|
|
698
674
|
import { Text as Text4 } from "react-native";
|
|
699
|
-
import { jsx as
|
|
675
|
+
import { jsx as jsx11 } from "react/jsx-runtime";
|
|
700
676
|
var SelectValue = forwardRef8(function SelectValue2({
|
|
701
677
|
placeholder,
|
|
702
678
|
children,
|
|
@@ -713,7 +689,7 @@ var SelectValue = forwardRef8(function SelectValue2({
|
|
|
713
689
|
const [styleProps, rest] = useStyleProps(props);
|
|
714
690
|
const label = children ?? (value !== void 0 ? labelFor(value) : void 0);
|
|
715
691
|
const isEmpty = label === void 0 || label === "";
|
|
716
|
-
return /* @__PURE__ */
|
|
692
|
+
return /* @__PURE__ */jsx11(Text4, {
|
|
717
693
|
ref,
|
|
718
694
|
numberOfLines,
|
|
719
695
|
...rest,
|
|
@@ -724,24 +700,11 @@ var SelectValue = forwardRef8(function SelectValue2({
|
|
|
724
700
|
SelectValue.displayName = "XAUI.Select.Value";
|
|
725
701
|
|
|
726
702
|
// src/components/select/select.tsx
|
|
727
|
-
import { useCallback as useCallback4, useMemo as
|
|
703
|
+
import { useCallback as useCallback4, useMemo as useMemo3, useState as useState3 } from "react";
|
|
728
704
|
import { StyleSheet } from "react-native";
|
|
729
705
|
|
|
730
706
|
// src/components/select/select.hook.ts
|
|
731
|
-
import { useCallback as useCallback3, useMemo as
|
|
732
|
-
function useControllableState({
|
|
733
|
-
value,
|
|
734
|
-
defaultValue,
|
|
735
|
-
onChange
|
|
736
|
-
}) {
|
|
737
|
-
const isControlled = useRef2(value !== void 0).current;
|
|
738
|
-
const [uncontrolled, setUncontrolled] = useState2(defaultValue);
|
|
739
|
-
const set = useCallback3(next => {
|
|
740
|
-
if (!isControlled) setUncontrolled(next);
|
|
741
|
-
onChange?.(next);
|
|
742
|
-
}, [isControlled, onChange]);
|
|
743
|
-
return [isControlled ? value : uncontrolled, set];
|
|
744
|
-
}
|
|
707
|
+
import { useCallback as useCallback3, useMemo as useMemo2, useRef as useRef2, useState as useState2 } from "react";
|
|
745
708
|
function useLabelRegistry() {
|
|
746
709
|
const labels = useRef2(/* @__PURE__ */new Map());
|
|
747
710
|
const [, force] = useState2(0);
|
|
@@ -751,7 +714,7 @@ function useLabelRegistry() {
|
|
|
751
714
|
force(n => n + 1);
|
|
752
715
|
}, []);
|
|
753
716
|
const labelFor = useCallback3(value => labels.current.get(value), []);
|
|
754
|
-
return
|
|
717
|
+
return useMemo2(() => ({
|
|
755
718
|
labelFor,
|
|
756
719
|
registerLabel
|
|
757
720
|
}), [labelFor, registerLabel]);
|
|
@@ -1011,7 +974,7 @@ var selectRecipe = createRecipe({
|
|
|
1011
974
|
});
|
|
1012
975
|
|
|
1013
976
|
// src/components/select/select.tsx
|
|
1014
|
-
import { jsx as
|
|
977
|
+
import { jsx as jsx12 } from "react/jsx-runtime";
|
|
1015
978
|
function Select({
|
|
1016
979
|
children,
|
|
1017
980
|
variant,
|
|
@@ -1038,7 +1001,7 @@ function Select({
|
|
|
1038
1001
|
defaultValue,
|
|
1039
1002
|
onChange: onValueChange
|
|
1040
1003
|
});
|
|
1041
|
-
const [isOpen
|
|
1004
|
+
const [isOpen, setOpen] = useControllableState({
|
|
1042
1005
|
value: controlledOpen,
|
|
1043
1006
|
defaultValue: defaultOpen,
|
|
1044
1007
|
onChange: onOpenChange
|
|
@@ -1077,7 +1040,7 @@ function Select({
|
|
|
1077
1040
|
setValue(next);
|
|
1078
1041
|
setOpen(false);
|
|
1079
1042
|
}, [registerLabel, setValue, setOpen]);
|
|
1080
|
-
const context =
|
|
1043
|
+
const context = useMemo3(() => {
|
|
1081
1044
|
const indicator = StyleSheet.flatten([styles.indicator, tint?.indicator]);
|
|
1082
1045
|
const itemLabel = StyleSheet.flatten([styles.itemLabel]);
|
|
1083
1046
|
const tintedPlaceholder = tint ? StyleSheet.flatten([tint.value]).color : void 0;
|
|
@@ -1120,7 +1083,7 @@ function Select({
|
|
|
1120
1083
|
registerLabel
|
|
1121
1084
|
};
|
|
1122
1085
|
}, [styles, pressed, tint, value, isOpen, isDisabled, isInvalid, open, close, toggle, select, anchor, labelFor, registerLabel]);
|
|
1123
|
-
return /* @__PURE__ */
|
|
1086
|
+
return /* @__PURE__ */jsx12(SelectProvider, {
|
|
1124
1087
|
value: context,
|
|
1125
1088
|
children
|
|
1126
1089
|
});
|
|
@@ -1140,4 +1103,4 @@ var Select2 = Object.assign(Select, {
|
|
|
1140
1103
|
ItemDescription: SelectItemDescription,
|
|
1141
1104
|
ItemIndicator: SelectItemIndicator
|
|
1142
1105
|
});
|
|
1143
|
-
export { useSelect, useSelectItem, SelectItemLabel, SelectItem, SelectContent,
|
|
1106
|
+
export { useSelect, useSelectItem, SelectItemLabel, SelectItem, SelectContent, SelectIndicator, SelectItemDescription, CheckIcon, SelectItemIndicator, SelectLabel, SelectOverlay, SelectTrigger, SelectValue, selectRecipe, Select, Select2 };
|
|
@@ -0,0 +1,34 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
var _chunkQ3MQ7S2Dcjs = require('../../chunk-Q3MQ7S2D.cjs');
|
|
13
|
+
require('../../chunk-4KFKWBN5.cjs');
|
|
14
|
+
require('../../chunk-7EIHHOHP.cjs');
|
|
15
|
+
require('../../chunk-TGMVEHV7.cjs');
|
|
16
|
+
require('../../chunk-7DPL3ZDS.cjs');
|
|
17
|
+
require('../../chunk-EJQCQPET.cjs');
|
|
18
|
+
require('../../chunk-7GHM4GKL.cjs');
|
|
19
|
+
require('../../chunk-H4E4HDEP.cjs');
|
|
20
|
+
require('../../chunk-FNEUOBCV.cjs');
|
|
21
|
+
require('../../chunk-57SJ4LJF.cjs');
|
|
22
|
+
require('../../chunk-TK44VBIE.cjs');
|
|
23
|
+
|
|
24
|
+
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
|
|
33
|
+
|
|
34
|
+
exports.Accordion = _chunkQ3MQ7S2Dcjs.Accordion; exports.AccordionContent = _chunkQ3MQ7S2Dcjs.AccordionContent; exports.AccordionIndicator = _chunkQ3MQ7S2Dcjs.AccordionIndicator; exports.AccordionItem = _chunkQ3MQ7S2Dcjs.AccordionItem; exports.AccordionRoot = _chunkQ3MQ7S2Dcjs.AccordionRoot; exports.AccordionTrigger = _chunkQ3MQ7S2Dcjs.AccordionTrigger; exports.accordionLayoutTransition = _chunkQ3MQ7S2Dcjs.LAYOUT; exports.accordionRecipe = _chunkQ3MQ7S2Dcjs.accordionRecipe; exports.useAccordion = _chunkQ3MQ7S2Dcjs.useAccordion; exports.useAccordionItem = _chunkQ3MQ7S2Dcjs.useAccordionItem;
|