tamagui 1.93.2 → 1.94.0
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/native.js +27 -90
- package/dist/native.js.map +2 -2
- package/dist/test.native.js +27 -90
- package/dist/test.native.js.map +2 -2
- package/package.json +54 -54
- package/types/views/Input.d.ts +4 -4
package/dist/test.native.js
CHANGED
|
@@ -4903,57 +4903,7 @@ var require_accessibilityDirectMap_native = __commonJS({
|
|
|
4903
4903
|
}
|
|
4904
4904
|
});
|
|
4905
4905
|
module2.exports = __toCommonJS2(accessibilityDirectMap_native_exports);
|
|
4906
|
-
var accessibilityDirectMap = {}, webToNativeAccessibilityDirectMap = {
|
|
4907
|
-
"aria-label": "accessibilityLabel",
|
|
4908
|
-
"aria-labelledby": "accessibilityLabelledBy",
|
|
4909
|
-
"aria-live": "accessibilityLiveRegion",
|
|
4910
|
-
"aria-modal": "accessibilityViewIsModal",
|
|
4911
|
-
"aria-hidden": "accessibilityElementsHidden"
|
|
4912
|
-
}, nativeAccessibilityValue = {
|
|
4913
|
-
"aria-valuemin": "min",
|
|
4914
|
-
"aria-valuemax": "max",
|
|
4915
|
-
"aria-valuenow": "now",
|
|
4916
|
-
"aria-valuetext": "text"
|
|
4917
|
-
}, nativeAccessibilityState = {
|
|
4918
|
-
"aria-disabled": "disabled",
|
|
4919
|
-
"aria-selected": "selected",
|
|
4920
|
-
"aria-checked": "checked",
|
|
4921
|
-
"aria-busy": "busy",
|
|
4922
|
-
"aria-expanded": "expanded"
|
|
4923
|
-
}, accessibilityWebRoleToNativeRole = {
|
|
4924
|
-
alert: "alert",
|
|
4925
|
-
button: "button",
|
|
4926
|
-
checkbox: "checkbox",
|
|
4927
|
-
combobox: "combobox",
|
|
4928
|
-
grid: "grid",
|
|
4929
|
-
group: "none",
|
|
4930
|
-
heading: "header",
|
|
4931
|
-
imagebutton: "imagebutton",
|
|
4932
|
-
img: "image",
|
|
4933
|
-
keyboardkey: "keyboardkey",
|
|
4934
|
-
link: "link",
|
|
4935
|
-
menu: "menu",
|
|
4936
|
-
menubar: "menubar",
|
|
4937
|
-
menuitem: "menuitem",
|
|
4938
|
-
none: "none",
|
|
4939
|
-
presentation: "none",
|
|
4940
|
-
progressbar: "progressbar",
|
|
4941
|
-
radio: "radio",
|
|
4942
|
-
radiogroup: "radiogroup",
|
|
4943
|
-
region: "summary",
|
|
4944
|
-
scrollbar: "scrollbar",
|
|
4945
|
-
searchbox: "search",
|
|
4946
|
-
slider: "adjustable",
|
|
4947
|
-
spinbutton: "spinbutton",
|
|
4948
|
-
summary: "summary",
|
|
4949
|
-
switch: "switch",
|
|
4950
|
-
tab: "tab",
|
|
4951
|
-
tablist: "tablist",
|
|
4952
|
-
text: "text",
|
|
4953
|
-
timer: "timer",
|
|
4954
|
-
togglebutton: "togglebutton",
|
|
4955
|
-
toolbar: "toolbar"
|
|
4956
|
-
};
|
|
4906
|
+
var accessibilityDirectMap = {}, webToNativeAccessibilityDirectMap = {}, nativeAccessibilityValue = {}, nativeAccessibilityState = {}, accessibilityWebRoleToNativeRole = {};
|
|
4957
4907
|
}
|
|
4958
4908
|
});
|
|
4959
4909
|
|
|
@@ -7367,24 +7317,7 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7367
7317
|
continue;
|
|
7368
7318
|
if (keyInit === "userSelect")
|
|
7369
7319
|
keyInit = "selectable", valInit = valInit !== "none";
|
|
7370
|
-
else if (keyInit
|
|
7371
|
-
viewProps.accessibilityRole = import_accessibilityDirectMap.accessibilityWebRoleToNativeRole[valInit];
|
|
7372
|
-
continue;
|
|
7373
|
-
} else if (keyInit.startsWith("aria-")) {
|
|
7374
|
-
if (import_accessibilityDirectMap.webToNativeAccessibilityDirectMap[keyInit]) {
|
|
7375
|
-
var nativeA11yProp = import_accessibilityDirectMap.webToNativeAccessibilityDirectMap[keyInit];
|
|
7376
|
-
keyInit === "aria-hidden" && (viewProps["aria-hidden"] = valInit), viewProps[nativeA11yProp] = valInit;
|
|
7377
|
-
continue;
|
|
7378
|
-
}
|
|
7379
|
-
if (import_accessibilityDirectMap.nativeAccessibilityValue[keyInit]) {
|
|
7380
|
-
var field = import_accessibilityDirectMap.nativeAccessibilityValue[keyInit];
|
|
7381
|
-
viewProps.accessibilityValue ? viewProps.accessibilityValue[field] = valInit : viewProps.accessibilityValue = _define_property9({}, field, valInit);
|
|
7382
|
-
} else if (import_accessibilityDirectMap.nativeAccessibilityState[keyInit]) {
|
|
7383
|
-
var field1 = import_accessibilityDirectMap.nativeAccessibilityState[keyInit];
|
|
7384
|
-
viewProps.accessibilityState ? viewProps.accessibilityState[field1] = valInit : viewProps.accessibilityState = _define_property9({}, field1, valInit);
|
|
7385
|
-
}
|
|
7386
|
-
continue;
|
|
7387
|
-
} else if (keyInit.startsWith("data-"))
|
|
7320
|
+
else if (keyInit.startsWith("data-"))
|
|
7388
7321
|
continue;
|
|
7389
7322
|
}
|
|
7390
7323
|
if (keyInit === "dataSet") {
|
|
@@ -7394,7 +7327,12 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7394
7327
|
}
|
|
7395
7328
|
if (0)
|
|
7396
7329
|
var didUseKeyInit;
|
|
7397
|
-
var isShorthand = keyInit in shorthands, isVariant = !isValidStyleKeyInit && variants && keyInit in variants, isStyleLikeKey = isShorthand || isValidStyleKeyInit || isVariant, isPseudo = keyInit in import_helpers.validPseudoKeys, isMedia = !isStyleLikeKey && !isPseudo && (0, import_useMedia.isMediaKey)(keyInit), isMediaOrPseudo1 = !!(isMedia || isPseudo)
|
|
7330
|
+
var isShorthand = keyInit in shorthands, isVariant = !isValidStyleKeyInit && variants && keyInit in variants, isStyleLikeKey = isShorthand || isValidStyleKeyInit || isVariant, isPseudo = keyInit in import_helpers.validPseudoKeys, isMedia = !isStyleLikeKey && !isPseudo && (0, import_useMedia.isMediaKey)(keyInit), isMediaOrPseudo1 = !!(isMedia || isPseudo);
|
|
7331
|
+
if (isMediaOrPseudo1 && keyInit.startsWith("$group-")) {
|
|
7332
|
+
var name = keyInit.split("-")[1];
|
|
7333
|
+
context != null && context.groups.subscribe && !(context != null && context.groups.state[name]) && (keyInit = keyInit.replace("$group-", "$group-true-"));
|
|
7334
|
+
}
|
|
7335
|
+
var isStyleProp = isValidStyleKeyInit || isMediaOrPseudo1 || isVariant && !styleProps.noExpand || isShorthand;
|
|
7398
7336
|
if (!(isStyleProp && (props.asChild === "except-style" || props.asChild === "except-style-web"))) {
|
|
7399
7337
|
var shouldPassProp = !isStyleProp || // is in parent variants
|
|
7400
7338
|
isHOC && (parentStaticConfig == null ? void 0 : parentStaticConfig.variants) && keyInit in parentStaticConfig.variants || (inlineProps == null ? void 0 : inlineProps.has(keyInit)), parentVariant = parentStaticConfig == null || (_parentStaticConfig_variants = parentStaticConfig.variants) === null || _parentStaticConfig_variants === void 0 ? void 0 : _parentStaticConfig_variants[keyInit], isHOCShouldPassThrough = !!(isHOC && (isShorthand || isValidStyleKeyInit || isMediaOrPseudo1 || parentVariant || keyInit in import_skipProps.skipProps)), shouldPassThrough = shouldPassProp || isHOCShouldPassThrough;
|
|
@@ -7681,7 +7619,7 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7681
7619
|
var cnStyles, _iteratorNormalCompletion3, _didIteratorError3, _iteratorError3;
|
|
7682
7620
|
try {
|
|
7683
7621
|
for (var _iterator3, _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = !0)
|
|
7684
|
-
var
|
|
7622
|
+
var name1;
|
|
7685
7623
|
} catch (err) {
|
|
7686
7624
|
} finally {
|
|
7687
7625
|
try {
|
|
@@ -8905,7 +8843,7 @@ var require_createComponent_native = __commonJS({
|
|
|
8905
8843
|
pseudoGroups ? Object.keys(_to_consumable_array2(pseudoGroups)).join("") : 0,
|
|
8906
8844
|
mediaGroups ? Object.keys(_to_consumable_array2(mediaGroups)).join("") : 0
|
|
8907
8845
|
]);
|
|
8908
|
-
var runtimePressStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.pressStyle), runtimeFocusStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.focusStyle), runtimeFocusVisibleStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.focusVisibleStyle), attachFocus = !!(runtimePressStyle || runtimeFocusStyle || runtimeFocusVisibleStyle || onFocus || onBlur), attachPress = !!(groupName || runtimePressStyle || onPress || onPressOut || onPressIn || onMouseDown || onMouseUp || onLongPress || onClick || pseudos != null && pseudos.focusVisibleStyle), runtimeHoverStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.hoverStyle), needsHoverState = !!(groupName || runtimeHoverStyle || onHoverIn || onHoverOut), attachHover = import_constants4.isWeb && !!(groupName || needsHoverState || onMouseEnter || onMouseLeave), shouldAttach = !disabled && !props.asChild && !!(attachFocus || attachPress || attachHover || runtimePressStyle || runtimeHoverStyle || runtimeFocusStyle), needsPressState = !!(groupName ||
|
|
8846
|
+
var runtimePressStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.pressStyle), runtimeFocusStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.focusStyle), runtimeFocusVisibleStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.focusVisibleStyle), attachFocus = !!(runtimePressStyle || runtimeFocusStyle || runtimeFocusVisibleStyle || onFocus || onBlur), attachPress = !!(groupName || runtimePressStyle || onPress || onPressOut || onPressIn || onMouseDown || onMouseUp || onLongPress || onClick || pseudos != null && pseudos.focusVisibleStyle), runtimeHoverStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.hoverStyle), needsHoverState = !!(groupName || runtimeHoverStyle || onHoverIn || onHoverOut), attachHover = import_constants4.isWeb && !!(groupName || needsHoverState || onMouseEnter || onMouseLeave), shouldAttach = !disabled && !props.asChild && !!(attachFocus || attachPress || attachHover || runtimePressStyle || runtimeHoverStyle || runtimeFocusStyle), needsPressState = !!(groupName || runtimePressStyle), events = shouldAttach ? _object_spread9(_object_spread_props8(_object_spread9({
|
|
8909
8847
|
onPressOut: attachPress ? function(e) {
|
|
8910
8848
|
unPress(), onPressOut == null || onPressOut(e), onMouseUp == null || onMouseUp(e);
|
|
8911
8849
|
} : void 0
|
|
@@ -9216,7 +9154,7 @@ var require_createComponent_native = __commonJS({
|
|
|
9216
9154
|
group
|
|
9217
9155
|
});
|
|
9218
9156
|
};
|
|
9219
|
-
if (pseudo && pseudoGroups != null && pseudoGroups.has(name))
|
|
9157
|
+
if (pseudo && pseudoGroups != null && pseudoGroups.has(String(name)))
|
|
9220
9158
|
Object.assign(current.pseudo, pseudo), persist();
|
|
9221
9159
|
else if (layout && mediaGroups) {
|
|
9222
9160
|
var mediaState3 = getMediaState(mediaGroups, layout), next = (0, import_createShallowSetState.mergeIfNotShallowEqual)(current.media, mediaState3);
|
|
@@ -15812,29 +15750,28 @@ var require_SizableText_native = __commonJS({
|
|
|
15812
15750
|
}
|
|
15813
15751
|
});
|
|
15814
15752
|
module2.exports = __toCommonJS2(SizableText_exports);
|
|
15815
|
-
var import_get_font_sized2 = require_index_native21(), import_web = require_index_native13(),
|
|
15816
|
-
unstyled: {
|
|
15817
|
-
false: {
|
|
15818
|
-
size: "$true",
|
|
15819
|
-
color: "$color"
|
|
15820
|
-
}
|
|
15821
|
-
},
|
|
15822
|
-
size: import_get_font_sized2.getFontSized
|
|
15823
|
-
};
|
|
15824
|
-
variants.fontFamily = {
|
|
15825
|
-
"...": function(_, extras) {
|
|
15826
|
-
var size3 = extras.props.size || "$true";
|
|
15827
|
-
return (0, import_get_font_sized2.getFontSized)(size3, extras);
|
|
15828
|
-
}
|
|
15829
|
-
};
|
|
15830
|
-
var SizableText2 = (0, import_web.styled)(import_web.Text, {
|
|
15753
|
+
var import_get_font_sized2 = require_index_native21(), import_web = require_index_native13(), SizableText2 = (0, import_web.styled)(import_web.Text, {
|
|
15831
15754
|
name: "SizableText",
|
|
15832
15755
|
fontFamily: "$body",
|
|
15833
|
-
variants
|
|
15756
|
+
variants: {
|
|
15757
|
+
unstyled: {
|
|
15758
|
+
false: {
|
|
15759
|
+
size: "$true",
|
|
15760
|
+
color: "$color"
|
|
15761
|
+
}
|
|
15762
|
+
},
|
|
15763
|
+
size: import_get_font_sized2.getFontSized
|
|
15764
|
+
},
|
|
15834
15765
|
defaultVariants: {
|
|
15835
15766
|
unstyled: process.env.TAMAGUI_HEADLESS === "1"
|
|
15836
15767
|
}
|
|
15837
15768
|
});
|
|
15769
|
+
SizableText2.staticConfig.variants.fontFamily = {
|
|
15770
|
+
"...": function(_, extras) {
|
|
15771
|
+
var size3 = extras.props.size || "$true";
|
|
15772
|
+
return (0, import_get_font_sized2.getFontSized)(size3, extras);
|
|
15773
|
+
}
|
|
15774
|
+
};
|
|
15838
15775
|
}
|
|
15839
15776
|
});
|
|
15840
15777
|
|