tamagui 1.105.0 → 1.105.2

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
@@ -2242,6 +2242,9 @@ var require_config_native = __commonJS({
2242
2242
  getFont: function() {
2243
2243
  return getFont;
2244
2244
  },
2245
+ getSetting: function() {
2246
+ return getSetting;
2247
+ },
2245
2248
  getThemes: function() {
2246
2249
  return getThemes3;
2247
2250
  },
@@ -2321,7 +2324,14 @@ var require_config_native = __commonJS({
2321
2324
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array2(o, minLen);
2322
2325
  }
2323
2326
  }
2324
- var conf, setConfig = function(next) {
2327
+ var conf, getSetting = function(key) {
2328
+ if (process.env.NODE_ENV === "development" && !conf) throw new Error("Haven't called createTamagui yet");
2329
+ var _conf_settings_key;
2330
+ return (_conf_settings_key = conf.settings[key]) !== null && _conf_settings_key !== void 0 ? _conf_settings_key : (
2331
+ // @ts-expect-error
2332
+ conf[key]
2333
+ );
2334
+ }, setConfig = function(next) {
2325
2335
  conf = next;
2326
2336
  }, setConfigFont = function(name, font, fontParsed) {
2327
2337
  if (process.env.NODE_ENV === "development" && !conf) throw new Error("Haven't called createTamagui yet");
@@ -3174,7 +3184,7 @@ var require_useDisableSSR_native = __commonJS({
3174
3184
  var import_config = require_config_native();
3175
3185
  function getDisableSSR(componentContext) {
3176
3186
  var _componentContext_disableSSR;
3177
- return (_componentContext_disableSSR = componentContext == null ? void 0 : componentContext.disableSSR) !== null && _componentContext_disableSSR !== void 0 ? _componentContext_disableSSR : (0, import_config.getConfig)().disableSSR;
3187
+ return (_componentContext_disableSSR = componentContext == null ? void 0 : componentContext.disableSSR) !== null && _componentContext_disableSSR !== void 0 ? _componentContext_disableSSR : (0, import_config.getSetting)("disableSSR");
3178
3188
  }
3179
3189
  }
3180
3190
  });
@@ -3221,6 +3231,9 @@ var require_useMedia_native = __commonJS({
3221
3231
  }), mod);
3222
3232
  }, useMedia_exports = {};
3223
3233
  __export2(useMedia_exports, {
3234
+ _dmt: function() {
3235
+ return _dmt;
3236
+ },
3224
3237
  configureMedia: function() {
3225
3238
  return configureMedia2;
3226
3239
  },
@@ -3233,6 +3246,9 @@ var require_useMedia_native = __commonJS({
3233
3246
  getMediaKeyImportance: function() {
3234
3247
  return getMediaKeyImportance;
3235
3248
  },
3249
+ getMediaState: function() {
3250
+ return getMediaState;
3251
+ },
3236
3252
  isMediaKey: function() {
3237
3253
  return isMediaKey;
3238
3254
  },
@@ -3274,6 +3290,9 @@ var require_useMedia_native = __commonJS({
3274
3290
  function _array_with_holes(arr) {
3275
3291
  if (Array.isArray(arr)) return arr;
3276
3292
  }
3293
+ function _array_without_holes2(arr) {
3294
+ if (Array.isArray(arr)) return _array_like_to_array2(arr);
3295
+ }
3277
3296
  function _define_property9(obj, key, value) {
3278
3297
  return key in obj ? Object.defineProperty(obj, key, {
3279
3298
  value,
@@ -3282,6 +3301,9 @@ var require_useMedia_native = __commonJS({
3282
3301
  writable: !0
3283
3302
  }) : obj[key] = value, obj;
3284
3303
  }
3304
+ function _iterable_to_array2(iter) {
3305
+ if ((typeof Symbol > "u" ? "undefined" : _type_of3(Symbol)) < "u" && iter[Symbol.iterator] != null || iter["@@iterator"] != null) return Array.from(iter);
3306
+ }
3285
3307
  function _iterable_to_array_limit(arr, i) {
3286
3308
  var _i = arr == null ? null : (typeof Symbol > "u" ? "undefined" : _type_of3(Symbol)) < "u" && arr[Symbol.iterator] || arr["@@iterator"];
3287
3309
  if (_i != null) {
@@ -3303,6 +3325,9 @@ var require_useMedia_native = __commonJS({
3303
3325
  function _non_iterable_rest() {
3304
3326
  throw new TypeError("Invalid attempt to destructure non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
3305
3327
  }
3328
+ function _non_iterable_spread2() {
3329
+ throw new TypeError("Invalid attempt to spread non-iterable instance.\\nIn order to be iterable, non-array objects must have a [Symbol.iterator]() method.");
3330
+ }
3306
3331
  function _object_spread9(target) {
3307
3332
  for (var i = 1; i < arguments.length; i++) {
3308
3333
  var source = arguments[i] != null ? arguments[i] : {}, ownKeys22 = Object.keys(source);
@@ -3332,6 +3357,9 @@ var require_useMedia_native = __commonJS({
3332
3357
  function _sliced_to_array(arr, i) {
3333
3358
  return _array_with_holes(arr) || _iterable_to_array_limit(arr, i) || _unsupported_iterable_to_array2(arr, i) || _non_iterable_rest();
3334
3359
  }
3360
+ function _to_consumable_array2(arr) {
3361
+ return _array_without_holes2(arr) || _iterable_to_array2(arr) || _unsupported_iterable_to_array2(arr) || _non_iterable_spread2();
3362
+ }
3335
3363
  function _unsupported_iterable_to_array2(o, minLen) {
3336
3364
  if (o) {
3337
3365
  if (typeof o == "string") return _array_like_to_array2(o, minLen);
@@ -3363,7 +3391,7 @@ var require_useMedia_native = __commonJS({
3363
3391
  var conf = (0, import_config.getConfig)();
3364
3392
  return conf.settings.mediaPropOrder ? defaultMediaImportance : mediaKeysOrdered.indexOf(key) + 100;
3365
3393
  }, dispose = /* @__PURE__ */ new Set(), mediaVersion = 0, configureMedia2 = function(config) {
3366
- var media = config.media, mediaQueryDefaultActive = config.mediaQueryDefaultActive;
3394
+ var media = config.media, mediaQueryDefaultActive = (0, import_config.getSetting)("mediaQueryDefaultActive");
3367
3395
  if (media) {
3368
3396
  mediaVersion++;
3369
3397
  for (var key in media) mediaState3[key] = (mediaQueryDefaultActive == null ? void 0 : mediaQueryDefaultActive[key]) || !1, mediaKeys.add("$".concat(key));
@@ -3441,16 +3469,37 @@ var require_useMedia_native = __commonJS({
3441
3469
  }
3442
3470
  return new Proxy(state, {
3443
3471
  get: function(_, key) {
3444
- if (typeof key == "string") {
3445
- var _componentState;
3446
- (_componentState = componentState).keys || (_componentState.keys = {}), componentState.keys[key] = !0, process.env.NODE_ENV === "development" && debug && console.info("useMedia() TOUCH", key);
3472
+ if (!disableMediaTouch) {
3473
+ if (typeof key == "string") {
3474
+ var _componentState;
3475
+ (_componentState = componentState).keys || (_componentState.keys = {}), componentState.keys[key] = !0, process.env.NODE_ENV === "development" && debug && console.info("useMedia() TOUCH", key);
3476
+ }
3477
+ return Reflect.get(state, key);
3447
3478
  }
3448
- return Reflect.get(state, key);
3449
3479
  }
3450
3480
  });
3451
3481
  }
3482
+ var disableMediaTouch = !1;
3483
+ function _dmt(val) {
3484
+ disableMediaTouch = val;
3485
+ }
3486
+ function getMediaState(mediaGroups, layout) {
3487
+ disableMediaTouch = !0;
3488
+ var res;
3489
+ try {
3490
+ res = Object.fromEntries(_to_consumable_array2(mediaGroups).map(function(mediaKey) {
3491
+ return [
3492
+ mediaKey,
3493
+ mediaKeyMatch2(mediaKey, layout)
3494
+ ];
3495
+ }));
3496
+ } finally {
3497
+ disableMediaTouch = !1;
3498
+ }
3499
+ return res;
3500
+ }
3452
3501
  var getMediaImportanceIfMoreImportant = function(mediaKey, key, importancesUsed, isSizeMedia) {
3453
- var conf = (0, import_config.getConfig)(), importance = isSizeMedia && !conf.settings.mediaPropOrder ? getMediaKeyImportance(mediaKey) : defaultMediaImportance;
3502
+ var importance = isSizeMedia && !(0, import_config.getSetting)("mediaPropOrder") ? getMediaKeyImportance(mediaKey) : defaultMediaImportance;
3454
3503
  return !importancesUsed[key] || importance > importancesUsed[key] ? importance : null;
3455
3504
  };
3456
3505
  function camelToHyphen(str) {
@@ -4005,7 +4054,7 @@ var require_createShallowSetState_native = __commonJS({
4005
4054
  }
4006
4055
  function mergeIfNotShallowEqual(prev, next, isDisabled, debug) {
4007
4056
  if (isDisabled || !prev || !next || isEqualShallow(prev, next)) return prev || next;
4008
- if (process.env.NODE_ENV === "development" && debug && (console.warn("setStateShallow CHANGE", {
4057
+ if (process.env.NODE_ENV === "development" && debug && (console.info("setStateShallow CHANGE", {
4009
4058
  prev,
4010
4059
  next
4011
4060
  }), debug === "break")) debugger;
@@ -4197,7 +4246,7 @@ var require_useTheme_native = __commonJS({
4197
4246
  }
4198
4247
  return next;
4199
4248
  }), themeManager = changedThemeState.themeManager, state = changedThemeState.state;
4200
- 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), `).
4249
+ 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), `).
4201
4250
 
4202
4251
  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`)));
4203
4252
  var themeProxied = (0, import_react4.useMemo)(function() {
@@ -4239,7 +4288,7 @@ If this is intended and you are using Tamagui without any themes, you can disabl
4239
4288
  if (subkey === "val") track(keyString);
4240
4289
  else if (subkey === "get") return function(platform2) {
4241
4290
  var outVal = (0, import_createVariable.getVariable)(val);
4242
- if (platform2 !== "web" && import_constants4.isIos && !deopt && config.settings.fastSchemeChange && !someParentIsInversed(themeManager) && scheme) {
4291
+ if (platform2 !== "web" && import_constants4.isIos && !deopt && (0, import_config.getSetting)("fastSchemeChange") && !someParentIsInversed(themeManager) && scheme) {
4243
4292
  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]);
4244
4293
  if (oppositeVal) {
4245
4294
  var dynamicVal = {
@@ -4280,7 +4329,16 @@ If this is intended and you are using Tamagui without any themes, you can disabl
4280
4329
  var id = _idToUID[t.id] = {};
4281
4330
  _uidToManager.set(id, t);
4282
4331
  }
4283
- }, useChangeThemeEffect = function(props) {
4332
+ }, ogLog = console.error, preventWarnSetState = process.env.NODE_ENV === "production" ? ogLog : (
4333
+ // temporary fix for logs, they are harmless in that i've tried to rewrite this
4334
+ // a few times using the "right" ways, but they are always slower. maybe skill issue
4335
+ function(a) {
4336
+ for (var _len = arguments.length, args = new Array(_len > 1 ? _len - 1 : 0), _key = 1; _key < _len; _key++) args[_key - 1] = arguments[_key];
4337
+ if (!(typeof a == "string" && a.includes("Cannot update a component"))) return ogLog.apply(void 0, [
4338
+ a
4339
+ ].concat(_to_consumable_array2(args)));
4340
+ }
4341
+ ), useChangeThemeEffect = function(props) {
4284
4342
  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() {
4285
4343
  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();
4286
4344
  if (!(!manager || !forceShouldChange && forceUpdate === !1)) {
@@ -4303,7 +4361,7 @@ If this is intended and you are using Tamagui without any themes, you can disabl
4303
4361
  }
4304
4362
  var isNewTheme2 = !!(themeManager2 !== parentManager || props.inverse);
4305
4363
  isNewTheme2 && registerThemeManager(themeManager2);
4306
- var isWebSSR = import_constants4.isWeb ? !(0, import_config.getConfig)().disableSSR : !1, mounted2 = isWebSSR ? isRoot || (prev == null ? void 0 : prev.mounted) : !0;
4364
+ var isWebSSR = import_constants4.isWeb ? !(0, import_config.getSetting)("disableSSR") : !1, mounted2 = isWebSSR ? isRoot || (prev == null ? void 0 : prev.mounted) : !0;
4307
4365
  state2 || (isNewTheme2 ? state2 = themeManager2.state : (state2 = parentManager.state, themeManager2 = parentManager));
4308
4366
  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 = {
4309
4367
  themeManager: themeManager2,
@@ -4347,9 +4405,9 @@ If this is intended and you are using Tamagui without any themes, you can disabl
4347
4405
  }
4348
4406
  (isNewTheme || getShouldUpdateTheme(themeManager)) && (activeThemeManagers.add(themeManager), setThemeState(createState));
4349
4407
  var selfListenerDispose = themeManager.onChangeTheme(function(_a, _b, forced) {
4350
- forced && setThemeState(function(prev) {
4408
+ forced && (console.error = preventWarnSetState, setThemeState(function(prev) {
4351
4409
  return createState(prev, !0);
4352
- });
4410
+ }), console.error = ogLog);
4353
4411
  }), disposeChangeListener = parentManager == null ? void 0 : parentManager.onChangeTheme(function(name, manager, forced) {
4354
4412
  var force = forced || (shouldUpdate == null ? void 0 : shouldUpdate()) || props.deopt || props["disable-child-theme"], shouldTryUpdate = force ?? !!(keys != null && keys.length || isNewTheme);
4355
4413
  process.env.NODE_ENV === "development" && props.debug === "verbose" && console.info(" \u{1F538} onChange", themeManager.id, {
@@ -4359,9 +4417,9 @@ If this is intended and you are using Tamagui without any themes, you can disabl
4359
4417
  name,
4360
4418
  manager,
4361
4419
  keys
4362
- }), shouldTryUpdate && setThemeState(function(prev) {
4420
+ }), shouldTryUpdate && (console.error = preventWarnSetState, setThemeState(function(prev) {
4363
4421
  return createState(prev, force);
4364
- });
4422
+ }), console.error = ogLog);
4365
4423
  }, themeManager.id);
4366
4424
  return function() {
4367
4425
  selfListenerDispose(), disposeChangeListener == null || disposeChangeListener(), isNewTheme && activeThemeManagers.delete(themeManager);
@@ -5384,7 +5442,7 @@ var require_createMediaStyle_native = __commonJS({
5384
5442
  if (isTheme || isGroup) {
5385
5443
  var groupInfo = (0, import_getGroupPropParts.getGroupPropParts)(mediaKeyIn), mediaName = groupInfo == null ? void 0 : groupInfo.name;
5386
5444
  groupMediaKey = groupInfo == null ? void 0 : groupInfo.media, isGroup && (containerName = mediaName);
5387
- 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", ""));
5445
+ 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", ""));
5388
5446
  styleRule = styleInner.replace(selector, nextSelector);
5389
5447
  } else styleRule = "".concat(precedenceImportancePrefix).concat(styleInner);
5390
5448
  }
@@ -6309,6 +6367,7 @@ var require_log_native = __commonJS({
6309
6367
  }
6310
6368
  });
6311
6369
  module2.exports = __toCommonJS2(log_exports);
6370
+ var import_useMedia = require_useMedia_native();
6312
6371
  function _array_like_to_array2(arr, len) {
6313
6372
  (len == null || len > arr.length) && (len = arr.length);
6314
6373
  for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
@@ -6336,10 +6395,15 @@ var require_log_native = __commonJS({
6336
6395
  }
6337
6396
  function log() {
6338
6397
  for (var _len = arguments.length, args = new Array(_len), _key = 0; _key < _len; _key++) args[_key] = arguments[_key];
6339
- var _console;
6340
6398
  if (process.env.NODE_ENV !== "production") {
6341
- if (0) var _console1;
6342
- return (_console = console).log.apply(_console, _to_consumable_array2(args));
6399
+ (0, import_useMedia._dmt)(!0);
6400
+ try {
6401
+ var _console;
6402
+ if (0) var _console1;
6403
+ return (_console = console).log.apply(_console, _to_consumable_array2(args));
6404
+ } finally {
6405
+ (0, import_useMedia._dmt)(!1);
6406
+ }
6343
6407
  }
6344
6408
  }
6345
6409
  }
@@ -7403,16 +7467,17 @@ var require_propMapper_native = __commonJS({
7403
7467
  }
7404
7468
  var propMapper = function(key, value, styleStateIn, subPropsIn) {
7405
7469
  if (lastFontFamilyToken = null, !(!import_constants4.isAndroid && key === "elevationAndroid")) {
7470
+ var conf = styleStateIn.conf, styleProps = styleStateIn.styleProps, fontFamily = styleStateIn.fontFamily, staticConfig = styleStateIn.staticConfig;
7406
7471
  if (value === "unset") {
7407
- var _styleStateIn_conf_unset, unsetVal = (_styleStateIn_conf_unset = styleStateIn.conf.unset) === null || _styleStateIn_conf_unset === void 0 ? void 0 : _styleStateIn_conf_unset[key];
7472
+ var _conf_unset, unsetVal = (_conf_unset = conf.unset) === null || _conf_unset === void 0 ? void 0 : _conf_unset[key];
7408
7473
  if (unsetVal != null) value = unsetVal;
7409
7474
  else return;
7410
7475
  }
7411
- var subProps = styleStateIn.styleProps.fallbackProps || subPropsIn, styleState = subProps ? new Proxy(styleStateIn, {
7476
+ var subProps = styleProps.fallbackProps || subPropsIn, styleState = subProps ? new Proxy(styleStateIn, {
7412
7477
  get: function(_, k) {
7413
7478
  return k === "curProps" ? subProps : Reflect.get(_, k);
7414
7479
  }
7415
- }) : styleStateIn, conf = styleState.conf, styleProps = styleState.styleProps, fontFamily = styleState.fontFamily, staticConfig = styleState.staticConfig, variants = staticConfig.variants;
7480
+ }) : styleStateIn, variants = staticConfig.variants;
7416
7481
  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) {
7417
7482
  styleState.curProps[key] = value;
7418
7483
  var variantValue = resolveVariants(key, value, styleProps, styleState, "");
@@ -7835,7 +7900,7 @@ var require_getSplitStyles_native = __commonJS({
7835
7900
  if (n === "Arguments" || /^(?:Ui|I)nt(?:8|16|32)(?:Clamped)?Array$/.test(n)) return _array_like_to_array2(o, minLen);
7836
7901
  }
7837
7902
  }
7838
- var conf, PROP_SPLIT = "-";
7903
+ var consoleGroupCollapsed = import_constants4.isWeb ? console.groupCollapsed : console.info, conf, PROP_SPLIT = "-";
7839
7904
  function isValidStyleKey(key, staticConfig) {
7840
7905
  var _staticConfig_accept, validStyleProps = staticConfig.validStyles || (staticConfig.isText || staticConfig.isInput ? import_helpers.stylePropsText : import_helpers.validStyles);
7841
7906
  return validStyleProps[key] || ((_staticConfig_accept = staticConfig.accept) === null || _staticConfig_accept === void 0 ? void 0 : _staticConfig_accept[key]);
@@ -7865,7 +7930,7 @@ var require_getSplitStyles_native = __commonJS({
7865
7930
  debug,
7866
7931
  skipThemeTokenResolution
7867
7932
  };
7868
- process.env.NODE_ENV === "development" && debug && debug !== "profile" && import_constants4.isClient && (console.groupCollapsed("getSplitStyles (collapsed)"), (0, import_log.log)({
7933
+ process.env.NODE_ENV === "development" && debug && debug !== "profile" && import_constants4.isClient && (consoleGroupCollapsed("getSplitStyles (collapsed)"), (0, import_log.log)({
7869
7934
  props,
7870
7935
  staticConfig,
7871
7936
  shouldDoClasses,
@@ -7914,7 +7979,7 @@ var require_getSplitStyles_native = __commonJS({
7914
7979
  if (!(isStyleProp && (asChild === "except-style" || asChild === "except-style-web"))) {
7915
7980
  var shouldPassProp = !isStyleProp || // is in parent variants
7916
7981
  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;
7917
- 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)({
7982
+ 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)({
7918
7983
  isVariant,
7919
7984
  valInit,
7920
7985
  shouldPassProp
@@ -7941,7 +8006,7 @@ var require_getSplitStyles_native = __commonJS({
7941
8006
  next && (styleState.fontFamily = next);
7942
8007
  }
7943
8008
  if (process.env.NODE_ENV === "development" && debug === "verbose") {
7944
- console.groupCollapsed(" \u{1F4A0} expanded", keyInit, valInit);
8009
+ consoleGroupCollapsed(" \u{1F4A0} expanded", keyInit, valInit);
7945
8010
  try {
7946
8011
  !import_constants4.isServer && import_isDevTools.isDevTools && ((0, import_log.log)({
7947
8012
  expanded,
@@ -7951,7 +8016,6 @@ var require_getSplitStyles_native = __commonJS({
7951
8016
  variant: variants == null ? void 0 : variants[keyInit],
7952
8017
  shouldPassProp,
7953
8018
  isHOCShouldPassThrough,
7954
- theme,
7955
8019
  usedKeys: _object_spread9({}, usedKeys),
7956
8020
  curProps: _object_spread9({}, styleState.curProps)
7957
8021
  }), (0, import_log.log)("expanded", expanded, `
@@ -7974,7 +8038,7 @@ current`, _object_spread9({}, styleState.style)));
7974
8038
  }
7975
8039
  var shouldPassThrough1 = styleProps.noExpand && isPseudo || isHOC && (isMediaOrPseudo1 || (parentStaticConfig == null || (_parentStaticConfig_variants = parentStaticConfig.variants) === null || _parentStaticConfig_variants === void 0 ? void 0 : _parentStaticConfig_variants[keyInit]));
7976
8040
  if (shouldPassThrough1) {
7977
- passDownProp(viewProps, key, val, isMediaOrPseudo1), process.env.NODE_ENV === "development" && debug === "verbose" && (console.groupCollapsed(" - passing down prop ".concat(key)), (0, import_log.log)({
8041
+ passDownProp(viewProps, key, val, isMediaOrPseudo1), process.env.NODE_ENV === "development" && debug === "verbose" && (consoleGroupCollapsed(" - passing down prop ".concat(key)), (0, import_log.log)({
7978
8042
  val,
7979
8043
  after: _object_spread9({}, viewProps[key])
7980
8044
  }), console.groupEnd());
@@ -7993,7 +8057,7 @@ current`, _object_spread9({}, styleState.style)));
7993
8057
  }
7994
8058
  if (shouldDoClasses && !isExit) {
7995
8059
  var pseudoStyles = (0, import_getStylesAtomic.getStyleAtomic)(pseudoStyleObject, descriptor);
7996
- process.env.NODE_ENV === "development" && debug === "verbose" && (console.groupCollapsed("pseudo (classes)", key), (0, import_log.log)({
8060
+ process.env.NODE_ENV === "development" && debug === "verbose" && (consoleGroupCollapsed("pseudo (classes)", key), (0, import_log.log)({
7997
8061
  pseudoStyleObject,
7998
8062
  pseudoStyles
7999
8063
  }), console.groupEnd());
@@ -8015,7 +8079,7 @@ current`, _object_spread9({}, styleState.style)));
8015
8079
  }
8016
8080
  if (!shouldDoClasses || isExit || isEnter) {
8017
8081
  var descriptorKey = descriptor.stateKey || descriptor.name, isDisabled = componentState[descriptorKey] === !1;
8018
- isExit && (isDisabled = !styleProps.isExiting), isEnter && componentState.unmounted === !1 && (isDisabled = !0), process.env.NODE_ENV === "development" && debug === "verbose" && (console.groupCollapsed("pseudo", key, {
8082
+ isExit && (isDisabled = !styleProps.isExiting), isEnter && componentState.unmounted === !1 && (isDisabled = !0), process.env.NODE_ENV === "development" && debug === "verbose" && (consoleGroupCollapsed("pseudo", key, {
8019
8083
  isDisabled
8020
8084
  }), (0, import_log.log)({
8021
8085
  pseudoStyleObject,
@@ -8111,22 +8175,21 @@ current`, _object_spread9({}, styleState.style)));
8111
8175
  } else if (isGroupMedia) {
8112
8176
  var _componentState_group, groupInfo = (0, import_getGroupPropParts.getGroupPropParts)(mediaKeyShort), groupName = groupInfo.name, groupContext = context == null ? void 0 : context.groups.state[groupName];
8113
8177
  if (!groupContext) {
8114
- process.env.NODE_ENV === "development" && debug && console.warn("No parent with group prop, skipping styles: ".concat(groupName));
8178
+ process.env.NODE_ENV === "development" && debug && (0, import_log.log)("No parent with group prop, skipping styles: ".concat(groupName));
8115
8179
  continue;
8116
8180
  }
8117
8181
  var groupPseudoKey = groupInfo.pseudo, groupMediaKey = groupInfo.media, componentGroupState = (_componentState_group = componentState.group) === null || _componentState_group === void 0 ? void 0 : _componentState_group[groupName];
8118
8182
  if (groupMediaKey) {
8119
8183
  mediaGroups || (mediaGroups = /* @__PURE__ */ new Set()), mediaGroups.add(groupMediaKey);
8120
8184
  var mediaState1 = componentGroupState == null ? void 0 : componentGroupState.media, isActive = mediaState1 == null ? void 0 : mediaState1[groupMediaKey];
8121
- if (!mediaState1 && groupContext.layout && (isActive = (0, import_useMedia.mediaKeyMatch)(groupMediaKey, groupContext.layout)), !isActive) continue;
8185
+ 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;
8122
8186
  importanceBump = 2;
8123
8187
  }
8124
8188
  if (groupPseudoKey) {
8125
8189
  pseudoGroups || (pseudoGroups = /* @__PURE__ */ new Set()), pseudoGroups.add(groupName);
8126
8190
  var componentGroupPseudoState = (componentGroupState || // fallback to context initially
8127
- context.groups.state[groupName]).pseudo, isActive1 = componentGroupPseudoState == null ? void 0 : componentGroupPseudoState[groupPseudoKey];
8128
- if (!isActive1) continue;
8129
- var priority1 = import_pseudoDescriptors.pseudoPriorities[groupPseudoKey];
8191
+ context.groups.state[groupName]).pseudo, isActive1 = componentGroupPseudoState == null ? void 0 : componentGroupPseudoState[groupPseudoKey], priority1 = import_pseudoDescriptors.pseudoPriorities[groupPseudoKey];
8192
+ 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;
8130
8193
  importanceBump = priority1;
8131
8194
  }
8132
8195
  }
@@ -8136,7 +8199,7 @@ current`, _object_spread9({}, styleState.style)));
8136
8199
  space = valInit.space;
8137
8200
  continue;
8138
8201
  }
8139
- (_styleState1 = styleState).style || (_styleState1.style = {}), mergeMediaByImportance(styleState, mediaKeyShort, subKey, mediaStyle1[subKey], usedKeys, mediaState3[mediaKeyShort], importanceBump), key === "fontFamily" && (styleState.fontFamily = mediaStyle1.fontFamily);
8202
+ (_styleState1 = styleState).style || (_styleState1.style = {}), mergeMediaByImportance(styleState, mediaKeyShort, subKey, mediaStyle1[subKey], usedKeys, mediaState3[mediaKeyShort], importanceBump, debug), key === "fontFamily" && (styleState.fontFamily = mediaStyle1.fontFamily);
8140
8203
  }
8141
8204
  }
8142
8205
  continue;
@@ -8258,7 +8321,7 @@ current`, _object_spread9({}, styleState.style)));
8258
8321
  } else style3 && !styleProps.noMergeStyle && (viewProps.style = style3);
8259
8322
  }
8260
8323
  if (process.env.NODE_ENV === "development" && debug === "verbose" && import_isDevTools.isDevTools) {
8261
- console.groupCollapsed("\u{1F539} getSplitStyles ===>");
8324
+ consoleGroupCollapsed("\u{1F539} getSplitStyles ===>");
8262
8325
  try {
8263
8326
  var logs = _object_spread_props8(_object_spread9({}, result), {
8264
8327
  className,
@@ -8365,9 +8428,15 @@ current`, _object_spread9({}, styleState.style)));
8365
8428
  delete viewProps[key], viewProps[key] = next;
8366
8429
  } else viewProps[key] = val;
8367
8430
  }
8368
- function mergeMediaByImportance(styleState, mediaKey, key, value, importancesUsed, isSizeMedia, importanceBump) {
8431
+ function mergeMediaByImportance(styleState, mediaKey, key, value, importancesUsed, isSizeMedia, importanceBump, debugProp) {
8369
8432
  var importance = (0, import_useMedia.getMediaImportanceIfMoreImportant)(mediaKey, key, importancesUsed, isSizeMedia);
8370
- return importanceBump && (importance = (importance || 0) + importanceBump), importance === null ? !1 : (importancesUsed[key] = importance, mergeStyle(styleState, key, value), !0);
8433
+ 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;
8434
+ if (importancesUsed[key] = importance, key in import_pseudoDescriptors.pseudoDescriptors) {
8435
+ var descriptor = import_pseudoDescriptors.pseudoDescriptors[key], descriptorKey = descriptor.stateKey || descriptor.name, isDisabled = styleState.componentState[descriptorKey] === !1;
8436
+ if (isDisabled) return !1;
8437
+ for (var subKey in value) mergeStyle(styleState, subKey, value[subKey]);
8438
+ } else mergeStyle(styleState, key, value);
8439
+ return !0;
8371
8440
  }
8372
8441
  function normalizeStyle(style) {
8373
8442
  var out = {};
@@ -9567,18 +9636,8 @@ var require_createComponent_native = __commonJS({
9567
9636
  }
9568
9637
  var shouldAvoidClasses = !import_constants4.isWeb;
9569
9638
  if (import_constants4.isWeb) {
9570
- var disableClassName = props.disableClassName, isAnimatedAndHydrated = isAnimated && !supportsCSSVars && didHydrateOnce && !import_constants4.isServer, isDisabledManually = disableClassName && !import_constants4.isServer && didHydrateOnce && state.unmounted === !0;
9571
- (isAnimatedAndHydrated || isDisabledManually) && (shouldAvoidClasses = !0, process.env.NODE_ENV === "development" && props.debug && console.info("\u274C\u26F9\uFE0F no className", {
9572
- isAnimatedAndHydrated,
9573
- isDisabledManually
9574
- }, {
9575
- isAnimated,
9576
- supportsCSSVars,
9577
- didHydrateOnce,
9578
- disableClassName,
9579
- isServer: import_constants4.isServer,
9580
- willBeAnimated
9581
- }));
9639
+ var disableClassName = props.disableClassName, isAnimatedAndHydrated = isAnimated && !supportsCSSVars && didHydrateOnce && !import_constants4.isServer, isClassNameDisabled = !staticConfig.acceptsClassName && (config.disableSSR || didHydrateOnce), isDisabledManually = disableClassName && !import_constants4.isServer && didHydrateOnce && state.unmounted === !0;
9640
+ (isAnimatedAndHydrated || isDisabledManually || isClassNameDisabled) && (shouldAvoidClasses = !0);
9582
9641
  }
9583
9642
  var groupName = props.group;
9584
9643
  if (groupName && !curStateRef.group) {
@@ -9714,7 +9773,7 @@ var require_createComponent_native = __commonJS({
9714
9773
  if ("themeInverse" in props && (themeStateProps.inverse = props.themeInverse), "theme" in props && (themeStateProps.name = props.theme), typeof curStateRef.isListeningToTheme == "boolean" && (themeStateProps.shouldUpdate = function() {
9715
9774
  return stateRef.current.isListeningToTheme;
9716
9775
  }), themeStateProps.deopt = willBeAnimated, process.env.NODE_ENV === "development" && debugProp && debugProp !== "profile") {
9717
- 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)" : "") + ((presenceState == null ? void 0 : presenceState.isPresent) === !1 ? "(EXIT)" : ""), dataIs = propsIn["data-is"] || "", banner = "".concat(internalID, " ").concat(name).concat(dataIs ? " ".concat(dataIs) : "", " ").concat(type);
9776
+ 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);
9718
9777
  if (console.info("%c ".concat(banner, " (hydrated: ").concat(isHydrated, ") (unmounted: ").concat(state.unmounted, ")"), "background: green; color: white;"), import_constants4.isServer) (0, import_log.log)({
9719
9778
  noClassNames,
9720
9779
  isAnimated,
@@ -9724,8 +9783,8 @@ var require_createComponent_native = __commonJS({
9724
9783
  });
9725
9784
  else {
9726
9785
  console.groupEnd();
9727
- 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 : "";
9728
- 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)({
9786
+ var ch = propsIn.children, childLog = typeof ch == "string" ? ch.length > 4 ? ch.slice(0, 4) + "..." : ch : "";
9787
+ 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)({
9729
9788
  state,
9730
9789
  staticConfig,
9731
9790
  elementType,
@@ -9832,7 +9891,7 @@ If you meant to do this, you can disable this warning - either change untilMeasu
9832
9891
  pressIn: !1
9833
9892
  });
9834
9893
  };
9835
- process.env.NODE_ENV === "development" && (0, import_constants4.useIsomorphicLayoutEffect)(function() {
9894
+ process.env.NODE_ENV === "development" && import_constants4.isWeb && (0, import_constants4.useIsomorphicLayoutEffect)(function() {
9836
9895
  debugProp && (console.groupCollapsed("Rendered style >"), console.warn(getComputedStyle(stateRef.current.host)), console.groupEnd());
9837
9896
  }), (0, import_react4.useEffect)(function() {
9838
9897
  if (!disabled) {
@@ -9867,7 +9926,17 @@ If you meant to do this, you can disable this warning - either change untilMeasu
9867
9926
  mediaGroups ? Object.keys(_to_consumable_array2(mediaGroups)).join("") : 0
9868
9927
  ]);
9869
9928
  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_constants4.isWeb && !!(groupName || needsHoverState || onMouseEnter || onMouseLeave), shouldAttach = !disabled && !props.asChild && !!(attachFocus || attachPress || attachHover || runtimePressStyle || runtimeHoverStyle || runtimeFocusStyle), needsPressState = !!(groupName || runtimePressStyle);
9870
- process.env.NODE_ENV === "development" && time && time(_templateObject14());
9929
+ process.env.NODE_ENV === "development" && time && time(_templateObject14()), process.env.NODE_ENV === "development" && debugProp === "verbose" && (0, import_log.log)("\u{1FAA9} events()", {
9930
+ runtimeFocusStyle,
9931
+ runtimePressStyle,
9932
+ runtimeHoverStyle,
9933
+ runtimeFocusVisibleStyle,
9934
+ attachPress,
9935
+ attachFocus,
9936
+ attachHover,
9937
+ shouldAttach,
9938
+ needsHoverState
9939
+ });
9871
9940
  var events = shouldAttach ? _object_spread9(_object_spread_props8(_object_spread9({
9872
9941
  onPressOut: attachPress ? function(e) {
9873
9942
  unPress(), onPressOut == null || onPressOut(e), onMouseUp == null || onMouseUp(e);
@@ -9995,26 +10064,7 @@ If you meant to do this, you can disable this warning - either change untilMeasu
9995
10064
  children: content
9996
10065
  }));
9997
10066
  }
9998
- if (process.env.TAMAGUI_REACT_19) {
9999
- var rulesToInsert = splitStyles.rulesToInsert, keys = Object.keys(splitStyles.rulesToInsert);
10000
- keys.length && (content = /* @__PURE__ */ (0, import_jsx_runtime6.jsxs)(import_jsx_runtime6.Fragment, {
10001
- children: [
10002
- content,
10003
- /* lets see if we can put a single style tag per rule for optimal de-duping */
10004
- keys.map(function(key3) {
10005
- var styleObject = rulesToInsert[key3], identifier = styleObject[import_helpers.StyleObjectIdentifier];
10006
- return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)("style", {
10007
- // @ts-ignore
10008
- href: "t_".concat(identifier),
10009
- // @ts-ignore
10010
- precedence: "default",
10011
- children: styleObject[import_helpers.StyleObjectRules].join(`
10012
- `)
10013
- }, identifier);
10014
- })
10015
- ]
10016
- }));
10017
- }
10067
+ if (process.env.TAMAGUI_REACT_19 && !1) var rulesToInsert, keys;
10018
10068
  if (process.env.NODE_ENV === "development" && debugProp && debugProp !== "profile") {
10019
10069
  var element1 = typeof elementType == "string" ? elementType : "Component", title = "render <".concat(element1, " /> (").concat(internalID, ") with props");
10020
10070
  if (import_constants4.isWeb) {
@@ -10208,14 +10258,6 @@ If you meant to do this, you can disable this warning - either change untilMeasu
10208
10258
  return val && ((typeof val > "u" ? "undefined" : _type_of3(val)) > "u" ? "undefined" : _type_of1(val)) === "object" && "_animation" in val;
10209
10259
  });
10210
10260
  }
10211
- function getMediaState(mediaGroups, layout) {
10212
- return Object.fromEntries(_to_consumable_array2(mediaGroups).map(function(mediaKey) {
10213
- return [
10214
- mediaKey,
10215
- (0, import_useMedia.mediaKeyMatch)(mediaKey, layout)
10216
- ];
10217
- }));
10218
- }
10219
10261
  var fromPx = function(val) {
10220
10262
  return typeof val != "string" ? val : +val.replace("px", "");
10221
10263
  }, isDisabled = function(props) {
@@ -10237,7 +10279,7 @@ If you meant to do this, you can disable this warning - either change untilMeasu
10237
10279
  };
10238
10280
  if (pseudo && pseudoGroups != null && pseudoGroups.has(String(name))) Object.assign(current.pseudo, pseudo), persist();
10239
10281
  else if (layout && mediaGroups) {
10240
- var mediaState3 = getMediaState(mediaGroups, layout), next = (0, import_createShallowSetState.mergeIfNotShallowEqual)(current.media, mediaState3);
10282
+ var mediaState3 = (0, import_useMedia.getMediaState)(mediaGroups, layout), next = (0, import_createShallowSetState.mergeIfNotShallowEqual)(current.media, mediaState3);
10241
10283
  next !== current.media && (Object.assign(current.media, next), persist());
10242
10284
  }
10243
10285
  });
@@ -11105,6 +11147,7 @@ var require_createTamagui_native = __commonJS({
11105
11147
  }
11106
11148
  var createdConfigs = /* @__PURE__ */ new WeakMap();
11107
11149
  function createTamagui2(configIn) {
11150
+ var _configIn_settings;
11108
11151
  if (createdConfigs.has(configIn)) return configIn;
11109
11152
  var tokensParsed = {}, tokens = (0, import_createVariables.createVariables)(configIn.tokens || {});
11110
11153
  if (configIn.tokens) {
@@ -11224,7 +11267,7 @@ var require_createTamagui_native = __commonJS({
11224
11267
  return getCSS(_object_spread_props8(_object_spread9({}, opts), {
11225
11268
  sinceLastCall: !0
11226
11269
  }));
11227
- }, defaultFontName = configIn.defaultFont || // uses font named "body" if present for compat
11270
+ }, _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
11228
11271
  configIn.fonts && ("body" in configIn.fonts ? "body" : "");
11229
11272
  !defaultFontName && configIn.fonts && (defaultFontName = Object.keys(configIn.fonts)[0]), (defaultFontName == null ? void 0 : defaultFontName[0]) === "$" && (defaultFontName = defaultFontName.slice(1));
11230
11273
  var defaultFont = "$".concat(defaultFontName), config = _object_spread_props8(_object_spread9({
@@ -11235,7 +11278,7 @@ var require_createTamagui_native = __commonJS({
11235
11278
  media: {}
11236
11279
  }, configIn), {
11237
11280
  unset: _object_spread9({
11238
- fontFamily: configIn.defaultFont ? defaultFont : void 0
11281
+ fontFamily: defaultFontName ? defaultFont : void 0
11239
11282
  }, configIn.unset),
11240
11283
  settings: _object_spread9({
11241
11284
  webContainerType: "inline-size"
@@ -11261,7 +11304,7 @@ var require_createTamagui_native = __commonJS({
11261
11304
  fontSizeTokens: fontSizeTokens || /* @__PURE__ */ new Set(),
11262
11305
  specificTokens
11263
11306
  });
11264
- 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) {
11307
+ 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) {
11265
11308
  return cb(config);
11266
11309
  }), import_config.configListeners.clear()), process.env.NODE_ENV === "development") {
11267
11310
  var _process_env_DEBUG;
@@ -12819,10 +12862,10 @@ var require_ThemeProvider_native = __commonJS({
12819
12862
  }
12820
12863
  });
12821
12864
  module2.exports = __toCommonJS2(ThemeProvider_exports);
12822
- var import_jsx_runtime6 = require("react/jsx-runtime"), import_constants4 = require_index_native6(), import_react4 = require("react"), import_constants22 = require_constants_native2(), import_Theme = require_Theme_native(), ThemeProvider = function(props) {
12865
+ var import_jsx_runtime6 = require("react/jsx-runtime"), import_constants4 = require_index_native6(), import_react4 = require("react"), import_constants22 = require_constants_native2(), import_Theme = require_Theme_native(), import_config = require_config_native(), ThemeProvider = function(props) {
12823
12866
  return import_constants4.isClient && (0, import_react4.useLayoutEffect)(function() {
12824
12867
  if (!props.disableRootThemeClass) {
12825
- var cn = "".concat(import_constants22.THEME_CLASSNAME_PREFIX).concat(props.defaultTheme), target = props.themeClassNameOnRoot ? document.documentElement : document.body;
12868
+ var cn = "".concat(import_constants22.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;
12826
12869
  return target.classList.add(cn), function() {
12827
12870
  target.classList.remove(cn);
12828
12871
  };
@@ -12971,7 +13014,7 @@ var require_TamaguiProvider_native = __commonJS({
12971
13014
  }
12972
13015
  });
12973
13016
  module2.exports = __toCommonJS2(TamaguiProvider_exports);
12974
- var import_jsx_runtime6 = require("react/jsx-runtime"), import_constants4 = require_index_native6(), import_react4 = require("react"), import_ComponentContext = require_ComponentContext_native(), import_useDidHydrateOnce = require_useDidHydrateOnce_native(), import_useMedia = require_useMedia_native(), import_ThemeProvider = require_ThemeProvider_native();
13017
+ var import_jsx_runtime6 = require("react/jsx-runtime"), import_constants4 = require_index_native6(), import_react4 = 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();
12975
13018
  function _array_like_to_array2(arr, len) {
12976
13019
  (len == null || len > arr.length) && (len = arr.length);
12977
13020
  for (var i = 0, arr2 = new Array(len); i < len; i++) arr2[i] = arr[i];
@@ -13028,8 +13071,8 @@ var require_TamaguiProvider_native = __commonJS({
13028
13071
  children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_ComponentContext.ComponentContext.Provider, {
13029
13072
  animationDriver: config == null ? void 0 : config.animations,
13030
13073
  children: /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_ThemeProvider.ThemeProvider, {
13031
- themeClassNameOnRoot: themeClassNameOnRoot ?? (config == null ? void 0 : config.themeClassNameOnRoot),
13032
- disableRootThemeClass: disableRootThemeClass ?? (config == null ? void 0 : config.disableRootThemeClass),
13074
+ themeClassNameOnRoot: themeClassNameOnRoot ?? (0, import_config.getSetting)("themeClassNameOnRoot"),
13075
+ disableRootThemeClass: disableRootThemeClass ?? (0, import_config.getSetting)("disableRootThemeClass"),
13033
13076
  defaultTheme: defaultTheme ?? (config ? Object.keys(config.themes)[0] : ""),
13034
13077
  reset,
13035
13078
  className,
@@ -22159,7 +22202,10 @@ var require_Dialog_native = __commonJS({
22159
22202
  var context = useDialogContext("DialogSheetController", props.__scopeDialog), showSheet = useShowDialogSheet(context), breakpointActive = useSheetBreakpointActive(context), getShowSheet = (0, import_core12.useGet)(showSheet);
22160
22203
  return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_sheet.SheetController, {
22161
22204
  onOpenChange: function(val) {
22162
- getShowSheet() && props.onOpenChange(val);
22205
+ if (getShowSheet()) {
22206
+ var _props_onOpenChange;
22207
+ (_props_onOpenChange = props.onOpenChange) === null || _props_onOpenChange === void 0 || _props_onOpenChange.call(props, val);
22208
+ }
22163
22209
  },
22164
22210
  open: context.open,
22165
22211
  hidden: breakpointActive === !1,
@@ -31649,7 +31695,10 @@ var require_Popover_native = __commonJS({
31649
31695
  ]), context = usePopoverContext(__scopePopover), showSheet = useShowPopoverSheet(context), breakpointActive = context.breakpointActive, getShowSheet = (0, import_core12.useGet)(showSheet);
31650
31696
  return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_sheet.SheetController, {
31651
31697
  onOpenChange: function(val) {
31652
- getShowSheet() && props.onOpenChange(val);
31698
+ if (getShowSheet()) {
31699
+ var _props_onOpenChange;
31700
+ (_props_onOpenChange = props.onOpenChange) === null || _props_onOpenChange === void 0 || _props_onOpenChange.call(props, val);
31701
+ }
31653
31702
  },
31654
31703
  open: context.open,
31655
31704
  hidden: breakpointActive === !1,