tamagui 1.129.17 → 1.129.19

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
@@ -289,8 +289,9 @@ var require_PresenceContext_native = __commonJS({
289
289
  });
290
290
  module2.exports = __toCommonJS2(PresenceContext_exports);
291
291
  var import_jsx_runtime6 = require("react/jsx-runtime"), React4 = __toESM2(require("react")), PresenceContext2 = /* @__PURE__ */ React4.createContext(null), ResetPresence2 = function(props) {
292
+ var parent = React4.useContext(PresenceContext2);
292
293
  return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(PresenceContext2.Provider, {
293
- value: null,
294
+ value: props.disable ? parent : null,
294
295
  children: props.children
295
296
  });
296
297
  };
@@ -6544,7 +6545,8 @@ var require_getSplitStyles_native = __commonJS({
6544
6545
  ...styleState.usedKeys
6545
6546
  },
6546
6547
  parentStaticConfig
6547
- })), shouldPassThrough && (passDownProp(viewProps, keyInit, valInit, isMediaOrPseudo), !isVariant) || !noSkip && keyInit in import_skipProps.skipProps) return "continue";
6548
+ })), shouldPassThrough && (passDownProp(viewProps, keyInit, valInit, isMediaOrPseudo), process.env.NODE_ENV === "development" && debug === "verbose" && console.groupEnd(), !isVariant)) return "continue";
6549
+ if (!noSkip && keyInit in import_skipProps.skipProps) return process.env.NODE_ENV === "development" && debug === "verbose" && console.groupEnd(), "continue";
6548
6550
  (isText || isInput) && valInit && (keyInit === "fontFamily" || keyInit === shorthands.fontFamily) && valInit in conf.fontsParsed && (styleState.fontFamily = valInit);
6549
6551
  var disablePropMap = isMediaOrPseudo || !isStyleLikeKey;
