@sanity/ui 3.5.1 → 3.5.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.
@@ -4,7 +4,7 @@ var __create = Object.create, __defProp = Object.defineProperty, __getOwnPropDes
4
4
  enumerable: !(desc = __getOwnPropDesc(from, key)) || desc.enumerable
5
5
  });
6
6
  return to;
7
- }, __toESM = (mod, isNodeMode, target) => (target = mod == null ? {} : __create(__getProtoOf(mod)), __copyProps(isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", {
7
+ }, __toESM = (mod, isNodeMode, target) => (target = mod == null ? {} : __create(__getProtoOf(mod)), __copyProps(isNodeMode || !mod || !mod.__esModule || !__hasOwnProp.call(mod, "default") ? __defProp(target, "default", {
8
8
  value: mod,
9
9
  enumerable: !0
10
10
  }) : target, mod));
@@ -236,7 +236,7 @@ function responsivePaddingStyle(props) {
236
236
  }
237
237
  const StyledBox = /* @__PURE__ */ styled_components.styled.div.withConfig({
238
238
  displayName: "StyledBox",
239
- componentId: "sc-p4sc7t-0"
239
+ componentId: "sc-00g4gn-0"
240
240
  })(boxStyle, flexItemStyle, responsiveBoxStyle, responsiveGridItemStyle, responsiveMarginStyle, responsivePaddingStyle), Box = (0, react.forwardRef)(function Box(props, ref) {
241
241
  let $ = (0, react_compiler_runtime.c)(115), deprecated_column, deprecated_columnEnd, deprecated_columnStart, deprecated_row, deprecated_rowEnd, deprecated_rowStart, flex, gridColumn, gridColumnEnd, gridColumnStart, gridRow, gridRowEnd, gridRowStart, height, marginBottom, marginLeft, marginRight, marginTop, marginX, marginY, overflow, paddingBottom, paddingLeft, paddingRight, paddingTop, paddingX, paddingY, restProps, sizing, t0, t1, t2, t3;
242
242
  $[0] === props ? (deprecated_column = $[1], deprecated_columnEnd = $[2], deprecated_columnStart = $[3], deprecated_row = $[4], deprecated_rowEnd = $[5], deprecated_rowStart = $[6], flex = $[7], gridColumn = $[8], gridColumnEnd = $[9], gridColumnStart = $[10], gridRow = $[11], gridRowEnd = $[12], gridRowStart = $[13], height = $[14], marginBottom = $[15], marginLeft = $[16], marginRight = $[17], marginTop = $[18], marginX = $[19], marginY = $[20], overflow = $[21], paddingBottom = $[22], paddingLeft = $[23], paddingRight = $[24], paddingTop = $[25], paddingX = $[26], paddingY = $[27], restProps = $[28], sizing = $[29], t0 = $[30], t1 = $[31], t2 = $[32], t3 = $[33]) : ({as: t0, gridColumn, column: deprecated_column, gridColumnStart, columnStart: deprecated_columnStart, gridColumnEnd, columnEnd: deprecated_columnEnd, display: t1, flex, height, margin: t2, marginX, marginY, marginTop, marginRight, marginBottom, marginLeft, overflow, padding: t3, paddingX, paddingY, paddingTop, paddingRight, paddingBottom, paddingLeft, gridRow, row: deprecated_row, gridRowStart, rowStart: deprecated_rowStart, gridRowEnd, rowEnd: deprecated_rowEnd, sizing, ...restProps} = props, $[0] = props, $[1] = deprecated_column, $[2] = deprecated_columnEnd, $[3] = deprecated_columnStart, $[4] = deprecated_row, $[5] = deprecated_rowEnd, $[6] = deprecated_rowStart, $[7] = flex, $[8] = gridColumn, $[9] = gridColumnEnd, $[10] = gridColumnStart, $[11] = gridRow, $[12] = gridRowEnd, $[13] = gridRowStart, $[14] = height, $[15] = marginBottom, $[16] = marginLeft, $[17] = marginRight, $[18] = marginTop, $[19] = marginX, $[20] = marginY, $[21] = overflow, $[22] = paddingBottom, $[23] = paddingLeft, $[24] = paddingRight, $[25] = paddingTop, $[26] = paddingX, $[27] = paddingY, $[28] = restProps, $[29] = sizing, $[30] = t0, $[31] = t1, $[32] = t2, $[33] = t3);
@@ -290,8 +290,8 @@ const StyledBox = /* @__PURE__ */ styled_components.styled.div.withConfig({
290
290
  $[80] === rowEnd ? t28 = $[81] : (t28 = _getArrayProp(rowEnd), $[80] = rowEnd, $[81] = t28);
291
291
  let t29;
292
292
  $[82] === sizing ? t29 = $[83] : (t29 = _getArrayProp(sizing), $[82] = sizing, $[83] = t29);
293
- let t30;
294
- return $[84] !== asProp || $[85] !== props.children || $[86] !== ref || $[87] !== restProps || $[88] !== t10 || $[89] !== t11 || $[90] !== t12 || $[91] !== t13 || $[92] !== t14 || $[93] !== t15 || $[94] !== t16 || $[95] !== t17 || $[96] !== t18 || $[97] !== t19 || $[98] !== t20 || $[99] !== t21 || $[100] !== t22 || $[101] !== t23 || $[102] !== t24 || $[103] !== t25 || $[104] !== t26 || $[105] !== t27 || $[106] !== t28 || $[107] !== t29 || $[108] !== t4 || $[109] !== t5 || $[110] !== t6 || $[111] !== t7 || $[112] !== t8 || $[113] !== t9 ? (t30 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(StyledBox, {
293
+ let t30 = asProp, t31;
294
+ return $[84] !== props.children || $[85] !== ref || $[86] !== restProps || $[87] !== t10 || $[88] !== t11 || $[89] !== t12 || $[90] !== t13 || $[91] !== t14 || $[92] !== t15 || $[93] !== t16 || $[94] !== t17 || $[95] !== t18 || $[96] !== t19 || $[97] !== t20 || $[98] !== t21 || $[99] !== t22 || $[100] !== t23 || $[101] !== t24 || $[102] !== t25 || $[103] !== t26 || $[104] !== t27 || $[105] !== t28 || $[106] !== t29 || $[107] !== t30 || $[108] !== t4 || $[109] !== t5 || $[110] !== t6 || $[111] !== t7 || $[112] !== t8 || $[113] !== t9 ? (t31 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(StyledBox, {
295
295
  "data-as": t4,
296
296
  "data-ui": "Box",
297
297
  ...restProps,
@@ -320,10 +320,10 @@ const StyledBox = /* @__PURE__ */ styled_components.styled.div.withConfig({
320
320
  $rowStart: t27,
321
321
  $rowEnd: t28,
322
322
  $sizing: t29,
323
- as: asProp,
323
+ as: t30,
324
324
  ref,
325
325
  children: props.children
326
- }), $[84] = asProp, $[85] = props.children, $[86] = ref, $[87] = restProps, $[88] = t10, $[89] = t11, $[90] = t12, $[91] = t13, $[92] = t14, $[93] = t15, $[94] = t16, $[95] = t17, $[96] = t18, $[97] = t19, $[98] = t20, $[99] = t21, $[100] = t22, $[101] = t23, $[102] = t24, $[103] = t25, $[104] = t26, $[105] = t27, $[106] = t28, $[107] = t29, $[108] = t4, $[109] = t5, $[110] = t6, $[111] = t7, $[112] = t8, $[113] = t9, $[114] = t30) : t30 = $[114], t30;
326
+ }), $[84] = props.children, $[85] = ref, $[86] = restProps, $[87] = t10, $[88] = t11, $[89] = t12, $[90] = t13, $[91] = t14, $[92] = t15, $[93] = t16, $[94] = t17, $[95] = t18, $[96] = t19, $[97] = t20, $[98] = t21, $[99] = t22, $[100] = t23, $[101] = t24, $[102] = t25, $[103] = t26, $[104] = t27, $[105] = t28, $[106] = t29, $[107] = t30, $[108] = t4, $[109] = t5, $[110] = t6, $[111] = t7, $[112] = t8, $[113] = t9, $[114] = t31) : t31 = $[114], t31;
327
327
  });
328
328
  function responsiveRadiusStyle(props) {
329
329
  let { media, radius } = require_getScopedTheme.i(props.theme);
@@ -924,7 +924,7 @@ function cardColorStyle(props) {
924
924
  }
925
925
  const StyledCard = /* @__PURE__ */ (0, styled_components.styled)(Box).withConfig({
926
926
  displayName: "StyledCard",
927
- componentId: "sc-2ikw89-0"
927
+ componentId: "sc-63y21e-0"
928
928
  })(responsiveBorderStyle, responsiveRadiusStyle, responsiveShadowStyle, cardStyle), Card = (0, react.forwardRef)(function Card(props, ref) {
929
929
  let $ = (0, react_compiler_runtime.c)(56), asProp, border, borderBottom, borderLeft, borderRight, borderTop, muted, pressed, restProps, scheme, selected, shadow, t0, t1, t2, t3;
930
930
  $[0] === props ? (asProp = $[1], border = $[2], borderBottom = $[3], borderLeft = $[4], borderRight = $[5], borderTop = $[6], muted = $[7], pressed = $[8], restProps = $[9], scheme = $[10], selected = $[11], shadow = $[12], t0 = $[13], t1 = $[14], t2 = $[15], t3 = $[16]) : ({__unstable_checkered: t0, __unstable_focusRing: t1, as: asProp, border, borderTop, borderRight, borderBottom, borderLeft, muted, pressed, radius: t2, scheme, selected, shadow, tone: t3, ...restProps} = props, $[0] = props, $[1] = asProp, $[2] = border, $[3] = borderBottom, $[4] = borderLeft, $[5] = borderRight, $[6] = borderTop, $[7] = muted, $[8] = pressed, $[9] = restProps, $[10] = scheme, $[11] = selected, $[12] = shadow, $[13] = t0, $[14] = t1, $[15] = t2, $[16] = t3);
@@ -938,12 +938,12 @@ const StyledCard = /* @__PURE__ */ (0, styled_components.styled)(Box).withConfig
938
938
  $[23] === borderBottom ? t9 = $[24] : (t9 = _getArrayProp(borderBottom), $[23] = borderBottom, $[24] = t9);
939
939
  let t10;
940
940
  $[25] === borderLeft ? t10 = $[26] : (t10 = _getArrayProp(borderLeft), $[25] = borderLeft, $[26] = t10);
941
- let t11;
942
- $[27] === radius ? t11 = $[28] : (t11 = _getArrayProp(radius), $[27] = radius, $[28] = t11);
943
- let t12;
944
- $[29] === shadow ? t12 = $[30] : (t12 = _getArrayProp(shadow), $[29] = shadow, $[30] = t12);
945
- let t13 = checkered ? "" : void 0, t14 = pressed ? "" : void 0, t15 = selected ? "" : void 0, t16;
946
- $[31] !== as || $[32] !== checkered || $[33] !== focusRing || $[34] !== muted || $[35] !== ref || $[36] !== restProps || $[37] !== rootTheme.scheme || $[38] !== selected || $[39] !== t10 || $[40] !== t11 || $[41] !== t12 || $[42] !== t13 || $[43] !== t14 || $[44] !== t15 || $[45] !== t4 || $[46] !== t6 || $[47] !== t7 || $[48] !== t8 || $[49] !== t9 || $[50] !== tone ? (t16 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(StyledCard, {
941
+ let t11 = muted ?? !1, t12;
942
+ $[27] === radius ? t12 = $[28] : (t12 = _getArrayProp(radius), $[27] = radius, $[28] = t12);
943
+ let t13;
944
+ $[29] === shadow ? t13 = $[30] : (t13 = _getArrayProp(shadow), $[29] = shadow, $[30] = t13);
945
+ let t14 = checkered ? "" : void 0, t15 = pressed ? "" : void 0, t16 = selected ? "" : void 0, t17;
946
+ $[31] !== as || $[32] !== checkered || $[33] !== focusRing || $[34] !== ref || $[35] !== restProps || $[36] !== rootTheme.scheme || $[37] !== selected || $[38] !== t10 || $[39] !== t11 || $[40] !== t12 || $[41] !== t13 || $[42] !== t14 || $[43] !== t15 || $[44] !== t16 || $[45] !== t4 || $[46] !== t6 || $[47] !== t7 || $[48] !== t8 || $[49] !== t9 || $[50] !== tone ? (t17 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(StyledCard, {
947
947
  "data-as": t4,
948
948
  "data-scheme": t5,
949
949
  "data-ui": "Card",
@@ -956,23 +956,23 @@ const StyledCard = /* @__PURE__ */ (0, styled_components.styled)(Box).withConfig
956
956
  $borderLeft: t10,
957
957
  $checkered: checkered,
958
958
  $focusRing: focusRing,
959
- $muted: muted,
960
- $radius: t11,
961
- $shadow: t12,
959
+ $muted: t11,
960
+ $radius: t12,
961
+ $shadow: t13,
962
962
  $tone: tone,
963
- "data-checkered": t13,
964
- "data-pressed": t14,
965
- "data-selected": t15,
963
+ "data-checkered": t14,
964
+ "data-pressed": t15,
965
+ "data-selected": t16,
966
966
  forwardedAs: as,
967
967
  ref,
968
968
  selected
969
- }), $[31] = as, $[32] = checkered, $[33] = focusRing, $[34] = muted, $[35] = ref, $[36] = restProps, $[37] = rootTheme.scheme, $[38] = selected, $[39] = t10, $[40] = t11, $[41] = t12, $[42] = t13, $[43] = t14, $[44] = t15, $[45] = t4, $[46] = t6, $[47] = t7, $[48] = t8, $[49] = t9, $[50] = tone, $[51] = t16) : t16 = $[51];
970
- let t17;
971
- return $[52] !== scheme || $[53] !== t16 || $[54] !== tone ? (t17 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ThemeColorProvider, {
969
+ }), $[31] = as, $[32] = checkered, $[33] = focusRing, $[34] = ref, $[35] = restProps, $[36] = rootTheme.scheme, $[37] = selected, $[38] = t10, $[39] = t11, $[40] = t12, $[41] = t13, $[42] = t14, $[43] = t15, $[44] = t16, $[45] = t4, $[46] = t6, $[47] = t7, $[48] = t8, $[49] = t9, $[50] = tone, $[51] = t17) : t17 = $[51];
970
+ let t18;
971
+ return $[52] !== scheme || $[53] !== t17 || $[54] !== tone ? (t18 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(ThemeColorProvider, {
972
972
  scheme,
973
973
  tone,
974
- children: t16
975
- }), $[52] = scheme, $[53] = t16, $[54] = tone, $[55] = t17) : t17 = $[55], t17;
974
+ children: t17
975
+ }), $[52] = scheme, $[53] = t17, $[54] = tone, $[55] = t18) : t18 = $[55], t18;
976
976
  }), _ResizeObserver = typeof document < "u" && typeof window < "u" && window.ResizeObserver ? window.ResizeObserver : _juggle_resize_observer.ResizeObserver, _elementSizeObserver = _createElementSizeObserver();
977
977
  function _createElementRectValueListener() {
978
978
  return { subscribe(element, subscriber) {
@@ -1460,10 +1460,10 @@ const StyledArrow = /* @__PURE__ */ styled_components.styled.div.withConfig({
1460
1460
  }), $[24] = ref, $[25] = restProps, $[26] = t7, $[27] = w, $[28] = t8) : t8 = $[28], t8;
1461
1461
  }), MotionCard$1 = (0, styled_components.styled)(motion_react.motion.create(Card)).withConfig({
1462
1462
  displayName: "MotionCard",
1463
- componentId: "sc-tq6s8o-0"
1463
+ componentId: "sc-uyh6zp-0"
1464
1464
  })`&:not([hidden]){display:flex;}flex-direction:column;width:max-content;min-width:min-content;will-change:transform;`, MotionFlex = (0, styled_components.styled)(motion_react.motion.create(Flex)).withConfig({
1465
1465
  displayName: "MotionFlex",
1466
- componentId: "sc-tq6s8o-1"
1466
+ componentId: "sc-uyh6zp-1"
1467
1467
  })`will-change:opacity;`, PopoverCard = (0, react.forwardRef)(function PopoverCard(props, ref) {
1468
1468
  let $ = (0, react_compiler_runtime.c)(66), animate, arrow, arrowRef, arrowX, arrowY, children, marginsProp, originX, originY, overflow, padding, placement, radius, restProps, scheme, shadow, strategy, style, tone, width, xProp, yProp;
1469
1469
  $[0] === props ? (animate = $[1], arrow = $[2], arrowRef = $[3], arrowX = $[4], arrowY = $[5], children = $[6], marginsProp = $[7], originX = $[8], originY = $[9], overflow = $[10], padding = $[11], placement = $[12], radius = $[13], restProps = $[14], scheme = $[15], shadow = $[16], strategy = $[17], style = $[18], tone = $[19], width = $[20], xProp = $[21], yProp = $[22]) : ({__unstable_margins: marginsProp, animate, arrow, arrowRef, arrowX, arrowY, children, padding, placement, originX, originY, overflow, radius, scheme, shadow, strategy, style, tone, width, x: xProp, y: yProp, ...restProps} = props, $[0] = props, $[1] = animate, $[2] = arrow, $[3] = arrowRef, $[4] = arrowX, $[5] = arrowY, $[6] = children, $[7] = marginsProp, $[8] = originX, $[9] = originY, $[10] = overflow, $[11] = padding, $[12] = placement, $[13] = radius, $[14] = restProps, $[15] = scheme, $[16] = shadow, $[17] = strategy, $[18] = style, $[19] = tone, $[20] = width, $[21] = xProp, $[22] = yProp);
@@ -1486,41 +1486,41 @@ const StyledArrow = /* @__PURE__ */ styled_components.styled.div.withConfig({
1486
1486
  right: void 0,
1487
1487
  bottom: void 0
1488
1488
  }, $[33] = t2, $[34] = t3, $[35] = t4) : t4 = $[35];
1489
- let arrowStyle = t4, t5 = restProps, t6;
1490
- $[36] === animate ? t6 = $[37] : (t6 = animate ? ["hidden", "initial"] : void 0, $[36] = animate, $[37] = t6);
1489
+ let arrowStyle = t4, t5;
1490
+ $[36] === animate ? t5 = $[37] : (t5 = animate ? ["hidden", "initial"] : void 0, $[36] = animate, $[37] = t5);
1491
+ let t6;
1492
+ $[38] === animate ? t6 = $[39] : (t6 = animate ? ["visible", "scaleIn"] : void 0, $[38] = animate, $[39] = t6);
1491
1493
  let t7;
1492
- $[38] === animate ? t7 = $[39] : (t7 = animate ? ["visible", "scaleIn"] : void 0, $[38] = animate, $[39] = t7);
1494
+ $[40] === animate ? t7 = $[41] : (t7 = animate ? ["hidden", "scaleOut"] : void 0, $[40] = animate, $[41] = t7);
1493
1495
  let t8;
1494
- $[40] === animate ? t8 = $[41] : (t8 = animate ? ["hidden", "scaleOut"] : void 0, $[40] = animate, $[41] = t8);
1495
- let t9;
1496
- $[42] !== children || $[43] !== padding ? (t9 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Flex, {
1496
+ $[42] !== children || $[43] !== padding ? (t8 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Flex, {
1497
1497
  direction: "column",
1498
1498
  flex: 1,
1499
1499
  padding,
1500
1500
  children
1501
- }), $[42] = children, $[43] = padding, $[44] = t9) : t9 = $[44];
1502
- let t10;
1503
- $[45] !== overflow || $[46] !== t9 ? (t10 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(MotionFlex, {
1501
+ }), $[42] = children, $[43] = padding, $[44] = t8) : t8 = $[44];
1502
+ let t9;
1503
+ $[45] !== overflow || $[46] !== t8 ? (t9 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)(MotionFlex, {
1504
1504
  "data-ui": "Popover__wrapper",
1505
1505
  direction: "column",
1506
1506
  flex: 1,
1507
1507
  overflow,
1508
1508
  variants: POPOVER_MOTION_PROPS.children,
1509
1509
  transition: POPOVER_MOTION_PROPS.transition,
1510
- children: t9
1511
- }), $[45] = overflow, $[46] = t9, $[47] = t10) : t10 = $[47];
1512
- let t11;
1513
- $[48] !== arrow || $[49] !== arrowRef || $[50] !== arrowStyle ? (t11 = arrow && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Arrow, {
1510
+ children: t8
1511
+ }), $[45] = overflow, $[46] = t8, $[47] = t9) : t9 = $[47];
1512
+ let t10;
1513
+ $[48] !== arrow || $[49] !== arrowRef || $[50] !== arrowStyle ? (t10 = arrow && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Arrow, {
1514
1514
  ref: arrowRef,
1515
1515
  style: arrowStyle,
1516
1516
  width: 19,
1517
1517
  height: 8,
1518
1518
  radius: 2
1519
- }), $[48] = arrow, $[49] = arrowRef, $[50] = arrowStyle, $[51] = t11) : t11 = $[51];
1520
- let t12;
1521
- return $[52] !== placement || $[53] !== radius || $[54] !== ref || $[55] !== rootStyle || $[56] !== scheme || $[57] !== shadow || $[58] !== t10 || $[59] !== t11 || $[60] !== t5 || $[61] !== t6 || $[62] !== t7 || $[63] !== t8 || $[64] !== tone ? (t12 = /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(MotionCard$1, {
1519
+ }), $[48] = arrow, $[49] = arrowRef, $[50] = arrowStyle, $[51] = t10) : t10 = $[51];
1520
+ let t11;
1521
+ return $[52] !== placement || $[53] !== radius || $[54] !== ref || $[55] !== restProps || $[56] !== rootStyle || $[57] !== scheme || $[58] !== shadow || $[59] !== t10 || $[60] !== t5 || $[61] !== t6 || $[62] !== t7 || $[63] !== t9 || $[64] !== tone ? (t11 = /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(MotionCard$1, {
1522
1522
  "data-ui": "Popover",
1523
- ...t5,
1523
+ ...restProps,
1524
1524
  "data-placement": placement,
1525
1525
  radius,
1526
1526
  ref,
@@ -1531,11 +1531,11 @@ const StyledArrow = /* @__PURE__ */ styled_components.styled.div.withConfig({
1531
1531
  tone,
1532
1532
  variants: POPOVER_MOTION_PROPS.card,
1533
1533
  transition: POPOVER_MOTION_PROPS.transition,
1534
- initial: t6,
1535
- animate: t7,
1536
- exit: t8,
1537
- children: [t10, t11]
1538
- }), $[52] = placement, $[53] = radius, $[54] = ref, $[55] = rootStyle, $[56] = scheme, $[57] = shadow, $[58] = t10, $[59] = t11, $[60] = t5, $[61] = t6, $[62] = t7, $[63] = t8, $[64] = tone, $[65] = t12) : t12 = $[65], t12;
1534
+ initial: t5,
1535
+ animate: t6,
1536
+ exit: t7,
1537
+ children: [t9, t10]
1538
+ }), $[52] = placement, $[53] = radius, $[54] = ref, $[55] = restProps, $[56] = rootStyle, $[57] = scheme, $[58] = shadow, $[59] = t10, $[60] = t5, $[61] = t6, $[62] = t7, $[63] = t9, $[64] = tone, $[65] = t11) : t11 = $[65], t11;
1539
1539
  }), ViewportOverlay = () => {
1540
1540
  let $ = (0, react_compiler_runtime.c)(2), { zIndex } = useLayer(), t0;
1541
1541
  return $[0] === zIndex ? t0 = $[1] : (t0 = /* @__PURE__ */ (0, react_jsx_runtime.jsx)("div", { style: {
@@ -1695,17 +1695,19 @@ const StyledArrow = /* @__PURE__ */ styled_components.styled.div.withConfig({
1695
1695
  function useMiddleware$1(t0) {
1696
1696
  let $ = (0, react_compiler_runtime.c)(42), { animate, arrowProp, arrowRef, constrainSize, fallbackPlacements, floatingBoundary, margins, matchReferenceWidth, maxWidthRef, placementProp, placementStrategy, preventOverflow, referenceBoundary, referenceWidthRef, rootBoundary, setReferenceWidth, widthRef } = t0, ret;
1697
1697
  if ($[0] !== animate || $[1] !== arrowProp || $[2] !== arrowRef || $[3] !== constrainSize || $[4] !== fallbackPlacements || $[5] !== floatingBoundary || $[6] !== margins || $[7] !== matchReferenceWidth || $[8] !== maxWidthRef || $[9] !== placementProp || $[10] !== placementStrategy || $[11] !== preventOverflow || $[12] !== referenceBoundary || $[13] !== referenceWidthRef || $[14] !== rootBoundary || $[15] !== setReferenceWidth || $[16] !== widthRef) {
1698
- if (ret = [], constrainSize || preventOverflow) if (placementStrategy === "autoPlacement") {
1699
- let t1;
1700
- $[18] !== fallbackPlacements || $[19] !== placementProp ? (t1 = (0, _floating_ui_react_dom.autoPlacement)({ allowedPlacements: [placementProp].concat(fallbackPlacements) }), $[18] = fallbackPlacements, $[19] = placementProp, $[20] = t1) : t1 = $[20], ret.push(t1);
1701
- } else {
1702
- let t1 = floatingBoundary || void 0, t2;
1703
- $[21] !== fallbackPlacements || $[22] !== rootBoundary || $[23] !== t1 ? (t2 = (0, _floating_ui_react_dom.flip)({
1704
- boundary: t1,
1705
- fallbackPlacements,
1706
- padding: 4,
1707
- rootBoundary
1708
- }), $[21] = fallbackPlacements, $[22] = rootBoundary, $[23] = t1, $[24] = t2) : t2 = $[24], ret.push(t2);
1698
+ if (ret = [], constrainSize || preventOverflow) {
1699
+ if (placementStrategy === "autoPlacement") {
1700
+ let t1;
1701
+ $[18] !== fallbackPlacements || $[19] !== placementProp ? (t1 = (0, _floating_ui_react_dom.autoPlacement)({ allowedPlacements: [placementProp].concat(fallbackPlacements) }), $[18] = fallbackPlacements, $[19] = placementProp, $[20] = t1) : t1 = $[20], ret.push(t1);
1702
+ } else {
1703
+ let t1 = floatingBoundary || void 0, t2;
1704
+ $[21] !== fallbackPlacements || $[22] !== rootBoundary || $[23] !== t1 ? (t2 = (0, _floating_ui_react_dom.flip)({
1705
+ boundary: t1,
1706
+ fallbackPlacements,
1707
+ padding: 4,
1708
+ rootBoundary
1709
+ }), $[21] = fallbackPlacements, $[22] = rootBoundary, $[23] = t1, $[24] = t2) : t2 = $[24], ret.push(t2);
1710
+ }
1709
1711
  }
1710
1712
  let t1;
1711
1713
  if ($[25] === Symbol.for("react.memo_cache_sentinel") ? (t1 = (0, _floating_ui_react_dom.offset)({ mainAxis: 4 }), $[25] = t1) : t1 = $[25], ret.push(t1), constrainSize || matchReferenceWidth) {
@@ -2988,7 +2990,7 @@ const DEFAULT_FALLBACK_PLACEMENTS = {
2988
2990
  ]
2989
2991
  }, MotionCard = (0, styled_components.styled)(motion_react.motion.create(Card)).withConfig({
2990
2992
  displayName: "MotionCard",
2991
- componentId: "sc-k6wgsf-0"
2993
+ componentId: "sc-gv6m6q-0"
2992
2994
  })`will-change:transform;`, TooltipCard = (0, react.forwardRef)(function TooltipCard(props, ref) {
2993
2995
  let $ = (0, react_compiler_runtime.c)(48), animate, arrow, arrowRef, arrowX, arrowY, children, originX, originY, padding, placement, radius, restProps, scheme, shadow, style;
2994
2996
  $[0] === props ? (animate = $[1], arrow = $[2], arrowRef = $[3], arrowX = $[4], arrowY = $[5], children = $[6], originX = $[7], originY = $[8], padding = $[9], placement = $[10], radius = $[11], restProps = $[12], scheme = $[13], shadow = $[14], style = $[15]) : ({animate, arrow, arrowRef, arrowX, arrowY, children, originX, originY, padding, placement, radius, scheme, shadow, style, ...restProps} = props, $[0] = props, $[1] = animate, $[2] = arrow, $[3] = arrowRef, $[4] = arrowX, $[5] = arrowY, $[6] = children, $[7] = originX, $[8] = originY, $[9] = padding, $[10] = placement, $[11] = radius, $[12] = restProps, $[13] = scheme, $[14] = shadow, $[15] = style);
@@ -3006,24 +3008,24 @@ const DEFAULT_FALLBACK_PLACEMENTS = {
3006
3008
  right: void 0,
3007
3009
  bottom: void 0
3008
3010
  }, $[21] = t2, $[22] = t3, $[23] = t4) : t4 = $[23];
3009
- let arrowStyle = t4, t5 = restProps, t6;
3010
- $[24] === animate ? t6 = $[25] : (t6 = animate ? ["hidden", "initial"] : void 0, $[24] = animate, $[25] = t6);
3011
+ let arrowStyle = t4, t5;
3012
+ $[24] === animate ? t5 = $[25] : (t5 = animate ? ["hidden", "initial"] : void 0, $[24] = animate, $[25] = t5);
3013
+ let t6;
3014
+ $[26] === animate ? t6 = $[27] : (t6 = animate ? ["visible", "scaleIn"] : void 0, $[26] = animate, $[27] = t6);
3011
3015
  let t7;
3012
- $[26] === animate ? t7 = $[27] : (t7 = animate ? ["visible", "scaleIn"] : void 0, $[26] = animate, $[27] = t7);
3016
+ $[28] === animate ? t7 = $[29] : (t7 = animate ? ["hidden", "scaleOut"] : void 0, $[28] = animate, $[29] = t7);
3013
3017
  let t8;
3014
- $[28] === animate ? t8 = $[29] : (t8 = animate ? ["hidden", "scaleOut"] : void 0, $[28] = animate, $[29] = t8);
3015
- let t9;
3016
- $[30] !== arrow || $[31] !== arrowRef || $[32] !== arrowStyle ? (t9 = arrow && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Arrow, {
3018
+ $[30] !== arrow || $[31] !== arrowRef || $[32] !== arrowStyle ? (t8 = arrow && /* @__PURE__ */ (0, react_jsx_runtime.jsx)(Arrow, {
3017
3019
  ref: arrowRef,
3018
3020
  style: arrowStyle,
3019
3021
  width: 15,
3020
3022
  height: 6,
3021
3023
  radius: 2
3022
- }), $[30] = arrow, $[31] = arrowRef, $[32] = arrowStyle, $[33] = t9) : t9 = $[33];
3023
- let t10;
3024
- return $[34] !== children || $[35] !== padding || $[36] !== placement || $[37] !== radius || $[38] !== ref || $[39] !== rootStyle || $[40] !== scheme || $[41] !== shadow || $[42] !== t5 || $[43] !== t6 || $[44] !== t7 || $[45] !== t8 || $[46] !== t9 ? (t10 = /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(MotionCard, {
3024
+ }), $[30] = arrow, $[31] = arrowRef, $[32] = arrowStyle, $[33] = t8) : t8 = $[33];
3025
+ let t9;
3026
+ return $[34] !== children || $[35] !== padding || $[36] !== placement || $[37] !== radius || $[38] !== ref || $[39] !== restProps || $[40] !== rootStyle || $[41] !== scheme || $[42] !== shadow || $[43] !== t5 || $[44] !== t6 || $[45] !== t7 || $[46] !== t8 ? (t9 = /* @__PURE__ */ (0, react_jsx_runtime.jsxs)(MotionCard, {
3025
3027
  "data-ui": "Tooltip__card",
3026
- ...t5,
3028
+ ...restProps,
3027
3029
  "data-placement": placement,
3028
3030
  padding,
3029
3031
  radius,
@@ -3033,11 +3035,11 @@ const DEFAULT_FALLBACK_PLACEMENTS = {
3033
3035
  style: rootStyle,
3034
3036
  variants: POPOVER_MOTION_PROPS.card,
3035
3037
  transition: POPOVER_MOTION_PROPS.transition,
3036
- initial: t6,
3037
- animate: t7,
3038
- exit: t8,
3039
- children: [children, t9]
3040
- }), $[34] = children, $[35] = padding, $[36] = placement, $[37] = radius, $[38] = ref, $[39] = rootStyle, $[40] = scheme, $[41] = shadow, $[42] = t5, $[43] = t6, $[44] = t7, $[45] = t8, $[46] = t9, $[47] = t10) : t10 = $[47], t10;
3038
+ initial: t5,
3039
+ animate: t6,
3040
+ exit: t7,
3041
+ children: [children, t8]
3042
+ }), $[34] = children, $[35] = padding, $[36] = placement, $[37] = radius, $[38] = ref, $[39] = restProps, $[40] = rootStyle, $[41] = scheme, $[42] = shadow, $[43] = t5, $[44] = t6, $[45] = t7, $[46] = t8, $[47] = t9) : t9 = $[47], t9;
3041
3043
  }), TooltipDelayGroupContext = createGlobalScopedContext("@sanity/ui/context/tooltipDelayGroup", null);
3042
3044
  /**
3043
3045
  * @beta
@@ -3077,11 +3079,12 @@ const StyledTooltip = (0, styled_components.styled)(Layer).withConfig({
3077
3079
  $[31] === delayGroupContext ? t11 = $[32] : (t11 = delayGroupContext || {}, $[31] = delayGroupContext, $[32] = t11);
3078
3080
  let { setIsGroupActive, setOpenTooltipId } = t11, showTooltip = isOpen || delayGroupContext?.openTooltipId === tooltipId, isInsideGroup = delayGroupContext !== null, openDelayProp = typeof delay == "number" ? delay : delay?.open || 0, closeDelayProp = typeof delay == "number" ? delay : delay?.close || 0, openDelay = isInsideGroup ? delayGroupContext.openDelay : openDelayProp, closeDelay = isInsideGroup ? delayGroupContext.closeDelay : closeDelayProp, t12;
3079
3081
  $[33] !== closeDelay || $[34] !== isInsideGroup || $[35] !== openDelay || $[36] !== setIsGroupActive || $[37] !== setIsOpen || $[38] !== setOpenTooltipId || $[39] !== tooltipId ? (t12 = (open, immediate) => {
3080
- if (isInsideGroup) if (open) {
3081
- let groupedOpenDelay = immediate ? 0 : openDelay;
3082
- setIsGroupActive?.(open, groupedOpenDelay), setOpenTooltipId?.(tooltipId, groupedOpenDelay);
3083
- } else setIsGroupActive?.(open, closeDelay > 200 ? closeDelay : 200), setOpenTooltipId?.(null, immediate ? 0 : closeDelay);
3084
- else setIsOpen(open, immediate ? 0 : open ? openDelay : closeDelay);
3082
+ if (isInsideGroup) {
3083
+ if (open) {
3084
+ let groupedOpenDelay = immediate ? 0 : openDelay;
3085
+ setIsGroupActive?.(open, groupedOpenDelay), setOpenTooltipId?.(tooltipId, groupedOpenDelay);
3086
+ } else setIsGroupActive?.(open, closeDelay > 200 ? closeDelay : 200), setOpenTooltipId?.(null, immediate ? 0 : closeDelay);
3087
+ } else setIsOpen(open, immediate ? 0 : open ? openDelay : closeDelay);
3085
3088
  }, $[33] = closeDelay, $[34] = isInsideGroup, $[35] = openDelay, $[36] = setIsGroupActive, $[37] = setIsOpen, $[38] = setOpenTooltipId, $[39] = tooltipId, $[40] = t12) : t12 = $[40];
3086
3089
  let handleIsOpenChange = t12, t13;
3087
3090
  $[41] !== childProp?.props || $[42] !== handleIsOpenChange ? (t13 = (e) => {