@tamagui/core 1.125.10 → 1.125.11
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 +13 -9
- package/dist/native.js.map +2 -2
- package/dist/test.native.js +13 -9
- package/dist/test.native.js.map +2 -2
- package/package.json +7 -7
package/dist/native.js
CHANGED
|
@@ -5929,7 +5929,8 @@ var require_createShallowSetState_native = __commonJS({
|
|
|
5929
5929
|
var import_react3 = require("react"), callImmediate = function(cb) {
|
|
5930
5930
|
return cb();
|
|
5931
5931
|
};
|
|
5932
|
-
function createShallowSetState(setter, onlyAllow, transition,
|
|
5932
|
+
function createShallowSetState(setter, onlyAllow, transition, debugIn, callback) {
|
|
5933
|
+
var debug = !0;
|
|
5933
5934
|
return (0, import_react3.useCallback)(function(next) {
|
|
5934
5935
|
var wrap = transition ? import_react3.startTransition : callImmediate;
|
|
5935
5936
|
wrap(function() {
|
|
@@ -5942,7 +5943,8 @@ var require_createShallowSetState_native = __commonJS({
|
|
|
5942
5943
|
setter,
|
|
5943
5944
|
onlyAllow ? onlyAllow.join("") : "",
|
|
5944
5945
|
transition,
|
|
5945
|
-
debug
|
|
5946
|
+
debug,
|
|
5947
|
+
callback
|
|
5946
5948
|
]);
|
|
5947
5949
|
}
|
|
5948
5950
|
function mergeIfNotShallowEqual(prev, next, onlyAllow, debug) {
|
|
@@ -6996,10 +6998,8 @@ var require_useComponentState_native = __commonJS({
|
|
|
6996
6998
|
import_constants2.isWeb && hasAnimationThatNeedsHydrate && !staticConfig.isHOC && !isHydrated && (isAnimated = !1, curStateRef.willHydrate = !0), disabled !== state.disabled && (state.disabled = disabled, disabled && Object.assign(state, import_defaultComponentState.defaultComponentStateMounted), setState({
|
|
6997
6999
|
...state
|
|
6998
7000
|
}));
|
|
6999
|
-
var groupName = props.group, setStateWrapper
|
|
7000
|
-
|
|
7001
|
-
var groupContextState = groups.state;
|
|
7002
|
-
setStateWrapper = function(state2) {
|
|
7001
|
+
var groupName = props.group, groupContextState = groups == null ? void 0 : groups.state, setStateWrapper = (0, import_react3.useMemo)(function() {
|
|
7002
|
+
if (groupContextState && groupName) return function(state2) {
|
|
7003
7003
|
curStateRef.group.emit(groupName, {
|
|
7004
7004
|
pseudo: state2
|
|
7005
7005
|
});
|
|
@@ -7009,8 +7009,11 @@ var require_useComponentState_native = __commonJS({
|
|
|
7009
7009
|
};
|
|
7010
7010
|
groupContextState[groupName] = next;
|
|
7011
7011
|
};
|
|
7012
|
-
}
|
|
7013
|
-
|
|
7012
|
+
}, [
|
|
7013
|
+
groupContextState,
|
|
7014
|
+
curStateRef,
|
|
7015
|
+
groupName
|
|
7016
|
+
]), setStateShallow = (0, import_createShallowSetState.createShallowSetState)(setState, disabled ? [
|
|
7014
7017
|
"disabled"
|
|
7015
7018
|
] : void 0, !1, props.debug, setStateWrapper);
|
|
7016
7019
|
if (presenceState && isAnimated && isHydrated && staticConfig.variants) {
|
|
@@ -8620,6 +8623,7 @@ var require_createTamagui_native = __commonJS({
|
|
|
8620
8623
|
var import_constants2 = require_index_native2(), import_config = require_config_native(), import_createVariables = require_createVariables_native(), import_getThemeCSSRules = require_getThemeCSSRules_native(), import_insertStyleRule = require_insertStyleRule_native(), import_proxyThemeToParents = require_proxyThemeToParents_native(), import_registerCSSVariable = require_registerCSSVariable_native(), import_themes = require_themes_native(), import_useMedia = require_useMedia_native(), import_insertFont = require_insertFont_native(), import_Tamagui = require_Tamagui_native(), createdConfigs = /* @__PURE__ */ new WeakMap();
|
|
8621
8624
|
function createTamagui2(configIn) {
|
|
8622
8625
|
var _configIn_settings;
|
|
8626
|
+
if (process.env.NODE_ENV === "test" && globalThis.__tamaguiConfig) return console.warn("Warning: You somehow have duplicate Tamagui dependencies, this can cause issues. Tamagui is working around this by loading a previously loaded config in test mode. "), globalThis.__tamaguiConfig;
|
|
8623
8627
|
if (createdConfigs.has(configIn)) return configIn;
|
|
8624
8628
|
var tokensParsed = {}, tokens = (0, import_createVariables.createVariables)(configIn.tokens || {});
|
|
8625
8629
|
if (configIn.tokens) {
|
|
@@ -8767,7 +8771,7 @@ ${JSON.stringify(variable, null, 2)}`);
|
|
|
8767
8771
|
specificTokens,
|
|
8768
8772
|
defaultFontToken
|
|
8769
8773
|
};
|
|
8770
|
-
if ((0, import_config.setConfig)(config), (0, import_useMedia.configureMedia)(config), createdConfigs.set(config, !0), import_config.configListeners.size && (import_config.configListeners.forEach(function(cb) {
|
|
8774
|
+
if ((0, import_config.setConfig)(config), (0, import_useMedia.configureMedia)(config), createdConfigs.set(config, !0), process.env.NODE_ENV === "test" && (globalThis.__tamaguiConfig = config), import_config.configListeners.size && (import_config.configListeners.forEach(function(cb) {
|
|
8771
8775
|
return cb(config);
|
|
8772
8776
|
}), import_config.configListeners.clear()), process.env.NODE_ENV === "development") {
|
|
8773
8777
|
var _process_env_DEBUG;
|