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/native.js
CHANGED
|
@@ -5264,57 +5264,7 @@ var require_accessibilityDirectMap_native = __commonJS({
|
|
|
5264
5264
|
}
|
|
5265
5265
|
});
|
|
5266
5266
|
module2.exports = __toCommonJS2(accessibilityDirectMap_native_exports);
|
|
5267
|
-
var accessibilityDirectMap = {}, webToNativeAccessibilityDirectMap = {
|
|
5268
|
-
"aria-label": "accessibilityLabel",
|
|
5269
|
-
"aria-labelledby": "accessibilityLabelledBy",
|
|
5270
|
-
"aria-live": "accessibilityLiveRegion",
|
|
5271
|
-
"aria-modal": "accessibilityViewIsModal",
|
|
5272
|
-
"aria-hidden": "accessibilityElementsHidden"
|
|
5273
|
-
}, nativeAccessibilityValue = {
|
|
5274
|
-
"aria-valuemin": "min",
|
|
5275
|
-
"aria-valuemax": "max",
|
|
5276
|
-
"aria-valuenow": "now",
|
|
5277
|
-
"aria-valuetext": "text"
|
|
5278
|
-
}, nativeAccessibilityState = {
|
|
5279
|
-
"aria-disabled": "disabled",
|
|
5280
|
-
"aria-selected": "selected",
|
|
5281
|
-
"aria-checked": "checked",
|
|
5282
|
-
"aria-busy": "busy",
|
|
5283
|
-
"aria-expanded": "expanded"
|
|
5284
|
-
}, accessibilityWebRoleToNativeRole = {
|
|
5285
|
-
alert: "alert",
|
|
5286
|
-
button: "button",
|
|
5287
|
-
checkbox: "checkbox",
|
|
5288
|
-
combobox: "combobox",
|
|
5289
|
-
grid: "grid",
|
|
5290
|
-
group: "none",
|
|
5291
|
-
heading: "header",
|
|
5292
|
-
imagebutton: "imagebutton",
|
|
5293
|
-
img: "image",
|
|
5294
|
-
keyboardkey: "keyboardkey",
|
|
5295
|
-
link: "link",
|
|
5296
|
-
menu: "menu",
|
|
5297
|
-
menubar: "menubar",
|
|
5298
|
-
menuitem: "menuitem",
|
|
5299
|
-
none: "none",
|
|
5300
|
-
presentation: "none",
|
|
5301
|
-
progressbar: "progressbar",
|
|
5302
|
-
radio: "radio",
|
|
5303
|
-
radiogroup: "radiogroup",
|
|
5304
|
-
region: "summary",
|
|
5305
|
-
scrollbar: "scrollbar",
|
|
5306
|
-
searchbox: "search",
|
|
5307
|
-
slider: "adjustable",
|
|
5308
|
-
spinbutton: "spinbutton",
|
|
5309
|
-
summary: "summary",
|
|
5310
|
-
switch: "switch",
|
|
5311
|
-
tab: "tab",
|
|
5312
|
-
tablist: "tablist",
|
|
5313
|
-
text: "text",
|
|
5314
|
-
timer: "timer",
|
|
5315
|
-
togglebutton: "togglebutton",
|
|
5316
|
-
toolbar: "toolbar"
|
|
5317
|
-
};
|
|
5267
|
+
var accessibilityDirectMap = {}, webToNativeAccessibilityDirectMap = {}, nativeAccessibilityValue = {}, nativeAccessibilityState = {}, accessibilityWebRoleToNativeRole = {};
|
|
5318
5268
|
}
|
|
5319
5269
|
});
|
|
5320
5270
|
|
|
@@ -7785,24 +7735,7 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7785
7735
|
continue;
|
|
7786
7736
|
if (keyInit === "userSelect")
|
|
7787
7737
|
keyInit = "selectable", valInit = valInit !== "none";
|
|
7788
|
-
else if (keyInit
|
|
7789
|
-
viewProps.accessibilityRole = import_accessibilityDirectMap.accessibilityWebRoleToNativeRole[valInit];
|
|
7790
|
-
continue;
|
|
7791
|
-
} else if (keyInit.startsWith("aria-")) {
|
|
7792
|
-
if (import_accessibilityDirectMap.webToNativeAccessibilityDirectMap[keyInit]) {
|
|
7793
|
-
var nativeA11yProp = import_accessibilityDirectMap.webToNativeAccessibilityDirectMap[keyInit];
|
|
7794
|
-
keyInit === "aria-hidden" && (viewProps["aria-hidden"] = valInit), viewProps[nativeA11yProp] = valInit;
|
|
7795
|
-
continue;
|
|
7796
|
-
}
|
|
7797
|
-
if (import_accessibilityDirectMap.nativeAccessibilityValue[keyInit]) {
|
|
7798
|
-
var field = import_accessibilityDirectMap.nativeAccessibilityValue[keyInit];
|
|
7799
|
-
viewProps.accessibilityValue ? viewProps.accessibilityValue[field] = valInit : viewProps.accessibilityValue = _define_property9({}, field, valInit);
|
|
7800
|
-
} else if (import_accessibilityDirectMap.nativeAccessibilityState[keyInit]) {
|
|
7801
|
-
var field1 = import_accessibilityDirectMap.nativeAccessibilityState[keyInit];
|
|
7802
|
-
viewProps.accessibilityState ? viewProps.accessibilityState[field1] = valInit : viewProps.accessibilityState = _define_property9({}, field1, valInit);
|
|
7803
|
-
}
|
|
7804
|
-
continue;
|
|
7805
|
-
} else if (keyInit.startsWith("data-"))
|
|
7738
|
+
else if (keyInit.startsWith("data-"))
|
|
7806
7739
|
continue;
|
|
7807
7740
|
}
|
|
7808
7741
|
if (keyInit === "dataSet") {
|
|
@@ -7812,7 +7745,12 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7812
7745
|
}
|
|
7813
7746
|
if (0)
|
|
7814
7747
|
var didUseKeyInit;
|
|
7815
|
-
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)
|
|
7748
|
+
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);
|
|
7749
|
+
if (isMediaOrPseudo1 && keyInit.startsWith("$group-")) {
|
|
7750
|
+
var name = keyInit.split("-")[1];
|
|
7751
|
+
context != null && context.groups.subscribe && !(context != null && context.groups.state[name]) && (keyInit = keyInit.replace("$group-", "$group-true-"));
|
|
7752
|
+
}
|
|
7753
|
+
var isStyleProp = isValidStyleKeyInit || isMediaOrPseudo1 || isVariant && !styleProps.noExpand || isShorthand;
|
|
7816
7754
|
if (!(isStyleProp && (props.asChild === "except-style" || props.asChild === "except-style-web"))) {
|
|
7817
7755
|
var shouldPassProp = !isStyleProp || // is in parent variants
|
|
7818
7756
|
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;
|
|
@@ -8171,7 +8109,7 @@ current`, _object_spread9({}, styleState.style)));
|
|
|
8171
8109
|
var cnStyles, _iteratorNormalCompletion3, _didIteratorError3, _iteratorError3;
|
|
8172
8110
|
try {
|
|
8173
8111
|
for (var _iterator3, _step3; !(_iteratorNormalCompletion3 = (_step3 = _iterator3.next()).done); _iteratorNormalCompletion3 = !0)
|
|
8174
|
-
var
|
|
8112
|
+
var name1;
|
|
8175
8113
|
} catch (err) {
|
|
8176
8114
|
} finally {
|
|
8177
8115
|
try {
|
|
@@ -9677,7 +9615,7 @@ If you meant to do this, you can disable this warning - either change untilMeasu
|
|
|
9677
9615
|
pseudoGroups ? Object.keys(_to_consumable_array2(pseudoGroups)).join("") : 0,
|
|
9678
9616
|
mediaGroups ? Object.keys(_to_consumable_array2(mediaGroups)).join("") : 0
|
|
9679
9617
|
]);
|
|
9680
|
-
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 ||
|
|
9618
|
+
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);
|
|
9681
9619
|
process.env.NODE_ENV === "development" && time && time(_templateObject14());
|
|
9682
9620
|
var events = shouldAttach ? _object_spread9(_object_spread_props8(_object_spread9({
|
|
9683
9621
|
onPressOut: attachPress ? function(e) {
|
|
@@ -10036,7 +9974,7 @@ If you meant to do this, you can disable this warning - either change untilMeasu
|
|
|
10036
9974
|
group
|
|
10037
9975
|
});
|
|
10038
9976
|
};
|
|
10039
|
-
if (pseudo && pseudoGroups != null && pseudoGroups.has(name))
|
|
9977
|
+
if (pseudo && pseudoGroups != null && pseudoGroups.has(String(name)))
|
|
10040
9978
|
Object.assign(current.pseudo, pseudo), persist();
|
|
10041
9979
|
else if (layout && mediaGroups) {
|
|
10042
9980
|
var mediaState3 = getMediaState(mediaGroups, layout), next = (0, import_createShallowSetState.mergeIfNotShallowEqual)(current.media, mediaState3);
|
|
@@ -16676,29 +16614,28 @@ var require_SizableText_native = __commonJS({
|
|
|
16676
16614
|
}
|
|
16677
16615
|
});
|
|
16678
16616
|
module2.exports = __toCommonJS2(SizableText_exports);
|
|
16679
|
-
var import_get_font_sized2 = require_index_native21(), import_web = require_index_native13(),
|
|
16680
|
-
unstyled: {
|
|
16681
|
-
false: {
|
|
16682
|
-
size: "$true",
|
|
16683
|
-
color: "$color"
|
|
16684
|
-
}
|
|
16685
|
-
},
|
|
16686
|
-
size: import_get_font_sized2.getFontSized
|
|
16687
|
-
};
|
|
16688
|
-
variants.fontFamily = {
|
|
16689
|
-
"...": function(_, extras) {
|
|
16690
|
-
var size3 = extras.props.size || "$true";
|
|
16691
|
-
return (0, import_get_font_sized2.getFontSized)(size3, extras);
|
|
16692
|
-
}
|
|
16693
|
-
};
|
|
16694
|
-
var SizableText2 = (0, import_web.styled)(import_web.Text, {
|
|
16617
|
+
var import_get_font_sized2 = require_index_native21(), import_web = require_index_native13(), SizableText2 = (0, import_web.styled)(import_web.Text, {
|
|
16695
16618
|
name: "SizableText",
|
|
16696
16619
|
fontFamily: "$body",
|
|
16697
|
-
variants
|
|
16620
|
+
variants: {
|
|
16621
|
+
unstyled: {
|
|
16622
|
+
false: {
|
|
16623
|
+
size: "$true",
|
|
16624
|
+
color: "$color"
|
|
16625
|
+
}
|
|
16626
|
+
},
|
|
16627
|
+
size: import_get_font_sized2.getFontSized
|
|
16628
|
+
},
|
|
16698
16629
|
defaultVariants: {
|
|
16699
16630
|
unstyled: process.env.TAMAGUI_HEADLESS === "1"
|
|
16700
16631
|
}
|
|
16701
16632
|
});
|
|
16633
|
+
SizableText2.staticConfig.variants.fontFamily = {
|
|
16634
|
+
"...": function(_, extras) {
|
|
16635
|
+
var size3 = extras.props.size || "$true";
|
|
16636
|
+
return (0, import_get_font_sized2.getFontSized)(size3, extras);
|
|
16637
|
+
}
|
|
16638
|
+
};
|
|
16702
16639
|
}
|
|
16703
16640
|
});
|
|
16704
16641
|
|