@tamagui/core 1.107.0 → 1.108.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 +369 -331
- package/dist/native.js.map +3 -3
- package/dist/test.native.js +305 -256
- package/dist/test.native.js.map +3 -3
- package/package.json +6 -6
package/dist/test.native.js
CHANGED
|
@@ -5002,18 +5002,26 @@ var require_createMediaStyle_native = __commonJS({
|
|
|
5002
5002
|
press: "active"
|
|
5003
5003
|
}, specifities = new Array(5).fill(0).map(function(_, i) {
|
|
5004
5004
|
return new Array(i).fill(":root").join("");
|
|
5005
|
-
})
|
|
5006
|
-
|
|
5005
|
+
});
|
|
5006
|
+
function getThemeOrGroupSelector(name, styleInner, isGroup, groupParts) {
|
|
5007
|
+
var isTheme = arguments.length > 4 && arguments[4] !== void 0 ? arguments[4] : !1, precedenceImportancePrefix = arguments.length > 5 && arguments[5] !== void 0 ? arguments[5] : "", selectorStart = styleInner.indexOf(":root"), selectorEnd = styleInner.lastIndexOf("{"), selector = styleInner.slice(selectorStart, selectorEnd), precedenceSpace = (0, import_config.getSetting)("themeClassNameOnRoot") && isTheme ? "" : " ", pseudoSelectorName = groupParts.pseudo ? groupPseudoToPseudoCSSMap[groupParts.pseudo] || groupParts.pseudo : void 0, pseudoSelector = pseudoSelectorName ? ":".concat(pseudoSelectorName) : "", presedencePrefix = ":root".concat(precedenceImportancePrefix).concat(precedenceSpace), mediaSelector = ".t_".concat(isGroup ? "group_" : "").concat(name).concat(pseudoSelector);
|
|
5008
|
+
return [
|
|
5009
|
+
selector,
|
|
5010
|
+
"".concat(presedencePrefix).concat(mediaSelector, " ").concat(selector.replace(":root", ""))
|
|
5011
|
+
];
|
|
5012
|
+
}
|
|
5013
|
+
var createMediaStyle = function(styleObject, mediaKeyIn, mediaQueries, type, negate, priority) {
|
|
5014
|
+
var _styleObject = _sliced_to_array(styleObject, 5), property = _styleObject[0], identifier = _styleObject[2], rules = _styleObject[4], enableMediaPropOrder = (0, import_config.getSetting)("mediaPropOrder"), isTheme = type === "theme", isPlatform = type === "platform", isGroup = type === "group", isNonWindowMedia = isTheme || isPlatform || isGroup, negKey = negate ? "0" : "", ogPrefix = identifier.slice(0, identifier.indexOf("-") + 1), id = "".concat(ogPrefix).concat(MEDIA_SEP).concat(mediaKeyIn.replace("-", "")).concat(negKey).concat(MEDIA_SEP), styleRule = "", groupPriority = "", groupMediaKey, containerName, nextIdentifier = identifier.replace(ogPrefix, id), styleInner = rules.map(function(rule) {
|
|
5007
5015
|
return rule.replace(identifier, nextIdentifier);
|
|
5008
5016
|
}).join(";"), isHover = !1;
|
|
5009
5017
|
if (isNonWindowMedia) {
|
|
5010
5018
|
var specificity = (priority || 0) + (isGroup || isPlatform ? 1 : 0);
|
|
5011
5019
|
if (isTheme || isGroup) {
|
|
5012
5020
|
var _getGroupPropParts = (0, import_getGroupPropParts.getGroupPropParts)(mediaKeyIn), name = _getGroupPropParts.name, media = _getGroupPropParts.media, pseudo = _getGroupPropParts.pseudo;
|
|
5013
|
-
groupMediaKey = media
|
|
5014
|
-
var
|
|
5015
|
-
pseudo === "press" && (specificity += 2), pseudo === "hover" && (isHover = !0);
|
|
5016
|
-
var
|
|
5021
|
+
groupMediaKey = media;
|
|
5022
|
+
var groupParts = (0, import_getGroupPropParts.getGroupPropParts)(mediaKeyIn);
|
|
5023
|
+
isGroup && (containerName = name), pseudo === "press" && (specificity += 2), pseudo === "hover" && (isHover = !0);
|
|
5024
|
+
var _getThemeOrGroupSelector = _sliced_to_array(getThemeOrGroupSelector(name, styleInner, isGroup, groupParts, isTheme, specifities[specificity]), 2), selector = _getThemeOrGroupSelector[0], nextSelector = _getThemeOrGroupSelector[1];
|
|
5017
5025
|
styleRule = styleInner.replace(selector, nextSelector);
|
|
5018
5026
|
} else styleRule = "".concat(specifities[specificity]).concat(styleInner);
|
|
5019
5027
|
}
|
|
@@ -5032,14 +5040,14 @@ var require_createMediaStyle_native = __commonJS({
|
|
|
5032
5040
|
];
|
|
5033
5041
|
})));
|
|
5034
5042
|
}
|
|
5035
|
-
var mediaKey = groupMediaKey || mediaKeyIn,
|
|
5043
|
+
var mediaKey = groupMediaKey || mediaKeyIn, mediaSelector = selectors[mediaKey], screenStr = negate ? "not all and " : "", mediaQuery = "".concat(screenStr).concat(mediaSelector), precedenceImportancePrefix = groupMediaKey ? groupPriority : enableMediaPropOrder && priority ? (
|
|
5036
5044
|
// this new array should be cached
|
|
5037
5045
|
specifities[priority]
|
|
5038
5046
|
) : (
|
|
5039
5047
|
// @ts-ignore
|
|
5040
5048
|
prefixes[mediaKey]
|
|
5041
5049
|
), prefix = groupMediaKey ? "@container ".concat(containerName) : "@media";
|
|
5042
|
-
groupMediaKey && (styleInner = styleRule), styleInner.includes(prefix) ? styleRule = styleInner.replace("{", " and ".concat(mediaQuery, " {")).replace("and screen and", "and") : styleRule = "".concat(prefix, " ").concat(mediaQuery, "{").concat(precedenceImportancePrefix).concat(styleInner, "}"), groupMediaKey && (styleRule = "@supports (contain: ".concat(
|
|
5050
|
+
groupMediaKey && (styleInner = styleRule), styleInner.includes(prefix) ? styleRule = styleInner.replace("{", " and ".concat(mediaQuery, " {")).replace("and screen and", "and") : styleRule = "".concat(prefix, " ").concat(mediaQuery, "{").concat(precedenceImportancePrefix).concat(styleInner, "}"), groupMediaKey && (styleRule = "@supports (contain: ".concat((0, import_config.getSetting)("webContainerType") || "inline-size", ") {").concat(styleRule, "}"));
|
|
5043
5051
|
}
|
|
5044
5052
|
return isHover && (styleRule = "@media (hover:hover){".concat(styleRule, "}")), [
|
|
5045
5053
|
property,
|
|
@@ -7289,6 +7297,65 @@ var require_transformsToString_native = __commonJS({
|
|
|
7289
7297
|
}
|
|
7290
7298
|
});
|
|
7291
7299
|
|
|
7300
|
+
// ../web/dist/cjs/helpers/isActivePlatform.native.js
|
|
7301
|
+
var require_isActivePlatform_native = __commonJS({
|
|
7302
|
+
"../web/dist/cjs/helpers/isActivePlatform.native.js"(exports2, module2) {
|
|
7303
|
+
"use strict";
|
|
7304
|
+
function _type_of(obj) {
|
|
7305
|
+
"@swc/helpers - typeof";
|
|
7306
|
+
return obj && typeof Symbol < "u" && obj.constructor === Symbol ? "symbol" : typeof obj;
|
|
7307
|
+
}
|
|
7308
|
+
var __defProp2 = Object.defineProperty, __getOwnPropDesc2 = Object.getOwnPropertyDescriptor, __getOwnPropNames2 = Object.getOwnPropertyNames, __hasOwnProp2 = Object.prototype.hasOwnProperty, __export2 = function(target, all) {
|
|
7309
|
+
for (var name in all) __defProp2(target, name, {
|
|
7310
|
+
get: all[name],
|
|
7311
|
+
enumerable: !0
|
|
7312
|
+
});
|
|
7313
|
+
}, __copyProps2 = function(to, from, except, desc) {
|
|
7314
|
+
var _iteratorNormalCompletion = !0, _didIteratorError = !1, _iteratorError = void 0;
|
|
7315
|
+
if (from && (typeof from > "u" ? "undefined" : _type_of(from)) == "object" || typeof from == "function") try {
|
|
7316
|
+
for (var _loop = function() {
|
|
7317
|
+
var key = _step.value;
|
|
7318
|
+
!__hasOwnProp2.call(to, key) && key !== except && __defProp2(to, key, {
|
|
7319
|
+
get: function() {
|
|
7320
|
+
return from[key];
|
|
7321
|
+
},
|
|
7322
|
+
enumerable: !(desc = __getOwnPropDesc2(from, key)) || desc.enumerable
|
|
7323
|
+
});
|
|
7324
|
+
}, _iterator = __getOwnPropNames2(from)[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = !0) _loop();
|
|
7325
|
+
} catch (err) {
|
|
7326
|
+
_didIteratorError = !0, _iteratorError = err;
|
|
7327
|
+
} finally {
|
|
7328
|
+
try {
|
|
7329
|
+
!_iteratorNormalCompletion && _iterator.return != null && _iterator.return();
|
|
7330
|
+
} finally {
|
|
7331
|
+
if (_didIteratorError)
|
|
7332
|
+
throw _iteratorError;
|
|
7333
|
+
}
|
|
7334
|
+
}
|
|
7335
|
+
return to;
|
|
7336
|
+
}, __toCommonJS2 = function(mod) {
|
|
7337
|
+
return __copyProps2(__defProp2({}, "__esModule", {
|
|
7338
|
+
value: !0
|
|
7339
|
+
}), mod);
|
|
7340
|
+
}, isActivePlatform_exports = {};
|
|
7341
|
+
__export2(isActivePlatform_exports, {
|
|
7342
|
+
isActivePlatform: function() {
|
|
7343
|
+
return isActivePlatform;
|
|
7344
|
+
}
|
|
7345
|
+
});
|
|
7346
|
+
module2.exports = __toCommonJS2(isActivePlatform_exports);
|
|
7347
|
+
var import_constants = require_index_native3();
|
|
7348
|
+
function isActivePlatform(key) {
|
|
7349
|
+
var platform = key.slice(10);
|
|
7350
|
+
return (
|
|
7351
|
+
// web, ios, android
|
|
7352
|
+
platform === import_constants.currentPlatform || // web, native
|
|
7353
|
+
platform === "native"
|
|
7354
|
+
);
|
|
7355
|
+
}
|
|
7356
|
+
}
|
|
7357
|
+
});
|
|
7358
|
+
|
|
7292
7359
|
// ../web/dist/cjs/helpers/getSplitStyles.native.js
|
|
7293
7360
|
var require_getSplitStyles_native = __commonJS({
|
|
7294
7361
|
"../web/dist/cjs/helpers/getSplitStyles.native.js"(exports2, module2) {
|
|
@@ -7345,7 +7412,7 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7345
7412
|
}
|
|
7346
7413
|
});
|
|
7347
7414
|
module2.exports = __toCommonJS2(getSplitStyles_exports);
|
|
7348
|
-
var import_constants = require_index_native3(), import_helpers = require_index_native4(), import_react3 = require("react"), import_config = require_config_native(), import_accessibilityDirectMap = require_accessibilityDirectMap_native(), import_constants2 = require_constants_native2(), import_isDevTools = require_isDevTools_native(), import_useMedia = require_useMedia_native(), import_createMediaStyle = require_createMediaStyle_native(), import_expandStyles = require_expandStyles_native(), import_getGroupPropParts = require_getGroupPropParts_native(), import_getStylesAtomic = require_getStylesAtomic_native(), import_insertStyleRule = require_insertStyleRule_native(), import_log = require_log_native(), import_normalizeValueWithProperty = require_normalizeValueWithProperty_native(), import_propMapper = require_propMapper_native(), import_pseudoDescriptors = require_pseudoDescriptors_native(), import_skipProps = require_skipProps_native(), import_transformsToString = require_transformsToString_native();
|
|
7415
|
+
var import_constants = require_index_native3(), import_helpers = require_index_native4(), import_react3 = require("react"), import_config = require_config_native(), import_accessibilityDirectMap = require_accessibilityDirectMap_native(), import_constants2 = require_constants_native2(), import_isDevTools = require_isDevTools_native(), import_useMedia = require_useMedia_native(), import_createMediaStyle = require_createMediaStyle_native(), import_expandStyles = require_expandStyles_native(), import_getGroupPropParts = require_getGroupPropParts_native(), import_getStylesAtomic = require_getStylesAtomic_native(), import_insertStyleRule = require_insertStyleRule_native(), import_log = require_log_native(), import_normalizeValueWithProperty = require_normalizeValueWithProperty_native(), import_propMapper = require_propMapper_native(), import_pseudoDescriptors = require_pseudoDescriptors_native(), import_skipProps = require_skipProps_native(), import_transformsToString = require_transformsToString_native(), import_isActivePlatform = require_isActivePlatform_native();
|
|
7349
7416
|
function _array_like_to_array(arr, len) {
|
|
7350
7417
|
(len == null || len > arr.length) && (len = arr.length);
|
|
7351
7418
|
for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
|
|
@@ -7430,6 +7497,207 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7430
7497
|
return validStyleProps[key] || ((_staticConfig_accept = staticConfig.accept) === null || _staticConfig_accept === void 0 ? void 0 : _staticConfig_accept[key]);
|
|
7431
7498
|
}
|
|
7432
7499
|
var getSplitStyles = function(props, staticConfig, theme, themeName, componentState, styleProps, parentSplitStyles, context, elementType, debug, skipThemeTokenResolution) {
|
|
7500
|
+
var _loop = function(keyOg2) {
|
|
7501
|
+
var _loop22 = function(i3) {
|
|
7502
|
+
var _parentStaticConfig_variants;
|
|
7503
|
+
if (expanded) {
|
|
7504
|
+
var _expanded_i = _sliced_to_array(expanded[i3], 2), k = _expanded_i[0], v = _expanded_i[1];
|
|
7505
|
+
key4 = k, val2 = v;
|
|
7506
|
+
}
|
|
7507
|
+
if (val2 == null || key4 in usedKeys) return "continue";
|
|
7508
|
+
if (isPseudo = key4 in import_helpers.validPseudoKeys, isMedia = !isPseudo && !isValidStyleKeyInit && (0, import_useMedia.isMediaKey)(key4), isMediaOrPseudo1 = !!(isMedia || isPseudo), isVariant = variants && key4 in variants, inlineProps != null && inlineProps.has(key4) || process.env.IS_STATIC === "is_static" && inlineWhenUnflattened != null && inlineWhenUnflattened.has(key4)) {
|
|
7509
|
+
var _props_key;
|
|
7510
|
+
viewProps[key4] = (_props_key = props[key4]) !== null && _props_key !== void 0 ? _props_key : val2;
|
|
7511
|
+
}
|
|
7512
|
+
var shouldPassThrough2 = styleProps.noExpand && isPseudo || isHOC && (isMediaOrPseudo1 || (parentStaticConfig == null || (_parentStaticConfig_variants = parentStaticConfig.variants) === null || _parentStaticConfig_variants === void 0 ? void 0 : _parentStaticConfig_variants[keyInit]));
|
|
7513
|
+
if (shouldPassThrough2) return passDownProp(viewProps, key4, val2, isMediaOrPseudo1), "continue";
|
|
7514
|
+
if (isPseudo) {
|
|
7515
|
+
if (!val2) return "continue";
|
|
7516
|
+
var pseudoStyleObject = getSubStyle(styleState, key4, val2, styleProps.noClassNames), descriptor = import_pseudoDescriptors.pseudoDescriptors[key4], isEnter = key4 === "enterStyle", isExit = key4 === "exitStyle";
|
|
7517
|
+
if (!descriptor) return "continue";
|
|
7518
|
+
if (!shouldDoClasses || process.env.IS_STATIC === "is_static") {
|
|
7519
|
+
var _pseudos, _key;
|
|
7520
|
+
if (pseudos || (pseudos = {}), (_pseudos = pseudos)[_key = key4] || (_pseudos[_key] = {}), process.env.IS_STATIC === "is_static") return Object.assign(pseudos[key4], pseudoStyleObject), "continue";
|
|
7521
|
+
}
|
|
7522
|
+
if (shouldDoClasses && !isExit) {
|
|
7523
|
+
var pseudoStyles = (0, import_getStylesAtomic.getStyleAtomic)(pseudoStyleObject, descriptor), _iteratorNormalCompletion2 = !0, _didIteratorError2 = !1, _iteratorError2 = void 0;
|
|
7524
|
+
try {
|
|
7525
|
+
for (var _iterator2 = pseudoStyles[Symbol.iterator](), _step2; !(_iteratorNormalCompletion2 = (_step2 = _iterator2.next()).done); _iteratorNormalCompletion2 = !0) {
|
|
7526
|
+
var psuedoStyle = _step2.value, fullKey = "".concat(psuedoStyle[import_helpers.StyleObjectProperty]).concat(PROP_SPLIT).concat(descriptor.name);
|
|
7527
|
+
fullKey in usedKeys || (addStyleToInsertRules(rulesToInsert, psuedoStyle), mergeClassName(transforms, classNames, fullKey, psuedoStyle[import_helpers.StyleObjectIdentifier], isMediaOrPseudo1, !0));
|
|
7528
|
+
}
|
|
7529
|
+
} catch (err) {
|
|
7530
|
+
_didIteratorError2 = !0, _iteratorError2 = err;
|
|
7531
|
+
} finally {
|
|
7532
|
+
try {
|
|
7533
|
+
!_iteratorNormalCompletion2 && _iterator2.return != null && _iterator2.return();
|
|
7534
|
+
} finally {
|
|
7535
|
+
if (_didIteratorError2) throw _iteratorError2;
|
|
7536
|
+
}
|
|
7537
|
+
}
|
|
7538
|
+
}
|
|
7539
|
+
if (!shouldDoClasses || isExit || isEnter) {
|
|
7540
|
+
var descriptorKey = descriptor.stateKey || descriptor.name, isDisabled = componentState[descriptorKey] === !1;
|
|
7541
|
+
isExit && (isDisabled = !styleProps.isExiting), isEnter && componentState.unmounted === !1 && (isDisabled = !0);
|
|
7542
|
+
var importance = descriptor.priority;
|
|
7543
|
+
for (var pkey in pseudoStyleObject) {
|
|
7544
|
+
var val12 = pseudoStyleObject[pkey];
|
|
7545
|
+
if (isDisabled) applyDefaultStyle(pkey, styleState);
|
|
7546
|
+
else {
|
|
7547
|
+
var curImportance = usedKeys[pkey] || 0, shouldMerge = importance >= curImportance;
|
|
7548
|
+
if (shouldMerge) {
|
|
7549
|
+
var _pseudos1, _key1;
|
|
7550
|
+
pseudos || (pseudos = {}), (_pseudos1 = pseudos)[_key1 = key4] || (_pseudos1[_key1] = {}), pseudos[key4][pkey] = val12, mergeStyle(styleState, pkey, val12);
|
|
7551
|
+
}
|
|
7552
|
+
}
|
|
7553
|
+
}
|
|
7554
|
+
if (!isDisabled) for (var key12 in val2) {
|
|
7555
|
+
var k1 = shorthands[key12] || key12;
|
|
7556
|
+
usedKeys[k1] = Math.max(importance, usedKeys[k1] || 0);
|
|
7557
|
+
}
|
|
7558
|
+
}
|
|
7559
|
+
return "continue";
|
|
7560
|
+
}
|
|
7561
|
+
if (isMedia) {
|
|
7562
|
+
if (!val2) return "continue";
|
|
7563
|
+
var hasSpace = val2.space, mediaKeyShort = key4.slice(1);
|
|
7564
|
+
if (hasMedia || (hasMedia = !0), (hasSpace || !shouldDoClasses || styleProps.willBeAnimated) && (((typeof hasMedia > "u" ? "undefined" : _type_of(hasMedia)) > "u" ? "undefined" : _type_of1(hasMedia)) !== "object" && (hasMedia = {}), hasMedia[mediaKeyShort] = !0), isMedia === "platform" && !(0, import_isActivePlatform.isActivePlatform)(key4)) return "continue";
|
|
7565
|
+
if (shouldDoClasses) {
|
|
7566
|
+
var mediaStyle = getSubStyle(styleState, key4, val2, !1);
|
|
7567
|
+
if (hasSpace && (delete mediaStyle.space, mediaState2[mediaKeyShort])) {
|
|
7568
|
+
var importance1 = (0, import_useMedia.getMediaImportanceIfMoreImportant)(mediaKeyShort, "space", usedKeys, !0);
|
|
7569
|
+
importance1 && (space = val2.space, usedKeys.space = importance1);
|
|
7570
|
+
}
|
|
7571
|
+
var mediaStyles = (0, import_getStylesAtomic.getStylesAtomic)(mediaStyle), priority = mediaStylesSeen;
|
|
7572
|
+
mediaStylesSeen += 1;
|
|
7573
|
+
var _iteratorNormalCompletion12 = !0, _didIteratorError12 = !1, _iteratorError12 = void 0;
|
|
7574
|
+
try {
|
|
7575
|
+
for (var _iterator12 = mediaStyles[Symbol.iterator](), _step12; !(_iteratorNormalCompletion12 = (_step12 = _iterator12.next()).done); _iteratorNormalCompletion12 = !0) {
|
|
7576
|
+
var style3 = _step12.value, property = style3[0];
|
|
7577
|
+
if (!(property[0] === "$" && property.startsWith("$platform") && !(0, import_isActivePlatform.isActivePlatform)(property))) {
|
|
7578
|
+
var out = (0, import_createMediaStyle.createMediaStyle)(style3, mediaKeyShort, import_useMedia.mediaQueryConfig, isMedia, !1, priority), fullKey1 = "".concat(style3[import_helpers.StyleObjectProperty]).concat(PROP_SPLIT).concat(mediaKeyShort).concat(style3[import_helpers.StyleObjectPseudo] || "");
|
|
7579
|
+
fullKey1 in usedKeys || (addStyleToInsertRules(rulesToInsert, out), mergeClassName(transforms, classNames, fullKey1, out[import_helpers.StyleObjectIdentifier], !0, !0));
|
|
7580
|
+
}
|
|
7581
|
+
}
|
|
7582
|
+
} catch (err) {
|
|
7583
|
+
_didIteratorError12 = !0, _iteratorError12 = err;
|
|
7584
|
+
} finally {
|
|
7585
|
+
try {
|
|
7586
|
+
!_iteratorNormalCompletion12 && _iterator12.return != null && _iterator12.return();
|
|
7587
|
+
} finally {
|
|
7588
|
+
if (_didIteratorError12) throw _iteratorError12;
|
|
7589
|
+
}
|
|
7590
|
+
}
|
|
7591
|
+
} else {
|
|
7592
|
+
var mergeMediaStyle = function(key5, val3) {
|
|
7593
|
+
var _styleState4;
|
|
7594
|
+
(_styleState4 = styleState).style || (_styleState4.style = {});
|
|
7595
|
+
var didMerge = mergeMediaByImportance(styleState, mediaKeyShort, key5, val3, usedKeys, mediaState2[mediaKeyShort], importanceBump, debug);
|
|
7596
|
+
didMerge && key5 === "fontFamily" && (styleState.fontFamily = mediaStyle1.fontFamily);
|
|
7597
|
+
}, isThemeMedia = isMedia === "theme", isGroupMedia = isMedia === "group", isPlatformMedia = isMedia === "platform";
|
|
7598
|
+
if (!isThemeMedia && !isPlatformMedia && !isGroupMedia && !mediaState2[mediaKeyShort])
|
|
7599
|
+
return "continue";
|
|
7600
|
+
var mediaStyle1 = getSubStyle(styleState, key4, val2, !0), importanceBump = 0;
|
|
7601
|
+
if (isThemeMedia) {
|
|
7602
|
+
dynamicThemeAccess = !0;
|
|
7603
|
+
var mediaThemeName = mediaKeyShort.slice(6);
|
|
7604
|
+
if (!(themeName === mediaThemeName || themeName.startsWith(mediaThemeName))) return "continue";
|
|
7605
|
+
} else if (isGroupMedia) {
|
|
7606
|
+
var _componentState_group, groupInfo = (0, import_getGroupPropParts.getGroupPropParts)(mediaKeyShort), groupName = groupInfo.name, groupContext = context == null ? void 0 : context.groups.state[groupName];
|
|
7607
|
+
if (!groupContext) return "continue";
|
|
7608
|
+
var groupPseudoKey = groupInfo.pseudo, groupMediaKey = groupInfo.media, componentGroupState = (_componentState_group = componentState.group) === null || _componentState_group === void 0 ? void 0 : _componentState_group[groupName];
|
|
7609
|
+
if (groupMediaKey) {
|
|
7610
|
+
mediaGroups || (mediaGroups = /* @__PURE__ */ new Set()), mediaGroups.add(groupMediaKey);
|
|
7611
|
+
var mediaState1 = componentGroupState == null ? void 0 : componentGroupState.media, isActive = mediaState1 == null ? void 0 : mediaState1[groupMediaKey];
|
|
7612
|
+
if (!mediaState1 && groupContext.layout && (isActive = (0, import_useMedia.mediaKeyMatch)(groupMediaKey, groupContext.layout)), !isActive) {
|
|
7613
|
+
for (var pkey1 in mediaStyle1) applyDefaultStyle(pkey1, styleState);
|
|
7614
|
+
return "continue";
|
|
7615
|
+
}
|
|
7616
|
+
importanceBump = 2;
|
|
7617
|
+
}
|
|
7618
|
+
if (groupPseudoKey) {
|
|
7619
|
+
pseudoGroups || (pseudoGroups = /* @__PURE__ */ new Set()), pseudoGroups.add(groupName);
|
|
7620
|
+
var componentGroupPseudoState = (componentGroupState || // fallback to context initially
|
|
7621
|
+
context.groups.state[groupName]).pseudo, isActive1 = componentGroupPseudoState == null ? void 0 : componentGroupPseudoState[groupPseudoKey], priority1 = import_pseudoDescriptors.pseudoPriorities[groupPseudoKey];
|
|
7622
|
+
if (!isActive1) {
|
|
7623
|
+
for (var pkey2 in mediaStyle1) applyDefaultStyle(pkey2, styleState);
|
|
7624
|
+
return "continue";
|
|
7625
|
+
}
|
|
7626
|
+
importanceBump = priority1;
|
|
7627
|
+
}
|
|
7628
|
+
}
|
|
7629
|
+
for (var subKey in mediaStyle1) {
|
|
7630
|
+
if (subKey === "space") {
|
|
7631
|
+
space = valInit.space;
|
|
7632
|
+
continue;
|
|
7633
|
+
}
|
|
7634
|
+
if (subKey[0] === "$") {
|
|
7635
|
+
if (!(0, import_isActivePlatform.isActivePlatform)(subKey)) continue;
|
|
7636
|
+
for (var subSubKey in mediaStyle1[subKey]) mergeMediaStyle(subSubKey, mediaStyle1[subKey][subSubKey]);
|
|
7637
|
+
} else mergeMediaStyle(subKey, mediaStyle1[subKey]);
|
|
7638
|
+
}
|
|
7639
|
+
}
|
|
7640
|
+
return "continue";
|
|
7641
|
+
}
|
|
7642
|
+
if (key4 === "pointerEvents") return viewProps[key4] = val2, "continue";
|
|
7643
|
+
if (
|
|
7644
|
+
// is HOC we can just pass through the styles as props
|
|
7645
|
+
// this fixes issues where style prop got merged with wrong priority
|
|
7646
|
+
!isHOC && (isValidStyleKey(key4, staticConfig) || import_constants.isAndroid && key4 === "elevation")
|
|
7647
|
+
) return mergeStyle(styleState, key4, val2), "continue";
|
|
7648
|
+
isVariant || (viewProps[key4] = val2);
|
|
7649
|
+
}, keyInit = keyOg2, valInit = props[keyInit];
|
|
7650
|
+
if (accept) {
|
|
7651
|
+
var accepted = accept[keyInit];
|
|
7652
|
+
if ((accepted === "style" || accepted === "textStyle") && valInit && ((typeof valInit > "u" ? "undefined" : _type_of(valInit)) > "u" ? "undefined" : _type_of1(valInit)) === "object") return viewProps[keyInit] = getSubStyle(styleState, keyInit, valInit, styleProps.noClassNames), "continue";
|
|
7653
|
+
}
|
|
7654
|
+
if (disableExpandShorthands || keyInit in shorthands && (keyInit = shorthands[keyInit]), keyInit === "className" || keyInit in usedKeys) return "continue";
|
|
7655
|
+
if (keyInit in import_skipProps.skipProps && !noSkip && !isHOC) {
|
|
7656
|
+
if (keyInit === "group" && !1) var identifier2, containerType, containerCSS;
|
|
7657
|
+
return "continue";
|
|
7658
|
+
}
|
|
7659
|
+
var valInitType = (typeof valInit > "u" ? "undefined" : _type_of(valInit)) > "u" ? "undefined" : _type_of1(valInit), isValidStyleKeyInit = isValidStyleKey(keyInit, staticConfig);
|
|
7660
|
+
if (0) {
|
|
7661
|
+
var isValidClassName, isMediaOrPseudo;
|
|
7662
|
+
if ((isValidClassName || isMediaOrPseudo) && !shouldDoClasses) var _styleState3;
|
|
7663
|
+
}
|
|
7664
|
+
if (!isValidStyleKeyInit) {
|
|
7665
|
+
if (!import_constants.isAndroid && keyInit === "elevationAndroid") return "continue";
|
|
7666
|
+
if (keyInit === "userSelect") keyInit = "selectable", valInit = valInit !== "none";
|
|
7667
|
+
else if (keyInit.startsWith("data-")) return "continue";
|
|
7668
|
+
}
|
|
7669
|
+
if (keyInit === "dataSet") {
|
|
7670
|
+
for (var keyInit1 in valInit) viewProps["data-".concat(hyphenate(keyInit1))] = valInit[keyInit1];
|
|
7671
|
+
return "continue";
|
|
7672
|
+
}
|
|
7673
|
+
if (0) var didUseKeyInit;
|
|
7674
|
+
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);
|
|
7675
|
+
if (isMediaOrPseudo1 && keyInit.startsWith("$group-")) {
|
|
7676
|
+
var name2 = keyInit.split("-")[1];
|
|
7677
|
+
context != null && context.groups.subscribe && !(context != null && context.groups.state[name2]) && (keyInit = keyInit.replace("$group-", "$group-true-"));
|
|
7678
|
+
}
|
|
7679
|
+
var isStyleProp = isValidStyleKeyInit || isMediaOrPseudo1 || isVariant && !noExpand || isShorthand;
|
|
7680
|
+
if (isStyleProp && (asChild === "except-style" || asChild === "except-style-web")) return "continue";
|
|
7681
|
+
var shouldPassProp = !isStyleProp || // is in parent variants
|
|
7682
|
+
isHOC && parentVariants && keyInit in parentVariants || (inlineProps == null ? void 0 : inlineProps.has(keyInit)), parentVariant = parentVariants == null ? void 0 : parentVariants[keyInit], isHOCShouldPassThrough = !!(isHOC && (isShorthand || isValidStyleKeyInit || isMediaOrPseudo1 || parentVariant || keyInit in import_skipProps.skipProps)), shouldPassThrough = shouldPassProp || isHOCShouldPassThrough;
|
|
7683
|
+
if (shouldPassThrough && (passDownProp(viewProps, keyInit, valInit, isMediaOrPseudo1), !isVariant) || !noSkip && keyInit in import_skipProps.skipProps) return "continue";
|
|
7684
|
+
(isText || isInput) && valInit && (keyInit === "fontFamily" || keyInit === shorthands.fontFamily) && valInit in conf.fontsParsed && (styleState.fontFamily = valInit);
|
|
7685
|
+
var avoidPropMap = isMediaOrPseudo1 || !isVariant && !isValidStyleKeyInit, expanded = avoidPropMap ? null : (0, import_propMapper.propMapper)(keyInit, valInit, styleState);
|
|
7686
|
+
if (!avoidPropMap) {
|
|
7687
|
+
if (!expanded) return "continue";
|
|
7688
|
+
var next = (0, import_propMapper.getPropMappedFontFamily)(expanded);
|
|
7689
|
+
next && (styleState.fontFamily = next);
|
|
7690
|
+
}
|
|
7691
|
+
if (0)
|
|
7692
|
+
try {
|
|
7693
|
+
} catch (e) {
|
|
7694
|
+
}
|
|
7695
|
+
for (var key4 = keyInit, val2 = valInit, max = expanded ? expanded.length : 1, i2 = 0; i2 < max; i2++) _loop22(i2);
|
|
7696
|
+
if (0)
|
|
7697
|
+
try {
|
|
7698
|
+
} catch (e) {
|
|
7699
|
+
}
|
|
7700
|
+
};
|
|
7433
7701
|
conf = conf || (0, import_config.getConfig)(), import_constants.isWeb && styleProps.isAnimated && conf.animations.isReactNative && !styleProps.noNormalize && (styleProps.noNormalize = "values");
|
|
7434
7702
|
var shorthands = conf.shorthands, isHOC = staticConfig.isHOC, isText = staticConfig.isText, isInput = staticConfig.isInput, variants = staticConfig.variants, isReactNative = staticConfig.isReactNative, inlineProps = staticConfig.inlineProps, inlineWhenUnflattened = staticConfig.inlineWhenUnflattened, parentStaticConfig = staticConfig.parentStaticConfig, acceptsClassName = staticConfig.acceptsClassName, viewProps = {}, mediaState2 = styleProps.mediaState || import_useMedia.mediaState, usedKeys = {}, shouldDoClasses = acceptsClassName && import_constants.isWeb && !styleProps.noClassNames, rulesToInsert = void 0, classNames = {}, transforms = {}, pseudos = null, space = props.space, hasMedia = !1, dynamicThemeAccess, pseudoGroups, mediaGroups, className = props.className || "", mediaStylesSeen = 0, curPropsState, styleState = {
|
|
7435
7703
|
// this should go away, right now we're doing really crazy cumulative props,
|
|
@@ -7454,243 +7722,24 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7454
7722
|
debug,
|
|
7455
7723
|
skipThemeTokenResolution
|
|
7456
7724
|
}, asChild = props.asChild, accept = staticConfig.accept, noSkip = styleProps.noSkip, disableExpandShorthands = styleProps.disableExpandShorthands, noExpand = styleProps.noExpand, webContainerType = conf.settings.webContainerType, parentVariants = parentStaticConfig == null ? void 0 : parentStaticConfig.variants;
|
|
7457
|
-
for (var keyOg in props)
|
|
7458
|
-
var keyInit = keyOg, valInit = props[keyInit];
|
|
7459
|
-
if (accept) {
|
|
7460
|
-
var accepted = accept[keyInit];
|
|
7461
|
-
if ((accepted === "style" || accepted === "textStyle") && valInit && ((typeof valInit > "u" ? "undefined" : _type_of(valInit)) > "u" ? "undefined" : _type_of1(valInit)) === "object") {
|
|
7462
|
-
viewProps[keyInit] = getSubStyle(styleState, keyInit, valInit, styleProps.noClassNames);
|
|
7463
|
-
continue;
|
|
7464
|
-
}
|
|
7465
|
-
}
|
|
7466
|
-
if (disableExpandShorthands || keyInit in shorthands && (keyInit = shorthands[keyInit]), keyInit !== "className" && !(keyInit in usedKeys)) {
|
|
7467
|
-
if (keyInit in import_skipProps.skipProps && !noSkip && !isHOC) {
|
|
7468
|
-
if (keyInit === "group" && !1) var identifier, containerType, containerCSS;
|
|
7469
|
-
continue;
|
|
7470
|
-
}
|
|
7471
|
-
var valInitType = (typeof valInit > "u" ? "undefined" : _type_of(valInit)) > "u" ? "undefined" : _type_of1(valInit), isValidStyleKeyInit = isValidStyleKey(keyInit, staticConfig);
|
|
7472
|
-
if (0) {
|
|
7473
|
-
var isValidClassName, isMediaOrPseudo;
|
|
7474
|
-
if ((isValidClassName || isMediaOrPseudo) && !shouldDoClasses) var _styleState;
|
|
7475
|
-
}
|
|
7476
|
-
if (!isValidStyleKeyInit) {
|
|
7477
|
-
if (!import_constants.isAndroid && keyInit === "elevationAndroid") continue;
|
|
7478
|
-
if (keyInit === "userSelect") keyInit = "selectable", valInit = valInit !== "none";
|
|
7479
|
-
else if (keyInit.startsWith("data-")) continue;
|
|
7480
|
-
}
|
|
7481
|
-
if (keyInit === "dataSet") {
|
|
7482
|
-
for (var keyInit1 in valInit) viewProps["data-".concat(hyphenate(keyInit1))] = valInit[keyInit1];
|
|
7483
|
-
continue;
|
|
7484
|
-
}
|
|
7485
|
-
if (0) var didUseKeyInit;
|
|
7486
|
-
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);
|
|
7487
|
-
if (isMediaOrPseudo1 && keyInit.startsWith("$group-")) {
|
|
7488
|
-
var name = keyInit.split("-")[1];
|
|
7489
|
-
context != null && context.groups.subscribe && !(context != null && context.groups.state[name]) && (keyInit = keyInit.replace("$group-", "$group-true-"));
|
|
7490
|
-
}
|
|
7491
|
-
var isStyleProp = isValidStyleKeyInit || isMediaOrPseudo1 || isVariant && !noExpand || isShorthand;
|
|
7492
|
-
if (!(isStyleProp && (asChild === "except-style" || asChild === "except-style-web"))) {
|
|
7493
|
-
var shouldPassProp = !isStyleProp || // is in parent variants
|
|
7494
|
-
isHOC && parentVariants && keyInit in parentVariants || (inlineProps == null ? void 0 : inlineProps.has(keyInit)), parentVariant = parentVariants == null ? void 0 : parentVariants[keyInit], isHOCShouldPassThrough = !!(isHOC && (isShorthand || isValidStyleKeyInit || isMediaOrPseudo1 || parentVariant || keyInit in import_skipProps.skipProps)), shouldPassThrough = shouldPassProp || isHOCShouldPassThrough;
|
|
7495
|
-
if (shouldPassThrough && (passDownProp(viewProps, keyInit, valInit, isMediaOrPseudo1), !isVariant) || !noSkip && keyInit in import_skipProps.skipProps)
|
|
7496
|
-
continue;
|
|
7497
|
-
(isText || isInput) && valInit && (keyInit === "fontFamily" || keyInit === shorthands.fontFamily) && valInit in conf.fontsParsed && (styleState.fontFamily = valInit);
|
|
7498
|
-
var avoidPropMap = isMediaOrPseudo1 || !isVariant && !isValidStyleKeyInit, expanded = avoidPropMap ? null : (0, import_propMapper.propMapper)(keyInit, valInit, styleState);
|
|
7499
|
-
if (!avoidPropMap) {
|
|
7500
|
-
if (!expanded) continue;
|
|
7501
|
-
var next = (0, import_propMapper.getPropMappedFontFamily)(expanded);
|
|
7502
|
-
next && (styleState.fontFamily = next);
|
|
7503
|
-
}
|
|
7504
|
-
if (0)
|
|
7505
|
-
try {
|
|
7506
|
-
} catch (e) {
|
|
7507
|
-
}
|
|
7508
|
-
for (var key = keyInit, val = valInit, max = expanded ? expanded.length : 1, i = 0; i < max; i++) {
|
|
7509
|
-
var _parentStaticConfig_variants;
|
|
7510
|
-
if (expanded) {
|
|
7511
|
-
var _expanded_i = _sliced_to_array(expanded[i], 2), k = _expanded_i[0], v = _expanded_i[1];
|
|
7512
|
-
key = k, val = v;
|
|
7513
|
-
}
|
|
7514
|
-
if (val != null && !(key in usedKeys)) {
|
|
7515
|
-
if (isPseudo = key in import_helpers.validPseudoKeys, isMedia = !isPseudo && !isValidStyleKeyInit && (0, import_useMedia.isMediaKey)(key), isMediaOrPseudo1 = !!(isMedia || isPseudo), isVariant = variants && key in variants, inlineProps != null && inlineProps.has(key) || process.env.IS_STATIC === "is_static" && inlineWhenUnflattened != null && inlineWhenUnflattened.has(key)) {
|
|
7516
|
-
var _props_key;
|
|
7517
|
-
viewProps[key] = (_props_key = props[key]) !== null && _props_key !== void 0 ? _props_key : val;
|
|
7518
|
-
}
|
|
7519
|
-
var shouldPassThrough1 = styleProps.noExpand && isPseudo || isHOC && (isMediaOrPseudo1 || (parentStaticConfig == null || (_parentStaticConfig_variants = parentStaticConfig.variants) === null || _parentStaticConfig_variants === void 0 ? void 0 : _parentStaticConfig_variants[keyInit]));
|
|
7520
|
-
if (shouldPassThrough1) {
|
|
7521
|
-
passDownProp(viewProps, key, val, isMediaOrPseudo1);
|
|
7522
|
-
continue;
|
|
7523
|
-
}
|
|
7524
|
-
if (isPseudo) {
|
|
7525
|
-
if (!val) continue;
|
|
7526
|
-
var pseudoStyleObject = getSubStyle(styleState, key, val, styleProps.noClassNames), descriptor = import_pseudoDescriptors.pseudoDescriptors[key], isEnter = key === "enterStyle", isExit = key === "exitStyle";
|
|
7527
|
-
if (!descriptor) continue;
|
|
7528
|
-
if (!shouldDoClasses || process.env.IS_STATIC === "is_static") {
|
|
7529
|
-
var _pseudos, _key;
|
|
7530
|
-
if (pseudos || (pseudos = {}), (_pseudos = pseudos)[_key = key] || (_pseudos[_key] = {}), process.env.IS_STATIC === "is_static") {
|
|
7531
|
-
Object.assign(pseudos[key], pseudoStyleObject);
|
|
7532
|
-
continue;
|
|
7533
|
-
}
|
|
7534
|
-
}
|
|
7535
|
-
if (shouldDoClasses && !isExit) {
|
|
7536
|
-
var pseudoStyles = (0, import_getStylesAtomic.getStyleAtomic)(pseudoStyleObject, descriptor), _iteratorNormalCompletion = !0, _didIteratorError = !1, _iteratorError = void 0;
|
|
7537
|
-
try {
|
|
7538
|
-
for (var _iterator = pseudoStyles[Symbol.iterator](), _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = !0) {
|
|
7539
|
-
var psuedoStyle = _step.value, fullKey = "".concat(psuedoStyle[import_helpers.StyleObjectProperty]).concat(PROP_SPLIT).concat(descriptor.name);
|
|
7540
|
-
fullKey in usedKeys || (addStyleToInsertRules(rulesToInsert, psuedoStyle), mergeClassName(transforms, classNames, fullKey, psuedoStyle[import_helpers.StyleObjectIdentifier], isMediaOrPseudo1, !0));
|
|
7541
|
-
}
|
|
7542
|
-
} catch (err) {
|
|
7543
|
-
_didIteratorError = !0, _iteratorError = err;
|
|
7544
|
-
} finally {
|
|
7545
|
-
try {
|
|
7546
|
-
!_iteratorNormalCompletion && _iterator.return != null && _iterator.return();
|
|
7547
|
-
} finally {
|
|
7548
|
-
if (_didIteratorError) throw _iteratorError;
|
|
7549
|
-
}
|
|
7550
|
-
}
|
|
7551
|
-
}
|
|
7552
|
-
if (!shouldDoClasses || isExit || isEnter) {
|
|
7553
|
-
var descriptorKey = descriptor.stateKey || descriptor.name, isDisabled = componentState[descriptorKey] === !1;
|
|
7554
|
-
isExit && (isDisabled = !styleProps.isExiting), isEnter && componentState.unmounted === !1 && (isDisabled = !0);
|
|
7555
|
-
var importance = descriptor.priority;
|
|
7556
|
-
for (var pkey in pseudoStyleObject) {
|
|
7557
|
-
var val1 = pseudoStyleObject[pkey];
|
|
7558
|
-
if (isDisabled) applyDefaultStyle(pkey, styleState);
|
|
7559
|
-
else {
|
|
7560
|
-
var curImportance = usedKeys[pkey] || 0, shouldMerge = importance >= curImportance;
|
|
7561
|
-
if (shouldMerge) {
|
|
7562
|
-
var _pseudos1, _key1;
|
|
7563
|
-
pseudos || (pseudos = {}), (_pseudos1 = pseudos)[_key1 = key] || (_pseudos1[_key1] = {}), pseudos[key][pkey] = val1, mergeStyle(styleState, pkey, val1);
|
|
7564
|
-
}
|
|
7565
|
-
}
|
|
7566
|
-
}
|
|
7567
|
-
if (!isDisabled) for (var key1 in val) {
|
|
7568
|
-
var k1 = shorthands[key1] || key1;
|
|
7569
|
-
usedKeys[k1] = Math.max(importance, usedKeys[k1] || 0);
|
|
7570
|
-
}
|
|
7571
|
-
}
|
|
7572
|
-
continue;
|
|
7573
|
-
}
|
|
7574
|
-
if (isMedia) {
|
|
7575
|
-
if (!val) continue;
|
|
7576
|
-
var hasSpace = val.space, mediaKeyShort = key.slice(1);
|
|
7577
|
-
if (hasMedia || (hasMedia = !0), (hasSpace || !shouldDoClasses || styleProps.willBeAnimated) && (((typeof hasMedia > "u" ? "undefined" : _type_of(hasMedia)) > "u" ? "undefined" : _type_of1(hasMedia)) !== "object" && (hasMedia = {}), hasMedia[mediaKeyShort] = !0), isMedia === "platform") {
|
|
7578
|
-
var platform = key.slice(10);
|
|
7579
|
-
if (
|
|
7580
|
-
// supports web, ios, android
|
|
7581
|
-
platform !== import_constants.currentPlatform && // supports web, native
|
|
7582
|
-
platform !== "native"
|
|
7583
|
-
) continue;
|
|
7584
|
-
}
|
|
7585
|
-
if (shouldDoClasses) {
|
|
7586
|
-
var mediaStyle = getSubStyle(styleState, key, val, !1);
|
|
7587
|
-
if (hasSpace && (delete mediaStyle.space, mediaState2[mediaKeyShort])) {
|
|
7588
|
-
var importance1 = (0, import_useMedia.getMediaImportanceIfMoreImportant)(mediaKeyShort, "space", usedKeys, !0);
|
|
7589
|
-
importance1 && (space = val.space, usedKeys.space = importance1);
|
|
7590
|
-
}
|
|
7591
|
-
var mediaStyles = (0, import_getStylesAtomic.getStylesAtomic)(mediaStyle), priority = mediaStylesSeen;
|
|
7592
|
-
mediaStylesSeen += 1;
|
|
7593
|
-
var _iteratorNormalCompletion1 = !0, _didIteratorError1 = !1, _iteratorError1 = void 0;
|
|
7594
|
-
try {
|
|
7595
|
-
for (var _iterator1 = mediaStyles[Symbol.iterator](), _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = !0) {
|
|
7596
|
-
var style = _step1.value, out = (0, import_createMediaStyle.createMediaStyle)(style, mediaKeyShort, import_useMedia.mediaQueryConfig, isMedia, !1, priority), fullKey1 = "".concat(style[import_helpers.StyleObjectProperty]).concat(PROP_SPLIT).concat(mediaKeyShort).concat(style[import_helpers.StyleObjectPseudo] || "");
|
|
7597
|
-
fullKey1 in usedKeys || (addStyleToInsertRules(rulesToInsert, out), mergeClassName(transforms, classNames, fullKey1, out[import_helpers.StyleObjectIdentifier], !0, !0));
|
|
7598
|
-
}
|
|
7599
|
-
} catch (err) {
|
|
7600
|
-
_didIteratorError1 = !0, _iteratorError1 = err;
|
|
7601
|
-
} finally {
|
|
7602
|
-
try {
|
|
7603
|
-
!_iteratorNormalCompletion1 && _iterator1.return != null && _iterator1.return();
|
|
7604
|
-
} finally {
|
|
7605
|
-
if (_didIteratorError1) throw _iteratorError1;
|
|
7606
|
-
}
|
|
7607
|
-
}
|
|
7608
|
-
} else {
|
|
7609
|
-
var isThemeMedia = isMedia === "theme", isGroupMedia = isMedia === "group", isPlatformMedia = isMedia === "platform";
|
|
7610
|
-
if (!isThemeMedia && !isPlatformMedia && !isGroupMedia && !mediaState2[mediaKeyShort])
|
|
7611
|
-
continue;
|
|
7612
|
-
var mediaStyle1 = getSubStyle(styleState, key, val, !0), importanceBump = 0;
|
|
7613
|
-
if (isThemeMedia) {
|
|
7614
|
-
dynamicThemeAccess = !0;
|
|
7615
|
-
var mediaThemeName = mediaKeyShort.slice(6);
|
|
7616
|
-
if (!(themeName === mediaThemeName || themeName.startsWith(mediaThemeName))) continue;
|
|
7617
|
-
} else if (isGroupMedia) {
|
|
7618
|
-
var _componentState_group, groupInfo = (0, import_getGroupPropParts.getGroupPropParts)(mediaKeyShort), groupName = groupInfo.name, groupContext = context == null ? void 0 : context.groups.state[groupName];
|
|
7619
|
-
if (!groupContext)
|
|
7620
|
-
continue;
|
|
7621
|
-
var groupPseudoKey = groupInfo.pseudo, groupMediaKey = groupInfo.media, componentGroupState = (_componentState_group = componentState.group) === null || _componentState_group === void 0 ? void 0 : _componentState_group[groupName];
|
|
7622
|
-
if (groupMediaKey) {
|
|
7623
|
-
mediaGroups || (mediaGroups = /* @__PURE__ */ new Set()), mediaGroups.add(groupMediaKey);
|
|
7624
|
-
var mediaState1 = componentGroupState == null ? void 0 : componentGroupState.media, isActive = mediaState1 == null ? void 0 : mediaState1[groupMediaKey];
|
|
7625
|
-
if (!mediaState1 && groupContext.layout && (isActive = (0, import_useMedia.mediaKeyMatch)(groupMediaKey, groupContext.layout)), !isActive) {
|
|
7626
|
-
for (var pkey1 in mediaStyle1) applyDefaultStyle(pkey1, styleState);
|
|
7627
|
-
continue;
|
|
7628
|
-
}
|
|
7629
|
-
importanceBump = 2;
|
|
7630
|
-
}
|
|
7631
|
-
if (groupPseudoKey) {
|
|
7632
|
-
pseudoGroups || (pseudoGroups = /* @__PURE__ */ new Set()), pseudoGroups.add(groupName);
|
|
7633
|
-
var componentGroupPseudoState = (componentGroupState || // fallback to context initially
|
|
7634
|
-
context.groups.state[groupName]).pseudo, isActive1 = componentGroupPseudoState == null ? void 0 : componentGroupPseudoState[groupPseudoKey], priority1 = import_pseudoDescriptors.pseudoPriorities[groupPseudoKey];
|
|
7635
|
-
if (!isActive1) {
|
|
7636
|
-
for (var pkey2 in mediaStyle1) applyDefaultStyle(pkey2, styleState);
|
|
7637
|
-
continue;
|
|
7638
|
-
}
|
|
7639
|
-
importanceBump = priority1;
|
|
7640
|
-
}
|
|
7641
|
-
}
|
|
7642
|
-
for (var subKey in mediaStyle1) {
|
|
7643
|
-
var _styleState1;
|
|
7644
|
-
if (subKey === "space") {
|
|
7645
|
-
space = valInit.space;
|
|
7646
|
-
continue;
|
|
7647
|
-
}
|
|
7648
|
-
(_styleState1 = styleState).style || (_styleState1.style = {});
|
|
7649
|
-
var didMerge = mergeMediaByImportance(styleState, mediaKeyShort, subKey, mediaStyle1[subKey], usedKeys, mediaState2[mediaKeyShort], importanceBump, debug);
|
|
7650
|
-
didMerge && key === "fontFamily" && (styleState.fontFamily = mediaStyle1.fontFamily);
|
|
7651
|
-
}
|
|
7652
|
-
}
|
|
7653
|
-
continue;
|
|
7654
|
-
}
|
|
7655
|
-
if (key === "pointerEvents") {
|
|
7656
|
-
viewProps[key] = val;
|
|
7657
|
-
continue;
|
|
7658
|
-
}
|
|
7659
|
-
if (
|
|
7660
|
-
// is HOC we can just pass through the styles as props
|
|
7661
|
-
// this fixes issues where style prop got merged with wrong priority
|
|
7662
|
-
!isHOC && (isValidStyleKey(key, staticConfig) || import_constants.isAndroid && key === "elevation")
|
|
7663
|
-
) {
|
|
7664
|
-
mergeStyle(styleState, key, val);
|
|
7665
|
-
continue;
|
|
7666
|
-
}
|
|
7667
|
-
isVariant || (viewProps[key] = val);
|
|
7668
|
-
}
|
|
7669
|
-
}
|
|
7670
|
-
if (0)
|
|
7671
|
-
try {
|
|
7672
|
-
} catch (e) {
|
|
7673
|
-
}
|
|
7674
|
-
}
|
|
7675
|
-
}
|
|
7676
|
-
}
|
|
7725
|
+
for (var keyOg in props) _loop(keyOg);
|
|
7677
7726
|
var avoidNormalize = styleProps.noNormalize === !1;
|
|
7678
7727
|
if (!avoidNormalize) {
|
|
7679
7728
|
if (styleState.style && ((0, import_expandStyles.fixStyles)(styleState.style), import_constants.isWeb && !isReactNative && (0, import_getStylesAtomic.styleToCSS)(styleState.style)), styleState.flatTransforms) {
|
|
7680
|
-
var
|
|
7681
|
-
(
|
|
7729
|
+
var _styleState;
|
|
7730
|
+
(_styleState = styleState).style || (_styleState.style = {}), Object.entries(styleState.flatTransforms).sort(function(param, param1) {
|
|
7682
7731
|
var _param = _sliced_to_array(param, 1), a = _param[0], _param1 = _sliced_to_array(param1, 1), b = _param1[0];
|
|
7683
7732
|
return a.localeCompare(b);
|
|
7684
7733
|
}).forEach(function(param) {
|
|
7685
|
-
var _param = _sliced_to_array(param, 2),
|
|
7686
|
-
mergeTransform(styleState.style,
|
|
7734
|
+
var _param = _sliced_to_array(param, 2), key4 = _param[0], val2 = _param[1];
|
|
7735
|
+
mergeTransform(styleState.style, key4, val2, !0);
|
|
7687
7736
|
});
|
|
7688
7737
|
}
|
|
7689
7738
|
if (parentSplitStyles) {
|
|
7690
|
-
if (0) for (var
|
|
7691
|
-
if (!shouldDoClasses) for (var
|
|
7692
|
-
var
|
|
7693
|
-
|
|
7739
|
+
if (0) for (var key in parentSplitStyles.classNames) var val;
|
|
7740
|
+
if (!shouldDoClasses) for (var key1 in parentSplitStyles.style) {
|
|
7741
|
+
var _styleState1;
|
|
7742
|
+
key1 in classNames || styleState.style && key1 in styleState.style || ((_styleState1 = styleState).style || (_styleState1.style = {}), styleState.style[key1] = parentSplitStyles.style[key1]);
|
|
7694
7743
|
}
|
|
7695
7744
|
}
|
|
7696
7745
|
}
|
|
@@ -7699,9 +7748,9 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7699
7748
|
if (styleState.style && shouldDoClasses) {
|
|
7700
7749
|
var retainedStyles, shouldRetain;
|
|
7701
7750
|
if (!styleState.style.$$css) {
|
|
7702
|
-
var atomic,
|
|
7751
|
+
var atomic, _iteratorNormalCompletion, _didIteratorError, _iteratorError;
|
|
7703
7752
|
try {
|
|
7704
|
-
for (var
|
|
7753
|
+
for (var _iterator, _step; !(_iteratorNormalCompletion = (_step = _iterator.next()).done); _iteratorNormalCompletion = !0) var atomicStyle, _props_animateOnly, _atomicStyle, key2, value, identifier, isAnimatedAndAnimateOnly, nonAnimatedAnimateOnly;
|
|
7705
7754
|
} catch (err) {
|
|
7706
7755
|
} finally {
|
|
7707
7756
|
try {
|
|
@@ -7710,8 +7759,8 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7710
7759
|
}
|
|
7711
7760
|
}
|
|
7712
7761
|
if (transforms) for (var namespace in transforms) {
|
|
7713
|
-
var _transforms_namespace, hash,
|
|
7714
|
-
if (import_constants.isClient && !insertedTransforms[
|
|
7762
|
+
var _transforms_namespace, hash, val1, identifier1;
|
|
7763
|
+
if (import_constants.isClient && !insertedTransforms[identifier1]) var rule;
|
|
7715
7764
|
}
|
|
7716
7765
|
}
|
|
7717
7766
|
if (isReactNative) {
|
|
@@ -7720,20 +7769,20 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7720
7769
|
}
|
|
7721
7770
|
var styleProp = props.style;
|
|
7722
7771
|
if (styleProp) if (isHOC) viewProps.style = normalizeStyle(styleProp);
|
|
7723
|
-
else for (var isArray = Array.isArray(styleProp), len = isArray ? styleProp.length : 1,
|
|
7724
|
-
var
|
|
7725
|
-
if (
|
|
7772
|
+
else for (var isArray = Array.isArray(styleProp), len = isArray ? styleProp.length : 1, i = 0; i < len; i++) {
|
|
7773
|
+
var style = isArray ? styleProp[i] : styleProp;
|
|
7774
|
+
if (style) if (style.$$css) Object.assign(styleState.classNames, style);
|
|
7726
7775
|
else {
|
|
7727
|
-
var
|
|
7728
|
-
(
|
|
7776
|
+
var _styleState2;
|
|
7777
|
+
(_styleState2 = styleState).style || (_styleState2.style = {}), Object.assign(styleState.style, normalizeStyle(style));
|
|
7729
7778
|
}
|
|
7730
7779
|
}
|
|
7731
|
-
var
|
|
7732
|
-
if (
|
|
7733
|
-
var _getFont, faceInfo = (_getFont = (0, import_config.getFont)(
|
|
7780
|
+
var style1 = styleState.style;
|
|
7781
|
+
if (style1 != null && style1.fontFamily) {
|
|
7782
|
+
var _getFont, faceInfo = (_getFont = (0, import_config.getFont)(style1.fontFamily)) === null || _getFont === void 0 ? void 0 : _getFont.face;
|
|
7734
7783
|
if (faceInfo) {
|
|
7735
|
-
var _faceInfo_style_fontWeight_, _faceInfo_style_fontWeight, overrideFace = (_faceInfo_style_fontWeight = faceInfo[
|
|
7736
|
-
overrideFace && (
|
|
7784
|
+
var _faceInfo_style_fontWeight_, _faceInfo_style_fontWeight, overrideFace = (_faceInfo_style_fontWeight = faceInfo[style1.fontWeight]) === null || _faceInfo_style_fontWeight === void 0 || (_faceInfo_style_fontWeight_ = _faceInfo_style_fontWeight[style1.fontStyle || "normal"]) === null || _faceInfo_style_fontWeight_ === void 0 ? void 0 : _faceInfo_style_fontWeight_.val;
|
|
7785
|
+
overrideFace && (style1.fontFamily = overrideFace, styleState.fontFamily = overrideFace, delete style1.fontWeight, delete style1.fontStyle);
|
|
7737
7786
|
}
|
|
7738
7787
|
}
|
|
7739
7788
|
var result = {
|
|
@@ -7750,13 +7799,13 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7750
7799
|
mediaGroups
|
|
7751
7800
|
}, asChildExceptStyleLike = asChild === "except-style" || asChild === "except-style-web";
|
|
7752
7801
|
if (!asChildExceptStyleLike) {
|
|
7753
|
-
var
|
|
7802
|
+
var style2 = styleState.style;
|
|
7754
7803
|
if (0) {
|
|
7755
7804
|
var _staticConfig_defaultProps, fontFamily, fontFamilyClassName, groupClassName, componentNameFinal, componentClassName, classList, finalClassName;
|
|
7756
7805
|
if (!styleProps.noMergeStyle && !(styleProps.isAnimated && !conf.animations.supportsCSSVars && isReactNative) && isReactNative) {
|
|
7757
|
-
var cnStyles,
|
|
7806
|
+
var cnStyles, _iteratorNormalCompletion1, _didIteratorError1, _iteratorError1;
|
|
7758
7807
|
try {
|
|
7759
|
-
for (var
|
|
7808
|
+
for (var _iterator1, _step1; !(_iteratorNormalCompletion1 = (_step1 = _iterator1.next()).done); _iteratorNormalCompletion1 = !0) var name;
|
|
7760
7809
|
} catch (err) {
|
|
7761
7810
|
} finally {
|
|
7762
7811
|
try {
|
|
@@ -7764,12 +7813,12 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7764
7813
|
}
|
|
7765
7814
|
}
|
|
7766
7815
|
}
|
|
7767
|
-
} else
|
|
7816
|
+
} else style2 && !styleProps.noMergeStyle && (viewProps.style = style2);
|
|
7768
7817
|
}
|
|
7769
7818
|
if (0)
|
|
7770
7819
|
try {
|
|
7771
7820
|
var logs;
|
|
7772
|
-
for (var
|
|
7821
|
+
for (var key3 in logs) ;
|
|
7773
7822
|
} catch (e) {
|
|
7774
7823
|
}
|
|
7775
7824
|
return result;
|