@xaui/native 0.9.1-alpha.36 → 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-B6OKVLC7.js → chunk-26OGEFQI.js} +4 -4
- package/dist/{chunk-V5IVMZQJ.js → chunk-2PMXMKS5.js} +13 -8
- package/dist/{chunk-QZO57TPX.js → chunk-346QBNUD.js} +4 -4
- package/dist/{chunk-PPWXLZGL.js → chunk-3GFRSZYR.js} +15 -23
- package/dist/{chunk-GPZSTEEI.cjs → chunk-3JXI2IHV.cjs} +17 -17
- package/dist/{chunk-ISPOIMGX.cjs → chunk-4KFKWBN5.cjs} +26 -5
- package/dist/{chunk-N2U63JUX.cjs → chunk-4KSKQD37.cjs} +10 -10
- package/dist/{chunk-ZU3XQZ63.cjs → chunk-54CWXA34.cjs} +66 -66
- package/dist/{chunk-EFPWXJAJ.cjs → chunk-66FOASTP.cjs} +16 -16
- package/dist/{chunk-E5ZW7MBW.js → chunk-6CO6FM67.js} +17 -17
- package/dist/{chunk-54FJOKAN.cjs → chunk-7GHM4GKL.cjs} +25 -25
- package/dist/{chunk-2L7FOIWY.cjs → chunk-7TOG4TVU.cjs} +26 -26
- package/dist/{chunk-6N5ZCEAB.cjs → chunk-A7YB7YWX.cjs} +10 -10
- package/dist/{chunk-FVKIQBHS.cjs → chunk-AAVCMCJ3.cjs} +4 -4
- package/dist/{chunk-HQVVQGYV.cjs → chunk-ACAPTWE3.cjs} +16 -12
- package/dist/{chunk-LCDHTLSG.cjs → chunk-BNFIFRQA.cjs} +7 -7
- package/dist/{chunk-6U5IUUAR.js → chunk-DY3SUG5P.js} +5 -5
- package/dist/{chunk-RSGIJ6RI.js → chunk-EYD4H4X6.js} +2 -2
- package/dist/{chunk-DL2PGB5G.js → chunk-FBCWNXZC.js} +59 -59
- package/dist/{chunk-OWE5IID7.js → chunk-FHUYHV6J.js} +28 -7
- package/dist/{chunk-K7GAHNMJ.js → chunk-HA6BFY3A.js} +6 -6
- package/dist/{chunk-MFXZHLOU.cjs → chunk-HOI5425P.cjs} +16 -16
- package/dist/{chunk-VWATEE5O.js → chunk-IKJVLJKT.js} +15 -15
- package/dist/{chunk-YXPYOOHU.js → chunk-K72UDPVN.js} +27 -27
- package/dist/{chunk-2LNE4PWB.cjs → chunk-KSUV74BE.cjs} +5 -5
- package/dist/{chunk-UCW25LL6.js → chunk-LIUO6D3D.js} +76 -76
- package/dist/{chunk-U3HFQHGZ.js → chunk-LTX6TB5I.js} +4 -4
- package/dist/{chunk-OSCW7I4H.js → chunk-M63GFNKV.js} +19 -4
- package/dist/chunk-MESKS6AI.js +0 -0
- package/dist/{chunk-SAGMDVFU.js → chunk-MXGER5PI.js} +5 -5
- package/dist/{chunk-GHKJ6MUH.cjs → chunk-NCCRQK3P.cjs} +14 -14
- package/dist/chunk-NCTOTTVW.js +13 -0
- package/dist/chunk-OJCCV65P.cjs +1 -0
- package/dist/chunk-Q3MQ7S2D.cjs +476 -0
- package/dist/{chunk-CVCE7TW5.js → chunk-QZ24MZRX.js} +4 -4
- package/dist/{chunk-5GMU7ESV.js → chunk-R7BU4CPS.js} +3 -3
- package/dist/chunk-RAWGK2XK.cjs +971 -0
- package/dist/{chunk-PGQWUASE.cjs → chunk-RKCWYUGA.cjs} +6 -6
- package/dist/{chunk-3YZSUDZ2.js → chunk-S2WNWMNT.js} +4 -4
- package/dist/{chunk-XARBUUIE.cjs → chunk-S4QUM4EE.cjs} +12 -12
- package/dist/{chunk-OMV5MUTM.js → chunk-SACDOFGF.js} +16 -16
- package/dist/{chunk-FYCDRRJ2.cjs → chunk-SIP5J7HU.cjs} +25 -25
- package/dist/{chunk-AQXNEV6J.cjs → chunk-SNIHUKDA.cjs} +16 -16
- package/dist/{chunk-2OZPOWFB.js → chunk-SZLXPF3G.js} +4 -4
- package/dist/{chunk-RPOKLFRB.cjs → chunk-TDTUAIFF.cjs} +12 -12
- package/dist/{chunk-2SCE7TFZ.cjs → chunk-TGMVEHV7.cjs} +68 -68
- package/dist/{chunk-K3AVOT6L.cjs → chunk-TK44VBIE.cjs} +22 -7
- package/dist/{chunk-KZVHC4FL.js → chunk-TRETQZEW.js} +7 -7
- package/dist/{chunk-AZRMOWRG.cjs → chunk-URA25DU4.cjs} +10 -10
- package/dist/{chunk-BAPXLO5N.js → chunk-USF6EWYR.js} +7 -7
- package/dist/{chunk-TE7KVFE4.cjs → chunk-VZK3NLBH.cjs} +11 -11
- package/dist/{chunk-5BNIIDQD.cjs → chunk-WDDXU3OH.cjs} +14 -9
- package/dist/chunk-WFEMJCXO.cjs +13 -0
- package/dist/{chunk-JB5XANQY.js → chunk-WKCQ6VGW.js} +15 -11
- package/dist/{chunk-DOLWSO7A.js → chunk-XNMZQSY5.js} +5 -5
- package/dist/{chunk-K4TWKF5U.cjs → chunk-XSQPVDFH.cjs} +15 -25
- package/dist/{chunk-4XFEEBPU.js → chunk-XTC2SLFT.js} +2 -2
- package/dist/{chunk-ADQVA2FQ.cjs → chunk-XWNG2U4K.cjs} +5 -5
- package/dist/chunk-ZF6KIHXH.js +591 -0
- package/dist/chunk-ZNZ7HVRW.js +1106 -0
- 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 -8
- 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 -7
- package/dist/components/avatar/index.cjs +5 -6
- package/dist/components/avatar/index.d.cts +2 -2
- package/dist/components/avatar/index.d.ts +2 -2
- package/dist/components/avatar/index.js +4 -5
- package/dist/components/badge/index.cjs +4 -5
- package/dist/components/badge/index.d.cts +1 -1
- package/dist/components/badge/index.d.ts +1 -1
- package/dist/components/badge/index.js +3 -4
- package/dist/components/button/index.cjs +8 -8
- package/dist/components/button/index.d.cts +41 -41
- package/dist/components/button/index.d.ts +41 -41
- package/dist/components/button/index.js +7 -7
- package/dist/components/card/index.cjs +5 -6
- package/dist/components/card/index.d.cts +43 -43
- package/dist/components/card/index.d.ts +43 -43
- package/dist/components/card/index.js +4 -5
- package/dist/components/checkbox/index.cjs +5 -6
- package/dist/components/checkbox/index.d.cts +82 -82
- package/dist/components/checkbox/index.d.ts +82 -82
- package/dist/components/checkbox/index.js +4 -5
- package/dist/components/chip/index.cjs +7 -8
- package/dist/components/chip/index.d.cts +42 -42
- package/dist/components/chip/index.d.ts +42 -42
- package/dist/components/chip/index.js +6 -7
- package/dist/components/divider/index.cjs +4 -5
- package/dist/components/divider/index.d.cts +3 -3
- package/dist/components/divider/index.d.ts +3 -3
- package/dist/components/divider/index.js +3 -4
- package/dist/components/field-group/index.cjs +6 -7
- package/dist/components/field-group/index.d.cts +2 -2
- package/dist/components/field-group/index.d.ts +2 -2
- package/dist/components/field-group/index.js +5 -6
- package/dist/components/input-otp/index.cjs +4 -5
- 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 +3 -4
- package/dist/components/radio/index.cjs +5 -6
- package/dist/components/radio/index.d.cts +82 -82
- package/dist/components/radio/index.d.ts +82 -82
- package/dist/components/radio/index.js +4 -5
- package/dist/components/select/index.cjs +48 -0
- package/dist/components/select/index.d.cts +509 -0
- package/dist/components/select/index.d.ts +509 -0
- package/dist/components/select/index.js +48 -0
- package/dist/components/skeleton/index.cjs +3 -4
- package/dist/components/skeleton/index.d.cts +1 -1
- package/dist/components/skeleton/index.d.ts +1 -1
- package/dist/components/skeleton/index.js +2 -3
- package/dist/components/spinner/index.cjs +5 -5
- 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 -4
- package/dist/components/switch/index.cjs +5 -6
- package/dist/components/switch/index.d.cts +81 -81
- package/dist/components/switch/index.d.ts +81 -81
- package/dist/components/switch/index.js +4 -5
- package/dist/components/text-area/index.cjs +5 -6
- package/dist/components/text-area/index.js +4 -5
- package/dist/components/text-field/index.cjs +4 -5
- 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 +3 -4
- package/dist/components/typography/index.cjs +4 -5
- package/dist/components/typography/index.d.cts +5 -5
- package/dist/components/typography/index.d.ts +5 -5
- package/dist/components/typography/index.js +3 -4
- package/dist/components/view/index.cjs +4 -5
- package/dist/components/view/index.d.cts +3 -3
- package/dist/components/view/index.d.ts +3 -3
- package/dist/components/view/index.js +3 -4
- package/dist/index.cjs +91 -31
- package/dist/index.d.cts +3 -1
- package/dist/index.d.ts +3 -1
- package/dist/index.js +125 -65
- package/dist/system/index.cjs +13 -11
- package/dist/system/index.d.cts +61 -35
- package/dist/system/index.d.ts +61 -35
- package/dist/system/index.js +13 -11
- package/dist/theme/index.cjs +4 -3
- package/dist/theme/index.d.cts +21 -1
- package/dist/theme/index.d.ts +21 -1
- package/dist/theme/index.js +3 -2
- package/package.json +21 -1
- package/dist/chunk-FJ5TLRT3.js +0 -21
- package/dist/chunk-HT7H35GU.cjs +0 -21
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import {
|
|
2
2
|
Slot
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-K72UDPVN.js";
|
|
4
4
|
import {
|
|
5
5
|
createRecipe
|
|
6
6
|
} from "./chunk-4GTAZM2C.js";
|
|
7
|
-
import {
|
|
8
|
-
useStyleProps
|
|
9
|
-
} from "./chunk-OSCW7I4H.js";
|
|
10
7
|
import {
|
|
11
8
|
useXAUITheme
|
|
12
9
|
} from "./chunk-A3EGFI6T.js";
|
|
10
|
+
import {
|
|
11
|
+
useStyleProps
|
|
12
|
+
} from "./chunk-M63GFNKV.js";
|
|
13
13
|
|
|
14
14
|
// src/components/divider/divider.tsx
|
|
15
15
|
import { forwardRef } from "react";
|
|
@@ -1,15 +1,13 @@
|
|
|
1
1
|
import {
|
|
2
2
|
useStyleProps
|
|
3
|
-
} from "./chunk-
|
|
4
|
-
|
|
5
|
-
// src/system/portal/portal.tsx
|
|
6
|
-
import { useContext, useId, useLayoutEffect } from "react";
|
|
3
|
+
} from "./chunk-M63GFNKV.js";
|
|
7
4
|
|
|
8
5
|
// src/system/portal/portal-context.ts
|
|
9
6
|
import { createContext } from "react";
|
|
10
7
|
var PortalContext = createContext(null);
|
|
11
8
|
|
|
12
9
|
// src/system/portal/portal.tsx
|
|
10
|
+
import { useContext, useId, useLayoutEffect } from "react";
|
|
13
11
|
function Portal({ children }) {
|
|
14
12
|
const context = useContext(PortalContext);
|
|
15
13
|
const key = useId();
|
|
@@ -24,7 +22,7 @@ function Portal({ children }) {
|
|
|
24
22
|
Portal.displayName = "XAUI.Portal";
|
|
25
23
|
|
|
26
24
|
// src/system/portal/portal-host.tsx
|
|
27
|
-
import { Fragment, useCallback, useMemo, useState } from "react";
|
|
25
|
+
import { Fragment, useCallback, useMemo, useRef, useState } from "react";
|
|
28
26
|
import { StyleSheet, View } from "react-native";
|
|
29
27
|
import { jsx, jsxs } from "react/jsx-runtime";
|
|
30
28
|
var styles = StyleSheet.create({
|
|
@@ -33,6 +31,13 @@ var styles = StyleSheet.create({
|
|
|
33
31
|
function PortalHost({ children, ...props }) {
|
|
34
32
|
const [styleProps] = useStyleProps(props);
|
|
35
33
|
const [portals, setPortals] = useState(/* @__PURE__ */ new Map());
|
|
34
|
+
const [origin, setOrigin] = useState({ x: 0, y: 0 });
|
|
35
|
+
const node = useRef(null);
|
|
36
|
+
const measure = useCallback((_event) => {
|
|
37
|
+
node.current?.measureInWindow((x, y) => {
|
|
38
|
+
setOrigin((current) => current.x === x && current.y === y ? current : { x, y });
|
|
39
|
+
});
|
|
40
|
+
}, []);
|
|
36
41
|
const addPortal = useCallback((key, element) => {
|
|
37
42
|
setPortals((current) => new Map(current).set(key, element));
|
|
38
43
|
}, []);
|
|
@@ -45,10 +50,10 @@ function PortalHost({ children, ...props }) {
|
|
|
45
50
|
});
|
|
46
51
|
}, []);
|
|
47
52
|
const methods = useMemo(
|
|
48
|
-
() => ({ addPortal, removePortal }),
|
|
49
|
-
[addPortal, removePortal]
|
|
53
|
+
() => ({ addPortal, removePortal, origin }),
|
|
54
|
+
[addPortal, removePortal, origin]
|
|
50
55
|
);
|
|
51
|
-
return /* @__PURE__ */ jsx(PortalContext.Provider, { value: methods, children: /* @__PURE__ */ jsxs(View, { style: [styles.container, styleProps], children: [
|
|
56
|
+
return /* @__PURE__ */ jsx(PortalContext.Provider, { value: methods, children: /* @__PURE__ */ jsxs(View, { ref: node, onLayout: measure, style: [styles.container, styleProps], children: [
|
|
52
57
|
children,
|
|
53
58
|
Array.from(portals, ([key, element]) => /* @__PURE__ */ jsx(Fragment, { children: element }, key))
|
|
54
59
|
] }) });
|
|
@@ -1,17 +1,17 @@
|
|
|
1
1
|
import {
|
|
2
2
|
Slot,
|
|
3
3
|
childrenToString
|
|
4
|
-
} from "./chunk-
|
|
4
|
+
} from "./chunk-K72UDPVN.js";
|
|
5
5
|
import {
|
|
6
6
|
createRecipe,
|
|
7
7
|
radiusAxis
|
|
8
8
|
} from "./chunk-4GTAZM2C.js";
|
|
9
|
-
import {
|
|
10
|
-
useStyleProps
|
|
11
|
-
} from "./chunk-OSCW7I4H.js";
|
|
12
9
|
import {
|
|
13
10
|
useXAUITheme
|
|
14
11
|
} from "./chunk-A3EGFI6T.js";
|
|
12
|
+
import {
|
|
13
|
+
useStyleProps
|
|
14
|
+
} from "./chunk-M63GFNKV.js";
|
|
15
15
|
|
|
16
16
|
// src/components/badge/badge.tsx
|
|
17
17
|
import { forwardRef, useMemo } from "react";
|
|
@@ -1,11 +1,3 @@
|
|
|
1
|
-
import { mergeRefs } from "./chunk-36PRYGAM.js";
|
|
2
|
-
|
|
3
|
-
// src/hooks/use-merged-ref.ts
|
|
4
|
-
import { useMemo } from "react";
|
|
5
|
-
function useMergedRef(...refs) {
|
|
6
|
-
return useMemo(() => mergeRefs(...refs), refs);
|
|
7
|
-
}
|
|
8
|
-
|
|
9
1
|
// src/hooks/use-previous.ts
|
|
10
2
|
import { useEffect, useRef } from "react";
|
|
11
3
|
function usePrevious(value) {
|
|
@@ -20,10 +12,10 @@ function usePrevious(value) {
|
|
|
20
12
|
import { useEffect as useEffect2 } from "react";
|
|
21
13
|
import { Easing, cancelAnimation, useAnimatedStyle, useSharedValue, withRepeat, withTiming } from "react-native-reanimated";
|
|
22
14
|
var ROTATION_DURATION = 900;
|
|
23
|
-
const
|
|
24
|
-
code: "function
|
|
25
|
-
location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-
|
|
26
|
-
sourceMap: "{\"version\":3,\"names\":[\"
|
|
15
|
+
const _worklet_6356758416325_init_data = {
|
|
16
|
+
code: "function chunk3GFRSZYRJs1(){const{angle}=this.__closure;return{transform:[{rotate:angle.value+\"deg\"}]};}",
|
|
17
|
+
location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-3GFRSZYR.js",
|
|
18
|
+
sourceMap: "{\"version\":3,\"names\":[\"chunk3GFRSZYRJs1\",\"angle\",\"__closure\",\"transform\",\"rotate\",\"value\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-3GFRSZYR.js\"],\"mappings\":\"AA+B0B,SAAAA,gBAAMA,CAAA,QAAAC,KAAA,OAAAC,SAAA,CAE5B,MAAO,CAAEC,SAAS,CAAE,CAAC,CAAEC,MAAM,CAAKH,KAAK,CAACI,KAAK,MAAM,CAAC,CAAE,CAAC,CACzD\",\"ignoreList\":[]}"
|
|
27
19
|
};
|
|
28
20
|
function useRotation() {
|
|
29
21
|
const angle = useSharedValue(0);
|
|
@@ -34,29 +26,29 @@ function useRotation() {
|
|
|
34
26
|
}), -1, false);
|
|
35
27
|
return () => cancelAnimation(angle);
|
|
36
28
|
}, [angle]);
|
|
37
|
-
return useAnimatedStyle(function
|
|
38
|
-
|
|
29
|
+
return useAnimatedStyle(function chunk3GFRSZYRJs1Factory({
|
|
30
|
+
_worklet_6356758416325_init_data,
|
|
39
31
|
angle
|
|
40
32
|
}) {
|
|
41
33
|
const _e = [new global.Error(), -2, -27];
|
|
42
|
-
const
|
|
34
|
+
const chunk3GFRSZYRJs1 = function () {
|
|
43
35
|
return {
|
|
44
36
|
transform: [{
|
|
45
37
|
rotate: `${angle.value}deg`
|
|
46
38
|
}]
|
|
47
39
|
};
|
|
48
40
|
};
|
|
49
|
-
|
|
41
|
+
chunk3GFRSZYRJs1.__closure = {
|
|
50
42
|
angle
|
|
51
43
|
};
|
|
52
|
-
|
|
53
|
-
|
|
54
|
-
|
|
55
|
-
|
|
56
|
-
return
|
|
44
|
+
chunk3GFRSZYRJs1.__workletHash = 6356758416325;
|
|
45
|
+
chunk3GFRSZYRJs1.__pluginVersion = "0.7.4";
|
|
46
|
+
chunk3GFRSZYRJs1.__initData = _worklet_6356758416325_init_data;
|
|
47
|
+
chunk3GFRSZYRJs1.__stackDetails = _e;
|
|
48
|
+
return chunk3GFRSZYRJs1;
|
|
57
49
|
}({
|
|
58
|
-
|
|
50
|
+
_worklet_6356758416325_init_data,
|
|
59
51
|
angle
|
|
60
52
|
}), [angle]);
|
|
61
53
|
}
|
|
62
|
-
export {
|
|
54
|
+
export { usePrevious, ROTATION_DURATION, useRotation };
|
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
|
|
2
2
|
|
|
3
3
|
|
|
4
|
-
var
|
|
4
|
+
var _chunkAAVCMCJ3cjs = require('./chunk-AAVCMCJ3.cjs');
|
|
5
5
|
|
|
6
6
|
|
|
7
|
-
var
|
|
7
|
+
var _chunk4KFKWBN5cjs = require('./chunk-4KFKWBN5.cjs');
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _chunkTGMVEHV7cjs = require('./chunk-TGMVEHV7.cjs');
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
var _chunk7DPL3ZDScjs = require('./chunk-7DPL3ZDS.cjs');
|
|
@@ -18,24 +18,24 @@ var _chunkEJQCQPETcjs = require('./chunk-EJQCQPET.cjs');
|
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
|
|
21
|
-
var
|
|
21
|
+
var _chunk7GHM4GKLcjs = require('./chunk-7GHM4GKL.cjs');
|
|
22
22
|
|
|
23
23
|
|
|
24
24
|
|
|
25
25
|
var _chunkFNEUOBCVcjs = require('./chunk-FNEUOBCV.cjs');
|
|
26
26
|
|
|
27
27
|
|
|
28
|
-
var
|
|
28
|
+
var _chunk57SJ4LJFcjs = require('./chunk-57SJ4LJF.cjs');
|
|
29
29
|
|
|
30
30
|
|
|
31
|
-
var
|
|
31
|
+
var _chunkTK44VBIEcjs = require('./chunk-TK44VBIE.cjs');
|
|
32
32
|
|
|
33
33
|
// src/components/chip/chip-avatar.tsx
|
|
34
34
|
var _react = require('react');
|
|
35
35
|
var _reactnative = require('react-native');
|
|
36
36
|
|
|
37
37
|
// src/components/chip/chip.context.ts
|
|
38
|
-
var [ChipProvider, useChip] =
|
|
38
|
+
var [ChipProvider, useChip] = _chunk7GHM4GKLcjs.createSlotContext.call(void 0, "Chip");
|
|
39
39
|
|
|
40
40
|
// src/components/chip/chip.style.ts
|
|
41
41
|
|
|
@@ -47,7 +47,7 @@ var chipSheet = _reactnative.StyleSheet.create({
|
|
|
47
47
|
var _jsxruntime = require('react/jsx-runtime');
|
|
48
48
|
var ChipAvatar = _react.forwardRef.call(void 0, function ChipAvatar2({ children, source, style, ...props }, ref) {
|
|
49
49
|
const { avatarStyle } = useChip();
|
|
50
|
-
const [styleProps, rest] =
|
|
50
|
+
const [styleProps, rest] = _chunkTK44VBIEcjs.useStyleProps.call(void 0, props);
|
|
51
51
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reactnative.View, { ref, style: [avatarStyle, styleProps, style], ...rest, children: source ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reactnative.Image, { source, style: chipSheet.avatarImage }) : children });
|
|
52
52
|
});
|
|
53
53
|
ChipAvatar.displayName = "XAUI.Chip.Avatar";
|
|
@@ -58,7 +58,7 @@ ChipAvatar.displayName = "XAUI.Chip.Avatar";
|
|
|
58
58
|
var ChipClose = _react.forwardRef.call(void 0, function ChipClose2({ isDisabled, ...props }, ref) {
|
|
59
59
|
const { closeStyle, closeGlyphStyle, isDisabled: isChipDisabled } = useChip();
|
|
60
60
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
61
|
-
|
|
61
|
+
_chunkAAVCMCJ3cjs.CloseButton,
|
|
62
62
|
{
|
|
63
63
|
ref,
|
|
64
64
|
name: "Chip.Close",
|
|
@@ -77,7 +77,7 @@ ChipClose.displayName = "XAUI.Chip.Close";
|
|
|
77
77
|
|
|
78
78
|
var ChipDot = _react.forwardRef.call(void 0, function ChipDot2({ style, ...props }, ref) {
|
|
79
79
|
const { dotStyle } = useChip();
|
|
80
|
-
const [styleProps, rest] =
|
|
80
|
+
const [styleProps, rest] = _chunkTK44VBIEcjs.useStyleProps.call(void 0, props);
|
|
81
81
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reactnative.View, { ref, style: [dotStyle, styleProps, style], ...rest });
|
|
82
82
|
});
|
|
83
83
|
ChipDot.displayName = "XAUI.Chip.Dot";
|
|
@@ -86,7 +86,7 @@ ChipDot.displayName = "XAUI.Chip.Dot";
|
|
|
86
86
|
|
|
87
87
|
function ChipIcon({ size, color, ...rest }) {
|
|
88
88
|
const { icon } = useChip();
|
|
89
|
-
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
89
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunk4KFKWBN5cjs.Icon, { size: _nullishCoalesce(size, () => ( icon.size)), color: _nullishCoalesce(color, () => ( icon.color)), ...rest });
|
|
90
90
|
}
|
|
91
91
|
ChipIcon.displayName = "XAUI.Chip.Icon";
|
|
92
92
|
|
|
@@ -96,7 +96,7 @@ ChipIcon.displayName = "XAUI.Chip.Icon";
|
|
|
96
96
|
|
|
97
97
|
var ChipLabel = _react.forwardRef.call(void 0, function ChipLabel2({ children, style, numberOfLines = 1, ...props }, ref) {
|
|
98
98
|
const { labelStyle } = useChip();
|
|
99
|
-
const [styleProps, rest] =
|
|
99
|
+
const [styleProps, rest] = _chunkTK44VBIEcjs.useStyleProps.call(void 0, props);
|
|
100
100
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
101
101
|
_reactnative.Text,
|
|
102
102
|
{
|
|
@@ -242,7 +242,7 @@ var chipRecipe = _chunkFNEUOBCVcjs.createRecipe.call(void 0, {
|
|
|
242
242
|
// The cross's own geometry — thickness and centring — belongs to the shared
|
|
243
243
|
// `CloseButton`; what stays below is the box and bar size this component's scale sets.
|
|
244
244
|
base: (theme) => ({
|
|
245
|
-
...
|
|
245
|
+
..._chunkAAVCMCJ3cjs.closeButtonBase.call(void 0, theme),
|
|
246
246
|
root: {
|
|
247
247
|
// A chip hugs its content where a `Button` fills its column. The difference is what
|
|
248
248
|
// the two are: a button is a control the layout sizes, a chip is a token *about*
|
|
@@ -334,7 +334,7 @@ var ChipRoot = _react.forwardRef.call(void 0, function Chip({
|
|
|
334
334
|
...props
|
|
335
335
|
}, ref) {
|
|
336
336
|
const theme = _chunk57SJ4LJFcjs.useXAUITheme.call(void 0, );
|
|
337
|
-
const [styleProps, rest] =
|
|
337
|
+
const [styleProps, rest] = _chunkTK44VBIEcjs.useStyleProps.call(void 0, props);
|
|
338
338
|
const [isPressed, press] = _chunk7DPL3ZDScjs.usePressState.call(void 0, { onPressIn, onPressOut });
|
|
339
339
|
const selection = { variant, size, radius };
|
|
340
340
|
const states = { pressed: isPressed, disabled: isDisabled };
|
|
@@ -363,7 +363,7 @@ var ChipRoot = _react.forwardRef.call(void 0, function Chip({
|
|
|
363
363
|
styleProps,
|
|
364
364
|
typeof style === "function" ? style({ pressed: isPressed }) : style
|
|
365
365
|
];
|
|
366
|
-
const text =
|
|
366
|
+
const text = _chunk7GHM4GKLcjs.childrenToString.call(void 0, children);
|
|
367
367
|
const content = text !== null ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0, ChipLabel, { children: text }) : children;
|
|
368
368
|
if (!isPressable && !asChild && (onPressIn || onPressOut || rest.onPress || rest.onLongPress)) {
|
|
369
369
|
_chunkEJQCQPETcjs.warnDev.call(void 0,
|
|
@@ -371,7 +371,7 @@ var ChipRoot = _react.forwardRef.call(void 0, function Chip({
|
|
|
371
371
|
);
|
|
372
372
|
}
|
|
373
373
|
const surface = isPressable ? /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
374
|
-
|
|
374
|
+
_chunkTGMVEHV7cjs.PressableFeedback,
|
|
375
375
|
{
|
|
376
376
|
ref,
|
|
377
377
|
isPressed,
|
|
@@ -390,7 +390,7 @@ var ChipRoot = _react.forwardRef.call(void 0, function Chip({
|
|
|
390
390
|
// R12 — the caller's element is the chip, so it takes the children it was written
|
|
391
391
|
// with and the auto-wrap does not apply.
|
|
392
392
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
393
|
-
|
|
393
|
+
_chunk7GHM4GKLcjs.Slot,
|
|
394
394
|
{
|
|
395
395
|
ref,
|
|
396
396
|
accessibilityRole,
|
|
@@ -1,9 +1,29 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
|
|
2
2
|
|
|
3
|
-
var
|
|
3
|
+
var _chunk57SJ4LJFcjs = require('./chunk-57SJ4LJF.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkTK44VBIEcjs = require('./chunk-TK44VBIE.cjs');
|
|
7
|
+
|
|
8
|
+
// src/system/icon/chevron-down-icon.tsx
|
|
9
|
+
var _reactnativesvg = require('react-native-svg');
|
|
10
|
+
var _jsxruntime = require('react/jsx-runtime');
|
|
11
|
+
function ChevronDownIcon({
|
|
12
|
+
size = 20,
|
|
13
|
+
color = "currentColor"
|
|
14
|
+
}) {
|
|
15
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reactnativesvg.Svg, { width: size, height: size, viewBox: "0 0 24 24", fill: "none", children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
16
|
+
_reactnativesvg.Path,
|
|
17
|
+
{
|
|
18
|
+
d: "m6 9 6 6 6-6",
|
|
19
|
+
stroke: color,
|
|
20
|
+
strokeWidth: 2,
|
|
21
|
+
strokeLinecap: "round",
|
|
22
|
+
strokeLinejoin: "round"
|
|
23
|
+
}
|
|
24
|
+
) });
|
|
25
|
+
}
|
|
26
|
+
ChevronDownIcon.displayName = "XAUI.ChevronDownIcon";
|
|
7
27
|
|
|
8
28
|
// src/system/icon/icon-context.ts
|
|
9
29
|
var _react = require('react');
|
|
@@ -16,7 +36,7 @@ function useIconContext() {
|
|
|
16
36
|
// src/system/icon/icon.tsx
|
|
17
37
|
|
|
18
38
|
var _reactnative = require('react-native');
|
|
19
|
-
|
|
39
|
+
|
|
20
40
|
function Icon(props) {
|
|
21
41
|
const inherited = useIconContext();
|
|
22
42
|
const theme = _chunk57SJ4LJFcjs.useXAUITheme.call(void 0, );
|
|
@@ -47,7 +67,7 @@ function IconImage({
|
|
|
47
67
|
color: _color,
|
|
48
68
|
...props
|
|
49
69
|
}) {
|
|
50
|
-
const [styleProps] =
|
|
70
|
+
const [styleProps] = _chunkTK44VBIEcjs.useStyleProps.call(void 0, props);
|
|
51
71
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
52
72
|
_reactnative.Image,
|
|
53
73
|
{
|
|
@@ -65,4 +85,5 @@ function IconImage({
|
|
|
65
85
|
|
|
66
86
|
|
|
67
87
|
|
|
68
|
-
|
|
88
|
+
|
|
89
|
+
exports.ChevronDownIcon = ChevronDownIcon; exports.IconContext = IconContext; exports.useIconContext = useIconContext; exports.Icon = Icon;
|
|
@@ -6,38 +6,38 @@ var _chunkF6CQ6CBIcjs = require('./chunk-F6CQ6CBI.cjs');
|
|
|
6
6
|
var _chunk7EIHHOHPcjs = require('./chunk-7EIHHOHP.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
var
|
|
9
|
+
var _chunkTGMVEHV7cjs = require('./chunk-TGMVEHV7.cjs');
|
|
10
10
|
|
|
11
11
|
|
|
12
12
|
var _chunk7DPL3ZDScjs = require('./chunk-7DPL3ZDS.cjs');
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _chunk7GHM4GKLcjs = require('./chunk-7GHM4GKL.cjs');
|
|
17
17
|
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
var _chunkFNEUOBCVcjs = require('./chunk-FNEUOBCV.cjs');
|
|
21
21
|
|
|
22
22
|
|
|
23
|
-
var
|
|
23
|
+
var _chunk57SJ4LJFcjs = require('./chunk-57SJ4LJF.cjs');
|
|
24
24
|
|
|
25
25
|
|
|
26
|
-
var
|
|
26
|
+
var _chunkTK44VBIEcjs = require('./chunk-TK44VBIE.cjs');
|
|
27
27
|
|
|
28
28
|
// src/components/radio/radio-indicator.tsx
|
|
29
29
|
var _react = require('react');
|
|
30
30
|
var _reactnative = require('react-native');
|
|
31
31
|
|
|
32
32
|
// src/components/radio/radio.context.ts
|
|
33
|
-
var [RadioProvider, useRadio] =
|
|
33
|
+
var [RadioProvider, useRadio] = _chunk7GHM4GKLcjs.createSlotContext.call(void 0, "Radio");
|
|
34
34
|
|
|
35
35
|
// src/components/radio/radio-indicator.tsx
|
|
36
36
|
var _jsxruntime = require('react/jsx-runtime');
|
|
37
37
|
var RadioIndicator = _react.forwardRef.call(void 0,
|
|
38
38
|
function RadioIndicator2({ children, animation = true, style, ...props }, ref) {
|
|
39
39
|
const { indicatorStyle, fillStyle, isSelected } = useRadio();
|
|
40
|
-
const [styleProps, rest] =
|
|
40
|
+
const [styleProps, rest] = _chunkTK44VBIEcjs.useStyleProps.call(void 0, props);
|
|
41
41
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reactnative.View, { ref, ...rest, style: [indicatorStyle, styleProps, style], children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
42
42
|
_chunkF6CQ6CBIcjs.SelectionFill,
|
|
43
43
|
{
|
|
@@ -61,7 +61,7 @@ function Thumb() {
|
|
|
61
61
|
|
|
62
62
|
var RadioLabel = _react.forwardRef.call(void 0, function RadioLabel2({ children, style, ...props }, ref) {
|
|
63
63
|
const { labelStyle } = useRadio();
|
|
64
|
-
const [styleProps, rest] =
|
|
64
|
+
const [styleProps, rest] = _chunkTK44VBIEcjs.useStyleProps.call(void 0, props);
|
|
65
65
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _reactnative.Text, { ref, style: [labelStyle, styleProps, style], ...rest, children });
|
|
66
66
|
});
|
|
67
67
|
RadioLabel.displayName = "XAUI.Radio.Label";
|
|
@@ -203,7 +203,7 @@ var RadioRoot = _react.forwardRef.call(void 0, function Radio({
|
|
|
203
203
|
...props
|
|
204
204
|
}, ref) {
|
|
205
205
|
const theme = _chunk57SJ4LJFcjs.useXAUITheme.call(void 0, );
|
|
206
|
-
const [styleProps, rest] =
|
|
206
|
+
const [styleProps, rest] = _chunkTK44VBIEcjs.useStyleProps.call(void 0, props);
|
|
207
207
|
const [isPressed, press] = _chunk7DPL3ZDScjs.usePressState.call(void 0, { onPressIn, onPressOut });
|
|
208
208
|
const [selected, setSelected] = _chunk7EIHHOHPcjs.useControllableState.call(void 0, {
|
|
209
209
|
value: isSelected,
|
|
@@ -246,13 +246,13 @@ var RadioRoot = _react.forwardRef.call(void 0, function Radio({
|
|
|
246
246
|
styleProps,
|
|
247
247
|
typeof style === "function" ? style({ pressed: isPressed }) : style
|
|
248
248
|
];
|
|
249
|
-
const text =
|
|
249
|
+
const text = _chunk7GHM4GKLcjs.childrenToString.call(void 0, children);
|
|
250
250
|
const content = text !== null ? /* @__PURE__ */ _jsxruntime.jsxs.call(void 0, _jsxruntime.Fragment, { children: [
|
|
251
251
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, RadioIndicator, {}),
|
|
252
252
|
/* @__PURE__ */ _jsxruntime.jsx.call(void 0, RadioLabel, { children: text })
|
|
253
253
|
] }) : _nullishCoalesce(children, () => ( /* @__PURE__ */ _jsxruntime.jsx.call(void 0, RadioIndicator, {})));
|
|
254
254
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, RadioProvider, { value: context, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
255
|
-
|
|
255
|
+
_chunkTGMVEHV7cjs.PressableFeedback,
|
|
256
256
|
{
|
|
257
257
|
ref,
|
|
258
258
|
isPressed,
|