@xaui/native 0.9.1-alpha.29 → 0.9.1-alpha.30
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-XYFMSRNJ.js → chunk-27ZRTZEE.js} +14 -10
- package/dist/{chunk-ICR42HHG.js → chunk-3FV4COTM.js} +3 -3
- package/dist/chunk-423RQBOX.js +21 -0
- package/dist/{chunk-TFNB2PNI.cjs → chunk-4XPLPQLM.cjs} +13 -11
- package/dist/{chunk-APONC4DB.cjs → chunk-5GO7MAVY.cjs} +12 -10
- package/dist/{chunk-AQNWXJYV.cjs → chunk-5RQ7AZPN.cjs} +20 -16
- package/dist/{chunk-FFEUGWVA.cjs → chunk-5Z4P6WHR.cjs} +11 -9
- package/dist/{chunk-L3Q5TVYE.js → chunk-6RVCGLKZ.js} +60 -58
- package/dist/chunk-7DPL3ZDS.cjs +21 -0
- package/dist/{chunk-Y4BPKSD3.js → chunk-7SEZGVTY.js} +1 -1
- package/dist/chunk-7XKQJQF2.cjs +70 -0
- package/dist/{chunk-7BOFQN2G.js → chunk-A5OCK3C2.js} +7 -5
- package/dist/{chunk-4HELPMAK.js → chunk-BFMTUMTU.js} +81 -101
- package/dist/chunk-BVJQ3UPZ.js +62 -0
- package/dist/{chunk-NG4GFBDR.js → chunk-DFME724B.js} +8 -6
- package/dist/chunk-E2CWBQTV.js +119 -0
- package/dist/chunk-E4TS6632.cjs +314 -0
- package/dist/{chunk-VUEDYW3M.js → chunk-FMZQW35T.js} +15 -11
- package/dist/{chunk-OYZYWWJ6.js → chunk-G7K652GC.js} +4 -2
- package/dist/{chunk-YGOXQSNU.js → chunk-GI24YJPE.js} +100 -206
- package/dist/chunk-GLGU2WFL.cjs +190 -0
- package/dist/{chunk-IG4Q3WQO.cjs → chunk-GPVNCJ3Z.cjs} +74 -95
- package/dist/{chunk-D4SOU26X.js → chunk-GVQOD3VW.js} +5 -3
- package/dist/chunk-KOC3KQIT.js +124 -0
- package/dist/chunk-KPWZLUES.cjs +124 -0
- package/dist/{chunk-SVRZJEDU.cjs → chunk-KWCHSIMI.cjs} +16 -12
- package/dist/{chunk-GCU5A5MM.cjs → chunk-N527BTY4.cjs} +17 -15
- package/dist/{chunk-F3H4TXAY.cjs → chunk-NBFWWQFW.cjs} +16 -12
- package/dist/{chunk-HOIQRGSK.js → chunk-NYRXUGVL.js} +6 -4
- package/dist/{chunk-V56334S3.js → chunk-Q3WFY5N3.js} +9 -7
- package/dist/{chunk-FXHRNUCS.cjs → chunk-QGN2BBJO.cjs} +8 -6
- package/dist/{chunk-J2JJLKLG.cjs → chunk-TGZZ3RZU.cjs} +7 -5
- package/dist/{chunk-YWBTIWT5.cjs → chunk-UBQLKIZC.cjs} +22 -18
- package/dist/{chunk-PMO62QK4.js → chunk-URSKA2VR.js} +1 -114
- package/dist/{chunk-A4RGJBP2.js → chunk-V4WDMM6Z.js} +5 -3
- package/dist/{chunk-FDSQOPJH.js → chunk-VJEER76X.js} +11 -7
- package/dist/{chunk-O5KDIEDH.cjs → chunk-VZBWYWEI.cjs} +25 -24
- package/dist/{chunk-B4W2XNBP.cjs → chunk-WR7YLDVV.cjs} +3 -3
- package/dist/{chunk-5RFRASSB.js → chunk-X4HQ4H2V.js} +16 -15
- package/dist/{chunk-IBEX4XGV.cjs → chunk-XFSW3ZNI.cjs} +13 -11
- package/dist/{chunk-VZGBEGDV.cjs → chunk-XQFAUDR2.cjs} +2 -2
- package/dist/{chunk-V3KS5PPK.js → chunk-YKL6XHM6.js} +14 -10
- package/dist/{chunk-HUZ4AUM2.cjs → chunk-ZP2E2H2G.cjs} +4 -188
- package/dist/{chunk-RZC4VFB5.cjs → chunk-ZSLNGBDS.cjs} +68 -66
- package/dist/components/alert/index.cjs +8 -6
- package/dist/components/alert/index.d.cts +2 -2
- package/dist/components/alert/index.d.ts +2 -2
- package/dist/components/alert/index.js +7 -5
- package/dist/components/button/index.cjs +9 -5
- package/dist/components/button/index.d.cts +9 -4
- package/dist/components/button/index.d.ts +9 -4
- package/dist/components/button/index.js +8 -4
- package/dist/components/card/index.cjs +6 -4
- package/dist/components/card/index.d.cts +1 -1
- package/dist/components/card/index.d.ts +1 -1
- package/dist/components/card/index.js +5 -3
- package/dist/components/checkbox/index.cjs +7 -5
- package/dist/components/checkbox/index.d.cts +1 -1
- package/dist/components/checkbox/index.d.ts +1 -1
- package/dist/components/checkbox/index.js +6 -4
- package/dist/components/chip/index.cjs +8 -6
- package/dist/components/chip/index.d.cts +2 -2
- package/dist/components/chip/index.d.ts +2 -2
- package/dist/components/chip/index.js +7 -5
- package/dist/components/input/index.cjs +4 -3
- package/dist/components/input/index.d.cts +1 -1
- package/dist/components/input/index.d.ts +1 -1
- package/dist/components/input/index.js +3 -2
- package/dist/components/input-group/index.cjs +6 -5
- package/dist/components/input-group/index.d.cts +1 -1
- package/dist/components/input-group/index.d.ts +1 -1
- package/dist/components/input-group/index.js +5 -4
- package/dist/components/input-otp/index.cjs +4 -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 +3 -2
- package/dist/components/radio/index.cjs +7 -5
- package/dist/components/radio/index.d.cts +1 -1
- package/dist/components/radio/index.d.ts +1 -1
- package/dist/components/radio/index.js +6 -4
- package/dist/components/spinner/index.cjs +16 -0
- package/dist/components/spinner/index.d.cts +104 -0
- package/dist/components/spinner/index.d.ts +104 -0
- package/dist/components/spinner/index.js +16 -0
- package/dist/components/switch/index.cjs +6 -4
- package/dist/components/switch/index.d.cts +1 -1
- package/dist/components/switch/index.d.ts +1 -1
- package/dist/components/switch/index.js +5 -3
- package/dist/components/text-area/index.cjs +5 -4
- package/dist/components/text-area/index.js +4 -3
- package/dist/components/typography/index.cjs +4 -3
- package/dist/components/typography/index.d.cts +1 -1
- package/dist/components/typography/index.d.ts +1 -1
- package/dist/components/typography/index.js +3 -2
- package/dist/components/view/index.cjs +4 -3
- package/dist/components/view/index.js +3 -2
- package/dist/{create-recipe-DUo8doTt.d.ts → create-recipe-BdVd2ffi.d.ts} +1 -1
- package/dist/{create-recipe-CWvI5ot3.d.cts → create-recipe-dC7wMfnj.d.cts} +1 -1
- package/dist/{icon.type-Dq4_qePa.d.ts → icon.type-Kml72iSz.d.ts} +1 -1
- package/dist/{icon.type-CF4KiMKl.d.cts → icon.type-d_i9ma-i.d.cts} +1 -1
- package/dist/index.cjs +39 -37
- package/dist/index.d.cts +24 -4
- package/dist/index.d.ts +24 -4
- package/dist/index.js +73 -71
- package/dist/system/index.cjs +11 -8
- package/dist/system/index.d.cts +4 -4
- package/dist/system/index.d.ts +4 -4
- package/dist/system/index.js +11 -8
- package/package.json +11 -1
- package/dist/chunk-E25JH7W2.cjs +0 -456
|
@@ -2,28 +2,6 @@ import {
|
|
|
2
2
|
stableHash
|
|
3
3
|
} from "./chunk-GGW42MY4.js";
|
|
4
4
|
|
|
5
|
-
// src/system/slot/create-slot-context.ts
|
|
6
|
-
import { createContext, useContext } from "react";
|
|
7
|
-
function createSlotContext(name) {
|
|
8
|
-
const Context = createContext(null);
|
|
9
|
-
Context.displayName = `XAUI.${name}.Context`;
|
|
10
|
-
function useSlotContext() {
|
|
11
|
-
const value = useContext(Context);
|
|
12
|
-
if (value === null) {
|
|
13
|
-
const error = new Error(
|
|
14
|
-
`XAUI: use${name} must be called inside <${name}>. A slot reads the values its root resolved, so it can only be rendered as a child of one.`
|
|
15
|
-
);
|
|
16
|
-
Error.captureStackTrace?.(
|
|
17
|
-
error,
|
|
18
|
-
useSlotContext
|
|
19
|
-
);
|
|
20
|
-
throw error;
|
|
21
|
-
}
|
|
22
|
-
return value;
|
|
23
|
-
}
|
|
24
|
-
return [Context.Provider, useSlotContext];
|
|
25
|
-
}
|
|
26
|
-
|
|
27
5
|
// src/system/slot/merge-refs.ts
|
|
28
6
|
function mergeRefs(...refs) {
|
|
29
7
|
return (value) => {
|
|
@@ -34,70 +12,6 @@ function mergeRefs(...refs) {
|
|
|
34
12
|
};
|
|
35
13
|
}
|
|
36
14
|
|
|
37
|
-
// src/system/slot/merge-props.ts
|
|
38
|
-
var EVENT_HANDLER = /^on[A-Z]/;
|
|
39
|
-
function mergeProps(ours, theirs) {
|
|
40
|
-
const merged = { ...ours };
|
|
41
|
-
for (const key of Object.keys(theirs)) {
|
|
42
|
-
const ourValue = ours[key];
|
|
43
|
-
const theirValue = theirs[key];
|
|
44
|
-
if (EVENT_HANDLER.test(key)) {
|
|
45
|
-
merged[key] = composeHandlers(ourValue, theirValue);
|
|
46
|
-
} else if (key === "style") {
|
|
47
|
-
merged[key] = mergeStyles(ourValue, theirValue);
|
|
48
|
-
} else if (key === "ref") {
|
|
49
|
-
merged[key] = mergeRefs(
|
|
50
|
-
ourValue,
|
|
51
|
-
theirValue
|
|
52
|
-
);
|
|
53
|
-
} else {
|
|
54
|
-
merged[key] = theirValue;
|
|
55
|
-
}
|
|
56
|
-
}
|
|
57
|
-
return merged;
|
|
58
|
-
}
|
|
59
|
-
function composeHandlers(ours, theirs) {
|
|
60
|
-
if (typeof ours !== "function") return theirs;
|
|
61
|
-
if (typeof theirs !== "function") return ours;
|
|
62
|
-
return (...args) => {
|
|
63
|
-
;
|
|
64
|
-
ours(...args);
|
|
65
|
-
return theirs(...args);
|
|
66
|
-
};
|
|
67
|
-
}
|
|
68
|
-
function mergeStyles(ours, theirs) {
|
|
69
|
-
if (typeof ours === "function" || typeof theirs === "function") {
|
|
70
|
-
return (state) => [
|
|
71
|
-
resolveStyle(ours, state),
|
|
72
|
-
resolveStyle(theirs, state)
|
|
73
|
-
];
|
|
74
|
-
}
|
|
75
|
-
return [ours, theirs];
|
|
76
|
-
}
|
|
77
|
-
function resolveStyle(style, state) {
|
|
78
|
-
return typeof style === "function" ? style(state) : style;
|
|
79
|
-
}
|
|
80
|
-
|
|
81
|
-
// src/system/slot/slot.tsx
|
|
82
|
-
import { cloneElement, forwardRef, isValidElement } from "react";
|
|
83
|
-
var Slot = forwardRef(function Slot2({ children, ...ours }, ref) {
|
|
84
|
-
if (!isValidElement(children)) {
|
|
85
|
-
throw new Error(
|
|
86
|
-
"XAUI: asChild expects exactly one React element as its child, and merges the component's props into it. Text, a fragment, several children or none give it nothing to merge into \u2014 drop `asChild` to render the component itself."
|
|
87
|
-
);
|
|
88
|
-
}
|
|
89
|
-
const child = children;
|
|
90
|
-
const merged = mergeProps(ours, child.props);
|
|
91
|
-
merged.ref = mergeRefs(ref, refOf(child));
|
|
92
|
-
return cloneElement(child, merged);
|
|
93
|
-
});
|
|
94
|
-
Slot.displayName = "XAUI.Slot";
|
|
95
|
-
function refOf(element) {
|
|
96
|
-
const fromProps = element.props.ref;
|
|
97
|
-
const fromElement = element.ref;
|
|
98
|
-
return fromProps ?? fromElement;
|
|
99
|
-
}
|
|
100
|
-
|
|
101
15
|
// src/system/style-props/use-style-props.ts
|
|
102
16
|
import { useMemo } from "react";
|
|
103
17
|
|
|
@@ -270,34 +184,7 @@ function useStyleProps(props) {
|
|
|
270
184
|
return [useMemo(() => styleProps, [key]), rest];
|
|
271
185
|
}
|
|
272
186
|
|
|
273
|
-
// src/system/slot/children-to-string.ts
|
|
274
|
-
import { isValidElement as isValidElement2 } from "react";
|
|
275
|
-
function childrenToString(children) {
|
|
276
|
-
const text = stringify(children);
|
|
277
|
-
return text === null || text === "" ? null : text;
|
|
278
|
-
}
|
|
279
|
-
function stringify(node) {
|
|
280
|
-
if (node === null || node === void 0 || typeof node === "boolean") return "";
|
|
281
|
-
if (typeof node === "string") return node;
|
|
282
|
-
if (typeof node === "number") return String(node);
|
|
283
|
-
if (isValidElement2(node)) return null;
|
|
284
|
-
if (Array.isArray(node)) {
|
|
285
|
-
let text = "";
|
|
286
|
-
for (const child of node) {
|
|
287
|
-
const part = stringify(child);
|
|
288
|
-
if (part === null) return null;
|
|
289
|
-
text += part;
|
|
290
|
-
}
|
|
291
|
-
return text;
|
|
292
|
-
}
|
|
293
|
-
return null;
|
|
294
|
-
}
|
|
295
|
-
|
|
296
187
|
export {
|
|
297
|
-
createSlotContext,
|
|
298
188
|
mergeRefs,
|
|
299
|
-
|
|
300
|
-
Slot,
|
|
301
|
-
useStyleProps,
|
|
302
|
-
childrenToString
|
|
189
|
+
useStyleProps
|
|
303
190
|
};
|
|
@@ -1,13 +1,15 @@
|
|
|
1
1
|
import {
|
|
2
|
-
PressableFeedback
|
|
2
|
+
PressableFeedback
|
|
3
|
+
} from "./chunk-BFMTUMTU.js";
|
|
4
|
+
import {
|
|
3
5
|
usePressState
|
|
4
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-423RQBOX.js";
|
|
5
7
|
import {
|
|
6
8
|
warnDev
|
|
7
9
|
} from "./chunk-EGLLDKN6.js";
|
|
8
10
|
import {
|
|
9
11
|
useStyleProps
|
|
10
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-URSKA2VR.js";
|
|
11
13
|
|
|
12
14
|
// src/system/close-button/close-button.tsx
|
|
13
15
|
import { forwardRef } from "react";
|
|
@@ -1,22 +1,26 @@
|
|
|
1
1
|
import {
|
|
2
|
-
PressableFeedback
|
|
2
|
+
PressableFeedback
|
|
3
|
+
} from "./chunk-BFMTUMTU.js";
|
|
4
|
+
import {
|
|
3
5
|
usePressState
|
|
4
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-423RQBOX.js";
|
|
5
7
|
import {
|
|
6
8
|
warnDev
|
|
7
9
|
} from "./chunk-EGLLDKN6.js";
|
|
8
10
|
import {
|
|
9
11
|
createRecipe
|
|
10
12
|
} from "./chunk-4GTAZM2C.js";
|
|
13
|
+
import {
|
|
14
|
+
useXAUITheme
|
|
15
|
+
} from "./chunk-A3EGFI6T.js";
|
|
11
16
|
import {
|
|
12
17
|
Slot,
|
|
13
18
|
childrenToString,
|
|
14
|
-
createSlotContext
|
|
15
|
-
|
|
16
|
-
} from "./chunk-PMO62QK4.js";
|
|
19
|
+
createSlotContext
|
|
20
|
+
} from "./chunk-E2CWBQTV.js";
|
|
17
21
|
import {
|
|
18
|
-
|
|
19
|
-
} from "./chunk-
|
|
22
|
+
useStyleProps
|
|
23
|
+
} from "./chunk-URSKA2VR.js";
|
|
20
24
|
|
|
21
25
|
// src/components/card/card-background.tsx
|
|
22
26
|
import { forwardRef } from "react";
|
|
@@ -38,16 +38,17 @@ function _optionalChain(ops) {
|
|
|
38
38
|
}
|
|
39
39
|
var _chunk7EIHHOHPcjs = require('./chunk-7EIHHOHP.cjs');
|
|
40
40
|
var _chunkFNEUOBCVcjs = require('./chunk-FNEUOBCV.cjs');
|
|
41
|
-
var _chunkHUZ4AUM2cjs = require('./chunk-HUZ4AUM2.cjs');
|
|
42
41
|
var _chunk57SJ4LJFcjs = require('./chunk-57SJ4LJF.cjs');
|
|
42
|
+
var _chunkZP2E2H2Gcjs = require('./chunk-ZP2E2H2G.cjs');
|
|
43
|
+
var _chunkGLGU2WFLcjs = require('./chunk-GLGU2WFL.cjs');
|
|
43
44
|
|
|
44
45
|
// src/components/input-otp/input-otp-box.tsx
|
|
45
46
|
var _react = require('react');
|
|
46
47
|
var _reactnative = require('react-native');
|
|
47
48
|
|
|
48
49
|
// src/components/input-otp/input-otp.context.ts
|
|
49
|
-
var [InputOTPProvider, useInputOTP] =
|
|
50
|
-
var [InputOTPBoxProvider, useInputOTPBox] =
|
|
50
|
+
var [InputOTPProvider, useInputOTP] = _chunkZP2E2H2Gcjs.createSlotContext.call(void 0, "InputOTP");
|
|
51
|
+
var [InputOTPBoxProvider, useInputOTPBox] = _chunkZP2E2H2Gcjs.createSlotContext.call(void 0, "InputOTP.Box");
|
|
51
52
|
|
|
52
53
|
// src/components/input-otp/input-otp-caret.tsx
|
|
53
54
|
|
|
@@ -66,7 +67,7 @@ function InputOTPCaret({
|
|
|
66
67
|
const {
|
|
67
68
|
slot
|
|
68
69
|
} = useInputOTPBox();
|
|
69
|
-
const [styleProps] =
|
|
70
|
+
const [styleProps] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
70
71
|
const barStyle = [caretStyle, styleProps, style];
|
|
71
72
|
if (!_optionalChain([slot, 'optionalAccess', _2 => _2.isCaretVisible])) return null;
|
|
72
73
|
if (!animation) return /* @__PURE__ */_jsxruntime.jsx.call(void 0, _reactnative.View, {
|
|
@@ -77,10 +78,10 @@ function InputOTPCaret({
|
|
|
77
78
|
});
|
|
78
79
|
}
|
|
79
80
|
InputOTPCaret.displayName = "XAUI.InputOTP.Caret";
|
|
80
|
-
const
|
|
81
|
-
code: "function
|
|
82
|
-
location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-
|
|
83
|
-
sourceMap: "{\"version\":3,\"names\":[\"
|
|
81
|
+
const _worklet_1245322763332_init_data = {
|
|
82
|
+
code: "function chunkVZBWYWEICjs1(){const{opacity}=this.__closure;return{opacity:opacity.value};}",
|
|
83
|
+
location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-VZBWYWEI.cjs",
|
|
84
|
+
sourceMap: "{\"version\":3,\"names\":[\"chunkVZBWYWEICjs1\",\"opacity\",\"__closure\",\"value\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-VZBWYWEI.cjs\"],\"mappings\":\"AA8D6E,SAAAA,iBAAMA,CAAA,QAAAC,OAAA,OAAAC,SAAA,CAE/E,MAAO,CAAED,OAAO,CAAEA,OAAO,CAACE,KAAM,CAAC,CACnC\",\"ignoreList\":[]}"
|
|
84
85
|
};
|
|
85
86
|
function BlinkingCaret({
|
|
86
87
|
style
|
|
@@ -93,26 +94,26 @@ function BlinkingCaret({
|
|
|
93
94
|
}), -1, true);
|
|
94
95
|
return () => _reactnativereanimated.cancelAnimation.call(void 0, opacity);
|
|
95
96
|
}, [opacity]);
|
|
96
|
-
const animatedStyle = _reactnativereanimated.useAnimatedStyle.call(void 0, function
|
|
97
|
-
|
|
97
|
+
const animatedStyle = _reactnativereanimated.useAnimatedStyle.call(void 0, function chunkVZBWYWEICjs1Factory({
|
|
98
|
+
_worklet_1245322763332_init_data,
|
|
98
99
|
opacity
|
|
99
100
|
}) {
|
|
100
101
|
const _e = [new global.Error(), -2, -27];
|
|
101
|
-
const
|
|
102
|
+
const chunkVZBWYWEICjs1 = function () {
|
|
102
103
|
return {
|
|
103
104
|
opacity: opacity.value
|
|
104
105
|
};
|
|
105
106
|
};
|
|
106
|
-
|
|
107
|
+
chunkVZBWYWEICjs1.__closure = {
|
|
107
108
|
opacity
|
|
108
109
|
};
|
|
109
|
-
|
|
110
|
-
|
|
111
|
-
|
|
112
|
-
|
|
113
|
-
return
|
|
110
|
+
chunkVZBWYWEICjs1.__workletHash = 1245322763332;
|
|
111
|
+
chunkVZBWYWEICjs1.__pluginVersion = "0.7.4";
|
|
112
|
+
chunkVZBWYWEICjs1.__initData = _worklet_1245322763332_init_data;
|
|
113
|
+
chunkVZBWYWEICjs1.__stackDetails = _e;
|
|
114
|
+
return chunkVZBWYWEICjs1;
|
|
114
115
|
}({
|
|
115
|
-
|
|
116
|
+
_worklet_1245322763332_init_data,
|
|
116
117
|
opacity
|
|
117
118
|
}), [opacity]);
|
|
118
119
|
return /* @__PURE__ */_jsxruntime.jsx.call(void 0, _reactnativereanimated2.default.View, {
|
|
@@ -134,7 +135,7 @@ var InputOTPPlaceholder = _react.forwardRef.call(void 0, function InputOTPPlaceh
|
|
|
134
135
|
const {
|
|
135
136
|
slot
|
|
136
137
|
} = useInputOTPBox();
|
|
137
|
-
const [styleProps, rest] =
|
|
138
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
138
139
|
const char = _nullishCoalesce(children, () => _optionalChain([slot, 'optionalAccess', _3 => _3.placeholderChar]));
|
|
139
140
|
if (!char) return null;
|
|
140
141
|
return /* @__PURE__ */_jsxruntime.jsx.call(void 0, _reactnative.Text, {
|
|
@@ -161,7 +162,7 @@ var InputOTPValue = _react.forwardRef.call(void 0, function InputOTPValue2({
|
|
|
161
162
|
const {
|
|
162
163
|
slot
|
|
163
164
|
} = useInputOTPBox();
|
|
164
|
-
const [styleProps, rest] =
|
|
165
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
165
166
|
const char = _nullishCoalesce(children, () => _optionalChain([slot, 'optionalAccess', _4 => _4.char]));
|
|
166
167
|
if (!char) return null;
|
|
167
168
|
return /* @__PURE__ */_jsxruntime.jsx.call(void 0, _reactnative.Text, {
|
|
@@ -187,7 +188,7 @@ var InputOTPBox = _react.forwardRef.call(void 0, function InputOTPBox2({
|
|
|
187
188
|
boxActiveStyle,
|
|
188
189
|
slots
|
|
189
190
|
} = useInputOTP();
|
|
190
|
-
const [styleProps, rest] =
|
|
191
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
191
192
|
const slot = slots[index];
|
|
192
193
|
const context = _react.useMemo.call(void 0, () => ({
|
|
193
194
|
slot
|
|
@@ -222,7 +223,7 @@ var InputOTPGroup = _react.forwardRef.call(void 0, function InputOTPGroup2({
|
|
|
222
223
|
isDisabled,
|
|
223
224
|
isInvalid
|
|
224
225
|
} = useInputOTP();
|
|
225
|
-
const [styleProps, rest] =
|
|
226
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
226
227
|
const content = typeof children === "function" ? children({
|
|
227
228
|
slots,
|
|
228
229
|
value,
|
|
@@ -250,7 +251,7 @@ var InputOTPSeparator = _react.forwardRef.call(void 0, function InputOTPSeparato
|
|
|
250
251
|
const {
|
|
251
252
|
separatorStyle
|
|
252
253
|
} = useInputOTP();
|
|
253
|
-
const [styleProps, rest] =
|
|
254
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
254
255
|
return /* @__PURE__ */_jsxruntime.jsx.call(void 0, _reactnative.View, {
|
|
255
256
|
ref,
|
|
256
257
|
accessibilityElementsHidden: true,
|
|
@@ -620,7 +621,7 @@ var InputOTPRoot = _react.forwardRef.call(void 0, function InputOTP({
|
|
|
620
621
|
...props
|
|
621
622
|
}, ref) {
|
|
622
623
|
const theme = _chunk57SJ4LJFcjs.useXAUITheme.call(void 0);
|
|
623
|
-
const [styleProps, rest] =
|
|
624
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
624
625
|
const state = useInputOTPState({
|
|
625
626
|
maxLength,
|
|
626
627
|
value: valueProp,
|
|
@@ -1,9 +1,9 @@
|
|
|
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 _chunkGLGU2WFLcjs = require('./chunk-GLGU2WFL.cjs');
|
|
7
7
|
|
|
8
8
|
// src/system/icon/icon-context.ts
|
|
9
9
|
var _react = require('react');
|
|
@@ -47,7 +47,7 @@ function IconImage({
|
|
|
47
47
|
color: _color,
|
|
48
48
|
...props
|
|
49
49
|
}) {
|
|
50
|
-
const [styleProps] =
|
|
50
|
+
const [styleProps] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
51
51
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
52
52
|
_reactnative.Image,
|
|
53
53
|
{
|
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import { useControllableState } from "./chunk-F6W3JQ7K.js";
|
|
2
2
|
import { createRecipe, radiusAxis } from "./chunk-4GTAZM2C.js";
|
|
3
|
-
import { createSlotContext, useStyleProps } from "./chunk-PMO62QK4.js";
|
|
4
3
|
import { useXAUITheme } from "./chunk-A3EGFI6T.js";
|
|
4
|
+
import { createSlotContext } from "./chunk-E2CWBQTV.js";
|
|
5
|
+
import { useStyleProps } from "./chunk-URSKA2VR.js";
|
|
5
6
|
|
|
6
7
|
// src/components/input-otp/input-otp-box.tsx
|
|
7
8
|
import { forwardRef as forwardRef3, useMemo } from "react";
|
|
@@ -39,10 +40,10 @@ function InputOTPCaret({
|
|
|
39
40
|
});
|
|
40
41
|
}
|
|
41
42
|
InputOTPCaret.displayName = "XAUI.InputOTP.Caret";
|
|
42
|
-
const
|
|
43
|
-
code: "function
|
|
44
|
-
location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-
|
|
45
|
-
sourceMap: "{\"version\":3,\"names\":[\"
|
|
43
|
+
const _worklet_6223106876401_init_data = {
|
|
44
|
+
code: "function chunkX4HQ4H2VJs1(){const{opacity}=this.__closure;return{opacity:opacity.value};}",
|
|
45
|
+
location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-X4HQ4H2V.js",
|
|
46
|
+
sourceMap: "{\"version\":3,\"names\":[\"chunkX4HQ4H2VJs1\",\"opacity\",\"__closure\",\"value\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-X4HQ4H2V.js\"],\"mappings\":\"AA8DyC,SAAAA,gBAAMA,CAAA,QAAAC,OAAA,OAAAC,SAAA,CAE3C,MAAO,CAAED,OAAO,CAAEA,OAAO,CAACE,KAAM,CAAC,CACnC\",\"ignoreList\":[]}"
|
|
46
47
|
};
|
|
47
48
|
function BlinkingCaret({
|
|
48
49
|
style
|
|
@@ -55,26 +56,26 @@ function BlinkingCaret({
|
|
|
55
56
|
}), -1, true);
|
|
56
57
|
return () => cancelAnimation(opacity);
|
|
57
58
|
}, [opacity]);
|
|
58
|
-
const animatedStyle = useAnimatedStyle(function
|
|
59
|
-
|
|
59
|
+
const animatedStyle = useAnimatedStyle(function chunkX4HQ4H2VJs1Factory({
|
|
60
|
+
_worklet_6223106876401_init_data,
|
|
60
61
|
opacity
|
|
61
62
|
}) {
|
|
62
63
|
const _e = [new global.Error(), -2, -27];
|
|
63
|
-
const
|
|
64
|
+
const chunkX4HQ4H2VJs1 = function () {
|
|
64
65
|
return {
|
|
65
66
|
opacity: opacity.value
|
|
66
67
|
};
|
|
67
68
|
};
|
|
68
|
-
|
|
69
|
+
chunkX4HQ4H2VJs1.__closure = {
|
|
69
70
|
opacity
|
|
70
71
|
};
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
return
|
|
72
|
+
chunkX4HQ4H2VJs1.__workletHash = 6223106876401;
|
|
73
|
+
chunkX4HQ4H2VJs1.__pluginVersion = "0.7.4";
|
|
74
|
+
chunkX4HQ4H2VJs1.__initData = _worklet_6223106876401_init_data;
|
|
75
|
+
chunkX4HQ4H2VJs1.__stackDetails = _e;
|
|
76
|
+
return chunkX4HQ4H2VJs1;
|
|
76
77
|
}({
|
|
77
|
-
|
|
78
|
+
_worklet_6223106876401_init_data,
|
|
78
79
|
opacity
|
|
79
80
|
}), [opacity]);
|
|
80
81
|
return /* @__PURE__ */jsx(Animated.View, {
|
|
@@ -1,7 +1,9 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); 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
|
+
var _chunkZP2E2H2Gcjs = require('./chunk-ZP2E2H2G.cjs');
|
|
3
4
|
|
|
4
|
-
|
|
5
|
+
|
|
6
|
+
var _chunkGLGU2WFLcjs = require('./chunk-GLGU2WFL.cjs');
|
|
5
7
|
|
|
6
8
|
// src/components/view/grid.tsx
|
|
7
9
|
var _react = require('react');
|
|
@@ -30,7 +32,7 @@ function spanWidth({ cellWidth, columns, gap }, span) {
|
|
|
30
32
|
var _jsxruntime = require('react/jsx-runtime');
|
|
31
33
|
var GridRoot = _react.forwardRef.call(void 0, function Grid({ children, columns = 2, gap = 0, style, onLayout, ...props }, ref) {
|
|
32
34
|
const [width, setWidth] = _react.useState.call(void 0, );
|
|
33
|
-
const [styleProps, rest] =
|
|
35
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
34
36
|
const safeColumns = Math.max(Math.floor(columns), 1);
|
|
35
37
|
const cellWidth = width === void 0 ? void 0 : (width - gap * (safeColumns - 1)) / safeColumns;
|
|
36
38
|
const context = _react.useMemo.call(void 0,
|
|
@@ -73,7 +75,7 @@ function isGridItem(child) {
|
|
|
73
75
|
|
|
74
76
|
var GridItem = _react.forwardRef.call(void 0, function GridItem2({ children, span = 1, style, ...props }, ref) {
|
|
75
77
|
const grid = useGrid();
|
|
76
|
-
const [styleProps, rest] =
|
|
78
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
77
79
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
78
80
|
_reactnative.View,
|
|
79
81
|
{
|
|
@@ -91,8 +93,8 @@ GridItem.displayName = "XAUI.Grid.Item";
|
|
|
91
93
|
|
|
92
94
|
|
|
93
95
|
var StackRoot = _react.forwardRef.call(void 0, function Stack({ children, asChild = false, style, ...props }, ref) {
|
|
94
|
-
const [styleProps, rest] =
|
|
95
|
-
const Root = asChild ?
|
|
96
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
97
|
+
const Root = asChild ? _chunkZP2E2H2Gcjs.Slot : _reactnative.View;
|
|
96
98
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Root, { ref, style: [{ position: "relative" }, styleProps, style], ...rest, children });
|
|
97
99
|
});
|
|
98
100
|
StackRoot.displayName = "XAUI.Stack";
|
|
@@ -102,8 +104,8 @@ StackRoot.displayName = "XAUI.Stack";
|
|
|
102
104
|
|
|
103
105
|
|
|
104
106
|
var StackItem = _react.forwardRef.call(void 0, function StackItem2({ children, asChild = false, style, ...props }, ref) {
|
|
105
|
-
const [styleProps, rest] =
|
|
106
|
-
const Root = asChild ?
|
|
107
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
108
|
+
const Root = asChild ? _chunkZP2E2H2Gcjs.Slot : _reactnative.View;
|
|
107
109
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Root, { ref, style: [{ position: "absolute" }, styleProps, style], ...rest, children });
|
|
108
110
|
});
|
|
109
111
|
StackItem.displayName = "XAUI.Stack.Item";
|
|
@@ -113,8 +115,8 @@ StackItem.displayName = "XAUI.Stack.Item";
|
|
|
113
115
|
|
|
114
116
|
|
|
115
117
|
var Row = _react.forwardRef.call(void 0, function Row2({ children, asChild = false, style, ...props }, ref) {
|
|
116
|
-
const [styleProps, rest] =
|
|
117
|
-
const Root = asChild ?
|
|
118
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
119
|
+
const Root = asChild ? _chunkZP2E2H2Gcjs.Slot : _reactnative.View;
|
|
118
120
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Root, { ref, style: [{ flexDirection: "row" }, styleProps, style], ...rest, children });
|
|
119
121
|
});
|
|
120
122
|
Row.displayName = "XAUI.Row";
|
|
@@ -124,8 +126,8 @@ Row.displayName = "XAUI.Row";
|
|
|
124
126
|
|
|
125
127
|
|
|
126
128
|
var Column = _react.forwardRef.call(void 0, function Column2({ children, asChild = false, style, ...props }, ref) {
|
|
127
|
-
const [styleProps, rest] =
|
|
128
|
-
const Root = asChild ?
|
|
129
|
+
const [styleProps, rest] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
130
|
+
const Root = asChild ? _chunkZP2E2H2Gcjs.Slot : _reactnative.View;
|
|
129
131
|
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, Root, { ref, style: [{ flexDirection: "column" }, styleProps, style], ...rest, children });
|
|
130
132
|
});
|
|
131
133
|
Column.displayName = "XAUI.Column";
|
|
@@ -1,6 +1,6 @@
|
|
|
1
1
|
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); 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
|
-
var
|
|
3
|
+
var _chunkGLGU2WFLcjs = require('./chunk-GLGU2WFL.cjs');
|
|
4
4
|
|
|
5
5
|
// src/system/portal/portal.tsx
|
|
6
6
|
var _react = require('react');
|
|
@@ -31,7 +31,7 @@ var styles = _reactnative.StyleSheet.create({
|
|
|
31
31
|
container: { flex: 1 }
|
|
32
32
|
});
|
|
33
33
|
function PortalHost({ children, ...props }) {
|
|
34
|
-
const [styleProps] =
|
|
34
|
+
const [styleProps] = _chunkGLGU2WFLcjs.useStyleProps.call(void 0, props);
|
|
35
35
|
const [portals, setPortals] = _react.useState.call(void 0, /* @__PURE__ */ new Map());
|
|
36
36
|
const addPortal = _react.useCallback.call(void 0, (key, element) => {
|
|
37
37
|
setPortals((current) => new Map(current).set(key, element));
|
|
@@ -1,25 +1,29 @@
|
|
|
1
|
-
import {
|
|
2
|
-
useControllableState
|
|
3
|
-
} from "./chunk-F6W3JQ7K.js";
|
|
4
1
|
import {
|
|
5
2
|
SelectionFill
|
|
6
3
|
} from "./chunk-BA2DBSAN.js";
|
|
7
4
|
import {
|
|
8
|
-
PressableFeedback
|
|
5
|
+
PressableFeedback
|
|
6
|
+
} from "./chunk-BFMTUMTU.js";
|
|
7
|
+
import {
|
|
9
8
|
usePressState
|
|
10
|
-
} from "./chunk-
|
|
9
|
+
} from "./chunk-423RQBOX.js";
|
|
10
|
+
import {
|
|
11
|
+
useControllableState
|
|
12
|
+
} from "./chunk-F6W3JQ7K.js";
|
|
11
13
|
import {
|
|
12
14
|
createRecipe,
|
|
13
15
|
radiusAxis
|
|
14
16
|
} from "./chunk-4GTAZM2C.js";
|
|
15
|
-
import {
|
|
16
|
-
childrenToString,
|
|
17
|
-
createSlotContext,
|
|
18
|
-
useStyleProps
|
|
19
|
-
} from "./chunk-PMO62QK4.js";
|
|
20
17
|
import {
|
|
21
18
|
useXAUITheme
|
|
22
19
|
} from "./chunk-A3EGFI6T.js";
|
|
20
|
+
import {
|
|
21
|
+
childrenToString,
|
|
22
|
+
createSlotContext
|
|
23
|
+
} from "./chunk-E2CWBQTV.js";
|
|
24
|
+
import {
|
|
25
|
+
useStyleProps
|
|
26
|
+
} from "./chunk-URSKA2VR.js";
|
|
23
27
|
|
|
24
28
|
// src/components/checkbox/checkbox-indicator.tsx
|
|
25
29
|
import { forwardRef } from "react";
|