@tamagui/core 1.89.28 → 1.89.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/cjs/createOptimizedView.native.js +4 -1
- package/dist/cjs/createOptimizedView.native.js.map +1 -1
- package/dist/cjs/index.native.js +39 -36
- package/dist/cjs/index.native.js.map +1 -1
- package/dist/esm/createOptimizedView.native.js +4 -1
- package/dist/esm/createOptimizedView.native.js.map +1 -1
- package/dist/esm/index.native.js +39 -36
- package/dist/esm/index.native.js.map +1 -1
- package/dist/native.js +310 -215
- package/dist/native.js.map +2 -2
- package/dist/test.native.js +295 -203
- package/dist/test.native.js.map +2 -2
- package/package.json +6 -6
package/dist/native.js
CHANGED
|
@@ -531,6 +531,7 @@ var require_ResponderTouchHistoryStore_native = __commonJS({
|
|
|
531
531
|
function ResponderTouchHistoryStore2() {
|
|
532
532
|
_class_call_check(this, ResponderTouchHistoryStore2), _define_property2(this, "_touchHistory", {
|
|
533
533
|
touchBank: [],
|
|
534
|
+
//Array<TouchRecord>
|
|
534
535
|
numberActiveTouches: 0,
|
|
535
536
|
// If there is only one active touch, we remember its location. This prevents
|
|
536
537
|
// us having to loop through all of the touches all the time in the most
|
|
@@ -744,7 +745,8 @@ var require_ResponderSystem_native = __commonJS({
|
|
|
744
745
|
}
|
|
745
746
|
function eventListener(domEvent) {
|
|
746
747
|
var eventType = domEvent.type, eventTarget = domEvent.target;
|
|
747
|
-
if (eventType === "touchstart" && (isEmulatingMouseEvents = !0), (eventType === "touchmove" || trackedTouchCount > 1) && (isEmulatingMouseEvents = !1),
|
|
748
|
+
if (eventType === "touchstart" && (isEmulatingMouseEvents = !0), (eventType === "touchmove" || trackedTouchCount > 1) && (isEmulatingMouseEvents = !1), // Ignore browser emulated mouse events
|
|
749
|
+
!(eventType === "mousedown" && isEmulatingMouseEvents || eventType === "mousemove" && isEmulatingMouseEvents || // Ignore mousemove if a mousedown didn't occur first
|
|
748
750
|
eventType === "mousemove" && trackedTouchCount < 1)) {
|
|
749
751
|
if (isEmulatingMouseEvents && eventType === "mouseup") {
|
|
750
752
|
trackedTouchCount === 0 && (isEmulatingMouseEvents = !1);
|
|
@@ -944,27 +946,27 @@ var require_useResponderEvents_native = __commonJS({
|
|
|
944
946
|
}
|
|
945
947
|
});
|
|
946
948
|
module2.exports = __toCommonJS2(useResponderEvents_exports);
|
|
947
|
-
var
|
|
949
|
+
var React = __toESM2(require("react")), ResponderSystem = __toESM2(require_ResponderSystem_native());
|
|
948
950
|
__reExport2(useResponderEvents_exports, require_utils_native(), module2.exports);
|
|
949
951
|
var emptyObject = {};
|
|
950
952
|
function useResponderEvents2(hostRef) {
|
|
951
|
-
var config = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : emptyObject, id =
|
|
952
|
-
|
|
953
|
+
var config = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : emptyObject, id = React.useId(), isAttachedRef = React.useRef(!1);
|
|
954
|
+
React.useEffect(function() {
|
|
953
955
|
return ResponderSystem.attachListeners(), function() {
|
|
954
956
|
ResponderSystem.removeNode(id);
|
|
955
957
|
};
|
|
956
958
|
}, [
|
|
957
959
|
id
|
|
958
|
-
]),
|
|
960
|
+
]), React.useEffect(function() {
|
|
959
961
|
var onMoveShouldSetResponder = config.onMoveShouldSetResponder, onMoveShouldSetResponderCapture = config.onMoveShouldSetResponderCapture, onScrollShouldSetResponder = config.onScrollShouldSetResponder, onScrollShouldSetResponderCapture = config.onScrollShouldSetResponderCapture, onSelectionChangeShouldSetResponder = config.onSelectionChangeShouldSetResponder, onSelectionChangeShouldSetResponderCapture = config.onSelectionChangeShouldSetResponderCapture, onStartShouldSetResponder = config.onStartShouldSetResponder, onStartShouldSetResponderCapture = config.onStartShouldSetResponderCapture, requiresResponderSystem = onMoveShouldSetResponder != null || onMoveShouldSetResponderCapture != null || onScrollShouldSetResponder != null || onScrollShouldSetResponderCapture != null || onSelectionChangeShouldSetResponder != null || onSelectionChangeShouldSetResponderCapture != null || onStartShouldSetResponder != null || onStartShouldSetResponderCapture != null, node = hostRef.current;
|
|
960
962
|
requiresResponderSystem ? (ResponderSystem.addNode(id, node, config), isAttachedRef.current = !0) : isAttachedRef.current && (ResponderSystem.removeNode(id), isAttachedRef.current = !1);
|
|
961
963
|
}, [
|
|
962
964
|
config,
|
|
963
965
|
hostRef,
|
|
964
966
|
id
|
|
965
|
-
]), process.env.NODE_ENV === "development" && (
|
|
967
|
+
]), process.env.NODE_ENV === "development" && (React.useDebugValue({
|
|
966
968
|
isResponder: hostRef.current === ResponderSystem.getResponderNode()
|
|
967
|
-
}),
|
|
969
|
+
}), React.useDebugValue(config));
|
|
968
970
|
}
|
|
969
971
|
}
|
|
970
972
|
});
|
|
@@ -1571,7 +1573,13 @@ var require_shouldRenderNativePlatform_native = __commonJS({
|
|
|
1571
1573
|
return null;
|
|
1572
1574
|
}
|
|
1573
1575
|
function resolvePlatformNames(nativeProp) {
|
|
1574
|
-
var platforms = nativeProp === !0 ?
|
|
1576
|
+
var platforms = nativeProp === !0 ? (
|
|
1577
|
+
// all native platforms
|
|
1578
|
+
ALL_PLATFORMS
|
|
1579
|
+
) : nativeProp === !1 ? (
|
|
1580
|
+
// no native platform
|
|
1581
|
+
[]
|
|
1582
|
+
) : Array.isArray(nativeProp) ? nativeProp : [
|
|
1575
1583
|
nativeProp
|
|
1576
1584
|
], set = new Set(platforms);
|
|
1577
1585
|
return set.has("mobile") && (set.add("android"), set.add("ios"), set.delete("mobile")), set;
|
|
@@ -1779,75 +1787,86 @@ var require_validStyleProps_native = __commonJS({
|
|
|
1779
1787
|
rotateY: !0,
|
|
1780
1788
|
rotateX: !0,
|
|
1781
1789
|
rotateZ: !0
|
|
1782
|
-
}, stylePropsView = _object_spread2(
|
|
1783
|
-
|
|
1784
|
-
|
|
1785
|
-
|
|
1786
|
-
|
|
1787
|
-
|
|
1788
|
-
|
|
1789
|
-
|
|
1790
|
-
|
|
1791
|
-
|
|
1792
|
-
|
|
1793
|
-
|
|
1794
|
-
|
|
1795
|
-
|
|
1796
|
-
|
|
1797
|
-
|
|
1798
|
-
|
|
1799
|
-
|
|
1800
|
-
|
|
1801
|
-
|
|
1802
|
-
|
|
1803
|
-
|
|
1804
|
-
|
|
1805
|
-
|
|
1806
|
-
|
|
1807
|
-
|
|
1808
|
-
|
|
1809
|
-
|
|
1810
|
-
|
|
1811
|
-
|
|
1812
|
-
|
|
1813
|
-
|
|
1814
|
-
|
|
1815
|
-
|
|
1816
|
-
|
|
1817
|
-
|
|
1818
|
-
|
|
1819
|
-
|
|
1820
|
-
|
|
1821
|
-
|
|
1822
|
-
|
|
1823
|
-
|
|
1824
|
-
|
|
1825
|
-
|
|
1826
|
-
|
|
1827
|
-
|
|
1828
|
-
|
|
1829
|
-
|
|
1830
|
-
|
|
1831
|
-
|
|
1832
|
-
|
|
1833
|
-
|
|
1834
|
-
|
|
1835
|
-
|
|
1836
|
-
|
|
1837
|
-
|
|
1838
|
-
|
|
1839
|
-
|
|
1840
|
-
|
|
1841
|
-
|
|
1842
|
-
|
|
1843
|
-
|
|
1844
|
-
|
|
1845
|
-
|
|
1846
|
-
|
|
1847
|
-
|
|
1848
|
-
|
|
1849
|
-
|
|
1850
|
-
|
|
1790
|
+
}, stylePropsView = _object_spread2(
|
|
1791
|
+
{
|
|
1792
|
+
backfaceVisibility: !0,
|
|
1793
|
+
borderBottomEndRadius: !0,
|
|
1794
|
+
borderBottomStartRadius: !0,
|
|
1795
|
+
borderBottomWidth: !0,
|
|
1796
|
+
borderLeftWidth: !0,
|
|
1797
|
+
borderRightWidth: !0,
|
|
1798
|
+
borderStyle: !0,
|
|
1799
|
+
borderTopEndRadius: !0,
|
|
1800
|
+
borderTopStartRadius: !0,
|
|
1801
|
+
borderTopWidth: !0,
|
|
1802
|
+
borderWidth: !0,
|
|
1803
|
+
transform: !0,
|
|
1804
|
+
transformOrigin: !0,
|
|
1805
|
+
alignContent: !0,
|
|
1806
|
+
alignItems: !0,
|
|
1807
|
+
alignSelf: !0,
|
|
1808
|
+
borderEndWidth: !0,
|
|
1809
|
+
borderStartWidth: !0,
|
|
1810
|
+
bottom: !0,
|
|
1811
|
+
display: !0,
|
|
1812
|
+
end: !0,
|
|
1813
|
+
flexBasis: !0,
|
|
1814
|
+
flexDirection: !0,
|
|
1815
|
+
flexWrap: !0,
|
|
1816
|
+
gap: !0,
|
|
1817
|
+
columnGap: !0,
|
|
1818
|
+
rowGap: !0,
|
|
1819
|
+
justifyContent: !0,
|
|
1820
|
+
left: !0,
|
|
1821
|
+
margin: !0,
|
|
1822
|
+
marginBlockEnd: !0,
|
|
1823
|
+
marginBlockStart: !0,
|
|
1824
|
+
marginInlineEnd: !0,
|
|
1825
|
+
marginInline: !0,
|
|
1826
|
+
marginInlineStart: !0,
|
|
1827
|
+
marginBottom: !0,
|
|
1828
|
+
marginEnd: !0,
|
|
1829
|
+
marginHorizontal: !0,
|
|
1830
|
+
marginLeft: !0,
|
|
1831
|
+
marginRight: !0,
|
|
1832
|
+
marginStart: !0,
|
|
1833
|
+
marginTop: !0,
|
|
1834
|
+
marginVertical: !0,
|
|
1835
|
+
overflow: !0,
|
|
1836
|
+
padding: !0,
|
|
1837
|
+
paddingBottom: !0,
|
|
1838
|
+
paddingInline: !0,
|
|
1839
|
+
paddingBlock: !0,
|
|
1840
|
+
paddingBlockStart: !0,
|
|
1841
|
+
paddingInlineEnd: !0,
|
|
1842
|
+
paddingInlineStart: !0,
|
|
1843
|
+
paddingEnd: !0,
|
|
1844
|
+
paddingHorizontal: !0,
|
|
1845
|
+
paddingLeft: !0,
|
|
1846
|
+
paddingRight: !0,
|
|
1847
|
+
paddingStart: !0,
|
|
1848
|
+
paddingTop: !0,
|
|
1849
|
+
paddingVertical: !0,
|
|
1850
|
+
position: !0,
|
|
1851
|
+
right: !0,
|
|
1852
|
+
start: !0,
|
|
1853
|
+
top: !0,
|
|
1854
|
+
direction: !0,
|
|
1855
|
+
shadowOffset: !0,
|
|
1856
|
+
shadowRadius: !0
|
|
1857
|
+
},
|
|
1858
|
+
tokenCategories.color,
|
|
1859
|
+
tokenCategories.radius,
|
|
1860
|
+
tokenCategories.size,
|
|
1861
|
+
tokenCategories.radius,
|
|
1862
|
+
stylePropsTransform,
|
|
1863
|
+
stylePropsUnitless,
|
|
1864
|
+
// allow a few web only ones
|
|
1865
|
+
!1,
|
|
1866
|
+
import_constants.isAndroid ? {
|
|
1867
|
+
elevationAndroid: !0
|
|
1868
|
+
} : {}
|
|
1869
|
+
), stylePropsFont = {
|
|
1851
1870
|
fontFamily: !0,
|
|
1852
1871
|
fontSize: !0,
|
|
1853
1872
|
fontStyle: !0,
|
|
@@ -1855,14 +1874,18 @@ var require_validStyleProps_native = __commonJS({
|
|
|
1855
1874
|
letterSpacing: !0,
|
|
1856
1875
|
lineHeight: !0,
|
|
1857
1876
|
textTransform: !0
|
|
1858
|
-
}, stylePropsTextOnly = _object_spread2(
|
|
1859
|
-
|
|
1860
|
-
|
|
1861
|
-
|
|
1862
|
-
|
|
1863
|
-
|
|
1864
|
-
|
|
1865
|
-
|
|
1877
|
+
}, stylePropsTextOnly = _object_spread2(
|
|
1878
|
+
_object_spread_props(_object_spread2(_object_spread_props(_object_spread2({}, stylePropsFont), {
|
|
1879
|
+
textAlign: !0,
|
|
1880
|
+
textDecorationLine: !0,
|
|
1881
|
+
textDecorationStyle: !0
|
|
1882
|
+
}), textColors), {
|
|
1883
|
+
textShadowOffset: !0,
|
|
1884
|
+
textShadowRadius: !0
|
|
1885
|
+
}),
|
|
1886
|
+
// allow some web only ones
|
|
1887
|
+
!1
|
|
1888
|
+
), stylePropsText = _object_spread2({}, stylePropsView, stylePropsTextOnly), stylePropsAll = stylePropsText, validPseudoKeys = {
|
|
1866
1889
|
enterStyle: !0,
|
|
1867
1890
|
exitStyle: !0,
|
|
1868
1891
|
hoverStyle: !0,
|
|
@@ -2179,7 +2202,12 @@ var require_config_native = __commonJS({
|
|
|
2179
2202
|
tokensMerged = _;
|
|
2180
2203
|
}
|
|
2181
2204
|
var getTokens2 = function() {
|
|
2182
|
-
var prefixed = (arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] :
|
|
2205
|
+
var prefixed = (arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : (
|
|
2206
|
+
/**
|
|
2207
|
+
* Force either with $ or without $ prefix
|
|
2208
|
+
*/
|
|
2209
|
+
{}
|
|
2210
|
+
)).prefixed;
|
|
2183
2211
|
if (process.env.NODE_ENV === "development" && !conf)
|
|
2184
2212
|
throw new Error("Haven't called createTamagui yet");
|
|
2185
2213
|
var tokens = conf.tokens, tokensParsed = conf.tokensParsed;
|
|
@@ -2678,6 +2706,7 @@ var require_insertStyleRule_native = __commonJS({
|
|
|
2678
2706
|
if (collectThemes && (text.startsWith(":root.t_") || text.startsWith(":root .t_")))
|
|
2679
2707
|
return [
|
|
2680
2708
|
text.slice(0, 20),
|
|
2709
|
+
// just used as uid
|
|
2681
2710
|
rule,
|
|
2682
2711
|
!0
|
|
2683
2712
|
];
|
|
@@ -3688,7 +3717,10 @@ var require_ThemeManager_native = __commonJS({
|
|
|
3688
3717
|
return (x == null ? void 0 : x.state.name) || "";
|
|
3689
3718
|
});
|
|
3690
3719
|
isDirectParentAComponentTheme && allComponentThemes.shift();
|
|
3691
|
-
for (var base = baseName.split(import_constants2.THEME_NAME_SEPARATOR), max = base.length, min = props.componentName && !nextName ? max :
|
|
3720
|
+
for (var base = baseName.split(import_constants2.THEME_NAME_SEPARATOR), max = base.length, min = props.componentName && !nextName ? max : (
|
|
3721
|
+
// component name only don't search upwards
|
|
3722
|
+
0
|
|
3723
|
+
), i = max; i >= min; i--) {
|
|
3692
3724
|
var prefix = base.slice(0, i).join(import_constants2.THEME_NAME_SEPARATOR);
|
|
3693
3725
|
props.inverse && (prefix = inverseThemeName(prefix));
|
|
3694
3726
|
var potentials = [];
|
|
@@ -4545,7 +4577,7 @@ var require_compose_refs_native = __commonJS({
|
|
|
4545
4577
|
}
|
|
4546
4578
|
});
|
|
4547
4579
|
module2.exports = __toCommonJS2(compose_refs_exports);
|
|
4548
|
-
var
|
|
4580
|
+
var React = __toESM2(require("react"));
|
|
4549
4581
|
function _array_like_to_array(arr, len) {
|
|
4550
4582
|
(len == null || len > arr.length) && (len = arr.length);
|
|
4551
4583
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
@@ -4592,7 +4624,7 @@ var require_compose_refs_native = __commonJS({
|
|
|
4592
4624
|
function useComposedRefs() {
|
|
4593
4625
|
for (var _len = arguments.length, refs = new Array(_len), _key = 0; _key < _len; _key++)
|
|
4594
4626
|
refs[_key] = arguments[_key];
|
|
4595
|
-
return
|
|
4627
|
+
return React.useCallback(composeRefs.apply(void 0, _to_consumable_array(refs)), refs);
|
|
4596
4628
|
}
|
|
4597
4629
|
}
|
|
4598
4630
|
});
|
|
@@ -4776,7 +4808,7 @@ var require_objectIdentityKey_native = __commonJS({
|
|
|
4776
4808
|
var require_createStyledContext_native = __commonJS({
|
|
4777
4809
|
"../web/dist/cjs/helpers/createStyledContext.native.js"(exports2, module2) {
|
|
4778
4810
|
"use strict";
|
|
4779
|
-
var
|
|
4811
|
+
var __defProp2 = Object.defineProperty, __getOwnPropDesc2 = Object.getOwnPropertyDescriptor, __getOwnPropNames2 = Object.getOwnPropertyNames, __hasOwnProp2 = Object.prototype.hasOwnProperty, __export2 = function(target, all) {
|
|
4780
4812
|
for (var name in all)
|
|
4781
4813
|
__defProp2(target, name, {
|
|
4782
4814
|
get: all[name],
|
|
@@ -4807,18 +4839,6 @@ var require_createStyledContext_native = __commonJS({
|
|
|
4807
4839
|
}
|
|
4808
4840
|
}
|
|
4809
4841
|
return to;
|
|
4810
|
-
}, __toESM2 = function(mod, isNodeMode, target) {
|
|
4811
|
-
return target = mod != null ? __create2(__getProtoOf2(mod)) : {}, __copyProps2(
|
|
4812
|
-
// If the importer is in node compatibility mode or this is not an ESM
|
|
4813
|
-
// file that has been converted to a CommonJS file using a Babel-
|
|
4814
|
-
// compatible transform (i.e. "__esModule" has not been set), then set
|
|
4815
|
-
// "default" to the CommonJS "module.exports" for node compatibility.
|
|
4816
|
-
isNodeMode || !mod || !mod.__esModule ? __defProp2(target, "default", {
|
|
4817
|
-
value: mod,
|
|
4818
|
-
enumerable: !0
|
|
4819
|
-
}) : target,
|
|
4820
|
-
mod
|
|
4821
|
-
);
|
|
4822
4842
|
}, __toCommonJS2 = function(mod) {
|
|
4823
4843
|
return __copyProps2(__defProp2({}, "__esModule", {
|
|
4824
4844
|
value: !0
|
|
@@ -4830,7 +4850,7 @@ var require_createStyledContext_native = __commonJS({
|
|
|
4830
4850
|
}
|
|
4831
4851
|
});
|
|
4832
4852
|
module2.exports = __toCommonJS2(createStyledContext_exports);
|
|
4833
|
-
var import_react3 =
|
|
4853
|
+
var import_jsx_runtime = require("react/jsx-runtime"), import_react3 = require("react"), import_objectIdentityKey = require_objectIdentityKey_native();
|
|
4834
4854
|
function _define_property2(obj, key, value) {
|
|
4835
4855
|
return key in obj ? Object.defineProperty(obj, key, {
|
|
4836
4856
|
value,
|
|
@@ -4875,7 +4895,12 @@ var require_createStyledContext_native = __commonJS({
|
|
|
4875
4895
|
"children",
|
|
4876
4896
|
"scope"
|
|
4877
4897
|
]), next = (0, import_react3.useMemo)(function() {
|
|
4878
|
-
return _object_spread2(
|
|
4898
|
+
return _object_spread2(
|
|
4899
|
+
{},
|
|
4900
|
+
// this ! is a workaround for ts error
|
|
4901
|
+
defaultValues,
|
|
4902
|
+
values
|
|
4903
|
+
);
|
|
4879
4904
|
}, [
|
|
4880
4905
|
(0, import_objectIdentityKey.objectIdentityKey)(values)
|
|
4881
4906
|
]), Provider22 = OGProvider;
|
|
@@ -4883,9 +4908,10 @@ var require_createStyledContext_native = __commonJS({
|
|
|
4883
4908
|
var ScopedContext = scopedContexts.get(scope);
|
|
4884
4909
|
ScopedContext || (ScopedContext = /* @__PURE__ */ (0, import_react3.createContext)(defaultValues), scopedContexts.set(scope, ScopedContext)), Provider22 = ScopedContext.Provider;
|
|
4885
4910
|
}
|
|
4886
|
-
return /* @__PURE__ */
|
|
4887
|
-
value: next
|
|
4888
|
-
|
|
4911
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Provider22, {
|
|
4912
|
+
value: next,
|
|
4913
|
+
children
|
|
4914
|
+
});
|
|
4889
4915
|
}, useStyledContext = function(scope) {
|
|
4890
4916
|
var context = scope ? scopedContexts.get(scope) : OGContext;
|
|
4891
4917
|
return (0, import_react3.useContext)(context);
|
|
@@ -5413,7 +5439,13 @@ var require_createMediaStyle_native = __commonJS({
|
|
|
5413
5439
|
];
|
|
5414
5440
|
})));
|
|
5415
5441
|
}
|
|
5416
|
-
var mediaKey = groupMediaKey || mediaKeyIn, mediaSelector1 = selectors[mediaKey], screenStr = negate ? "not all and " : "", mediaQuery = "".concat(screenStr).concat(mediaSelector1), precedenceImportancePrefix1 = groupMediaKey ? "" : enableMediaPropOrder ?
|
|
5442
|
+
var mediaKey = groupMediaKey || mediaKeyIn, mediaSelector1 = selectors[mediaKey], screenStr = negate ? "not all and " : "", mediaQuery = "".concat(screenStr).concat(mediaSelector1), precedenceImportancePrefix1 = groupMediaKey ? "" : enableMediaPropOrder ? (
|
|
5443
|
+
// this new array should be cached
|
|
5444
|
+
new Array(priority).fill(":root").join("")
|
|
5445
|
+
) : (
|
|
5446
|
+
// @ts-ignore
|
|
5447
|
+
prefixes[mediaKey]
|
|
5448
|
+
), prefix = groupMediaKey ? "@container ".concat(containerName) : "@media";
|
|
5417
5449
|
groupMediaKey && (styleInner = styleRule), styleInner.includes(prefix) ? styleRule = styleInner.replace("{", " and ".concat(mediaQuery, " {")).replace("and screen and", "and") : styleRule = "".concat(prefix, " ").concat(mediaQuery, "{").concat(precedenceImportancePrefix1).concat(styleInner, "}"), groupMediaKey && (styleRule = "@supports (contain: ".concat(conf.settings.webContainerType || "inline-size", ") {").concat(styleRule, "}"));
|
|
5418
5450
|
}
|
|
5419
5451
|
return {
|
|
@@ -5505,16 +5537,52 @@ var require_normalize_color = __commonJS({
|
|
|
5505
5537
|
parse255(match[3]) << 16 | // g
|
|
5506
5538
|
parse255(match[4]) << 8 | // b
|
|
5507
5539
|
parse1(match[5])) >>> // a
|
|
5508
|
-
0 : (match = matchers.hex3.exec(color)) ? parseInt(
|
|
5509
|
-
|
|
5510
|
-
|
|
5511
|
-
|
|
5512
|
-
|
|
5513
|
-
|
|
5514
|
-
|
|
5515
|
-
0 : (match = matchers.
|
|
5516
|
-
|
|
5517
|
-
|
|
5540
|
+
0 : (match = matchers.hex3.exec(color)) ? parseInt(
|
|
5541
|
+
match[1] + match[1] + // r
|
|
5542
|
+
match[2] + match[2] + // g
|
|
5543
|
+
match[3] + match[3] + // b
|
|
5544
|
+
"ff",
|
|
5545
|
+
// a
|
|
5546
|
+
16
|
|
5547
|
+
) >>> 0 : (match = matchers.hex8.exec(color)) ? parseInt(match[1], 16) >>> 0 : (match = matchers.hex4.exec(color)) ? parseInt(
|
|
5548
|
+
match[1] + match[1] + // r
|
|
5549
|
+
match[2] + match[2] + // g
|
|
5550
|
+
match[3] + match[3] + // b
|
|
5551
|
+
match[4] + match[4],
|
|
5552
|
+
// a
|
|
5553
|
+
16
|
|
5554
|
+
) >>> 0 : (match = matchers.hsl.exec(color)) ? (hslToRgb(
|
|
5555
|
+
parse360(match[1]),
|
|
5556
|
+
// h
|
|
5557
|
+
parsePercentage(match[2]),
|
|
5558
|
+
// s
|
|
5559
|
+
parsePercentage(match[3])
|
|
5560
|
+
) | // l
|
|
5561
|
+
255) >>> // a
|
|
5562
|
+
0 : (match = matchers.hsla.exec(color)) ? match[6] !== void 0 ? (hslToRgb(
|
|
5563
|
+
parse360(match[6]),
|
|
5564
|
+
// h
|
|
5565
|
+
parsePercentage(match[7]),
|
|
5566
|
+
// s
|
|
5567
|
+
parsePercentage(match[8])
|
|
5568
|
+
) | // l
|
|
5569
|
+
parse1(match[9])) >>> // a
|
|
5570
|
+
0 : (hslToRgb(
|
|
5571
|
+
parse360(match[2]),
|
|
5572
|
+
// h
|
|
5573
|
+
parsePercentage(match[3]),
|
|
5574
|
+
// s
|
|
5575
|
+
parsePercentage(match[4])
|
|
5576
|
+
) | // l
|
|
5577
|
+
parse1(match[5])) >>> // a
|
|
5578
|
+
0 : (match = matchers.hwb.exec(color)) ? (hwbToRgb(
|
|
5579
|
+
parse360(match[1]),
|
|
5580
|
+
// h
|
|
5581
|
+
parsePercentage(match[2]),
|
|
5582
|
+
// w
|
|
5583
|
+
parsePercentage(match[3])
|
|
5584
|
+
) | // b
|
|
5585
|
+
255) >>> // a
|
|
5518
5586
|
0 : null);
|
|
5519
5587
|
}
|
|
5520
5588
|
function hue2rgb(p, q, t) {
|
|
@@ -6922,6 +6990,7 @@ var require_skipProps_native = __commonJS({
|
|
|
6922
6990
|
disableOptimization: 1,
|
|
6923
6991
|
tag: 1,
|
|
6924
6992
|
style: 1,
|
|
6993
|
+
// handled after loop so pseudos set usedKeys and override it if necessary
|
|
6925
6994
|
group: 1,
|
|
6926
6995
|
themeInverse: 1
|
|
6927
6996
|
};
|
|
@@ -7167,7 +7236,8 @@ var require_propMapper_native = __commonJS({
|
|
|
7167
7236
|
res[subKey] = val;
|
|
7168
7237
|
else if (variants && subKey in variants) {
|
|
7169
7238
|
if (styleState.curProps[subKey] = val, parentVariantKey && parentVariantKey === key)
|
|
7170
|
-
res[subKey] =
|
|
7239
|
+
res[subKey] = // SYNC WITH *1
|
|
7240
|
+
val[0] === "$" ? getTokenForKey(subKey, val, styleProps.resolveValues, styleState) : val;
|
|
7171
7241
|
else {
|
|
7172
7242
|
var variantOut = resolveVariants(subKey, val, styleProps, styleState, key);
|
|
7173
7243
|
if (variantOut) {
|
|
@@ -8329,7 +8399,7 @@ var require_Theme_native = __commonJS({
|
|
|
8329
8399
|
}
|
|
8330
8400
|
});
|
|
8331
8401
|
module2.exports = __toCommonJS2(Theme_exports);
|
|
8332
|
-
var import_constants = require_index_native3(), import_react3 = __toESM2(require("react")), import_createVariable = require_createVariable_native(), import_ThemeManagerContext = require_ThemeManagerContext_native(), import_useTheme = require_useTheme_native(), import_ThemeDebug = require_ThemeDebug_native();
|
|
8402
|
+
var import_jsx_runtime = require("react/jsx-runtime"), import_constants = require_index_native3(), import_react3 = __toESM2(require("react")), import_createVariable = require_createVariable_native(), import_ThemeManagerContext = require_ThemeManagerContext_native(), import_useTheme = require_useTheme_native(), import_ThemeDebug = require_ThemeDebug_native();
|
|
8333
8403
|
function _define_property2(obj, key, value) {
|
|
8334
8404
|
return key in obj ? Object.defineProperty(obj, key, {
|
|
8335
8405
|
value,
|
|
@@ -8373,10 +8443,11 @@ var require_Theme_native = __commonJS({
|
|
|
8373
8443
|
});
|
|
8374
8444
|
} catch {
|
|
8375
8445
|
}
|
|
8376
|
-
return process.env.NODE_ENV === "development" && props.debug === "visualize" && (finalChildren = /* @__PURE__ */
|
|
8446
|
+
return process.env.NODE_ENV === "development" && props.debug === "visualize" && (finalChildren = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ThemeDebug.ThemeDebug, {
|
|
8377
8447
|
themeState,
|
|
8378
|
-
themeProps: props
|
|
8379
|
-
|
|
8448
|
+
themeProps: props,
|
|
8449
|
+
children: finalChildren
|
|
8450
|
+
})), getThemedChildren(themeState, finalChildren, props, isRoot);
|
|
8380
8451
|
});
|
|
8381
8452
|
Theme.displayName = "Theme";
|
|
8382
8453
|
Theme.avoidForwardRef = !0;
|
|
@@ -8389,13 +8460,15 @@ var require_Theme_native = __commonJS({
|
|
|
8389
8460
|
return children;
|
|
8390
8461
|
var next = children;
|
|
8391
8462
|
shallow && (next = import_react3.Children.toArray(children).map(function(child) {
|
|
8392
|
-
return /* @__PURE__ */ (0, import_react3.isValidElement)(child) ? /* @__PURE__ */ (0, import_react3.cloneElement)(child, void 0, /* @__PURE__ */
|
|
8393
|
-
name: themeManager.state.parentName
|
|
8394
|
-
|
|
8463
|
+
return /* @__PURE__ */ (0, import_react3.isValidElement)(child) ? /* @__PURE__ */ (0, import_react3.cloneElement)(child, void 0, /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Theme, {
|
|
8464
|
+
name: themeManager.state.parentName,
|
|
8465
|
+
children: child.props.children
|
|
8466
|
+
})) : child;
|
|
8395
8467
|
}));
|
|
8396
|
-
var elementsWithContext = /* @__PURE__ */
|
|
8397
|
-
value: themeManager.id
|
|
8398
|
-
|
|
8468
|
+
var elementsWithContext = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ThemeManagerContext.ThemeManagerIDContext.Provider, {
|
|
8469
|
+
value: themeManager.id,
|
|
8470
|
+
children: next
|
|
8471
|
+
});
|
|
8399
8472
|
return forceClassName === !1 ? elementsWithContext : import_constants.isWeb ? wrapThemeElements({
|
|
8400
8473
|
children: elementsWithContext,
|
|
8401
8474
|
themeState,
|
|
@@ -8407,15 +8480,17 @@ var require_Theme_native = __commonJS({
|
|
|
8407
8480
|
var children = param.children, themeState = param.themeState, forceClassName = param.forceClassName, isRoot = param.isRoot;
|
|
8408
8481
|
if (isRoot && forceClassName === !1)
|
|
8409
8482
|
return children;
|
|
8410
|
-
var inverse = themeState.inversed, requiresExtraWrapper = inverse != null || forceClassName, _getThemeClassNameAndStyle = getThemeClassNameAndStyle(themeState, isRoot), className = _getThemeClassNameAndStyle.className, style = _getThemeClassNameAndStyle.style, themedChildren = /* @__PURE__ */
|
|
8483
|
+
var inverse = themeState.inversed, requiresExtraWrapper = inverse != null || forceClassName, _getThemeClassNameAndStyle = getThemeClassNameAndStyle(themeState, isRoot), className = _getThemeClassNameAndStyle.className, style = _getThemeClassNameAndStyle.style, themedChildren = /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
8411
8484
|
className: "".concat(className, " _dsp_contents is_Theme"),
|
|
8412
|
-
style
|
|
8413
|
-
|
|
8485
|
+
style,
|
|
8486
|
+
children
|
|
8487
|
+
});
|
|
8414
8488
|
if (requiresExtraWrapper) {
|
|
8415
8489
|
var _themeState_state, name = ((_themeState_state = themeState.state) === null || _themeState_state === void 0 ? void 0 : _themeState_state.name) || "", inverseClassName = name.startsWith("light") ? "t_light is_inversed" : name.startsWith("dark") ? "t_dark is_inversed" : "";
|
|
8416
|
-
themedChildren = /* @__PURE__ */
|
|
8417
|
-
className: "".concat(inverse ? inverseClassName : "", " _dsp_contents")
|
|
8418
|
-
|
|
8490
|
+
themedChildren = /* @__PURE__ */ (0, import_jsx_runtime.jsx)("span", {
|
|
8491
|
+
className: "".concat(inverse ? inverseClassName : "", " _dsp_contents"),
|
|
8492
|
+
children: themedChildren
|
|
8493
|
+
});
|
|
8419
8494
|
}
|
|
8420
8495
|
return themedChildren;
|
|
8421
8496
|
}
|
|
@@ -8484,7 +8559,7 @@ var require_themeable_native = __commonJS({
|
|
|
8484
8559
|
}
|
|
8485
8560
|
});
|
|
8486
8561
|
module2.exports = __toCommonJS2(themeable_exports);
|
|
8487
|
-
var import_react3 = require("react"), import_Theme = require_Theme_native();
|
|
8562
|
+
var import_jsx_runtime = require("react/jsx-runtime"), import_react3 = require("react"), import_Theme = require_Theme_native();
|
|
8488
8563
|
function _define_property2(obj, key, value) {
|
|
8489
8564
|
return key in obj ? Object.defineProperty(obj, key, {
|
|
8490
8565
|
value,
|
|
@@ -8547,19 +8622,20 @@ var require_themeable_native = __commonJS({
|
|
|
8547
8622
|
"themeReset"
|
|
8548
8623
|
]), element = (
|
|
8549
8624
|
// @ts-expect-error its ok
|
|
8550
|
-
/* @__PURE__ */
|
|
8625
|
+
/* @__PURE__ */ (0, import_jsx_runtime.jsx)(Component, _object_spread_props(_object_spread2({
|
|
8551
8626
|
ref
|
|
8552
8627
|
}, rest), {
|
|
8553
8628
|
"data-disable-theme": !0
|
|
8554
8629
|
}))
|
|
8555
|
-
), contents = /* @__PURE__ */
|
|
8630
|
+
), contents = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_Theme.Theme, {
|
|
8556
8631
|
componentName: componentName || (staticConfig == null ? void 0 : staticConfig.componentName),
|
|
8557
8632
|
name: theme,
|
|
8558
8633
|
"disable-child-theme": !0,
|
|
8559
8634
|
debug: props.debug,
|
|
8560
8635
|
inverse: themeInverse,
|
|
8561
|
-
reset: themeReset
|
|
8562
|
-
|
|
8636
|
+
reset: themeReset,
|
|
8637
|
+
children: element
|
|
8638
|
+
});
|
|
8563
8639
|
return contents;
|
|
8564
8640
|
}), withTheme = withThemeComponent;
|
|
8565
8641
|
return withTheme.displayName = "Themed(".concat((Component == null ? void 0 : Component.displayName) || (Component == null ? void 0 : Component.name) || "Anonymous", ")"), withTheme;
|
|
@@ -8672,7 +8748,7 @@ var require_Slot_native = __commonJS({
|
|
|
8672
8748
|
}
|
|
8673
8749
|
});
|
|
8674
8750
|
module2.exports = __toCommonJS2(Slot_exports);
|
|
8675
|
-
var import_compose_refs = require_index_native5(), import_constants = require_index_native3(), import_helpers = require_index_native4(), import_react3 = require("react");
|
|
8751
|
+
var import_jsx_runtime = require("react/jsx-runtime"), import_compose_refs = require_index_native5(), import_constants = require_index_native3(), import_helpers = require_index_native4(), import_react3 = require("react");
|
|
8676
8752
|
function _define_property2(obj, key, value) {
|
|
8677
8753
|
return key in obj ? Object.defineProperty(obj, key, {
|
|
8678
8754
|
value,
|
|
@@ -8741,7 +8817,9 @@ var require_Slot_native = __commonJS({
|
|
|
8741
8817
|
Slot.displayName = "Slot";
|
|
8742
8818
|
var Slottable = function(param) {
|
|
8743
8819
|
var children = param.children;
|
|
8744
|
-
return /* @__PURE__ */
|
|
8820
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_jsx_runtime.Fragment, {
|
|
8821
|
+
children
|
|
8822
|
+
});
|
|
8745
8823
|
};
|
|
8746
8824
|
Slottable.displayName = "Slottable";
|
|
8747
8825
|
var pressMap = import_constants.isWeb ? {
|
|
@@ -8843,7 +8921,7 @@ var require_createComponent_native = __commonJS({
|
|
|
8843
8921
|
}
|
|
8844
8922
|
});
|
|
8845
8923
|
module2.exports = __toCommonJS2(createComponent_exports);
|
|
8846
|
-
var import_compose_refs = require_index_native5(), import_constants = require_index_native3(), import_helpers = require_index_native4(), import_use_did_finish_ssr = require_index_native6(), import_react3 = __toESM2(require("react")), import_config = require_config_native(), import_constants2 = require_constants_native2(), import_ComponentContext = require_ComponentContext_native(), import_createVariable = require_createVariable_native(), import_defaultComponentState = require_defaultComponentState_native(), import_createShallowSetState = require_createShallowSetState_native(), import_getSplitStyles = require_getSplitStyles_native(), import_isObj = require_isObj_native(), import_log = require_log_native(), import_mergeProps = require_mergeProps_native(), import_themeable = require_themeable_native(), import_useMedia = require_useMedia_native(), import_useTheme = require_useTheme_native(), import_setupHooks = require_setupHooks_native(), import_Slot = require_Slot_native(), import_Theme = require_Theme_native(), import_ThemeDebug = require_ThemeDebug_native();
|
|
8924
|
+
var import_jsx_runtime = require("react/jsx-runtime"), import_compose_refs = require_index_native5(), import_constants = require_index_native3(), import_helpers = require_index_native4(), import_use_did_finish_ssr = require_index_native6(), import_react3 = __toESM2(require("react")), import_config = require_config_native(), import_constants2 = require_constants_native2(), import_ComponentContext = require_ComponentContext_native(), import_createVariable = require_createVariable_native(), import_defaultComponentState = require_defaultComponentState_native(), import_createShallowSetState = require_createShallowSetState_native(), import_getSplitStyles = require_getSplitStyles_native(), import_isObj = require_isObj_native(), import_log = require_log_native(), import_mergeProps = require_mergeProps_native(), import_themeable = require_themeable_native(), import_useMedia = require_useMedia_native(), import_useTheme = require_useTheme_native(), import_setupHooks = require_setupHooks_native(), import_Slot = require_Slot_native(), import_Theme = require_Theme_native(), import_ThemeDebug = require_ThemeDebug_native();
|
|
8847
8925
|
function _array_like_to_array(arr, len) {
|
|
8848
8926
|
(len == null || len > arr.length) && (len = arr.length);
|
|
8849
8927
|
for (var i = 0, arr2 = new Array(len); i < len; i++)
|
|
@@ -9545,7 +9623,9 @@ If you meant to do this, you can disable this warning - either change untilMeasu
|
|
|
9545
9623
|
var useChildrenResult;
|
|
9546
9624
|
import_setupHooks.hooks.useChildren && (useChildrenResult = import_setupHooks.hooks.useChildren(elementType, content, viewProps, events, staticConfig)), useChildrenResult ? content = useChildrenResult : content = /* @__PURE__ */ (0, import_react3.createElement)(elementType, viewProps, content);
|
|
9547
9625
|
var ResetPresence = config == null || (_config_animations = config.animations) === null || _config_animations === void 0 ? void 0 : _config_animations.ResetPresence;
|
|
9548
|
-
ResetPresence && willBeAnimated && (hasEnterStyle || presenceState) && content && typeof content != "string" && (content = /* @__PURE__ */
|
|
9626
|
+
ResetPresence && willBeAnimated && (hasEnterStyle || presenceState) && content && typeof content != "string" && (content = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(ResetPresence, {
|
|
9627
|
+
children: content
|
|
9628
|
+
})), process.env.NODE_ENV === "development" && time && time(_templateObject18());
|
|
9549
9629
|
var groupState = curState.group, subGroupContext = (0, import_react3.useMemo)(function() {
|
|
9550
9630
|
var _splitStyles_style, _splitStyles_style1;
|
|
9551
9631
|
if (!(!groupState || !groupName))
|
|
@@ -9566,12 +9646,14 @@ If you meant to do this, you can disable this warning - either change untilMeasu
|
|
|
9566
9646
|
}, [
|
|
9567
9647
|
groupName
|
|
9568
9648
|
]);
|
|
9569
|
-
if (groupName && subGroupContext && (content = /* @__PURE__ */
|
|
9570
|
-
groups: subGroupContext
|
|
9571
|
-
|
|
9649
|
+
if (groupName && subGroupContext && (content = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ComponentContext.ComponentContext.Provider, _object_spread_props(_object_spread2({}, componentContext), {
|
|
9650
|
+
groups: subGroupContext,
|
|
9651
|
+
children: content
|
|
9652
|
+
}))), process.env.NODE_ENV === "development" && time && time(_templateObject19()), content = disableTheme ? content : (0, import_Theme.getThemedChildren)(themeState, content, themeStateProps, !1), process.env.NODE_ENV === "development" && time && time(_templateObject20()), process.env.NODE_ENV === "development" && props.debug === "visualize" && (content = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ThemeDebug.ThemeDebug, {
|
|
9572
9653
|
themeState,
|
|
9573
|
-
themeProps: props
|
|
9574
|
-
|
|
9654
|
+
themeProps: props,
|
|
9655
|
+
children: content
|
|
9656
|
+
})), staticConfig.context) {
|
|
9575
9657
|
var contextProps = staticConfig.context.props;
|
|
9576
9658
|
for (var key1 in contextProps)
|
|
9577
9659
|
if (viewProps.style && key1 in viewProps.style || key1 in viewProps) {
|
|
@@ -9583,7 +9665,9 @@ If you meant to do this, you can disable this warning - either change untilMeasu
|
|
|
9583
9665
|
}
|
|
9584
9666
|
if (overriddenContextProps) {
|
|
9585
9667
|
var Provider = staticConfig.context.Provider;
|
|
9586
|
-
content = /* @__PURE__ */
|
|
9668
|
+
content = /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Provider, _object_spread_props(_object_spread2({}, contextValue, overriddenContextProps), {
|
|
9669
|
+
children: content
|
|
9670
|
+
}));
|
|
9587
9671
|
}
|
|
9588
9672
|
if (process.env.NODE_ENV === "development" && debugProp && debugProp !== "profile") {
|
|
9589
9673
|
var element1 = typeof elementType == "string" ? elementType : "Component", title = "render <".concat(element1, " /> (").concat(internalID, ") with props");
|
|
@@ -9716,9 +9800,11 @@ If you meant to do this, you can disable this warning - either change untilMeasu
|
|
|
9716
9800
|
spaceFlex,
|
|
9717
9801
|
separator,
|
|
9718
9802
|
key: child.key
|
|
9719
|
-
})), isEmpty || !child || child.key && !isZStack ? final.push(child) : final.push(/* @__PURE__ */
|
|
9720
|
-
|
|
9721
|
-
|
|
9803
|
+
})), isEmpty || !child || child.key && !isZStack ? final.push(child) : final.push(/* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_react3.Fragment, {
|
|
9804
|
+
children: isZStack ? /* @__PURE__ */ (0, import_jsx_runtime.jsx)(AbsoluteFill, {
|
|
9805
|
+
children: child
|
|
9806
|
+
}) : child
|
|
9807
|
+
}, index)), !(isUnspaced(child) && index === 0) && !isZStack) {
|
|
9722
9808
|
var next = childrenList[index + 1];
|
|
9723
9809
|
next && !isUnspaced(next) && (separator ? (hasSpace && final.push(createSpacer({
|
|
9724
9810
|
key: "_".concat(index, "_00tmgui"),
|
|
@@ -9754,13 +9840,12 @@ If you meant to do this, you can disable this warning - either change untilMeasu
|
|
|
9754
9840
|
}
|
|
9755
9841
|
function createSpacer(param) {
|
|
9756
9842
|
var key = param.key, direction = param.direction, space = param.space, spaceFlex = param.spaceFlex;
|
|
9757
|
-
return /* @__PURE__ */
|
|
9758
|
-
key,
|
|
9843
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Spacer, _object_spread2({
|
|
9759
9844
|
size: space,
|
|
9760
9845
|
direction
|
|
9761
9846
|
}, (typeof spaceFlex > "u" ? "undefined" : _type_of(spaceFlex)) < "u" && {
|
|
9762
9847
|
flex: spaceFlex === !0 ? 1 : spaceFlex === !1 ? 0 : spaceFlex
|
|
9763
|
-
}));
|
|
9848
|
+
}), key);
|
|
9764
9849
|
}
|
|
9765
9850
|
function isUnspaced(child) {
|
|
9766
9851
|
var t = child == null ? void 0 : child.type;
|
|
@@ -11540,7 +11625,7 @@ var require_withStableStyle_native = __commonJS({
|
|
|
11540
11625
|
}
|
|
11541
11626
|
});
|
|
11542
11627
|
module2.exports = __toCommonJS2(withStableStyle_exports);
|
|
11543
|
-
var import_react3 = require("react"), import_useTheme = require_useTheme_native();
|
|
11628
|
+
var import_jsx_runtime = require("react/jsx-runtime"), import_react3 = require("react"), import_useTheme = require_useTheme_native();
|
|
11544
11629
|
function _define_property2(obj, key, value) {
|
|
11545
11630
|
return key in obj ? Object.defineProperty(obj, key, {
|
|
11546
11631
|
value,
|
|
@@ -11584,7 +11669,7 @@ var require_withStableStyle_native = __commonJS({
|
|
|
11584
11669
|
var _props__expressions = props._expressions, _expressions = _props__expressions === void 0 ? [] : _props__expressions, rest = _object_without_properties(props, [
|
|
11585
11670
|
"_expressions"
|
|
11586
11671
|
]), theme = (0, import_useTheme.useTheme)();
|
|
11587
|
-
return /* @__PURE__ */
|
|
11672
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(Component, _object_spread2({
|
|
11588
11673
|
ref,
|
|
11589
11674
|
style: styleProvider(theme, _expressions)
|
|
11590
11675
|
}, rest));
|
|
@@ -12316,7 +12401,7 @@ var require_ThemeProvider_native = __commonJS({
|
|
|
12316
12401
|
}
|
|
12317
12402
|
});
|
|
12318
12403
|
module2.exports = __toCommonJS2(ThemeProvider_exports);
|
|
12319
|
-
var import_constants = require_index_native3(), import_react3 = require("react"), import_constants2 = require_constants_native2(), import_Theme = require_Theme_native(), ThemeProvider = function(props) {
|
|
12404
|
+
var import_jsx_runtime = require("react/jsx-runtime"), import_constants = require_index_native3(), import_react3 = require("react"), import_constants2 = require_constants_native2(), import_Theme = require_Theme_native(), ThemeProvider = function(props) {
|
|
12320
12405
|
return import_constants.isClient && (0, import_react3.useLayoutEffect)(function() {
|
|
12321
12406
|
if (!props.disableRootThemeClass) {
|
|
12322
12407
|
var cn = "".concat(import_constants2.THEME_CLASSNAME_PREFIX).concat(props.defaultTheme), target = props.themeClassNameOnRoot ? document.documentElement : document.body;
|
|
@@ -12328,14 +12413,15 @@ var require_ThemeProvider_native = __commonJS({
|
|
|
12328
12413
|
props.defaultTheme,
|
|
12329
12414
|
props.disableRootThemeClass,
|
|
12330
12415
|
props.themeClassNameOnRoot
|
|
12331
|
-
]), /* @__PURE__ */
|
|
12416
|
+
]), /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_Theme.Theme, {
|
|
12332
12417
|
className: props.className,
|
|
12333
12418
|
name: props.defaultTheme,
|
|
12334
12419
|
// if root class disabled, force class here
|
|
12335
12420
|
forceClassName: !props.disableRootThemeClass,
|
|
12336
12421
|
// @ts-expect-error
|
|
12337
|
-
_isRoot: !0
|
|
12338
|
-
|
|
12422
|
+
_isRoot: !0,
|
|
12423
|
+
children: props.children
|
|
12424
|
+
});
|
|
12339
12425
|
};
|
|
12340
12426
|
}
|
|
12341
12427
|
});
|
|
@@ -12386,7 +12472,7 @@ var require_FontLanguage_native = __commonJS({
|
|
|
12386
12472
|
}
|
|
12387
12473
|
});
|
|
12388
12474
|
module2.exports = __toCommonJS2(FontLanguage_native_exports);
|
|
12389
|
-
var import_react3 = require("react"), import_ComponentContext = require_ComponentContext_native();
|
|
12475
|
+
var import_jsx_runtime = require("react/jsx-runtime"), import_react3 = require("react"), import_ComponentContext = require_ComponentContext_native();
|
|
12390
12476
|
function _object_without_properties(source, excluded) {
|
|
12391
12477
|
if (source == null)
|
|
12392
12478
|
return {};
|
|
@@ -12414,9 +12500,10 @@ var require_FontLanguage_native = __commonJS({
|
|
|
12414
12500
|
}, [
|
|
12415
12501
|
JSON.stringify(props)
|
|
12416
12502
|
]);
|
|
12417
|
-
return /* @__PURE__ */
|
|
12418
|
-
language
|
|
12419
|
-
|
|
12503
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ComponentContext.ComponentContext.Provider, {
|
|
12504
|
+
language,
|
|
12505
|
+
children
|
|
12506
|
+
});
|
|
12420
12507
|
};
|
|
12421
12508
|
FontLanguage.displayName = "FontLanguage";
|
|
12422
12509
|
}
|
|
@@ -12480,7 +12567,7 @@ var require_TamaguiProvider_native = __commonJS({
|
|
|
12480
12567
|
}
|
|
12481
12568
|
});
|
|
12482
12569
|
module2.exports = __toCommonJS2(TamaguiProvider_exports);
|
|
12483
|
-
var import_constants = require_index_native3(),
|
|
12570
|
+
var import_jsx_runtime = require("react/jsx-runtime"), import_constants = require_index_native3(), React = __toESM2(require("react")), import_ComponentContext = require_ComponentContext_native(), import_useMedia = require_useMedia_native(), import_ThemeProvider = require_ThemeProvider_native();
|
|
12484
12571
|
function _define_property2(obj, key, value) {
|
|
12485
12572
|
return key in obj ? Object.defineProperty(obj, key, {
|
|
12486
12573
|
value,
|
|
@@ -12540,7 +12627,7 @@ var require_TamaguiProvider_native = __commonJS({
|
|
|
12540
12627
|
"disableInjectCSS",
|
|
12541
12628
|
"config"
|
|
12542
12629
|
]);
|
|
12543
|
-
(0, import_useMedia.setupMediaListeners)(), import_constants.isClient &&
|
|
12630
|
+
(0, import_useMedia.setupMediaListeners)(), import_constants.isClient && React.useLayoutEffect(function() {
|
|
12544
12631
|
if (config && (config.disableSSR || document.documentElement.classList.contains("t_unmounted") && document.documentElement.classList.remove("t_unmounted"), !disableInjectCSS)) {
|
|
12545
12632
|
var style = document.createElement("style");
|
|
12546
12633
|
return style.appendChild(document.createTextNode(config.getCSS())), document.head.appendChild(style), function() {
|
|
@@ -12552,14 +12639,16 @@ var require_TamaguiProvider_native = __commonJS({
|
|
|
12552
12639
|
disableInjectCSS
|
|
12553
12640
|
]);
|
|
12554
12641
|
var _themePropsProvider_defaultTheme;
|
|
12555
|
-
return /* @__PURE__ */
|
|
12556
|
-
animationDriver: config == null ? void 0 : config.animations
|
|
12557
|
-
|
|
12558
|
-
|
|
12559
|
-
|
|
12560
|
-
|
|
12561
|
-
|
|
12562
|
-
|
|
12642
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ComponentContext.ComponentContext.Provider, {
|
|
12643
|
+
animationDriver: config == null ? void 0 : config.animations,
|
|
12644
|
+
children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ThemeProvider.ThemeProvider, _object_spread_props(_object_spread2({
|
|
12645
|
+
themeClassNameOnRoot: config == null ? void 0 : config.themeClassNameOnRoot,
|
|
12646
|
+
disableRootThemeClass: config == null ? void 0 : config.disableRootThemeClass
|
|
12647
|
+
}, themePropsProvider), {
|
|
12648
|
+
defaultTheme: (_themePropsProvider_defaultTheme = themePropsProvider.defaultTheme) !== null && _themePropsProvider_defaultTheme !== void 0 ? _themePropsProvider_defaultTheme : config ? Object.keys(config.themes)[0] : "",
|
|
12649
|
+
children
|
|
12650
|
+
}))
|
|
12651
|
+
});
|
|
12563
12652
|
}
|
|
12564
12653
|
TamaguiProvider.displayName = "TamaguiProvider";
|
|
12565
12654
|
}
|
|
@@ -12611,7 +12700,7 @@ var require_Configuration_native = __commonJS({
|
|
|
12611
12700
|
}
|
|
12612
12701
|
});
|
|
12613
12702
|
module2.exports = __toCommonJS2(Configuration_exports);
|
|
12614
|
-
var import_react3 = require("react"), import_ComponentContext = require_ComponentContext_native();
|
|
12703
|
+
var import_jsx_runtime = require("react/jsx-runtime"), import_react3 = require("react"), import_ComponentContext = require_ComponentContext_native();
|
|
12615
12704
|
function _define_property2(obj, key, value) {
|
|
12616
12705
|
return key in obj ? Object.defineProperty(obj, key, {
|
|
12617
12706
|
value,
|
|
@@ -12633,7 +12722,7 @@ var require_Configuration_native = __commonJS({
|
|
|
12633
12722
|
}
|
|
12634
12723
|
var Configuration = function(props) {
|
|
12635
12724
|
var current = (0, import_react3.useContext)(import_ComponentContext.ComponentContext);
|
|
12636
|
-
return /* @__PURE__ */
|
|
12725
|
+
return /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ComponentContext.ComponentContext.Provider, _object_spread2({}, current, props));
|
|
12637
12726
|
};
|
|
12638
12727
|
Configuration.displayName = "Configuration";
|
|
12639
12728
|
}
|
|
@@ -13013,7 +13102,10 @@ var import_react_native_use_responder_events = __toESM(require_index_native()),
|
|
|
13013
13102
|
// src/createOptimizedView.native.tsx
|
|
13014
13103
|
var import_react = require("react");
|
|
13015
13104
|
function createOptimizedView(children, viewProps, baseViews2) {
|
|
13016
|
-
var TextAncestor = baseViews2.TextAncestor, ViewNativeComponent = baseViews2.View, accessibilityElementsHidden =
|
|
13105
|
+
var TextAncestor = baseViews2.TextAncestor, ViewNativeComponent = baseViews2.View, accessibilityElementsHidden = (
|
|
13106
|
+
// ...otherProps
|
|
13107
|
+
viewProps.accessibilityElementsHidden
|
|
13108
|
+
), accessibilityLabel = viewProps.accessibilityLabel, accessibilityLabelledBy = viewProps.accessibilityLabelledBy, accessibilityLiveRegion = viewProps.accessibilityLiveRegion, accessibilityRole = viewProps.accessibilityRole, accessibilityState = viewProps.accessibilityState, accessibilityValue = viewProps.accessibilityValue, ariaBusy = viewProps["aria-busy"], ariaChecked = viewProps["aria-checked"], ariaDisabled = viewProps["aria-disabled"], ariaExpanded = viewProps["aria-expanded"], ariaHidden = viewProps["aria-hidden"], ariaLabel = viewProps["aria-label"], ariaLabelledBy = viewProps["aria-labelledby"], ariaLive = viewProps["aria-live"], ariaSelected = viewProps["aria-selected"], ariaValueMax = viewProps["aria-valuemax"], ariaValueMin = viewProps["aria-valuemin"], ariaValueNow = viewProps["aria-valuenow"], ariaValueText = viewProps["aria-valuetext"], focusable = viewProps.focusable, id = viewProps.id, importantForAccessibility = viewProps.importantForAccessibility, nativeID = viewProps.nativeID, pointerEvents = viewProps.pointerEvents, role = viewProps.role, tabIndex = viewProps.tabIndex, _ariaLabelledBy_split, _accessibilityLabelledBy = (_ariaLabelledBy_split = ariaLabelledBy == null ? void 0 : ariaLabelledBy.split(/\s*,\s*/g)) !== null && _ariaLabelledBy_split !== void 0 ? _ariaLabelledBy_split : accessibilityLabelledBy, _accessibilityState;
|
|
13017
13109
|
(accessibilityState != null || ariaBusy != null || ariaChecked != null || ariaDisabled != null || ariaExpanded != null || ariaSelected != null) && (_accessibilityState = {
|
|
13018
13110
|
busy: ariaBusy ?? (accessibilityState == null ? void 0 : accessibilityState.busy),
|
|
13019
13111
|
checked: ariaChecked ?? (accessibilityState == null ? void 0 : accessibilityState.checked),
|
|
@@ -13221,47 +13313,50 @@ function _object_spread(target) {
|
|
|
13221
13313
|
return target;
|
|
13222
13314
|
}
|
|
13223
13315
|
var baseViews = getBaseViews();
|
|
13224
|
-
(0, import_web.setupHooks)(_object_spread(
|
|
13225
|
-
|
|
13226
|
-
|
|
13227
|
-
|
|
13228
|
-
|
|
13229
|
-
|
|
13230
|
-
|
|
13231
|
-
|
|
13232
|
-
|
|
13316
|
+
(0, import_web.setupHooks)(_object_spread(
|
|
13317
|
+
{
|
|
13318
|
+
getBaseViews,
|
|
13319
|
+
usePropsTransform: function(elementType, propsIn, stateRef, willHydrate) {
|
|
13320
|
+
if (0) {
|
|
13321
|
+
var isDOM, onMoveShouldSetResponder, onMoveShouldSetResponderCapture, onResponderEnd, onResponderGrant, onResponderMove, onResponderReject, onResponderRelease, onResponderStart, onResponderTerminate, onResponderTerminationRequest, onScrollShouldSetResponder, onScrollShouldSetResponderCapture, onSelectionChangeShouldSetResponder, onSelectionChangeShouldSetResponderCapture, onStartShouldSetResponder, onStartShouldSetResponderCapture, collapsable, focusable, accessible, accessibilityDisabled, onLayout, hrefAttrs, plainDOMProps;
|
|
13322
|
+
if (willHydrate || isDOM)
|
|
13323
|
+
var hostRef;
|
|
13324
|
+
if (isDOM && plainDOMProps.href && hrefAttrs)
|
|
13325
|
+
var download, rel, target;
|
|
13326
|
+
}
|
|
13327
|
+
},
|
|
13328
|
+
useEvents: function(viewProps, events, param, setStateShallow, staticConfig) {
|
|
13329
|
+
var pseudos = param.pseudos;
|
|
13330
|
+
if (events && (events.onFocus && (viewProps.onFocus = events.onFocus), events.onBlur && (viewProps.onBlur = events.onBlur)), staticConfig.isInput) {
|
|
13331
|
+
if (events) {
|
|
13332
|
+
var onPressIn = events.onPressIn, onPressOut = events.onPressOut, onPress = events.onPress, inputEvents = {
|
|
13333
|
+
onPressIn,
|
|
13334
|
+
onPressOut: onPressOut || onPress
|
|
13335
|
+
};
|
|
13336
|
+
onPressOut && onPress && (inputEvents.onPressOut = (0, import_web.composeEventHandlers)(onPress, onPressOut)), Object.assign(viewProps, inputEvents);
|
|
13337
|
+
}
|
|
13338
|
+
} else {
|
|
13339
|
+
events && viewProps.hitSlop && (events.hitSlop = viewProps.hitSlop);
|
|
13340
|
+
var pressability = usePressability(events);
|
|
13341
|
+
if (events && (process.env.NODE_ENV === "development" && viewProps.debug && console.info("Checking for press ".concat(!!events.onPress, " then applying pressability props: ").concat(Object.keys(pressability || {}))), events.onPress))
|
|
13342
|
+
for (var key in pressability) {
|
|
13343
|
+
var og = viewProps[key], val = pressability[key];
|
|
13344
|
+
viewProps[key] = og && !dontComposePressabilityKeys[key] ? (0, import_web.composeEventHandlers)(og, val) : val;
|
|
13345
|
+
}
|
|
13346
|
+
}
|
|
13233
13347
|
}
|
|
13234
13348
|
},
|
|
13235
|
-
|
|
13236
|
-
|
|
13237
|
-
|
|
13238
|
-
|
|
13239
|
-
|
|
13240
|
-
|
|
13241
|
-
|
|
13242
|
-
};
|
|
13243
|
-
onPressOut && onPress && (inputEvents.onPressOut = (0, import_web.composeEventHandlers)(onPress, onPressOut)), Object.assign(viewProps, inputEvents);
|
|
13349
|
+
{
|
|
13350
|
+
useChildren: function(elementType, children, viewProps, events, staticConfig) {
|
|
13351
|
+
if (process.env.NODE_ENV !== "test") {
|
|
13352
|
+
if (elementType === baseViews.View)
|
|
13353
|
+
return createOptimizedView(children, viewProps, baseViews);
|
|
13354
|
+
if (process.env.TAMAGUI_OPTIMIZE_NATIVE_VIEWS && elementType === baseViews.Text)
|
|
13355
|
+
return viewProps.children = children, /* @__PURE__ */ (0, import_react2.createElement)("RCTText", viewProps);
|
|
13244
13356
|
}
|
|
13245
|
-
} else {
|
|
13246
|
-
events && viewProps.hitSlop && (events.hitSlop = viewProps.hitSlop);
|
|
13247
|
-
var pressability = usePressability(events);
|
|
13248
|
-
if (events && (process.env.NODE_ENV === "development" && viewProps.debug && console.info("Checking for press ".concat(!!events.onPress, " then applying pressability props: ").concat(Object.keys(pressability || {}))), events.onPress))
|
|
13249
|
-
for (var key in pressability) {
|
|
13250
|
-
var og = viewProps[key], val = pressability[key];
|
|
13251
|
-
viewProps[key] = og && !dontComposePressabilityKeys[key] ? (0, import_web.composeEventHandlers)(og, val) : val;
|
|
13252
|
-
}
|
|
13253
|
-
}
|
|
13254
|
-
}
|
|
13255
|
-
}, {
|
|
13256
|
-
useChildren: function(elementType, children, viewProps, events, staticConfig) {
|
|
13257
|
-
if (process.env.NODE_ENV !== "test") {
|
|
13258
|
-
if (elementType === baseViews.View)
|
|
13259
|
-
return createOptimizedView(children, viewProps, baseViews);
|
|
13260
|
-
if (process.env.TAMAGUI_OPTIMIZE_NATIVE_VIEWS && elementType === baseViews.Text)
|
|
13261
|
-
return viewProps.children = children, /* @__PURE__ */ (0, import_react2.createElement)("RCTText", viewProps);
|
|
13262
13357
|
}
|
|
13263
13358
|
}
|
|
13264
|
-
|
|
13359
|
+
));
|
|
13265
13360
|
var dontComposePressabilityKeys = {
|
|
13266
13361
|
onClick: !0
|
|
13267
13362
|
}, View = import_web.View, Stack = import_web.Stack, Text = import_web.Text;
|