tamagui 1.129.13 → 1.129.15
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 +57 -66
- package/dist/native.js.map +2 -2
- package/dist/test.native.js +53 -67
- package/dist/test.native.js.map +2 -2
- package/package.json +55 -55
package/dist/native.js
CHANGED
|
@@ -2981,39 +2981,39 @@ var require_pseudoDescriptors_native = __commonJS({
|
|
|
2981
2981
|
// order of keys here important! in priority order
|
|
2982
2982
|
hoverStyle: {
|
|
2983
2983
|
name: "hover",
|
|
2984
|
-
priority:
|
|
2984
|
+
priority: 2
|
|
2985
2985
|
},
|
|
2986
2986
|
pressStyle: {
|
|
2987
2987
|
name: "active",
|
|
2988
2988
|
stateKey: "press",
|
|
2989
|
-
priority:
|
|
2989
|
+
priority: 3
|
|
2990
2990
|
},
|
|
2991
2991
|
focusVisibleStyle: {
|
|
2992
2992
|
name: "focus-visible",
|
|
2993
|
-
priority:
|
|
2993
|
+
priority: 4,
|
|
2994
2994
|
stateKey: "focusVisible"
|
|
2995
2995
|
},
|
|
2996
2996
|
focusStyle: {
|
|
2997
2997
|
name: "focus",
|
|
2998
|
-
priority:
|
|
2998
|
+
priority: 4
|
|
2999
2999
|
},
|
|
3000
3000
|
focusWithinStyle: {
|
|
3001
3001
|
name: "focus-within",
|
|
3002
|
-
priority:
|
|
3002
|
+
priority: 4,
|
|
3003
3003
|
stateKey: "focusWithin"
|
|
3004
3004
|
},
|
|
3005
3005
|
disabledStyle: {
|
|
3006
3006
|
name: "disabled",
|
|
3007
|
-
priority:
|
|
3007
|
+
priority: 5,
|
|
3008
3008
|
stateKey: "disabled"
|
|
3009
3009
|
}
|
|
3010
3010
|
}, pseudoPriorities = {
|
|
3011
|
-
hover:
|
|
3012
|
-
press:
|
|
3013
|
-
focus:
|
|
3014
|
-
focusVisible:
|
|
3015
|
-
focusWithin:
|
|
3016
|
-
disabled:
|
|
3011
|
+
hover: pseudoDescriptorsBase.hoverStyle.priority,
|
|
3012
|
+
press: pseudoDescriptorsBase.pressStyle.priority,
|
|
3013
|
+
focus: pseudoDescriptorsBase.focusStyle.priority,
|
|
3014
|
+
focusVisible: pseudoDescriptorsBase.focusVisibleStyle.priority,
|
|
3015
|
+
focusWithin: pseudoDescriptorsBase.focusWithinStyle.priority,
|
|
3016
|
+
disabled: pseudoDescriptorsBase.disabledStyle.priority
|
|
3017
3017
|
}, pseudoDescriptors = {
|
|
3018
3018
|
...pseudoDescriptorsBase,
|
|
3019
3019
|
enterStyle: {
|
|
@@ -3258,9 +3258,9 @@ var require_useMedia_native = __commonJS({
|
|
|
3258
3258
|
}
|
|
3259
3259
|
return res;
|
|
3260
3260
|
}
|
|
3261
|
-
var getMediaImportanceIfMoreImportant = function(mediaKey, key,
|
|
3262
|
-
var importance = isSizeMedia && !(0, import_config.getSetting)("mediaPropOrder") ? getMediaKeyImportance(mediaKey) : defaultMediaImportance;
|
|
3263
|
-
return !
|
|
3261
|
+
var getMediaImportanceIfMoreImportant = function(mediaKey, key, styleState, isSizeMedia) {
|
|
3262
|
+
var importance = isSizeMedia && !(0, import_config.getSetting)("mediaPropOrder") ? getMediaKeyImportance(mediaKey) : defaultMediaImportance, usedKeys = styleState.usedKeys;
|
|
3263
|
+
return !usedKeys[key] || importance > usedKeys[key] ? importance : null;
|
|
3264
3264
|
};
|
|
3265
3265
|
function camelToHyphen(str) {
|
|
3266
3266
|
return str.replace(/[A-Z]/g, function(m) {
|
|
@@ -6541,7 +6541,7 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6541
6541
|
if (keyInit === "group" && !1) var identifier2, containerType, containerCSS;
|
|
6542
6542
|
return "continue";
|
|
6543
6543
|
}
|
|
6544
|
-
var
|
|
6544
|
+
var isValidStyleKeyInit = isValidStyleKey(keyInit, validStyles, accept);
|
|
6545
6545
|
if (0) var _viewProps2, _dataSet;
|
|
6546
6546
|
if (!isValidStyleKeyInit) {
|
|
6547
6547
|
if (!import_constants4.isAndroid && keyInit === "elevationAndroid") return "continue";
|
|
@@ -6555,13 +6555,13 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6555
6555
|
if (0) var didUseKeyInit;
|
|
6556
6556
|
var isVariant = !isValidStyleKeyInit && variants && keyInit in variants, isStyleLikeKey = isValidStyleKeyInit || isVariant, isPseudo = keyInit in import_helpers.validPseudoKeys, isMedia = !isStyleLikeKey && !isPseudo && (0, import_useMedia.isMediaKey)(keyInit), isMediaOrPseudo = !!(isMedia || isPseudo);
|
|
6557
6557
|
if (isMediaOrPseudo && keyInit.startsWith("$group-")) {
|
|
6558
|
-
var parts = keyInit.split("-");
|
|
6558
|
+
var parts = keyInit.split("-"), plen = parts.length;
|
|
6559
6559
|
if (
|
|
6560
6560
|
// check if its actually a simple group selector to avoid breaking selectors
|
|
6561
|
-
|
|
6561
|
+
plen === 2 || plen === 3 && import_pseudoDescriptors.pseudoPriorities[parts[parts.length - 1]]
|
|
6562
6562
|
) {
|
|
6563
6563
|
var name2 = parts[1];
|
|
6564
|
-
groupContext != null && groupContext[name2]
|
|
6564
|
+
groupContext && !(groupContext != null && groupContext[name2]) && (keyInit = keyInit.replace("$group-", "$group-true-"));
|
|
6565
6565
|
}
|
|
6566
6566
|
}
|
|
6567
6567
|
var isStyleProp = isValidStyleKeyInit || isMediaOrPseudo || isVariant && !noExpand;
|
|
@@ -6577,6 +6577,9 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6577
6577
|
variant: variants == null ? void 0 : variants[keyInit],
|
|
6578
6578
|
isVariant,
|
|
6579
6579
|
isHOCShouldPassThrough,
|
|
6580
|
+
usedKeys: {
|
|
6581
|
+
...styleState.usedKeys
|
|
6582
|
+
},
|
|
6580
6583
|
parentStaticConfig
|
|
6581
6584
|
})), shouldPassThrough && (passDownProp(viewProps, keyInit, valInit, isMediaOrPseudo), !isVariant) || !noSkip && keyInit in import_skipProps.skipProps) return "continue";
|
|
6582
6585
|
(isText || isInput) && valInit && (keyInit === "fontFamily" || keyInit === shorthands.fontFamily) && valInit in conf.fontsParsed && (styleState.fontFamily = valInit);
|
|
@@ -6656,7 +6659,7 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6656
6659
|
var _$val = pseudoStyleObject[pkey];
|
|
6657
6660
|
if (isDisabled) applyDefaultStyle(pkey, styleState);
|
|
6658
6661
|
else {
|
|
6659
|
-
var curImportance = usedKeys[pkey] || 0, shouldMerge = importance >= curImportance;
|
|
6662
|
+
var curImportance = styleState.usedKeys[pkey] || 0, shouldMerge = importance >= curImportance;
|
|
6660
6663
|
if (shouldMerge) {
|
|
6661
6664
|
if (process.env.IS_STATIC === "is_static") {
|
|
6662
6665
|
var _pseudos1, _key1;
|
|
@@ -6674,7 +6677,7 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6674
6677
|
}
|
|
6675
6678
|
if (!isDisabled) for (var _$key in val2) {
|
|
6676
6679
|
var k = shorthands[_$key] || _$key;
|
|
6677
|
-
usedKeys[k] = Math.max(importance, usedKeys[k] || 0);
|
|
6680
|
+
styleState.usedKeys[k] = Math.max(importance, styleState.usedKeys[k] || 0);
|
|
6678
6681
|
}
|
|
6679
6682
|
}
|
|
6680
6683
|
return;
|
|
@@ -6696,8 +6699,8 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6696
6699
|
if (mediaStylesSeen += 1, shouldDoClasses) {
|
|
6697
6700
|
var mediaStyle = getSubStyle(styleState, key4, val2, !1);
|
|
6698
6701
|
if (hasSpace && (delete mediaStyle.space, mediaState3[mediaKeyShort])) {
|
|
6699
|
-
var importance1 = (0, import_useMedia.getMediaImportanceIfMoreImportant)(mediaKeyShort, "space",
|
|
6700
|
-
importance1 && (space = val2.space, usedKeys.space = importance1, process.env.NODE_ENV === "development" && debug === "verbose" && (0, import_log.log)(`Found more important space for current media ${mediaKeyShort}: ${val2} (importance: ${importance1})`));
|
|
6702
|
+
var importance1 = (0, import_useMedia.getMediaImportanceIfMoreImportant)(mediaKeyShort, "space", styleState, !0);
|
|
6703
|
+
importance1 && (space = val2.space, styleState.usedKeys.space = importance1, process.env.NODE_ENV === "development" && debug === "verbose" && (0, import_log.log)(`Found more important space for current media ${mediaKeyShort}: ${val2} (importance: ${importance1})`));
|
|
6701
6704
|
}
|
|
6702
6705
|
var mediaStyles = (0, import_getCSSStylesAtomic.getCSSStylesAtomic)(mediaStyle), _iteratorNormalCompletion12 = !0, _didIteratorError12 = !1, _iteratorError12 = void 0;
|
|
6703
6706
|
try {
|
|
@@ -6723,7 +6726,7 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6723
6726
|
var mergeMediaStyle2 = function(key5, val3) {
|
|
6724
6727
|
var _styleState4;
|
|
6725
6728
|
(_styleState4 = styleState).style || (_styleState4.style = {});
|
|
6726
|
-
var didMerge = mergeMediaByImportance(styleState, mediaKeyShort, key5, val3,
|
|
6729
|
+
var didMerge = mergeMediaByImportance(styleState, mediaKeyShort, key5, val3, mediaState3[mediaKeyShort], importanceBump, debug);
|
|
6727
6730
|
didMerge && key5 === "fontFamily" && (styleState.fontFamily = mediaStyle1.fontFamily);
|
|
6728
6731
|
}, mergeMediaStyle = mergeMediaStyle2, isThemeMedia = isMedia === "theme", isGroupMedia = isMedia === "group", isPlatformMedia = isMedia === "platform";
|
|
6729
6732
|
if (!isThemeMedia && !isPlatformMedia && !isGroupMedia) {
|
|
@@ -6823,7 +6826,7 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6823
6826
|
conf = conf || (0, import_config.getConfig)();
|
|
6824
6827
|
var animationDriver = (componentContext == null ? void 0 : componentContext.animationDriver) || conf.animations;
|
|
6825
6828
|
import_constants4.isWeb && styleProps.isAnimated && animationDriver.isReactNative && !styleProps.noNormalize && (styleProps.noNormalize = "values");
|
|
6826
|
-
var { shorthands } = conf, { isHOC, isText, isInput, variants, isReactNative, inlineProps, inlineWhenUnflattened, parentStaticConfig, acceptsClassName } = staticConfig, viewProps = {}, mediaState3 = styleProps.mediaState || import_useMedia.mediaState,
|
|
6829
|
+
var { shorthands } = conf, { isHOC, isText, isInput, variants, isReactNative, inlineProps, inlineWhenUnflattened, parentStaticConfig, acceptsClassName } = staticConfig, viewProps = {}, mediaState3 = styleProps.mediaState || import_useMedia.mediaState, shouldDoClasses = acceptsClassName && import_constants4.isWeb && !styleProps.noClass && !styleProps.isAnimated, rulesToInsert = void 0, classNames = {}, pseudos = null, space = props.space, hasMedia = !1, dynamicThemeAccess, pseudoGroups, mediaGroups, className = props.className || "", mediaStylesSeen = 0, validStyles = staticConfig.validStyles || (staticConfig.isText || staticConfig.isInput ? import_helpers.stylePropsText : import_helpers.validStyles);
|
|
6827
6830
|
process.env.NODE_ENV === "development" && debug === "profile" && time`split-styles-setup`;
|
|
6828
6831
|
var styleState = {
|
|
6829
6832
|
classNames,
|
|
@@ -6834,7 +6837,7 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6834
6837
|
staticConfig,
|
|
6835
6838
|
style: null,
|
|
6836
6839
|
theme,
|
|
6837
|
-
usedKeys,
|
|
6840
|
+
usedKeys: {},
|
|
6838
6841
|
viewProps,
|
|
6839
6842
|
context: componentContext,
|
|
6840
6843
|
debug
|
|
@@ -6968,10 +6971,10 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6968
6971
|
});
|
|
6969
6972
|
}
|
|
6970
6973
|
function mergeStyle(styleState, key, val, importance) {
|
|
6971
|
-
var disableNormalize = arguments.length > 4 && arguments[4] !== void 0 ? arguments[4] : !1, { viewProps, styleProps, staticConfig } = styleState, existingImportance =
|
|
6972
|
-
if (!(
|
|
6973
|
-
var _styleState
|
|
6974
|
-
(_styleState = styleState).flatTransforms || (_styleState.flatTransforms = {}),
|
|
6974
|
+
var disableNormalize = arguments.length > 4 && arguments[4] !== void 0 ? arguments[4] : !1, { viewProps, styleProps, staticConfig, usedKeys } = styleState, existingImportance = usedKeys[key] || 0;
|
|
6975
|
+
if (!(existingImportance > importance)) if (key in import_helpers.stylePropsTransform) {
|
|
6976
|
+
var _styleState;
|
|
6977
|
+
(_styleState = styleState).flatTransforms || (_styleState.flatTransforms = {}), usedKeys[key] = importance, styleState.flatTransforms[key] = val;
|
|
6975
6978
|
} else {
|
|
6976
6979
|
var shouldNormalize = import_constants4.isWeb && !disableNormalize && !styleProps.noNormalize, out = shouldNormalize ? (0, import_normalizeValueWithProperty.normalizeValueWithProperty)(val, key) : val;
|
|
6977
6980
|
if (
|
|
@@ -6979,8 +6982,8 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
6979
6982
|
staticConfig.accept && key in staticConfig.accept
|
|
6980
6983
|
) viewProps[key] = out;
|
|
6981
6984
|
else {
|
|
6982
|
-
var _styleState1
|
|
6983
|
-
(_styleState1 = styleState).style || (_styleState1.style = {}),
|
|
6985
|
+
var _styleState1;
|
|
6986
|
+
(_styleState1 = styleState).style || (_styleState1.style = {}), usedKeys[key] = importance, styleState.style[key] = // if you dont do this you'll be passing props.transform arrays directly here and then mutating them
|
|
6984
6987
|
// if theres any flatTransforms later, causing issues (mutating props is bad, in strict mode styles get borked)
|
|
6985
6988
|
key === "transform" && Array.isArray(out) ? [
|
|
6986
6989
|
...out
|
|
@@ -7057,10 +7060,10 @@ var require_getSplitStyles_native = __commonJS({
|
|
|
7057
7060
|
delete viewProps[key], viewProps[key] = next;
|
|
7058
7061
|
} else viewProps[key] = val;
|
|
7059
7062
|
}
|
|
7060
|
-
function mergeMediaByImportance(styleState, mediaKey, key, value,
|
|
7061
|
-
var importance = (0, import_useMedia.getMediaImportanceIfMoreImportant)(mediaKey, key,
|
|
7063
|
+
function mergeMediaByImportance(styleState, mediaKey, key, value, isSizeMedia, importanceBump, debugProp) {
|
|
7064
|
+
var usedKeys = styleState.usedKeys, importance = (0, import_useMedia.getMediaImportanceIfMoreImportant)(mediaKey, key, styleState, isSizeMedia);
|
|
7062
7065
|
if (importanceBump && (importance = (importance || 0) + importanceBump), process.env.NODE_ENV === "development" && debugProp === "verbose" && (0, import_log.log)(`mergeMediaByImportance ${key} importance usedKey ${usedKeys[key]} next ${importance}`), importance === null) return !1;
|
|
7063
|
-
if (
|
|
7066
|
+
if (key in import_pseudoDescriptors.pseudoDescriptors) {
|
|
7064
7067
|
var descriptor = import_pseudoDescriptors.pseudoDescriptors[key], descriptorKey = descriptor.stateKey || descriptor.name, isDisabled = styleState.componentState[descriptorKey] === !1;
|
|
7065
7068
|
if (isDisabled) return !1;
|
|
7066
7069
|
for (var subKey in value) mergeStyle(styleState, subKey, value[subKey], importance);
|
|
@@ -8315,9 +8318,7 @@ var require_useComponentState_native = __commonJS({
|
|
|
8315
8318
|
var states = (0, import_react3.useState)(initialState), state = props.forceStyle ? {
|
|
8316
8319
|
...states[0],
|
|
8317
8320
|
[props.forceStyle]: !0
|
|
8318
|
-
} : states[0], setState = states[1];
|
|
8319
|
-
stateRef.current.nextComponentState && Object.assign(state, stateRef.current.nextComponentState);
|
|
8320
|
-
var isAnimated = willBeAnimated;
|
|
8321
|
+
} : states[0], setState = states[1], isAnimated = willBeAnimated;
|
|
8321
8322
|
import_constants4.isWeb && hasAnimationThatNeedsHydrate && !staticConfig.isHOC && !isHydrated && (isAnimated = !1, curStateRef.willHydrate = !0), disabled !== state.disabled && (disabled && Object.assign(state, import_defaultComponentState.defaultComponentStateMounted), state.disabled = disabled, setState(function(_) {
|
|
8322
8323
|
return {
|
|
8323
8324
|
...state
|
|
@@ -8589,7 +8590,7 @@ var require_createComponent_native = __commonJS({
|
|
|
8589
8590
|
}
|
|
8590
8591
|
});
|
|
8591
8592
|
module2.exports = __toCommonJS2(createComponent_exports);
|
|
8592
|
-
var import_jsx_runtime6 = require("react/jsx-runtime"), import_compose_refs = require_index_native11(), import_constants4 = require_index_native6(), import_helpers = require_index_native7(), import_is_equal_shallow = require_index_native12(), import_react3 = __toESM2(require("react")), import_config = require_config_native(), import_constants22 = require_constants_native2(), import_isDevTools = require_isDevTools_native(), import_ComponentContext = require_ComponentContext_native(), import_GroupContext = require_GroupContext_native(), import_createVariable = require_createVariable_native(), import_defaultComponentState = require_defaultComponentState_native(), import_getShorthandValue = require_getShorthandValue_native(), import_getSplitStyles = require_getSplitStyles_native(), import_log = require_log_native(), import_mergeProps = require_mergeProps_native(), import_setElementProps = require_setElementProps_native(), import_subscribeToContextGroup = require_subscribeToContextGroup_native(), import_themeable = require_themeable_native(), import_wrapStyleTags = require_wrapStyleTags_native(), import_useComponentState = require_useComponentState_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(), time2, debugKeyListeners, startVisualizer, componentSetStates = /* @__PURE__ */ new Set(), avoidReRenderKeys = /* @__PURE__ */ new Set([
|
|
8593
|
+
var import_jsx_runtime6 = require("react/jsx-runtime"), import_compose_refs = require_index_native11(), import_constants4 = require_index_native6(), import_helpers = require_index_native7(), import_is_equal_shallow = require_index_native12(), import_react3 = __toESM2(require("react")), import_config = require_config_native(), import_constants22 = require_constants_native2(), import_isDevTools = require_isDevTools_native(), import_ComponentContext = require_ComponentContext_native(), import_GroupContext = require_GroupContext_native(), import_createVariable = require_createVariable_native(), import_defaultComponentState = require_defaultComponentState_native(), import_getShorthandValue = require_getShorthandValue_native(), import_getSplitStyles = require_getSplitStyles_native(), import_log = require_log_native(), import_mergeProps = require_mergeProps_native(), import_setElementProps = require_setElementProps_native(), import_subscribeToContextGroup = require_subscribeToContextGroup_native(), import_themeable = require_themeable_native(), import_wrapStyleTags = require_wrapStyleTags_native(), import_useComponentState = require_useComponentState_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(), time2, NextState = /* @__PURE__ */ new WeakMap(), debugKeyListeners, startVisualizer, componentSetStates = /* @__PURE__ */ new Set(), avoidReRenderKeys = /* @__PURE__ */ new Set([
|
|
8593
8594
|
"hover",
|
|
8594
8595
|
"press",
|
|
8595
8596
|
"pressIn",
|
|
@@ -8603,7 +8604,7 @@ var require_createComponent_native = __commonJS({
|
|
|
8603
8604
|
var BaseText, BaseView, hasSetupBaseViews = !1, lastInteractionWasKeyboard = {
|
|
8604
8605
|
value: !1
|
|
8605
8606
|
};
|
|
8606
|
-
import_constants4.isWeb &&
|
|
8607
|
+
import_constants4.isWeb && typeof document < "u" && (document.addEventListener("keydown", function() {
|
|
8607
8608
|
lastInteractionWasKeyboard.value || (lastInteractionWasKeyboard.value = !0);
|
|
8608
8609
|
}), document.addEventListener("mousedown", function() {
|
|
8609
8610
|
lastInteractionWasKeyboard.value && (lastInteractionWasKeyboard.value = !1);
|
|
@@ -8677,7 +8678,12 @@ var require_createComponent_native = __commonJS({
|
|
|
8677
8678
|
}, [
|
|
8678
8679
|
componentName2
|
|
8679
8680
|
]);
|
|
8680
|
-
var componentContext = import_react3.default.useContext(import_ComponentContext.ComponentContext), groupContextParent = import_react3.default.useContext(import_GroupContext.GroupContext), animationDriver = componentContext.animationDriver, useAnimations = animationDriver == null ? void 0 : animationDriver.useAnimations, componentState = (0, import_useComponentState.useComponentState)(props, animationDriver, staticConfig, config), { disabled, groupName, hasAnimationProp, hasEnterStyle, isAnimated, isExiting, isHydrated, presence, presenceState, setState, noClass, state, stateRef, supportsCSS, willBeAnimated, willBeAnimatedClient, startedUnhydrated } = componentState
|
|
8681
|
+
var componentContext = import_react3.default.useContext(import_ComponentContext.ComponentContext), groupContextParent = import_react3.default.useContext(import_GroupContext.GroupContext), animationDriver = componentContext.animationDriver, useAnimations = animationDriver == null ? void 0 : animationDriver.useAnimations, componentState = (0, import_useComponentState.useComponentState)(props, animationDriver, staticConfig, config), { disabled, groupName, hasAnimationProp, hasEnterStyle, isAnimated, isExiting, isHydrated, presence, presenceState, setState, noClass, state, stateRef, supportsCSS, willBeAnimated, willBeAnimatedClient, startedUnhydrated } = componentState;
|
|
8682
|
+
hasAnimationProp && animationDriver != null && animationDriver.avoidReRenders && (0, import_constants4.useIsomorphicLayoutEffect)(function() {
|
|
8683
|
+
var pendingState = NextState.get(stateRef);
|
|
8684
|
+
pendingState && (setStateShallow(pendingState), NextState.set(stateRef, void 0));
|
|
8685
|
+
});
|
|
8686
|
+
var allGroupContexts = (0, import_react3.useMemo)(function() {
|
|
8681
8687
|
var _stateRef_current_group;
|
|
8682
8688
|
if (!groupName) return groupContextParent;
|
|
8683
8689
|
(_stateRef_current_group = stateRef.current.group) === null || _stateRef_current_group === void 0 || _stateRef_current_group.listeners.clear();
|
|
@@ -8716,13 +8722,8 @@ var require_createComponent_native = __commonJS({
|
|
|
8716
8722
|
stateRef,
|
|
8717
8723
|
groupName,
|
|
8718
8724
|
groupContextParent
|
|
8719
|
-
]), setStateShallow = componentState.setStateShallow
|
|
8720
|
-
|
|
8721
|
-
return {
|
|
8722
|
-
...prev,
|
|
8723
|
-
...pendingState
|
|
8724
|
-
};
|
|
8725
|
-
})), process.env.NODE_ENV === "development" && time2 && time2`use-state`;
|
|
8725
|
+
]), setStateShallow = componentState.setStateShallow;
|
|
8726
|
+
process.env.NODE_ENV === "development" && time2 && time2`use-state`;
|
|
8726
8727
|
var hasTextAncestor = !!(import_constants4.isWeb && isText && componentContext.inText), isTaggable = !Component || typeof Component == "string", tagProp = props.tag, element = import_constants4.isWeb && isTaggable && tagProp || Component, BaseTextComponent = BaseText || element || "span", BaseViewComponent = BaseView || element || (hasTextAncestor ? "span" : "div"), elementType = isText ? BaseTextComponent : BaseViewComponent;
|
|
8727
8728
|
animationDriver && isAnimated && // this should really be behind another prop as it's not really related to
|
|
8728
8729
|
// "needsWebStyles" basically with motion we just animate a plain div, but
|
|
@@ -8801,7 +8802,7 @@ var require_createComponent_native = __commonJS({
|
|
|
8801
8802
|
if ((hasAnimationProp || groupName) && animationDriver != null && animationDriver.avoidReRenders) {
|
|
8802
8803
|
var styleListener = stateRef.current.useStyleListener, ogSetStateShallow = setStateShallow;
|
|
8803
8804
|
stateRef.current.setStateShallow = function(nextOrGetNext) {
|
|
8804
|
-
var prev = stateRef
|
|
8805
|
+
var prev = NextState.get(stateRef) || state, next = typeof nextOrGetNext == "function" ? nextOrGetNext(prev) : nextOrGetNext;
|
|
8805
8806
|
if (!(next === prev || (0, import_is_equal_shallow.isEqualShallow)(prev, next))) {
|
|
8806
8807
|
var canAvoidReRender = Object.keys(next).every(function(key3) {
|
|
8807
8808
|
return avoidReRenderKeys.has(key3);
|
|
@@ -8811,7 +8812,7 @@ var require_createComponent_native = __commonJS({
|
|
|
8811
8812
|
...prev,
|
|
8812
8813
|
...next
|
|
8813
8814
|
};
|
|
8814
|
-
stateRef
|
|
8815
|
+
NextState.set(stateRef, updatedState), process.env.NODE_ENV === "development" && debugProp && debugProp !== "profile" && (console.groupCollapsed("[\u26A1\uFE0F] avoid setState", next, {
|
|
8815
8816
|
updatedState,
|
|
8816
8817
|
props
|
|
8817
8818
|
}), console.info(stateRef.current.host), console.groupEnd());
|
|
@@ -8963,9 +8964,7 @@ If you meant to do this, you can disable this warning - either change untilMeasu
|
|
|
8963
8964
|
mediaGroups ? Object.keys([
|
|
8964
8965
|
...mediaGroups
|
|
8965
8966
|
]).join("") : 0
|
|
8966
|
-
])
|
|
8967
|
-
stateRef.current.nextComponentState = void 0;
|
|
8968
|
-
});
|
|
8967
|
+
]);
|
|
8969
8968
|
var groupEmitter = stateRef.current.group;
|
|
8970
8969
|
(0, import_constants4.useIsomorphicLayoutEffect)(function() {
|
|
8971
8970
|
!groupContext || !groupEmitter || notifyGroupSubscribers(groupContext, groupEmitter, state);
|
|
@@ -9017,24 +9016,16 @@ If you meant to do this, you can disable this warning - either change untilMeasu
|
|
|
9017
9016
|
},
|
|
9018
9017
|
...attachFocus && {
|
|
9019
9018
|
onFocus: function(e) {
|
|
9020
|
-
|
|
9021
|
-
|
|
9022
|
-
}), pseudos != null && pseudos.focusVisibleStyle ? setTimeout(function() {
|
|
9023
|
-
setStateShallow({
|
|
9024
|
-
focus: !0,
|
|
9025
|
-
focusVisible: !!lastInteractionWasKeyboard.value
|
|
9026
|
-
});
|
|
9027
|
-
}, 0) : setStateShallow({
|
|
9028
|
-
focus: !0,
|
|
9029
|
-
focusVisible: !1
|
|
9030
|
-
}), onFocus == null || onFocus(e);
|
|
9019
|
+
var next = {};
|
|
9020
|
+
componentContext.setParentFocusState && (next.focusWithin = !0), pseudos != null && pseudos.focusVisibleStyle && lastInteractionWasKeyboard.value ? next.focusVisible = !0 : next.focus = !0, setStateShallow(next), onFocus == null || onFocus(e);
|
|
9031
9021
|
},
|
|
9032
9022
|
onBlur: function(e) {
|
|
9033
9023
|
componentContext.setParentFocusState && componentContext.setParentFocusState({
|
|
9034
9024
|
focusWithin: !1
|
|
9035
9025
|
}), setStateShallow({
|
|
9036
9026
|
focus: !1,
|
|
9037
|
-
focusVisible: !1
|
|
9027
|
+
focusVisible: !1,
|
|
9028
|
+
focusWithin: !1
|
|
9038
9029
|
}), onBlur == null || onBlur(e);
|
|
9039
9030
|
}
|
|
9040
9031
|
}
|
|
@@ -9082,7 +9073,7 @@ If you meant to do this, you can disable this warning - either change untilMeasu
|
|
|
9082
9073
|
...componentContext,
|
|
9083
9074
|
setParentFocusState: setStateShallow,
|
|
9084
9075
|
children: content
|
|
9085
|
-
})), "group" in
|
|
9076
|
+
})), "group" in props && (content = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_GroupContext.GroupContext.Provider, {
|
|
9086
9077
|
value: allGroupContexts,
|
|
9087
9078
|
children: content
|
|
9088
9079
|
})), process.env.NODE_ENV === "development" && time2 && time2`group-context`, content = disableTheme ? content : (0, import_Theme.getThemedChildren)(themeState, content, themeStateProps, !1, stateRef), process.env.NODE_ENV === "development" && time2 && time2`themed-children`, staticConfig.context) {
|