@tamagui/core 1.105.1 → 1.105.3

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 CHANGED
@@ -2136,6 +2136,9 @@ var require_config_native = __commonJS({
2136
2136
  getFont: function() {
2137
2137
  return getFont;
2138
2138
  },
2139
+ getSetting: function() {
2140
+ return getSetting;
2141
+ },
2139
2142
  getThemes: function() {
2140
2143
  return getThemes2;
2141
2144
  },
@@ -2215,7 +2218,14 @@ var require_config_native = __commonJS({
2215
2218
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
2216
2219
  }
2217
2220
  }
2218
- var conf, setConfig = function(next) {
2221
+ var conf, getSetting = function(key) {
2222
+ if (process.env.NODE_ENV === "development" && !conf) throw new Error("Haven't called createTamagui yet");
2223
+ var _conf_settings_key;
2224
+ return (_conf_settings_key = conf.settings[key]) !== null && _conf_settings_key !== void 0 ? _conf_settings_key : (
2225
+ // @ts-expect-error
2226
+ conf[key]
2227
+ );
2228
+ }, setConfig = function(next) {
2219
2229
  conf = next;
2220
2230
  }, setConfigFont = function(name, font, fontParsed) {
2221
2231
  if (process.env.NODE_ENV === "development" && !conf) throw new Error("Haven't called createTamagui yet");
@@ -3068,7 +3078,7 @@ var require_useDisableSSR_native = __commonJS({
3068
3078
  var import_config = require_config_native();
3069
3079
  function getDisableSSR(componentContext) {
3070
3080
  var _componentContext_disableSSR;
3071
- return (_componentContext_disableSSR = componentContext == null ? void 0 : componentContext.disableSSR) !== null && _componentContext_disableSSR !== void 0 ? _componentContext_disableSSR : (0, import_config.getConfig)().disableSSR;
3081
+ return (_componentContext_disableSSR = componentContext == null ? void 0 : componentContext.disableSSR) !== null && _componentContext_disableSSR !== void 0 ? _componentContext_disableSSR : (0, import_config.getSetting)("disableSSR");
3072
3082
  }
3073
3083
  }
3074
3084
  });
@@ -3115,6 +3125,9 @@ var require_useMedia_native = __commonJS({
3115
3125
  }), mod);
3116
3126
  }, useMedia_exports = {};
3117
3127
  __export2(useMedia_exports, {
3128
+ _dmt: function() {
3129
+ return _dmt;
3130
+ },
3118
3131
  configureMedia: function() {
3119
3132
  return configureMedia2;
3120
3133
  },
@@ -3127,6 +3140,9 @@ var require_useMedia_native = __commonJS({
3127
3140
  getMediaKeyImportance: function() {
3128
3141
  return getMediaKeyImportance;
3129
3142
  },
3143
+ getMediaState: function() {
3144
+ return getMediaState;
3145
+ },
3130
3146
  isMediaKey: function() {
3131
3147
  return isMediaKey;
3132
3148
  },
@@ -3168,6 +3184,9 @@ var require_useMedia_native = __commonJS({
3168
3184
  function _array_with_holes(arr) {
3169
3185
  if (Array.isArray(arr)) return arr;
3170
3186
  }
3187
+ function _array_without_holes(arr) {
3188
+ if (Array.isArray(arr)) return _array_like_to_array(arr);
3189
+ }
3171
3190
  function _define_property2(obj, key, value) {
3172
3191
  return key in obj ? Object.defineProperty(obj, key, {
3173
3192
  value,
@@ -3176,6 +3195,9 @@ var require_useMedia_native = __commonJS({
3176
3195
  writable: !0
3177
3196
  }) : obj[key] = value, obj;
3178
3197
  }
3198
+ function _iterable_to_array(iter) {
3199
+ if ((typeof Symbol > "u" ? "undefined" : _type_of(Symbol)) < "u" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
3200
+ }
3179
3201
  function _iterable_to_array_limit(arr, i) {
3180
3202
  var _i = arr == null ? null : (typeof Symbol > "u" ? "undefined" : _type_of(Symbol)) < "u" && arr[Symbol.iterator] || arr["@@iterator"];
3181
3203
  if (_i != null) {
@@ -3197,6 +3219,9 @@ var require_useMedia_native = __commonJS({
3197
3219
  function _non_iterable_rest() {
3198
3220
  throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
3199
3221
  }
3222
+ function _non_iterable_spread() {
3223
+ throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
3224
+ }
3200
3225
  function _object_spread2(target) {
3201
3226
  for (var i = 1; i < arguments.length; i++) {
3202
3227
  var source = arguments[i] != null ? arguments[i] : {}, ownKeys2 = Object.keys(source);
@@ -3226,6 +3251,9 @@ var require_useMedia_native = __commonJS({
3226
3251
  function _sliced_to_array(arr, i) {
3227
3252
  return _array_with_holes(arr) || _iterable_to_array_limit(arr, i) || _unsupported_iterable_to_array(arr, i) || _non_iterable_rest();
3228
3253
  }
3254
+ function _to_consumable_array(arr) {
3255
+ return _array_without_holes(arr) || _iterable_to_array(arr) || _unsupported_iterable_to_array(arr) || _non_iterable_spread();
3256
+ }
3229
3257
  function _unsupported_iterable_to_array(o, minLen) {
3230
3258
  if (o) {
3231
3259
  if (typeof o == "string") return _array_like_to_array(o, minLen);
@@ -3257,7 +3285,7 @@ var require_useMedia_native = __commonJS({
3257
3285
  var conf = (0, import_config.getConfig)();
3258
3286
  return conf.settings.mediaPropOrder ? defaultMediaImportance : mediaKeysOrdered.indexOf(key) + 100;
3259
3287
  }, dispose = /* @__PURE__ */ new Set(), mediaVersion = 0, configureMedia2 = function(config) {
3260
- var media = config.media, mediaQueryDefaultActive = config.mediaQueryDefaultActive;
3288
+ var media = config.media, mediaQueryDefaultActive = (0, import_config.getSetting)("mediaQueryDefaultActive");
3261
3289
  if (media) {
3262
3290
  mediaVersion++;
3263
3291
  for (var key in media) mediaState2[key] = (mediaQueryDefaultActive == null ? void 0 : mediaQueryDefaultActive[key]) || !1, mediaKeys.add("$".concat(key));
@@ -3314,7 +3342,7 @@ var require_useMedia_native = __commonJS({
3314
3342
  if (!componentState) return initialState;
3315
3343
  var enabled = componentState.enabled, keys = componentState.keys, _componentState_prev = componentState.prev, prev = _componentState_prev === void 0 ? initialState : _componentState_prev;
3316
3344
  if (enabled === !1) return prev;
3317
- var _ref, testKeys = (_ref = (keys != null || enabled) && keys) !== null && _ref !== void 0 ? _ref : null, hasntUpdated = !testKeys || Object.keys(testKeys).every(function(key) {
3345
+ var hasntUpdated = !keys || Object.keys(keys).every(function(key) {
3318
3346
  return mediaState2[key] === prev[key];
3319
3347
  });
3320
3348
  return hasntUpdated ? prev : (componentState.prev = mediaState2, mediaState2);
@@ -3335,16 +3363,37 @@ var require_useMedia_native = __commonJS({
3335
3363
  }
3336
3364
  return new Proxy(state, {
3337
3365
  get: function(_, key) {
3338
- if (typeof key == "string") {
3339
- var _componentState;
3340
- (_componentState = componentState).keys || (_componentState.keys = {}), componentState.keys[key] = !0, process.env.NODE_ENV === "development" && debug && console.info("useMedia() TOUCH", key);
3366
+ if (!disableMediaTouch) {
3367
+ if (typeof key == "string") {
3368
+ var _componentState;
3369
+ (_componentState = componentState).keys || (_componentState.keys = {}), componentState.keys[key] = !0, process.env.NODE_ENV === "development" && debug && console.info("useMedia() TOUCH", key);
3370
+ }
3371
+ return Reflect.get(state, key);
3341
3372
  }
3342
- return Reflect.get(state, key);
3343
3373
  }
3344
3374
  });
3345
3375
  }
3376
+ var disableMediaTouch = !1;
3377
+ function _dmt(val) {
3378
+ disableMediaTouch = val;
3379
+ }
3380
+ function getMediaState(mediaGroups, layout) {
3381
+ disableMediaTouch = !0;
3382
+ var res;
3383
+ try {
3384
+ res = Object.fromEntries(_to_consumable_array(mediaGroups).map(function(mediaKey) {
3385
+ return [
3386
+ mediaKey,
3387
+ mediaKeyMatch2(mediaKey, layout)
3388
+ ];
3389
+ }));
3390
+ } finally {
3391
+ disableMediaTouch = !1;
3392
+ }
3393
+ return res;
3394
+ }
3346
3395
  var getMediaImportanceIfMoreImportant = function(mediaKey, key, importancesUsed, isSizeMedia) {
3347
- var conf = (0, import_config.getConfig)(), importance = isSizeMedia && !conf.settings.mediaPropOrder ? getMediaKeyImportance(mediaKey) : defaultMediaImportance;
3396
+ var importance = isSizeMedia && !(0, import_config.getSetting)("mediaPropOrder") ? getMediaKeyImportance(mediaKey) : defaultMediaImportance;
3348
3397
  return !importancesUsed[key] || importance > importancesUsed[key] ? importance : null;
3349
3398
  };
3350
3399
  function camelToHyphen(str) {
@@ -3899,7 +3948,7 @@ var require_createShallowSetState_native = __commonJS({
3899
3948
  }
3900
3949
  function mergeIfNotShallowEqual(prev, next, isDisabled, debug) {
3901
3950
  if (isDisabled || !prev || !next || isEqualShallow(prev, next)) return prev || next;
3902
- if (process.env.NODE_ENV === "development" && debug && (console.warn("setStateShallow CHANGE", {
3951
+ if (process.env.NODE_ENV === "development" && debug && (console.info("setStateShallow CHANGE", {
3903
3952
  prev,
3904
3953
  next
3905
3954
  }), debug === "break")) debugger;
@@ -4091,7 +4140,7 @@ var require_useTheme_native = __commonJS({
4091
4140
  }
4092
4141
  return next;
4093
4142
  }), themeManager = changedThemeState.themeManager, state = changedThemeState.state;
4094
- process.env.NODE_ENV === "development" && (state != null && state.theme || process.env.TAMAGUI_DISABLE_NO_THEME_WARNING !== "1" && console.warn("[tamagui] No theme found, this could be due to an invalid theme name (given theme props ".concat(JSON.stringify(props), `).
4143
+ process.env.NODE_ENV === "development" && (state != null && state.theme || process.env.TAMAGUI_DISABLE_NO_THEME_WARNING !== "1" && console.error("[tamagui] No theme found, this could be due to an invalid theme name (given theme props ".concat(JSON.stringify(props), `).
4095
4144
 
4096
4145
  If this is intended and you are using Tamagui without any themes, you can disable this warning by setting the environment variable TAMAGUI_DISABLE_NO_THEME_WARNING=1`)));
4097
4146
  var themeProxied = (0, import_react3.useMemo)(function() {
@@ -4133,7 +4182,7 @@ If this is intended and you are using Tamagui without any themes, you can disabl
4133
4182
  if (subkey === "val") track(keyString);
4134
4183
  else if (subkey === "get") return function(platform) {
4135
4184
  var outVal = (0, import_createVariable.getVariable)(val);
4136
- if (platform !== "web" && import_constants.isIos && !deopt && config.settings.fastSchemeChange && !someParentIsInversed(themeManager) && scheme) {
4185
+ if (platform !== "web" && import_constants.isIos && !deopt && (0, import_config.getSetting)("fastSchemeChange") && !someParentIsInversed(themeManager) && scheme) {
4137
4186
  var oppositeThemeName = name.replace(scheme === "dark" ? "dark" : "light", scheme === "dark" ? "light" : "dark"), oppositeTheme = config.themes[oppositeThemeName], oppositeVal = (0, import_createVariable.getVariable)(oppositeTheme == null ? void 0 : oppositeTheme[keyString]);
4138
4187
  if (oppositeVal) {
4139
4188
  var dynamicVal = {
@@ -4174,7 +4223,16 @@ If this is intended and you are using Tamagui without any themes, you can disabl
4174
4223
  var id = _idToUID[t.id] = {};
4175
4224
  _uidToManager.set(id, t);
4176
4225
  }
4177
- }, useChangeThemeEffect = function(props) {
4226
+ }, ogLog = console.error, preventWarnSetState = process.env.NODE_ENV === "production" ? ogLog : (
4227
+ // temporary fix for logs, they are harmless in that i've tried to rewrite this
4228
+ // a few times using the "right" ways, but they are always slower. maybe skill issue
4229
+ function(a) {
4230
+ for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) args[_key - 1] = arguments[_key];
4231
+ if (!(typeof a == "string" && a.includes("Cannot update a component"))) return ogLog.apply(void 0, [
4232
+ a
4233
+ ].concat(_to_consumable_array(args)));
4234
+ }
4235
+ ), useChangeThemeEffect = function(props) {
4178
4236
  var isRoot = arguments.length > 1 && arguments[1] !== void 0 ? arguments[1] : !1, keys = arguments.length > 2 ? arguments[2] : void 0, shouldUpdate = arguments.length > 3 ? arguments[3] : void 0, getShouldUpdateTheme = function() {
4179
4237
  var manager = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : themeManager, nextState = arguments.length > 1 ? arguments[1] : void 0, prevState = arguments.length > 2 && arguments[2] !== void 0 ? arguments[2] : state, forceShouldChange = arguments.length > 3 && arguments[3] !== void 0 ? arguments[3] : !1, forceUpdate = shouldUpdate == null ? void 0 : shouldUpdate();
4180
4238
  if (!(!manager || !forceShouldChange && forceUpdate === !1)) {
@@ -4197,7 +4255,7 @@ If this is intended and you are using Tamagui without any themes, you can disabl
4197
4255
  }
4198
4256
  var isNewTheme2 = !!(themeManager2 !== parentManager || props.inverse);
4199
4257
  isNewTheme2 && registerThemeManager(themeManager2);
4200
- var isWebSSR = import_constants.isWeb ? !(0, import_config.getConfig)().disableSSR : !1, mounted2 = isWebSSR ? isRoot || (prev == null ? void 0 : prev.mounted) : !0;
4258
+ var isWebSSR = import_constants.isWeb ? !(0, import_config.getSetting)("disableSSR") : !1, mounted2 = isWebSSR ? isRoot || (prev == null ? void 0 : prev.mounted) : !0;
4201
4259
  state2 || (isNewTheme2 ? state2 = themeManager2.state : (state2 = parentManager.state, themeManager2 = parentManager));
4202
4260
  var wasInversed = prev == null ? void 0 : prev.inversed, isInherentlyInversed = isNewTheme2 && state2.scheme !== (parentManager == null ? void 0 : parentManager.state.scheme), inversed2 = isRoot ? !1 : isInherentlyInversed ? !0 : isWebSSR ? wasInversed != null ? !1 : null : props.inverse, response = {
4203
4261
  themeManager: themeManager2,
@@ -4241,9 +4299,9 @@ If this is intended and you are using Tamagui without any themes, you can disabl
4241
4299
  }
4242
4300
  (isNewTheme || getShouldUpdateTheme(themeManager)) && (activeThemeManagers.add(themeManager), setThemeState(createState));
4243
4301
  var selfListenerDispose = themeManager.onChangeTheme(function(_a, _b, forced) {
4244
- forced && setThemeState(function(prev) {
4302
+ forced && (console.error = preventWarnSetState, setThemeState(function(prev) {
4245
4303
  return createState(prev, !0);
4246
- });
4304
+ }), console.error = ogLog);
4247
4305
  }), disposeChangeListener = parentManager == null ? void 0 : parentManager.onChangeTheme(function(name, manager, forced) {
4248
4306
  var force = forced || (shouldUpdate == null ? void 0 : shouldUpdate()) || props.deopt || props["disable-child-theme"], shouldTryUpdate = force ?? !!(keys != null && keys.length || isNewTheme);
4249
4307
  process.env.NODE_ENV === "development" && props.debug === "verbose" && console.info(" \u{1F538} onChange", themeManager.id, {
@@ -4253,9 +4311,9 @@ If this is intended and you are using Tamagui without any themes, you can disabl
4253
4311
  name,
4254
4312
  manager,
4255
4313
  keys
4256
- }), shouldTryUpdate && setThemeState(function(prev) {
4314
+ }), shouldTryUpdate && (console.error = preventWarnSetState, setThemeState(function(prev) {
4257
4315
  return createState(prev, force);
4258
- });
4316
+ }), console.error = ogLog);
4259
4317
  }, themeManager.id);
4260
4318
  return function() {
4261
4319
  selfListenerDispose(), disposeChangeListener == null || disposeChangeListener(), isNewTheme && activeThemeManagers.delete(themeManager);
@@ -5278,7 +5336,7 @@ var require_createMediaStyle_native = __commonJS({
5278
5336
  if (isTheme || isGroup) {
5279
5337
  var groupInfo = (0, import_getGroupPropParts.getGroupPropParts)(mediaKeyIn), mediaName = groupInfo == null ? void 0 : groupInfo.name;
5280
5338
  groupMediaKey = groupInfo == null ? void 0 : groupInfo.media, isGroup && (containerName = mediaName);
5281
- var name = (isGroup ? "group_" : "") + mediaName, selectorStart = styleInner.indexOf(":root"), selectorEnd = styleInner.lastIndexOf("{"), selector = styleInner.slice(selectorStart, selectorEnd), precedenceSpace = conf.themeClassNameOnRoot && isTheme ? "" : " ", pseudoSelectorName = groupInfo.pseudo ? groupPseudoToPseudoCSSMap[groupInfo.pseudo] || groupInfo.pseudo : void 0, pseudoSelector = pseudoSelectorName ? ":".concat(pseudoSelectorName) : "", presedencePrefix = ":root".concat(precedenceImportancePrefix).concat(precedenceSpace), mediaSelector = ".t_".concat(name).concat(pseudoSelector), nextSelector = "".concat(presedencePrefix).concat(mediaSelector, " ").concat(selector.replace(":root", ""));
5339
+ var name = (isGroup ? "group_" : "") + mediaName, selectorStart = styleInner.indexOf(":root"), selectorEnd = styleInner.lastIndexOf("{"), selector = styleInner.slice(selectorStart, selectorEnd), precedenceSpace = (0, import_config.getSetting)("themeClassNameOnRoot") && isTheme ? "" : " ", pseudoSelectorName = groupInfo.pseudo ? groupPseudoToPseudoCSSMap[groupInfo.pseudo] || groupInfo.pseudo : void 0, pseudoSelector = pseudoSelectorName ? ":".concat(pseudoSelectorName) : "", presedencePrefix = ":root".concat(precedenceImportancePrefix).concat(precedenceSpace), mediaSelector = ".t_".concat(name).concat(pseudoSelector), nextSelector = "".concat(presedencePrefix).concat(mediaSelector, " ").concat(selector.replace(":root", ""));
5282
5340
  styleRule = styleInner.replace(selector, nextSelector);
5283
5341
  } else styleRule = "".concat(precedenceImportancePrefix).concat(styleInner);
5284
5342
  }
@@ -6203,6 +6261,7 @@ var require_log_native = __commonJS({
6203
6261
  }
6204
6262
  });
6205
6263
  module2.exports = __toCommonJS2(log_exports);
6264
+ var import_useMedia = require_useMedia_native();
6206
6265
  function _array_like_to_array(arr, len) {
6207
6266
  (len == null || len > arr.length) && (len = arr.length);
6208
6267
  for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
@@ -6230,10 +6289,15 @@ var require_log_native = __commonJS({
6230
6289
  }
6231
6290
  function log() {
6232
6291
  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key];
6233
- var _console;
6234
6292
  if (process.env.NODE_ENV !== "production") {
6235
- if (0) var _console1;
6236
- return (_console = console).log.apply(_console, _to_consumable_array(args));
6293
+ (0, import_useMedia._dmt)(!0);
6294
+ try {
6295
+ var _console;
6296
+ if (0) var _console1;
6297
+ return (_console = console).log.apply(_console, _to_consumable_array(args));
6298
+ } finally {
6299
+ (0, import_useMedia._dmt)(!1);
6300
+ }
6237
6301
  }
6238
6302
  }
6239
6303
  }
@@ -6619,7 +6683,7 @@ var require_expandStyle_native = __commonJS({
6619
6683
  }
6620
6684
  });
6621
6685
  module2.exports = __toCommonJS2(expandStyle_exports);
6622
- var import_constants = require_index_native3(), import_webToNativeProps = require_webToNativeProps_native(), import_config = require_config_native();
6686
+ var import_constants = require_index_native3(), import_config = require_config_native(), import_webToNativeProps = require_webToNativeProps_native();
6623
6687
  function _define_property2(obj, key, value) {
6624
6688
  return key in obj ? Object.defineProperty(obj, key, {
6625
6689
  value,
@@ -7297,16 +7361,17 @@ var require_propMapper_native = __commonJS({
7297
7361
  }
7298
7362
  var propMapper = function(key, value, styleStateIn, subPropsIn) {
7299
7363
  if (lastFontFamilyToken = null, !(!import_constants.isAndroid && key === "elevationAndroid")) {
7364
+ var conf = styleStateIn.conf, styleProps = styleStateIn.styleProps, fontFamily = styleStateIn.fontFamily, staticConfig = styleStateIn.staticConfig;
7300
7365
  if (value === "unset") {
7301
- var _styleStateIn_conf_unset, unsetVal = (_styleStateIn_conf_unset = styleStateIn.conf.unset) === null || _styleStateIn_conf_unset === void 0 ? void 0 : _styleStateIn_conf_unset[key];
7366
+ var _conf_unset, unsetVal = (_conf_unset = conf.unset) === null || _conf_unset === void 0 ? void 0 : _conf_unset[key];
7302
7367
  if (unsetVal != null) value = unsetVal;
7303
7368
  else return;
7304
7369
  }
7305
- var subProps = styleStateIn.styleProps.fallbackProps || subPropsIn, styleState = subProps ? new Proxy(styleStateIn, {
7370
+ var subProps = styleProps.fallbackProps || subPropsIn, styleState = subProps ? new Proxy(styleStateIn, {
7306
7371
  get: function(_, k) {
7307
7372
  return k === "curProps" ? subProps : Reflect.get(_, k);
7308
7373
  }
7309
- }) : styleStateIn, conf = styleState.conf, styleProps = styleState.styleProps, fontFamily = styleState.fontFamily, staticConfig = styleState.staticConfig, variants = staticConfig.variants;
7374
+ }) : styleStateIn, variants = staticConfig.variants;
7310
7375
  if (process.env.NODE_ENV === "development" && fontFamily && fontFamily[0] === "$" && !(fontFamily in conf.fontsParsed) && console.warn('Warning: no fontFamily "'.concat(fontFamily, '" found in config: ').concat(Object.keys(conf.fontsParsed).join(", "))), !styleProps.noExpand && variants && key in variants) {
7311
7376
  styleState.curProps[key] = value;
7312
7377
  var variantValue = resolveVariants(key, value, styleProps, styleState, "");
@@ -7729,7 +7794,7 @@ var require_getSplitStyles_native = __commonJS({
7729
7794
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array(o, minLen);
7730
7795
  }
7731
7796
  }
7732
- var conf, PROP_SPLIT = "-";
7797
+ var consoleGroupCollapsed = import_constants.isWeb ? console.groupCollapsed : console.info, conf, PROP_SPLIT = "-";
7733
7798
  function isValidStyleKey(key, staticConfig) {
7734
7799
  var _staticConfig_accept, validStyleProps = staticConfig.validStyles || (staticConfig.isText || staticConfig.isInput ? import_helpers.stylePropsText : import_helpers.validStyles);
7735
7800
  return validStyleProps[key] || ((_staticConfig_accept = staticConfig.accept) === null || _staticConfig_accept === void 0 ? void 0 : _staticConfig_accept[key]);
@@ -7759,7 +7824,7 @@ var require_getSplitStyles_native = __commonJS({
7759
7824
  debug,
7760
7825
  skipThemeTokenResolution
7761
7826
  };
7762
- process.env.NODE_ENV === "development" && debug && debug !== "profile" && import_constants.isClient && (console.groupCollapsed("getSplitStyles (collapsed)"), (0, import_log.log)({
7827
+ process.env.NODE_ENV === "development" && debug && debug !== "profile" && import_constants.isClient && (consoleGroupCollapsed("getSplitStyles (collapsed)"), (0, import_log.log)({
7763
7828
  props,
7764
7829
  staticConfig,
7765
7830
  shouldDoClasses,
@@ -7808,7 +7873,7 @@ var require_getSplitStyles_native = __commonJS({
7808
7873
  if (!(isStyleProp && (asChild === "except-style" || asChild === "except-style-web"))) {
7809
7874
  var shouldPassProp = !isStyleProp || // is in parent variants
7810
7875
  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;
7811
- if (process.env.NODE_ENV === "development" && debug === "verbose" && (console.groupEnd(), console.groupEnd(), console.groupCollapsed(" \u{1F511} ".concat(keyOg).concat(keyInit !== keyOg ? " (shorthand for ".concat(keyInit, ")") : "", " ").concat(shouldPassThrough ? "(pass)" : "")), (0, import_log.log)({
7876
+ if (process.env.NODE_ENV === "development" && debug === "verbose" && (console.groupEnd(), console.groupEnd(), consoleGroupCollapsed(" \u{1F511} ".concat(keyOg).concat(keyInit !== keyOg ? " (shorthand for ".concat(keyInit, ")") : "", " ").concat(shouldPassThrough ? "(pass)" : "")), (0, import_log.log)({
7812
7877
  isVariant,
7813
7878
  valInit,
7814
7879
  shouldPassProp
@@ -7835,7 +7900,7 @@ var require_getSplitStyles_native = __commonJS({
7835
7900
  next && (styleState.fontFamily = next);
7836
7901
  }
7837
7902
  if (process.env.NODE_ENV === "development" && debug === "verbose") {
7838
- console.groupCollapsed(" \u{1F4A0} expanded", keyInit, valInit);
7903
+ consoleGroupCollapsed(" \u{1F4A0} expanded", keyInit, valInit);
7839
7904
  try {
7840
7905
  !import_constants.isServer && import_isDevTools.isDevTools && ((0, import_log.log)({
7841
7906
  expanded,
@@ -7845,7 +7910,6 @@ var require_getSplitStyles_native = __commonJS({
7845
7910
  variant: variants == null ? void 0 : variants[keyInit],
7846
7911
  shouldPassProp,
7847
7912
  isHOCShouldPassThrough,
7848
- theme,
7849
7913
  usedKeys: _object_spread2({}, usedKeys),
7850
7914
  curProps: _object_spread2({}, styleState.curProps)
7851
7915
  }), (0, import_log.log)("expanded", expanded, `
@@ -7868,7 +7932,7 @@ current`, _object_spread2({}, styleState.style)));
7868
7932
  }
7869
7933
  var shouldPassThrough1 = styleProps.noExpand && isPseudo || isHOC && (isMediaOrPseudo1 || (parentStaticConfig == null || (_parentStaticConfig_variants = parentStaticConfig.variants) === null || _parentStaticConfig_variants === void 0 ? void 0 : _parentStaticConfig_variants[keyInit]));
7870
7934
  if (shouldPassThrough1) {
7871
- passDownProp(viewProps, key, val, isMediaOrPseudo1), process.env.NODE_ENV === "development" && debug === "verbose" && (console.groupCollapsed(" - passing down prop ".concat(key)), (0, import_log.log)({
7935
+ passDownProp(viewProps, key, val, isMediaOrPseudo1), process.env.NODE_ENV === "development" && debug === "verbose" && (consoleGroupCollapsed(" - passing down prop ".concat(key)), (0, import_log.log)({
7872
7936
  val,
7873
7937
  after: _object_spread2({}, viewProps[key])
7874
7938
  }), console.groupEnd());
@@ -7887,7 +7951,7 @@ current`, _object_spread2({}, styleState.style)));
7887
7951
  }
7888
7952
  if (shouldDoClasses && !isExit) {
7889
7953
  var pseudoStyles = (0, import_getStylesAtomic.getStyleAtomic)(pseudoStyleObject, descriptor);
7890
- process.env.NODE_ENV === "development" && debug === "verbose" && (console.groupCollapsed("pseudo (classes)", key), (0, import_log.log)({
7954
+ process.env.NODE_ENV === "development" && debug === "verbose" && (consoleGroupCollapsed("pseudo (classes)", key), (0, import_log.log)({
7891
7955
  pseudoStyleObject,
7892
7956
  pseudoStyles
7893
7957
  }), console.groupEnd());
@@ -7909,7 +7973,7 @@ current`, _object_spread2({}, styleState.style)));
7909
7973
  }
7910
7974
  if (!shouldDoClasses || isExit || isEnter) {
7911
7975
  var descriptorKey = descriptor.stateKey || descriptor.name, isDisabled = componentState[descriptorKey] === !1;
7912
- isExit && (isDisabled = !styleProps.isExiting), isEnter && componentState.unmounted === !1 && (isDisabled = !0), process.env.NODE_ENV === "development" && debug === "verbose" && (console.groupCollapsed("pseudo", key, {
7976
+ isExit && (isDisabled = !styleProps.isExiting), isEnter && componentState.unmounted === !1 && (isDisabled = !0), process.env.NODE_ENV === "development" && debug === "verbose" && (consoleGroupCollapsed("pseudo", key, {
7913
7977
  isDisabled
7914
7978
  }), (0, import_log.log)({
7915
7979
  pseudoStyleObject,
@@ -8005,22 +8069,21 @@ current`, _object_spread2({}, styleState.style)));
8005
8069
  } else if (isGroupMedia) {
8006
8070
  var _componentState_group, groupInfo = (0, import_getGroupPropParts.getGroupPropParts)(mediaKeyShort), groupName = groupInfo.name, groupContext = context == null ? void 0 : context.groups.state[groupName];
8007
8071
  if (!groupContext) {
8008
- process.env.NODE_ENV === "development" && debug && console.warn("No parent with group prop, skipping styles: ".concat(groupName));
8072
+ process.env.NODE_ENV === "development" && debug && (0, import_log.log)("No parent with group prop, skipping styles: ".concat(groupName));
8009
8073
  continue;
8010
8074
  }
8011
8075
  var groupPseudoKey = groupInfo.pseudo, groupMediaKey = groupInfo.media, componentGroupState = (_componentState_group = componentState.group) === null || _componentState_group === void 0 ? void 0 : _componentState_group[groupName];
8012
8076
  if (groupMediaKey) {
8013
8077
  mediaGroups || (mediaGroups = /* @__PURE__ */ new Set()), mediaGroups.add(groupMediaKey);
8014
8078
  var mediaState1 = componentGroupState == null ? void 0 : componentGroupState.media, isActive = mediaState1 == null ? void 0 : mediaState1[groupMediaKey];
8015
- if (!mediaState1 && groupContext.layout && (isActive = (0, import_useMedia.mediaKeyMatch)(groupMediaKey, groupContext.layout)), !isActive) continue;
8079
+ if (!mediaState1 && groupContext.layout && (isActive = (0, import_useMedia.mediaKeyMatch)(groupMediaKey, groupContext.layout)), process.env.NODE_ENV === "development" && debug === "verbose" && (0, import_log.log)(" \u{1F3D8}\uFE0F GROUP media ".concat(groupMediaKey, " active? ").concat(isActive)), !isActive) continue;
8016
8080
  importanceBump = 2;
8017
8081
  }
8018
8082
  if (groupPseudoKey) {
8019
8083
  pseudoGroups || (pseudoGroups = /* @__PURE__ */ new Set()), pseudoGroups.add(groupName);
8020
8084
  var componentGroupPseudoState = (componentGroupState || // fallback to context initially
8021
- context.groups.state[groupName]).pseudo, isActive1 = componentGroupPseudoState == null ? void 0 : componentGroupPseudoState[groupPseudoKey];
8022
- if (!isActive1) continue;
8023
- var priority1 = import_pseudoDescriptors.pseudoPriorities[groupPseudoKey];
8085
+ context.groups.state[groupName]).pseudo, isActive1 = componentGroupPseudoState == null ? void 0 : componentGroupPseudoState[groupPseudoKey], priority1 = import_pseudoDescriptors.pseudoPriorities[groupPseudoKey];
8086
+ if (process.env.NODE_ENV === "development" && debug === "verbose" && (0, import_log.log)(" \u{1F3D8}\uFE0F GROUP pseudo ".concat(groupMediaKey, " active? ").concat(isActive1, ", priority ").concat(priority1)), !isActive1) continue;
8024
8087
  importanceBump = priority1;
8025
8088
  }
8026
8089
  }
@@ -8030,7 +8093,7 @@ current`, _object_spread2({}, styleState.style)));
8030
8093
  space = valInit.space;
8031
8094
  continue;
8032
8095
  }
8033
- (_styleState1 = styleState).style || (_styleState1.style = {}), mergeMediaByImportance(styleState, mediaKeyShort, subKey, mediaStyle1[subKey], usedKeys, mediaState2[mediaKeyShort], importanceBump), key === "fontFamily" && (styleState.fontFamily = mediaStyle1.fontFamily);
8096
+ (_styleState1 = styleState).style || (_styleState1.style = {}), mergeMediaByImportance(styleState, mediaKeyShort, subKey, mediaStyle1[subKey], usedKeys, mediaState2[mediaKeyShort], importanceBump, debug), key === "fontFamily" && (styleState.fontFamily = mediaStyle1.fontFamily);
8034
8097
  }
8035
8098
  }
8036
8099
  continue;
@@ -8152,7 +8215,7 @@ current`, _object_spread2({}, styleState.style)));
8152
8215
  } else style3 && !styleProps.noMergeStyle && (viewProps.style = style3);
8153
8216
  }
8154
8217
  if (process.env.NODE_ENV === "development" && debug === "verbose" && import_isDevTools.isDevTools) {
8155
- console.groupCollapsed("\u{1F539} getSplitStyles ===>");
8218
+ consoleGroupCollapsed("\u{1F539} getSplitStyles ===>");
8156
8219
  try {
8157
8220
  var logs = _object_spread_props(_object_spread2({}, result), {
8158
8221
  className,
@@ -8259,9 +8322,15 @@ current`, _object_spread2({}, styleState.style)));
8259
8322
  delete viewProps[key], viewProps[key] = next;
8260
8323
  } else viewProps[key] = val;
8261
8324
  }
8262
- function mergeMediaByImportance(styleState, mediaKey, key, value, importancesUsed, isSizeMedia, importanceBump) {
8325
+ function mergeMediaByImportance(styleState, mediaKey, key, value, importancesUsed, isSizeMedia, importanceBump, debugProp) {
8263
8326
  var importance = (0, import_useMedia.getMediaImportanceIfMoreImportant)(mediaKey, key, importancesUsed, isSizeMedia);
8264
- return importanceBump && (importance = (importance || 0) + importanceBump), importance === null ? !1 : (importancesUsed[key] = importance, mergeStyle(styleState, key, value), !0);
8327
+ if (importanceBump && (importance = (importance || 0) + importanceBump), process.env.NODE_ENV === "development" && debugProp === "verbose" && (0, import_log.log)("mergeMediaByImportance ".concat(key, " importance existing ").concat(importancesUsed[key], " next ").concat(importance)), importance === null) return !1;
8328
+ if (importancesUsed[key] = importance, key in import_pseudoDescriptors.pseudoDescriptors) {
8329
+ var descriptor = import_pseudoDescriptors.pseudoDescriptors[key], descriptorKey = descriptor.stateKey || descriptor.name, isDisabled = styleState.componentState[descriptorKey] === !1;
8330
+ if (isDisabled) return !1;
8331
+ for (var subKey in value) mergeStyle(styleState, subKey, value[subKey]);
8332
+ } else mergeStyle(styleState, key, value);
8333
+ return !0;
8265
8334
  }
8266
8335
  function normalizeStyle(style) {
8267
8336
  var out = {};
@@ -9598,7 +9667,7 @@ var require_createComponent_native = __commonJS({
9598
9667
  if ("themeInverse" in props && (themeStateProps.inverse = props.themeInverse), "theme" in props && (themeStateProps.name = props.theme), typeof curStateRef.isListeningToTheme == "boolean" && (themeStateProps.shouldUpdate = function() {
9599
9668
  return stateRef.current.isListeningToTheme;
9600
9669
  }), themeStateProps.deopt = willBeAnimated, process.env.NODE_ENV === "development" && debugProp && debugProp !== "profile") {
9601
- var name = "".concat(componentName2 || (Component == null ? void 0 : Component.displayName) || (Component == null ? void 0 : Component.name) || "[Unnamed Component]"), type = (hasEnterStyle ? "(hasEnter)" : " ") + (isAnimated ? "(animated)" : " ") + (isReactNative ? "(rnw)" : " ") + (shouldAvoidClasses ? "(shouldAvoidClasses)" : " ") + ((presenceState == null ? void 0 : presenceState.isPresent) === !1 ? "(EXIT)" : ""), dataIs = propsIn["data-is"] || "", banner = "".concat(internalID, " ").concat(name).concat(dataIs ? " ".concat(dataIs) : "", " ").concat(type);
9670
+ var name = "".concat(componentName2 || (Component == null ? void 0 : Component.displayName) || (Component == null ? void 0 : Component.name) || "[Unnamed Component]"), type = (hasEnterStyle ? "(hasEnter)" : " ") + (isAnimated ? "(animated)" : " ") + (isReactNative ? "(rnw)" : " ") + (shouldAvoidClasses ? "(shouldAvoidClasses)" : " ") + (state.press || state.pressIn ? "(PRESSED)" : " ") + (state.hover ? "(HOVERED)" : " ") + (state.focus ? "(FOCUSED)" : " ") + ((presenceState == null ? void 0 : presenceState.isPresent) === !1 ? "(EXIT)" : ""), dataIs = propsIn["data-is"] || "", banner = "".concat(internalID, " ").concat(name).concat(dataIs ? " ".concat(dataIs) : "", " ").concat(type);
9602
9671
  if (console.info("%c ".concat(banner, " (hydrated: ").concat(isHydrated, ") (unmounted: ").concat(state.unmounted, ")"), "background: green; color: white;"), import_constants.isServer) (0, import_log.log)({
9603
9672
  noClassNames,
9604
9673
  isAnimated,
@@ -9608,8 +9677,8 @@ var require_createComponent_native = __commonJS({
9608
9677
  });
9609
9678
  else {
9610
9679
  console.groupEnd();
9611
- var pressLog = "".concat(state.press || state.pressIn ? " PRESS " : ""), stateLog = "".concat(pressLog).concat(state.hover ? " HOVER " : "").concat(state.focus ? " FOCUS" : " "), ch = propsIn.children, childLog = typeof ch == "string" ? ch.length > 4 ? ch.slice(0, 4) + "..." : ch : "";
9612
- childLog.length && (childLog = "(children: ".concat(childLog, ")")), console.groupCollapsed("".concat(childLog).concat(stateLog, "Props:")), (0, import_log.log)("props in:", propsIn), (0, import_log.log)("final props:", props), (0, import_log.log)({
9680
+ var ch = propsIn.children, childLog = typeof ch == "string" ? ch.length > 4 ? ch.slice(0, 4) + "..." : ch : "";
9681
+ childLog.length && (childLog = "(children: ".concat(childLog, ")")), console.groupCollapsed("".concat(childLog, " Props:")), (0, import_log.log)("props in:", propsIn), (0, import_log.log)("final props:", props), (0, import_log.log)({
9613
9682
  state,
9614
9683
  staticConfig,
9615
9684
  elementType,
@@ -9716,7 +9785,7 @@ If you meant to do this, you can disable this warning - either change untilMeasu
9716
9785
  pressIn: !1
9717
9786
  });
9718
9787
  };
9719
- process.env.NODE_ENV === "development" && (0, import_constants.useIsomorphicLayoutEffect)(function() {
9788
+ process.env.NODE_ENV === "development" && import_constants.isWeb && (0, import_constants.useIsomorphicLayoutEffect)(function() {
9720
9789
  debugProp && (console.groupCollapsed("Rendered style >"), console.warn(getComputedStyle(stateRef.current.host)), console.groupEnd());
9721
9790
  }), (0, import_react3.useEffect)(function() {
9722
9791
  if (!disabled) {
@@ -9751,7 +9820,17 @@ If you meant to do this, you can disable this warning - either change untilMeasu
9751
9820
  mediaGroups ? Object.keys(_to_consumable_array(mediaGroups)).join("") : 0
9752
9821
  ]);
9753
9822
  var runtimePressStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.pressStyle), runtimeFocusStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.focusStyle), runtimeFocusVisibleStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.focusVisibleStyle), attachFocus = !!(runtimePressStyle || runtimeFocusStyle || runtimeFocusVisibleStyle || onFocus || onBlur), attachPress = !!(groupName || runtimePressStyle || onPress || onPressOut || onPressIn || onMouseDown || onMouseUp || onLongPress || onClick || pseudos != null && pseudos.focusVisibleStyle), runtimeHoverStyle = !disabled && noClassNames && (pseudos == null ? void 0 : pseudos.hoverStyle), needsHoverState = !!(groupName || runtimeHoverStyle || onHoverIn || onHoverOut), attachHover = import_constants.isWeb && !!(groupName || needsHoverState || onMouseEnter || onMouseLeave), shouldAttach = !disabled && !props.asChild && !!(attachFocus || attachPress || attachHover || runtimePressStyle || runtimeHoverStyle || runtimeFocusStyle), needsPressState = !!(groupName || runtimePressStyle);
9754
- process.env.NODE_ENV === "development" && time && time(_templateObject14());
9823
+ process.env.NODE_ENV === "development" && time && time(_templateObject14()), process.env.NODE_ENV === "development" && debugProp === "verbose" && (0, import_log.log)("\u{1FAA9} events()", {
9824
+ runtimeFocusStyle,
9825
+ runtimePressStyle,
9826
+ runtimeHoverStyle,
9827
+ runtimeFocusVisibleStyle,
9828
+ attachPress,
9829
+ attachFocus,
9830
+ attachHover,
9831
+ shouldAttach,
9832
+ needsHoverState
9833
+ });
9755
9834
  var events = shouldAttach ? _object_spread2(_object_spread_props(_object_spread2({
9756
9835
  onPressOut: attachPress ? function(e) {
9757
9836
  unPress(), onPressOut == null || onPressOut(e), onMouseUp == null || onMouseUp(e);
@@ -10073,14 +10152,6 @@ If you meant to do this, you can disable this warning - either change untilMeasu
10073
10152
  return val && ((typeof val > "u" ? "undefined" : _type_of(val)) > "u" ? "undefined" : _type_of1(val)) === "object" && "_animation" in val;
10074
10153
  });
10075
10154
  }
10076
- function getMediaState(mediaGroups, layout) {
10077
- return Object.fromEntries(_to_consumable_array(mediaGroups).map(function(mediaKey) {
10078
- return [
10079
- mediaKey,
10080
- (0, import_useMedia.mediaKeyMatch)(mediaKey, layout)
10081
- ];
10082
- }));
10083
- }
10084
10155
  var fromPx = function(val) {
10085
10156
  return typeof val != "string" ? val : +val.replace("px", "");
10086
10157
  }, isDisabled = function(props) {
@@ -10102,7 +10173,7 @@ If you meant to do this, you can disable this warning - either change untilMeasu
10102
10173
  };
10103
10174
  if (pseudo && pseudoGroups != null && pseudoGroups.has(String(name))) Object.assign(current.pseudo, pseudo), persist();
10104
10175
  else if (layout && mediaGroups) {
10105
- var mediaState2 = getMediaState(mediaGroups, layout), next = (0, import_createShallowSetState.mergeIfNotShallowEqual)(current.media, mediaState2);
10176
+ var mediaState2 = (0, import_useMedia.getMediaState)(mediaGroups, layout), next = (0, import_createShallowSetState.mergeIfNotShallowEqual)(current.media, mediaState2);
10106
10177
  next !== current.media && (Object.assign(current.media, next), persist());
10107
10178
  }
10108
10179
  });
@@ -10970,6 +11041,7 @@ var require_createTamagui_native = __commonJS({
10970
11041
  }
10971
11042
  var createdConfigs = /* @__PURE__ */ new WeakMap();
10972
11043
  function createTamagui(configIn) {
11044
+ var _configIn_settings;
10973
11045
  if (createdConfigs.has(configIn)) return configIn;
10974
11046
  var tokensParsed = {}, tokens = (0, import_createVariables.createVariables)(configIn.tokens || {});
10975
11047
  if (configIn.tokens) {
@@ -11089,7 +11161,7 @@ var require_createTamagui_native = __commonJS({
11089
11161
  return getCSS(_object_spread_props(_object_spread2({}, opts), {
11090
11162
  sinceLastCall: !0
11091
11163
  }));
11092
- }, defaultFontName = configIn.defaultFont || // uses font named "body" if present for compat
11164
+ }, _configIn_settings_defaultFont, defaultFontSetting = (_configIn_settings_defaultFont = (_configIn_settings = configIn.settings) === null || _configIn_settings === void 0 ? void 0 : _configIn_settings.defaultFont) !== null && _configIn_settings_defaultFont !== void 0 ? _configIn_settings_defaultFont : configIn.defaultFont, defaultFontName = defaultFontSetting || // uses font named "body" if present for compat
11093
11165
  configIn.fonts && ("body" in configIn.fonts ? "body" : "");
11094
11166
  !defaultFontName && configIn.fonts && (defaultFontName = Object.keys(configIn.fonts)[0]), (defaultFontName == null ? void 0 : defaultFontName[0]) === "$" && (defaultFontName = defaultFontName.slice(1));
11095
11167
  var defaultFont = "$".concat(defaultFontName), config = _object_spread_props(_object_spread2({
@@ -11100,7 +11172,7 @@ var require_createTamagui_native = __commonJS({
11100
11172
  media: {}
11101
11173
  }, configIn), {
11102
11174
  unset: _object_spread2({
11103
- fontFamily: configIn.defaultFont ? defaultFont : void 0
11175
+ fontFamily: defaultFontName ? defaultFont : void 0
11104
11176
  }, configIn.unset),
11105
11177
  settings: _object_spread2({
11106
11178
  webContainerType: "inline-size"
@@ -11126,7 +11198,7 @@ var require_createTamagui_native = __commonJS({
11126
11198
  fontSizeTokens: fontSizeTokens || /* @__PURE__ */ new Set(),
11127
11199
  specificTokens
11128
11200
  });
11129
- if ((0, import_useMedia.configureMedia)(config), (0, import_config.setConfig)(config), createdConfigs.set(config, !0), import_config.configListeners.size && (import_config.configListeners.forEach(function(cb) {
11201
+ 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) {
11130
11202
  return cb(config);
11131
11203
  }), import_config.configListeners.clear()), process.env.NODE_ENV === "development") {
11132
11204
  var _process_env_DEBUG;
@@ -12684,10 +12756,10 @@ var require_ThemeProvider_native = __commonJS({
12684
12756
  }
12685
12757
  });
12686
12758
  module2.exports = __toCommonJS2(ThemeProvider_exports);
12687
- 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) {
12759
+ 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(), import_config = require_config_native(), ThemeProvider = function(props) {
12688
12760
  return import_constants.isClient && (0, import_react3.useLayoutEffect)(function() {
12689
12761
  if (!props.disableRootThemeClass) {
12690
- var cn = "".concat(import_constants2.THEME_CLASSNAME_PREFIX).concat(props.defaultTheme), target = props.themeClassNameOnRoot ? document.documentElement : document.body;
12762
+ var cn = "".concat(import_constants2.THEME_CLASSNAME_PREFIX).concat(props.defaultTheme), _props_themeClassNameOnRoot, target = ((_props_themeClassNameOnRoot = props.themeClassNameOnRoot) !== null && _props_themeClassNameOnRoot !== void 0 ? _props_themeClassNameOnRoot : (0, import_config.getSetting)("themeClassNameOnRoot")) ? document.documentElement : document.body;
12691
12763
  return target.classList.add(cn), function() {
12692
12764
  target.classList.remove(cn);
12693
12765
  };
@@ -12836,7 +12908,7 @@ var require_TamaguiProvider_native = __commonJS({
12836
12908
  }
12837
12909
  });
12838
12910
  module2.exports = __toCommonJS2(TamaguiProvider_exports);
12839
- var import_jsx_runtime = require("react/jsx-runtime"), import_constants = require_index_native3(), import_react3 = require("react"), import_ComponentContext = require_ComponentContext_native(), import_useDidHydrateOnce = require_useDidHydrateOnce_native(), import_useMedia = require_useMedia_native(), import_ThemeProvider = require_ThemeProvider_native();
12911
+ var import_jsx_runtime = require("react/jsx-runtime"), import_constants = require_index_native3(), import_react3 = require("react"), import_ComponentContext = require_ComponentContext_native(), import_useDidHydrateOnce = require_useDidHydrateOnce_native(), import_useMedia = require_useMedia_native(), import_ThemeProvider = require_ThemeProvider_native(), import_config = require_config_native();
12840
12912
  function _array_like_to_array(arr, len) {
12841
12913
  (len == null || len > arr.length) && (len = arr.length);
12842
12914
  for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
@@ -12893,8 +12965,8 @@ var require_TamaguiProvider_native = __commonJS({
12893
12965
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ComponentContext.ComponentContext.Provider, {
12894
12966
  animationDriver: config == null ? void 0 : config.animations,
12895
12967
  children: /* @__PURE__ */ (0, import_jsx_runtime.jsx)(import_ThemeProvider.ThemeProvider, {
12896
- themeClassNameOnRoot: themeClassNameOnRoot ?? (config == null ? void 0 : config.themeClassNameOnRoot),
12897
- disableRootThemeClass: disableRootThemeClass ?? (config == null ? void 0 : config.disableRootThemeClass),
12968
+ themeClassNameOnRoot: themeClassNameOnRoot ?? (0, import_config.getSetting)("themeClassNameOnRoot"),
12969
+ disableRootThemeClass: disableRootThemeClass ?? (0, import_config.getSetting)("disableRootThemeClass"),
12898
12970
  defaultTheme: defaultTheme ?? (config ? Object.keys(config.themes)[0] : ""),
12899
12971
  reset,
12900
12972
  className,