6550
6552
  if ((0, import_propMapper.propMapper)(keyInit, valInit, styleState, disablePropMap, function(key4, val2) {
@@ -8628,16 +8630,22 @@ var require_createComponent_native = __commonJS({
8628
8630
  curDefaultProps && (props = (0, import_mergeProps.mergeProps)(curDefaultProps, propsIn));
8629
8631
  var componentName2 = props.componentName || staticConfig.componentName;
8630
8632
  process.env.NODE_ENV === "development" && import_constants4.isClient && import_react3.default.useEffect(function() {
8631
- var overlay = null, debugVisualizerHandler = function() {
8632
- var show = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1, node = stateRef.current.host;
8633
- if (node) if (show) {
8634
- overlay = document.createElement("span"), overlay.style.inset = "0px", overlay.style.zIndex = "1000000", overlay.style.position = "absolute", overlay.style.borderColor = "red", overlay.style.borderWidth = "1px", overlay.style.borderStyle = "dotted";
8633
+ var node, overlay = null, remove = function() {
8634
+ if (overlay) try {
8635
+ var _overlay_parentNode;
8636
+ (_overlay_parentNode = overlay.parentNode) === null || _overlay_parentNode === void 0 || _overlay_parentNode.removeChild(overlay), overlay = null;
8637
+ } catch {
8638
+ }
8639
+ }, debugVisualizerHandler = function() {
8640
+ var show = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : !1;
8641
+ if (node = stateRef.current.host, !!node) if (show) {
8642
+ overlay || (overlay = document.createElement("span"), overlay.style.inset = "0px", overlay.style.zIndex = "1000000", overlay.style.position = "absolute", overlay.style.borderColor = "red", overlay.style.borderWidth = "1px", overlay.style.borderStyle = "dotted");
8635
8643
  var dataAt = node.getAttribute("data-at") || "", dataIn = node.getAttribute("data-in") || "", tooltip = document.createElement("span");
8636
- tooltip.style.position = "absolute", tooltip.style.top = "0px", tooltip.style.left = "0px", tooltip.style.padding = "3px", tooltip.style.background = "rgba(0,0,0,0.75)", tooltip.style.color = "rgba(255,255,255,1)", tooltip.style.fontSize = "12px", tooltip.style.lineHeight = "12px", tooltip.style.fontFamily = "monospace", tooltip.style.webkitFontSmoothing = "none", tooltip.innerText = `${componentName2 || ""} ${dataAt} ${dataIn}`.trim(), overlay.appendChild(tooltip), node.appendChild(overlay);
8637
- } else overlay && node.removeChild(overlay);
8644
+ tooltip.style.position = "absolute", tooltip.style.top = "0px", tooltip.style.left = "0px", tooltip.style.padding = "3px", tooltip.style.background = "rgba(0,0,0,0.75)", tooltip.style.color = "rgba(255,255,255,1)", tooltip.style.fontSize = "12px", tooltip.style.lineHeight = "12px", tooltip.style.fontFamily = "monospace", tooltip.innerText = `${componentName2 || ""} ${dataAt} ${dataIn}`.trim(), overlay.appendChild(tooltip), node.appendChild(overlay);
8645
+ } else remove();
8638
8646
  };
8639
8647
  return debugKeyListeners || (debugKeyListeners = /* @__PURE__ */ new Set()), debugKeyListeners.add(debugVisualizerHandler), function() {
8640
- debugKeyListeners == null || debugKeyListeners.delete(debugVisualizerHandler);
8648
+ remove(), debugKeyListeners == null || debugKeyListeners.delete(debugVisualizerHandler);
8641
8649
  };
8642
8650
  }, [
8643
8651
  componentName2
@@ -8748,8 +8756,7 @@ var require_createComponent_native = __commonJS({
8748
8756
  isExiting,
8749
8757
  isAnimated,
8750
8758
  willBeAnimated,
8751
- styledContextProps,
8752
- noMergeStyle: isAnimated && (animationDriver == null ? void 0 : animationDriver.needsWebStyles)
8759
+ styledContextProps
8753
8760
  }, themeName = (themeState == null ? void 0 : themeState.name) || "";
8754
8761
  process.env.NODE_ENV === "development" && time2 && time2`split-styles-prepare`;
8755
8762
  var splitStyles = (0, import_getSplitStyles.useSplitStyles)(props, staticConfig, theme, themeName, state, styleProps, null, componentContext, allGroupContexts, elementType, startedUnhydrated, debugProp), groupContext = groupName && (allGroupContexts == null ? void 0 : allGroupContexts[groupName]) || null;
@@ -8849,7 +8856,7 @@ var require_createComponent_native = __commonJS({
8849
8856
  staticConfig,
8850
8857
  stateRef
8851
8858
  });
8852
- isHydrated && animations && (animationStyles = animations.style, viewProps.style = animationStyles, animations.className && (viewProps.className = `${state.unmounted === "should-enter" ? "t_unmounted " : ""}${viewProps.className || ""} ${animations.className}`), animations.ref && (animatedRef = animations.ref)), process.env.NODE_ENV === "development" && time2 && time2`animations`;
8859
+ animations && (animations.ref && (animatedRef = animations.ref), isHydrated && animations && (animationStyles = animations.style, viewProps.style = animationStyles, animations.className && (viewProps.className = `${state.unmounted === "should-enter" ? "t_unmounted " : ""}${viewProps.className || ""} ${animations.className}`))), process.env.NODE_ENV === "development" && time2 && time2`animations`;
8853
8860
  }
8854
8861
  process.env.NODE_ENV === "development" && props.untilMeasured && !props.group && console.warn(`You set the untilMeasured prop without setting group. This doesn't work, be sure to set untilMeasured on the parent that sets group, not the children that use the $group- prop.
8855
8862
 
@@ -9030,8 +9037,11 @@ If you meant to do this, you can disable this warning - either change untilMeasu
9030
9037
  process.env.NODE_ENV === "development" && time2 && time2`spaced-as-child`;
9031
9038
  var useChildrenResult;
9032
9039
  import_setupHooks.hooks.useChildren && (useChildrenResult = import_setupHooks.hooks.useChildren(elementType, content, viewProps)), process.env.NODE_ENV === "development" && time2 && time2`use-children`, useChildrenResult ? content = useChildrenResult : content = /* @__PURE__ */ import_react3.default.createElement(elementType, viewProps, content);
9033
- var ResetPresence2 = config == null || (_config_animations = config.animations) === null || _config_animations === void 0 ? void 0 : _config_animations.ResetPresence;
9034
- if (ResetPresence2 && willBeAnimated && (hasEnterStyle || presenceState) && content && typeof content != "string" && (content = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ResetPresence2, {
9040
+ var ResetPresence2 = config == null || (_config_animations = config.animations) === null || _config_animations === void 0 ? void 0 : _config_animations.ResetPresence, needsReset = !!(!isHOC && ResetPresence2 && willBeAnimated && (hasEnterStyle || presenceState)), hasEverReset = stateRef.current.hasEverResetPresence;
9041
+ needsReset && !hasEverReset && (stateRef.current.hasEverResetPresence = !0);
9042
+ var renderReset = needsReset || hasEverReset;
9043
+ if (renderReset && ResetPresence2 && (content = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(ResetPresence2, {
9044
+ disabled: !needsReset,
9035
9045
  children: content
9036
9046
  })), process.env.NODE_ENV === "development" && time2 && time2`create-element`, "focusWithinStyle" in propsIn && (content = /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_ComponentContext.ComponentContext.Provider, {
9037
9047
  ...componentContext,