@xaui/native 0.9.1-alpha.23 → 0.9.1-alpha.25
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-E3LXUXE7.js → chunk-2OY76YNB.js} +47 -13
- package/dist/{chunk-KM2TI5IC.js → chunk-4HELPMAK.js} +76 -82
- package/dist/{chunk-AHL33YAO.js → chunk-4J26FA6O.js} +9 -7
- package/dist/{chunk-BNWS26PX.cjs → chunk-6FBGCF5T.cjs} +9 -7
- package/dist/{chunk-ZQ3JSWRO.js → chunk-A4RGJBP2.js} +4 -2
- package/dist/{chunk-I6PE5UUH.cjs → chunk-AV5LMFS3.cjs} +13 -11
- package/dist/{chunk-OGC4RKE3.js → chunk-AXSJPWSJ.js} +5 -5
- package/dist/chunk-BULNTP5N.cjs +620 -0
- package/dist/chunk-EGLLDKN6.js +9 -0
- package/dist/chunk-EJQCQPET.cjs +9 -0
- package/dist/{chunk-VDRRD6GM.cjs → chunk-EWBBDVTM.cjs} +22 -21
- package/dist/chunk-GSEK6OCY.cjs +72 -0
- package/dist/chunk-I6UCYAO2.js +731 -0
- package/dist/{chunk-BH5DSJVX.cjs → chunk-IG4Q3WQO.cjs} +61 -68
- package/dist/{chunk-6WW4CSPY.cjs → chunk-J2JJLKLG.cjs} +6 -4
- package/dist/{chunk-4MHJOWM4.cjs → chunk-J4JFIC4W.cjs} +7 -7
- package/dist/{chunk-FNQF4KQV.js → chunk-MRYLLKML.js} +18 -17
- package/dist/{chunk-GBPWTFTU.cjs → chunk-OHEHPQLC.cjs} +10 -1
- package/dist/{chunk-GG2WWCBK.js → chunk-TZG3DERP.js} +10 -1
- package/dist/{chunk-TIP3T7JJ.cjs → chunk-YEW5LPWL.cjs} +47 -13
- package/dist/chunk-ZDCGPK5Z.js +72 -0
- package/dist/{chunk-FTCTTBLG.js → chunk-ZTA47PO5.js} +7 -5
- package/dist/components/alert/index.cjs +7 -6
- package/dist/components/alert/index.js +6 -5
- package/dist/components/button/index.cjs +6 -5
- package/dist/components/button/index.js +5 -4
- package/dist/components/card/index.cjs +5 -4
- package/dist/components/card/index.js +4 -3
- package/dist/components/chip/index.cjs +7 -6
- package/dist/components/chip/index.js +6 -5
- package/dist/components/input/index.cjs +13 -3
- package/dist/components/input/index.d.cts +109 -117
- package/dist/components/input/index.d.ts +109 -117
- package/dist/components/input/index.js +12 -2
- package/dist/components/input-otp/index.cjs +27 -0
- package/dist/components/input-otp/index.d.cts +325 -0
- package/dist/components/input-otp/index.d.ts +325 -0
- package/dist/components/input-otp/index.js +27 -0
- package/dist/components/text-area/index.cjs +13 -0
- package/dist/components/text-area/index.d.cts +73 -0
- package/dist/components/text-area/index.d.ts +73 -0
- package/dist/components/text-area/index.js +13 -0
- package/dist/components/typography/index.cjs +3 -3
- package/dist/components/typography/index.js +2 -2
- package/dist/index.cjs +53 -51
- package/dist/index.d.cts +4 -1
- package/dist/index.d.ts +4 -1
- package/dist/index.js +69 -67
- package/dist/input.type-BpJeUIe8.d.cts +151 -0
- package/dist/input.type-DjyZ6P2C.d.ts +151 -0
- package/dist/system/index.cjs +6 -5
- package/dist/system/index.js +5 -4
- package/dist/theme/index.cjs +2 -2
- package/dist/theme/index.js +1 -1
- package/package.json +21 -1
- package/dist/{chunk-DXGQ43IV.cjs → chunk-B4W2XNBP.cjs} +2 -2
- package/dist/{chunk-2U6JR7BF.js → chunk-G52TQJBI.js} +3 -3
- package/dist/{chunk-FVP5FUVS.js → chunk-ICR42HHG.js} +3 -3
- package/dist/{chunk-RAWOJ3N3.cjs → chunk-Y7U6ACMB.cjs} +2 -2
|
@@ -36,11 +36,12 @@ function _optionalChain(ops) {
|
|
|
36
36
|
}
|
|
37
37
|
return value;
|
|
38
38
|
}
|
|
39
|
-
var
|
|
40
|
-
var
|
|
39
|
+
var _chunkB4W2XNBPcjs = require('./chunk-B4W2XNBP.cjs');
|
|
40
|
+
var _chunkIG4Q3WQOcjs = require('./chunk-IG4Q3WQO.cjs');
|
|
41
|
+
var _chunkEJQCQPETcjs = require('./chunk-EJQCQPET.cjs');
|
|
41
42
|
var _chunkYXVKQMCKcjs = require('./chunk-YXVKQMCK.cjs');
|
|
42
|
-
var _chunk57SJ4LJFcjs = require('./chunk-57SJ4LJF.cjs');
|
|
43
43
|
var _chunkHUZ4AUM2cjs = require('./chunk-HUZ4AUM2.cjs');
|
|
44
|
+
var _chunk57SJ4LJFcjs = require('./chunk-57SJ4LJF.cjs');
|
|
44
45
|
|
|
45
46
|
// src/components/button/button.context.ts
|
|
46
47
|
var [ButtonProvider, useButton] = _chunkHUZ4AUM2cjs.createSlotContext.call(void 0, "Button");
|
|
@@ -55,7 +56,7 @@ function ButtonIcon({
|
|
|
55
56
|
const {
|
|
56
57
|
icon
|
|
57
58
|
} = useButton();
|
|
58
|
-
return /* @__PURE__ */_jsxruntime.jsx.call(void 0,
|
|
59
|
+
return /* @__PURE__ */_jsxruntime.jsx.call(void 0, _chunkB4W2XNBPcjs.Icon, {
|
|
59
60
|
size: _nullishCoalesce(size, () => icon.size),
|
|
60
61
|
color: _nullishCoalesce(color, () => icon.color),
|
|
61
62
|
...rest
|
|
@@ -109,10 +110,10 @@ function ButtonSpinner({
|
|
|
109
110
|
});
|
|
110
111
|
}
|
|
111
112
|
ButtonSpinner.displayName = "XAUI.Button.Spinner";
|
|
112
|
-
const
|
|
113
|
-
code: "function
|
|
114
|
-
location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-
|
|
115
|
-
sourceMap: "{\"version\":3,\"names\":[\"
|
|
113
|
+
const _worklet_11964476235389_init_data = {
|
|
114
|
+
code: "function chunkEWBBDVTMCjs1(){const{angle}=this.__closure;return{transform:[{rotate:angle.value+\"deg\"}]};}",
|
|
115
|
+
location: "/home/runner/work/xaui/xaui/packages/native/dist/chunk-EWBBDVTM.cjs",
|
|
116
|
+
sourceMap: "{\"version\":3,\"names\":[\"chunkEWBBDVTMCjs1\",\"angle\",\"__closure\",\"transform\",\"rotate\",\"value\"],\"sources\":[\"/home/runner/work/xaui/xaui/packages/native/dist/chunk-EWBBDVTM.cjs\"],\"mappings\":\"AAqF6E,SAAAA,iBAAMA,CAAA,QAAAC,KAAA,OAAAC,SAAA,CAE/E,MAAO,CAAEC,SAAS,CAAE,CAAC,CAAEC,MAAM,CAAKH,KAAK,CAACI,KAAK,MAAM,CAAC,CAAE,CAAC,CACzD\",\"ignoreList\":[]}"
|
|
116
117
|
};
|
|
117
118
|
function SpinningRing({
|
|
118
119
|
style
|
|
@@ -125,28 +126,28 @@ function SpinningRing({
|
|
|
125
126
|
}), -1, false);
|
|
126
127
|
return () => _reactnativereanimated.cancelAnimation.call(void 0, angle);
|
|
127
128
|
}, [angle]);
|
|
128
|
-
const animatedStyle = _reactnativereanimated.useAnimatedStyle.call(void 0, function
|
|
129
|
-
|
|
129
|
+
const animatedStyle = _reactnativereanimated.useAnimatedStyle.call(void 0, function chunkEWBBDVTMCjs1Factory({
|
|
130
|
+
_worklet_11964476235389_init_data,
|
|
130
131
|
angle
|
|
131
132
|
}) {
|
|
132
133
|
const _e = [new global.Error(), -2, -27];
|
|
133
|
-
const
|
|
134
|
+
const chunkEWBBDVTMCjs1 = function () {
|
|
134
135
|
return {
|
|
135
136
|
transform: [{
|
|
136
137
|
rotate: `${angle.value}deg`
|
|
137
138
|
}]
|
|
138
139
|
};
|
|
139
140
|
};
|
|
140
|
-
|
|
141
|
+
chunkEWBBDVTMCjs1.__closure = {
|
|
141
142
|
angle
|
|
142
143
|
};
|
|
143
|
-
|
|
144
|
-
|
|
145
|
-
|
|
146
|
-
|
|
147
|
-
return
|
|
144
|
+
chunkEWBBDVTMCjs1.__workletHash = 11964476235389;
|
|
145
|
+
chunkEWBBDVTMCjs1.__pluginVersion = "0.7.4";
|
|
146
|
+
chunkEWBBDVTMCjs1.__initData = _worklet_11964476235389_init_data;
|
|
147
|
+
chunkEWBBDVTMCjs1.__stackDetails = _e;
|
|
148
|
+
return chunkEWBBDVTMCjs1;
|
|
148
149
|
}({
|
|
149
|
-
|
|
150
|
+
_worklet_11964476235389_init_data,
|
|
150
151
|
angle
|
|
151
152
|
}), [angle]);
|
|
152
153
|
return /* @__PURE__ */_jsxruntime.jsx.call(void 0, _reactnativereanimated2.default.View, {
|
|
@@ -369,7 +370,7 @@ var ButtonRoot = _react.forwardRef.call(void 0, function Button({
|
|
|
369
370
|
}, ref) {
|
|
370
371
|
const theme = _chunk57SJ4LJFcjs.useXAUITheme.call(void 0);
|
|
371
372
|
const [styleProps, rest] = _chunkHUZ4AUM2cjs.useStyleProps.call(void 0, props);
|
|
372
|
-
const [isPressed, press] =
|
|
373
|
+
const [isPressed, press] = _chunkIG4Q3WQOcjs.usePressState.call(void 0, {
|
|
373
374
|
onPressIn,
|
|
374
375
|
onPressOut
|
|
375
376
|
});
|
|
@@ -415,11 +416,11 @@ var ButtonRoot = _react.forwardRef.call(void 0, function Button({
|
|
|
415
416
|
const text = _chunkHUZ4AUM2cjs.childrenToString.call(void 0, children);
|
|
416
417
|
const showSpinner = isLoading && !containsElementOfType(children, ButtonSpinner);
|
|
417
418
|
if (isIconOnly && !rest.accessibilityLabel && !rest["aria-label"]) {
|
|
418
|
-
|
|
419
|
+
_chunkEJQCQPETcjs.warnDev.call(void 0, "Button: an icon-only button needs an `accessibilityLabel` \u2014 there is no text for a screen reader to read, so it announces as an unlabelled button.");
|
|
419
420
|
}
|
|
420
421
|
return /* @__PURE__ */_jsxruntime.jsx.call(void 0, ButtonProvider, {
|
|
421
422
|
value: context,
|
|
422
|
-
children: /* @__PURE__ */_jsxruntime.jsx.call(void 0,
|
|
423
|
+
children: /* @__PURE__ */_jsxruntime.jsx.call(void 0, _chunkIG4Q3WQOcjs.PressableFeedback, {
|
|
423
424
|
ref,
|
|
424
425
|
isPressed,
|
|
425
426
|
isDisabled: isDisabled || isLoading,
|
|
@@ -0,0 +1,72 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
|
|
2
|
+
|
|
3
|
+
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
|
|
8
|
+
var _chunkYEW5LPWLcjs = require('./chunk-YEW5LPWL.cjs');
|
|
9
|
+
|
|
10
|
+
|
|
11
|
+
|
|
12
|
+
var _chunkHUZ4AUM2cjs = require('./chunk-HUZ4AUM2.cjs');
|
|
13
|
+
|
|
14
|
+
// src/components/text-area/text-area-field.tsx
|
|
15
|
+
var _react = require('react');
|
|
16
|
+
|
|
17
|
+
// src/components/text-area/text-area.context.ts
|
|
18
|
+
var [TextAreaProvider, useTextArea] = _chunkHUZ4AUM2cjs.createSlotContext.call(void 0, "TextArea");
|
|
19
|
+
|
|
20
|
+
// src/components/text-area/text-area-field.tsx
|
|
21
|
+
var _jsxruntime = require('react/jsx-runtime');
|
|
22
|
+
var TextAreaField = _react.forwardRef.call(void 0,
|
|
23
|
+
function TextAreaField2({ style, scrollEnabled, ...props }, ref) {
|
|
24
|
+
const { textAreaStyle, textArea } = _chunkYEW5LPWLcjs.useInput.call(void 0, );
|
|
25
|
+
const { rows, maxRows } = useTextArea();
|
|
26
|
+
const [styleProps, rest] = _chunkHUZ4AUM2cjs.useStyleProps.call(void 0, props);
|
|
27
|
+
const height = _react.useMemo.call(void 0, () => {
|
|
28
|
+
const chrome = textArea.paddingVertical * 2;
|
|
29
|
+
return {
|
|
30
|
+
minHeight: rows * textArea.lineHeight + chrome,
|
|
31
|
+
// Unset, the field grows for as long as the text does. With a ceiling it stops
|
|
32
|
+
// there and scrolls, which is the only case that needs `scrollEnabled` — a
|
|
33
|
+
// multiline field that can grow has nothing to scroll.
|
|
34
|
+
maxHeight: maxRows ? maxRows * textArea.lineHeight + chrome : void 0
|
|
35
|
+
};
|
|
36
|
+
}, [rows, maxRows, textArea]);
|
|
37
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0,
|
|
38
|
+
_chunkYEW5LPWLcjs.InputField,
|
|
39
|
+
{
|
|
40
|
+
ref,
|
|
41
|
+
multiline: true,
|
|
42
|
+
scrollEnabled: _nullishCoalesce(scrollEnabled, () => ( maxRows !== void 0)),
|
|
43
|
+
...rest,
|
|
44
|
+
style: [textAreaStyle, height, styleProps, style]
|
|
45
|
+
}
|
|
46
|
+
);
|
|
47
|
+
}
|
|
48
|
+
);
|
|
49
|
+
TextAreaField.displayName = "XAUI.TextArea.Field";
|
|
50
|
+
|
|
51
|
+
// src/components/text-area/text-area.tsx
|
|
52
|
+
|
|
53
|
+
|
|
54
|
+
var DEFAULT_ROWS = 3;
|
|
55
|
+
var TextAreaRoot = _react.forwardRef.call(void 0, function TextArea({ rows = DEFAULT_ROWS, maxRows, children, ...props }, ref) {
|
|
56
|
+
const context = _react.useMemo.call(void 0, () => ({ rows, maxRows }), [rows, maxRows]);
|
|
57
|
+
return /* @__PURE__ */ _jsxruntime.jsx.call(void 0, TextAreaProvider, { value: context, children: /* @__PURE__ */ _jsxruntime.jsx.call(void 0, _chunkYEW5LPWLcjs.InputRoot, { ref, ...props, children }) });
|
|
58
|
+
});
|
|
59
|
+
TextAreaRoot.displayName = "XAUI.TextArea.Root";
|
|
60
|
+
|
|
61
|
+
// src/components/text-area/index.ts
|
|
62
|
+
var TextArea2 = Object.assign(TextAreaRoot, {
|
|
63
|
+
Label: _chunkYEW5LPWLcjs.InputLabel,
|
|
64
|
+
Field: TextAreaField,
|
|
65
|
+
Description: _chunkYEW5LPWLcjs.InputDescription,
|
|
66
|
+
Error: _chunkYEW5LPWLcjs.InputError
|
|
67
|
+
});
|
|
68
|
+
|
|
69
|
+
|
|
70
|
+
|
|
71
|
+
|
|
72
|
+
exports.useTextArea = useTextArea; exports.TextArea = TextArea2;
|