tamagui 1.110.1 → 1.110.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
@@ -5917,6 +5917,7 @@ var require_normalize_color = __commonJS({
5917
5917
  switch (name) {
5918
5918
  case "transparent":
5919
5919
  return 0;
5920
+ // http://www.w3.org/TR/css3-color/#svg-color
5920
5921
  case "aliceblue":
5921
5922
  return 4042850303;
5922
5923
  case "antiquewhite":
@@ -8390,7 +8391,10 @@ var require_getSplitStyles_native = __commonJS({
8390
8391
  // this fixes issues where style prop got merged with wrong priority
8391
8392
  !isHOC && (isValidStyleKey(key, staticConfig) || import_constants4.isAndroid && key === "elevation")
8392
8393
  ) return mergeStyle(styleState, key, val), "continue";
8393
- isVariant || (viewProps[key] = val);
8394
+ if (!isVariant) {
8395
+ if (styleProps.styledContextProps && key in styleProps.styledContextProps) return "continue";
8396
+ viewProps[key] = val;
8397
+ }
8394
8398
  }, keyInit = keyOg, valInit = props[keyInit];
8395
8399
  if (accept) {
8396
8400
  var accepted = accept[keyInit];
@@ -9444,7 +9448,7 @@ var require_Slot_native = __commonJS({
9444
9448
  for (i = 0; i < sourceKeys.length; i++) key = sourceKeys[i], !(excluded.indexOf(key) >= 0) && (target[key] = source[key]);
9445
9449
  return target;
9446
9450
  }
9447
- var is19 = import_react4.version.startsWith("19."), Slot = /* @__PURE__ */ (0, import_react4.forwardRef)(function(props, forwardedRef) {
9451
+ var is19 = import_react4.version.startsWith("19."), Slot = /* @__PURE__ */ (0, import_react4.memo)(/* @__PURE__ */ (0, import_react4.forwardRef)(function(props, forwardedRef) {
9448
9452
  var children = props.children, slotProps = _object_without_properties5(props, [
9449
9453
  "children"
9450
9454
  ]);
@@ -9455,9 +9459,7 @@ var require_Slot_native = __commonJS({
9455
9459
  }));
9456
9460
  }
9457
9461
  return import_react4.Children.count(children) > 1 ? import_react4.Children.only(null) : null;
9458
- });
9459
- Slot.displayName = "Slot";
9460
- var Slottable = function(param) {
9462
+ })), Slottable = function(param) {
9461
9463
  var children = param.children;
9462
9464
  return /* @__PURE__ */ (0, import_jsx_runtime6.jsx)(import_jsx_runtime6.Fragment, {
9463
9465
  children
@@ -10018,7 +10020,10 @@ var require_createComponent_native = __commonJS({
10018
10020
  var inverseShorthands = (0, import_config.getConfig)().inverseShorthands;
10019
10021
  for (var key in context.props) {
10020
10022
  var _propsIn_key, _ref, _ref1, propVal = (_ref1 = (_ref = (_propsIn_key = propsIn[key]) !== null && _propsIn_key !== void 0 ? _propsIn_key : propsIn[inverseShorthands[key]]) !== null && _ref !== void 0 ? _ref : defaultProps == null ? void 0 : defaultProps[key]) !== null && _ref1 !== void 0 ? _ref1 : defaultProps == null ? void 0 : defaultProps[inverseShorthands[key]];
10021
- propVal === void 0 ? contextValue && (styledContextProps || (styledContextProps = {}), styledContextProps[key] = contextValue[key]) : (overriddenContextProps || (overriddenContextProps = {}), overriddenContextProps[key] = propVal);
10023
+ if (propVal === void 0) {
10024
+ var val = contextValue == null ? void 0 : contextValue[key];
10025
+ val !== void 0 && (styledContextProps || (styledContextProps = {}), styledContextProps[key] = val);
10026
+ } else overriddenContextProps || (overriddenContextProps = {}), overriddenContextProps[key] = propVal;
10022
10027
  }
10023
10028
  }
10024
10029
  var curDefaultProps = styledContextProps ? _object_spread9({}, defaultProps, styledContextProps) : defaultProps, props = propsIn;
@@ -10102,7 +10107,8 @@ var require_createComponent_native = __commonJS({
10102
10107
  resolveValues,
10103
10108
  isExiting,
10104
10109
  isAnimated,
10105
- willBeAnimated
10110
+ willBeAnimated,
10111
+ styledContextProps
10106
10112
  }, splitStyles = (0, import_getSplitStyles.useSplitStyles)(props, staticConfig, theme, (themeState == null || (_themeState_state = themeState.state) === null || _themeState_state === void 0 ? void 0 : _themeState_state.name) || "", state, styleProps, null, componentContext, elementType, debugProp);
10107
10113
  if (props.group && props.untilMeasured === "hide" && !curStateRef.hasMeasured) {
10108
10114
  var _splitStyles;
@@ -17246,23 +17252,15 @@ var require_index_native22 = __commonJS({
17246
17252
  }
17247
17253
  var getFontSized2 = function() {
17248
17254
  var sizeTokenIn = arguments.length > 0 && arguments[0] !== void 0 ? arguments[0] : "$true", _ref = arguments.length > 1 ? arguments[1] : void 0, font = _ref.font, fontFamily = _ref.fontFamily, props = _ref.props, _font_lineHeight, _font_weight, _font_letterSpacing, _font_transform, _font_style, _font_color;
17249
- if (font) {
17250
- var sizeToken = sizeTokenIn === "$true" ? getDefaultSizeToken(font) : sizeTokenIn, fontSize = font.size[sizeToken], lineHeight = (_font_lineHeight = font.lineHeight) === null || _font_lineHeight === void 0 ? void 0 : _font_lineHeight[sizeToken], fontWeight = (_font_weight = font.weight) === null || _font_weight === void 0 ? void 0 : _font_weight[sizeToken], letterSpacing = (_font_letterSpacing = font.letterSpacing) === null || _font_letterSpacing === void 0 ? void 0 : _font_letterSpacing[sizeToken], textTransform = (_font_transform = font.transform) === null || _font_transform === void 0 ? void 0 : _font_transform[sizeToken], _props_fontStyle, fontStyle = (_props_fontStyle = props.fontStyle) !== null && _props_fontStyle !== void 0 ? _props_fontStyle : (_font_style = font.style) === null || _font_style === void 0 ? void 0 : _font_style[sizeToken], _props_color, color = (_props_color = props.color) !== null && _props_color !== void 0 ? _props_color : (_font_color = font.color) === null || _font_color === void 0 ? void 0 : _font_color[sizeToken], style = {
17251
- color,
17252
- fontStyle,
17253
- textTransform,
17254
- fontFamily,
17255
- fontWeight,
17256
- letterSpacing,
17257
- fontSize,
17258
- lineHeight
17259
- };
17260
- return process.env.NODE_ENV === "development" && props.debug && props.debug === "verbose" && (console.groupCollapsed(" \u{1F539} getFontSized", sizeTokenIn, sizeToken), console.info({
17261
- style,
17262
- props,
17263
- font
17264
- }), console.groupEnd()), style;
17265
- }
17255
+ if (!font) return {
17256
+ fontSize: sizeTokenIn
17257
+ };
17258
+ var sizeToken = sizeTokenIn === "$true" ? getDefaultSizeToken(font) : sizeTokenIn, style = {}, fontSize = font.size[sizeToken], lineHeight = (_font_lineHeight = font.lineHeight) === null || _font_lineHeight === void 0 ? void 0 : _font_lineHeight[sizeToken], fontWeight = (_font_weight = font.weight) === null || _font_weight === void 0 ? void 0 : _font_weight[sizeToken], letterSpacing = (_font_letterSpacing = font.letterSpacing) === null || _font_letterSpacing === void 0 ? void 0 : _font_letterSpacing[sizeToken], textTransform = (_font_transform = font.transform) === null || _font_transform === void 0 ? void 0 : _font_transform[sizeToken], _props_fontStyle, fontStyle = (_props_fontStyle = props.fontStyle) !== null && _props_fontStyle !== void 0 ? _props_fontStyle : (_font_style = font.style) === null || _font_style === void 0 ? void 0 : _font_style[sizeToken], _props_color, color = (_props_color = props.color) !== null && _props_color !== void 0 ? _props_color : (_font_color = font.color) === null || _font_color === void 0 ? void 0 : _font_color[sizeToken];
17259
+ return fontStyle && (style.fontStyle = fontStyle), textTransform && (style.textTransform = textTransform), fontFamily && (style.fontFamily = fontFamily), fontWeight && (style.fontWeight = fontWeight), letterSpacing && (style.letterSpacing = letterSpacing), fontSize && (style.fontSize = fontSize), lineHeight && (style.lineHeight = lineHeight), color && (style.color = color), process.env.NODE_ENV === "development" && props.debug && props.debug === "verbose" && (console.groupCollapsed(" \u{1F539} getFontSized", sizeTokenIn, sizeToken), console.info({
17260
+ style,
17261
+ props,
17262
+ font
17263
+ }), console.groupEnd()), style;
17266
17264
  }, cache = /* @__PURE__ */ new WeakMap();
17267
17265
  function getDefaultSizeToken(font) {
17268
17266
  if (((typeof font > "u" ? "undefined" : _type_of3(font)) > "u" ? "undefined" : _type_of1(font)) === "object" && cache.has(font)) return cache.get(font);
@@ -17341,8 +17339,8 @@ var require_SizableText_native = __commonJS({
17341
17339
  }
17342
17340
  });
17343
17341
  SizableText2.staticConfig.variants.fontFamily = {
17344
- "...": function(_, extras) {
17345
- var size4 = extras.props.size || "$true";
17342
+ "...": function(_val, extras) {
17343
+ var sizeProp = extras.props.size, fontSizeProp = extras.props.fontSize, size4 = sizeProp === "$true" && fontSizeProp ? fontSizeProp : extras.props.size || "$true";
17346
17344
  return (0, import_get_font_sized2.getFontSized)(size4, extras);
17347
17345
  }
17348
17346
  };