@sanity/ui 3.0.0-static.10 → 3.0.0-static.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/_chunks-cjs/_visual-editing.js +105 -143
- package/dist/_chunks-cjs/_visual-editing.js.map +1 -1
- package/dist/_chunks-cjs/buildCommand.js +1 -1
- package/dist/_chunks-cjs/buildCommand.js.map +1 -1
- package/dist/_chunks-cjs/v3_v2.js +251 -0
- package/dist/_chunks-cjs/v3_v2.js.map +1 -0
- package/dist/_chunks-es/_visual-editing.mjs +106 -144
- package/dist/_chunks-es/_visual-editing.mjs.map +1 -1
- package/dist/_chunks-es/v3_v2.mjs +252 -0
- package/dist/_chunks-es/v3_v2.mjs.map +1 -0
- package/dist/_visual-editing.d.mts +11 -14
- package/dist/_visual-editing.d.ts +11 -14
- package/dist/cli.js +1 -1
- package/dist/css.d.mts +1006 -282
- package/dist/css.d.ts +1006 -282
- package/dist/css.js +743 -852
- package/dist/css.js.map +1 -1
- package/dist/css.mjs +743 -852
- package/dist/css.mjs.map +1 -1
- package/dist/index.d.mts +11 -14
- package/dist/index.d.ts +11 -14
- package/dist/index.js +31 -17
- package/dist/index.js.map +1 -1
- package/dist/index.mjs +33 -19
- package/dist/index.mjs.map +1 -1
- package/dist/sanity-palette.css +9 -1
- package/dist/sanity-theme.css +1 -1
- package/dist/system.css +1023 -1448
- package/dist/theme.d.mts +119 -85
- package/dist/theme.d.ts +119 -85
- package/dist/theme.js +219 -432
- package/dist/theme.js.map +1 -1
- package/dist/theme.mjs +202 -413
- package/dist/theme.mjs.map +1 -1
- package/package.json +2 -2
- package/src/cli/buildCommand.ts +2 -2
- package/src/css/_comp.ts +0 -1
- package/src/css/aspects/flex/flexJustify.style.ts +3 -3
- package/src/css/aspects/grid/types.ts +2 -2
- package/src/css/aspects/index.ts +0 -1
- package/src/css/aspects/textOverflow/textOverflow.ts +2 -2
- package/src/css/compile/compilePalette.ts +41 -8
- package/src/css/compile/compileRule.ts +0 -1
- package/src/css/compile/compileStyle.ts +1 -1
- package/src/css/compile/compileTheme_v3.ts +55 -46
- package/src/css/index.ts +2 -2
- package/src/css/primitives/_input/__workshop__/index.ts +1 -1
- package/src/css/primitives/_selectable/_contants.ts +1 -1
- package/src/css/primitives/badge/badge.style.ts +1 -1
- package/src/css/primitives/box/box.style.ts +1 -1
- package/src/css/primitives/box/box.ts +0 -2
- package/src/css/primitives/box/types.ts +0 -2
- package/src/css/primitives/button/_constants.ts +1 -1
- package/src/css/primitives/button/button.style.ts +13 -32
- package/src/css/primitives/card/_constants.ts +2 -2
- package/src/css/primitives/card/card.style.ts +44 -116
- package/src/css/primitives/card/card.ts +1 -1
- package/src/css/primitives/card/rules.ts +473 -0
- package/src/css/primitives/card/types.ts +1 -0
- package/src/css/primitives/kbd/kbd.style.ts +1 -1
- package/src/css/primitives/popover/popover.ts +0 -4
- package/src/css/primitives/switch/switch.style.ts +83 -8
- package/src/css/primitives/text/text.style.ts +3 -11
- package/src/css/system.style.ts +0 -4
- package/src/css/types.ts +188 -202
- package/src/css/varNames.ts +76 -110
- package/src/css/vars.ts +76 -109
- package/src/theme/defaults/config.ts +2 -2
- package/src/theme/defaults/fonts.ts +4 -4
- package/src/theme/palette/constants.ts +3 -1
- package/src/theme/palette/types.ts +12 -0
- package/src/theme/v3/buildTheme_v3.ts +2 -1
- package/src/theme/v3/color/buildColor_v3.ts +38 -43
- package/src/theme/v3/color/card.ts +38 -43
- package/src/theme/v3/color/color.ts +38 -42
- package/src/theme/v3/defaults.ts +72 -69
- package/src/theme/v3/resolveTokens.ts +38 -43
- package/src/theme/v3/types.ts +3 -0
- package/src/theme/versioning/themeColor_v3_v2.ts +1 -1
- package/src/ui/StyleTags.tsx +1 -1
- package/src/ui/components/autocomplete/__workshop__/async.tsx +1 -0
- package/src/ui/components/autocomplete/__workshop__/index.ts +1 -1
- package/src/ui/components/autocomplete/autocomplete.tsx +11 -2
- package/src/ui/components/dialog/dialog.tsx +4 -3
- package/src/ui/constants.ts +0 -6
- package/src/ui/hooks/useMediaIndex/useMediaIndex.ts +2 -0
- package/src/ui/primitives/box/box.tsx +2 -9
- package/src/ui/primitives/button/button.tsx +11 -12
- package/src/ui/primitives/card/card.tsx +5 -4
- package/src/ui/primitives/code/code.tsx +1 -1
- package/src/ui/primitives/heading/heading.tsx +1 -1
- package/src/ui/primitives/kbd/kbd.tsx +2 -2
- package/src/ui/primitives/popover/popover.tsx +75 -5
- package/src/ui/primitives/popover/popoverCard.tsx +39 -45
- package/src/ui/primitives/select/select.tsx +3 -3
- package/src/ui/primitives/stack/stack.tsx +5 -10
- package/src/ui/primitives/text/text.tsx +1 -1
- package/src/ui/primitives/textInput/textInput.tsx +1 -1
- package/src/ui/primitives/tooltip/tooltip.tsx +3 -2
- package/src/css/aspects/minWidth/index.ts +0 -2
- package/src/css/aspects/minWidth/minWidth.style.ts +0 -13
- package/src/css/aspects/minWidth/minWidth.ts +0 -6
- package/src/css/aspects/minWidth/types.ts +0 -7
- package/src/css/primitives/stack/index.ts +0 -1
- package/src/css/primitives/stack/stack.style.ts +0 -9
- package/src/css/primitives/stack/stack.ts +0 -6
|
@@ -3,7 +3,7 @@ import { c } from "react-compiler-runtime";
|
|
|
3
3
|
import { getScopedTheme, getTheme_v2, createColorTheme as createColorTheme$1, hexToRgb as hexToRgb$1, hslToRgb as hslToRgb$1, multiply as multiply$1, parseColor as parseColor$1, rgbToHex as rgbToHex$1, rgbToHsl as rgbToHsl$1, rgba as rgba$1, screen as screen$1, buildTheme } from "@sanity/ui/theme";
|
|
4
4
|
import { createContext, useContext, useState, useEffect, useDebugValue, useSyncExternalStore, forwardRef, Children, isValidElement, cloneElement, createElement, useRef, useImperativeHandle, lazy, Suspense, memo, useMemo, useCallback, useId, useLayoutEffect } from "react";
|
|
5
5
|
import { ThemeProvider as ThemeProvider$1, useTheme as useTheme$1 } from "styled-components";
|
|
6
|
-
import { composeClassNames, box, label, textOverflow, avatar, avatarArrow, avatarInitials, avatarImage, avatarCounter, avatarStack, text, badge, animatedSpinnerIcon, spinner, buttonLoadingBox, button, card, checkbox, checkboxInput, code, container, heading, kbd, _arrow, _arrowStroke, _arrowShape, srOnly,
|
|
6
|
+
import { composeClassNames, box, label, textOverflow, avatar, avatarArrow, avatarInitials, avatarImage, avatarCounter, avatarStack, text, badge, animatedSpinnerIcon, spinner, buttonLoadingBox, button, _selectable, card, checkbox, checkboxInput, code, container, heading, kbd, _arrow, _arrowStroke, _arrowShape, srOnly, radio, select, _inputElement, selectPresentation, _switch, _switchElement, _switchPresentation, _switchTrack, _switchThumb, textArea, _inputPresentation, textInput, tooltipCard, tooltip, menu, menuDivider } from "@sanity/ui/css";
|
|
7
7
|
import ReactIs, { isValidElementType } from "react-is";
|
|
8
8
|
import { SpinnerIcon, CheckmarkIcon, RemoveIcon, ChevronDownIcon, CloseIcon, ChevronRightIcon } from "@sanity/icons";
|
|
9
9
|
import { detectOverflow, flip, offset, shift, arrow, hide, useFloating, autoUpdate } from "@floating-ui/react-dom";
|
|
@@ -142,10 +142,6 @@ const createColorTheme = createColorTheme$1, hexToRgb = hexToRgb$1, hslToRgb = h
|
|
|
142
142
|
visualDuration: 0.2,
|
|
143
143
|
bounce: 0.25
|
|
144
144
|
}
|
|
145
|
-
}, Z_OFFSETS = {
|
|
146
|
-
dialog: 600,
|
|
147
|
-
popover: 400,
|
|
148
|
-
tooltip: 200
|
|
149
145
|
};
|
|
150
146
|
function _isEnterToClickElement(element) {
|
|
151
147
|
return isHTMLAnchorElement(element) || isHTMLButtonElement(element);
|
|
@@ -369,15 +365,12 @@ function _temp$6() {
|
|
|
369
365
|
return !1;
|
|
370
366
|
}
|
|
371
367
|
const Box = forwardRef(function(props, ref) {
|
|
372
|
-
const $ = c(
|
|
373
|
-
let align,
|
|
368
|
+
const $ = c(112);
|
|
369
|
+
let align, border, borderBottom, borderLeft, borderRight, borderTop, className, column, columnEnd, columnStart, columns, direction, flex, gap, gapX, gapY, height, inset, insetBottom, insetLeft, insetRight, insetTop, justify, marginBottom, marginLeft, marginRight, marginTop, marginX, marginY, maxWidth, muted, overflow, paddingBottom, paddingLeft, paddingRight, paddingTop, paddingX, paddingY, pointerEvents, position, radius, restProps, row, rowEnd, rowStart, rows, t0, t1, t2, t3, t4, width, wrap;
|
|
374
370
|
$[0] !== props ? ({
|
|
375
371
|
align,
|
|
376
372
|
as: t0,
|
|
377
|
-
|
|
378
|
-
autoFlow,
|
|
379
|
-
autoRows,
|
|
380
|
-
border: t1,
|
|
373
|
+
border,
|
|
381
374
|
borderTop,
|
|
382
375
|
borderRight,
|
|
383
376
|
borderBottom,
|
|
@@ -388,7 +381,7 @@ const Box = forwardRef(function(props, ref) {
|
|
|
388
381
|
columnEnd,
|
|
389
382
|
columns,
|
|
390
383
|
direction,
|
|
391
|
-
display:
|
|
384
|
+
display: t1,
|
|
392
385
|
flex,
|
|
393
386
|
gap,
|
|
394
387
|
gapX,
|
|
@@ -400,7 +393,7 @@ const Box = forwardRef(function(props, ref) {
|
|
|
400
393
|
insetRight,
|
|
401
394
|
insetTop,
|
|
402
395
|
justify,
|
|
403
|
-
margin:
|
|
396
|
+
margin: t2,
|
|
404
397
|
marginX,
|
|
405
398
|
marginY,
|
|
406
399
|
marginTop,
|
|
@@ -408,9 +401,8 @@ const Box = forwardRef(function(props, ref) {
|
|
|
408
401
|
marginBottom,
|
|
409
402
|
marginLeft,
|
|
410
403
|
maxWidth,
|
|
411
|
-
minWidth: t4,
|
|
412
404
|
overflow,
|
|
413
|
-
padding:
|
|
405
|
+
padding: t3,
|
|
414
406
|
paddingX,
|
|
415
407
|
paddingY,
|
|
416
408
|
paddingTop,
|
|
@@ -425,18 +417,15 @@ const Box = forwardRef(function(props, ref) {
|
|
|
425
417
|
rows,
|
|
426
418
|
rowStart,
|
|
427
419
|
rowEnd,
|
|
428
|
-
sizing:
|
|
420
|
+
sizing: t4,
|
|
429
421
|
width,
|
|
430
422
|
wrap,
|
|
431
423
|
...restProps
|
|
432
|
-
} = props, $[0] = props, $[1] = align, $[2] =
|
|
433
|
-
const As = t0 === void 0 ? "div" : t0,
|
|
434
|
-
let
|
|
435
|
-
$[
|
|
424
|
+
} = props, $[0] = props, $[1] = align, $[2] = border, $[3] = borderBottom, $[4] = borderLeft, $[5] = borderRight, $[6] = borderTop, $[7] = className, $[8] = column, $[9] = columnEnd, $[10] = columnStart, $[11] = columns, $[12] = direction, $[13] = flex, $[14] = gap, $[15] = gapX, $[16] = gapY, $[17] = height, $[18] = inset, $[19] = insetBottom, $[20] = insetLeft, $[21] = insetRight, $[22] = insetTop, $[23] = justify, $[24] = marginBottom, $[25] = marginLeft, $[26] = marginRight, $[27] = marginTop, $[28] = marginX, $[29] = marginY, $[30] = maxWidth, $[31] = muted, $[32] = overflow, $[33] = paddingBottom, $[34] = paddingLeft, $[35] = paddingRight, $[36] = paddingTop, $[37] = paddingX, $[38] = paddingY, $[39] = pointerEvents, $[40] = position, $[41] = radius, $[42] = restProps, $[43] = row, $[44] = rowEnd, $[45] = rowStart, $[46] = rows, $[47] = t0, $[48] = t1, $[49] = t2, $[50] = t3, $[51] = t4, $[52] = width, $[53] = wrap) : (align = $[1], border = $[2], borderBottom = $[3], borderLeft = $[4], borderRight = $[5], borderTop = $[6], className = $[7], column = $[8], columnEnd = $[9], columnStart = $[10], columns = $[11], direction = $[12], flex = $[13], gap = $[14], gapX = $[15], gapY = $[16], height = $[17], inset = $[18], insetBottom = $[19], insetLeft = $[20], insetRight = $[21], insetTop = $[22], justify = $[23], marginBottom = $[24], marginLeft = $[25], marginRight = $[26], marginTop = $[27], marginX = $[28], marginY = $[29], maxWidth = $[30], muted = $[31], overflow = $[32], paddingBottom = $[33], paddingLeft = $[34], paddingRight = $[35], paddingTop = $[36], paddingX = $[37], paddingY = $[38], pointerEvents = $[39], position = $[40], radius = $[41], restProps = $[42], row = $[43], rowEnd = $[44], rowStart = $[45], rows = $[46], t0 = $[47], t1 = $[48], t2 = $[49], t3 = $[50], t4 = $[51], width = $[52], wrap = $[53]);
|
|
425
|
+
const As = t0 === void 0 ? "div" : t0, display = t1 === void 0 ? "block" : t1, margin = t2 === void 0 ? 0 : t2, padding = t3 === void 0 ? 0 : t3, sizing = t4 === void 0 ? "border" : t4;
|
|
426
|
+
let t5;
|
|
427
|
+
$[54] !== align || $[55] !== border || $[56] !== borderBottom || $[57] !== borderLeft || $[58] !== borderRight || $[59] !== borderTop || $[60] !== className || $[61] !== column || $[62] !== columnEnd || $[63] !== columnStart || $[64] !== columns || $[65] !== direction || $[66] !== display || $[67] !== flex || $[68] !== gap || $[69] !== gapX || $[70] !== gapY || $[71] !== height || $[72] !== inset || $[73] !== insetBottom || $[74] !== insetLeft || $[75] !== insetRight || $[76] !== insetTop || $[77] !== justify || $[78] !== margin || $[79] !== marginBottom || $[80] !== marginLeft || $[81] !== marginRight || $[82] !== marginTop || $[83] !== marginX || $[84] !== marginY || $[85] !== maxWidth || $[86] !== muted || $[87] !== overflow || $[88] !== padding || $[89] !== paddingBottom || $[90] !== paddingLeft || $[91] !== paddingRight || $[92] !== paddingTop || $[93] !== paddingX || $[94] !== paddingY || $[95] !== pointerEvents || $[96] !== position || $[97] !== radius || $[98] !== row || $[99] !== rowEnd || $[100] !== rowStart || $[101] !== rows || $[102] !== sizing || $[103] !== width || $[104] !== wrap ? (t5 = composeClassNames(className, box({
|
|
436
428
|
align,
|
|
437
|
-
autoCols,
|
|
438
|
-
autoFlow,
|
|
439
|
-
autoRows,
|
|
440
429
|
border,
|
|
441
430
|
borderTop,
|
|
442
431
|
borderRight,
|
|
@@ -468,7 +457,6 @@ const Box = forwardRef(function(props, ref) {
|
|
|
468
457
|
marginBottom,
|
|
469
458
|
marginLeft,
|
|
470
459
|
maxWidth,
|
|
471
|
-
minWidth,
|
|
472
460
|
muted,
|
|
473
461
|
padding,
|
|
474
462
|
paddingX,
|
|
@@ -487,9 +475,9 @@ const Box = forwardRef(function(props, ref) {
|
|
|
487
475
|
sizing,
|
|
488
476
|
width,
|
|
489
477
|
wrap
|
|
490
|
-
})), $[
|
|
491
|
-
let
|
|
492
|
-
return $[
|
|
478
|
+
})), $[54] = align, $[55] = border, $[56] = borderBottom, $[57] = borderLeft, $[58] = borderRight, $[59] = borderTop, $[60] = className, $[61] = column, $[62] = columnEnd, $[63] = columnStart, $[64] = columns, $[65] = direction, $[66] = display, $[67] = flex, $[68] = gap, $[69] = gapX, $[70] = gapY, $[71] = height, $[72] = inset, $[73] = insetBottom, $[74] = insetLeft, $[75] = insetRight, $[76] = insetTop, $[77] = justify, $[78] = margin, $[79] = marginBottom, $[80] = marginLeft, $[81] = marginRight, $[82] = marginTop, $[83] = marginX, $[84] = marginY, $[85] = maxWidth, $[86] = muted, $[87] = overflow, $[88] = padding, $[89] = paddingBottom, $[90] = paddingLeft, $[91] = paddingRight, $[92] = paddingTop, $[93] = paddingX, $[94] = paddingY, $[95] = pointerEvents, $[96] = position, $[97] = radius, $[98] = row, $[99] = rowEnd, $[100] = rowStart, $[101] = rows, $[102] = sizing, $[103] = width, $[104] = wrap, $[105] = t5) : t5 = $[105];
|
|
479
|
+
let t6;
|
|
480
|
+
return $[106] !== As || $[107] !== props.children || $[108] !== ref || $[109] !== restProps || $[110] !== t5 ? (t6 = /* @__PURE__ */ jsx(As, { "data-ui": "Box", ...restProps, className: t5, ref, children: props.children }), $[106] = As, $[107] = props.children, $[108] = ref, $[109] = restProps, $[110] = t5, $[111] = t6) : t6 = $[111], t6;
|
|
493
481
|
});
|
|
494
482
|
Box.displayName = "ForwardRef(Box)";
|
|
495
483
|
const Label = forwardRef(function(props, ref) {
|
|
@@ -669,7 +657,7 @@ const Text = forwardRef(function(props, ref) {
|
|
|
669
657
|
weight,
|
|
670
658
|
...restProps
|
|
671
659
|
} = props, $[0] = props, $[1] = align, $[2] = children, $[3] = className, $[4] = flex, $[5] = restProps, $[6] = t0, $[7] = t1, $[8] = t2, $[9] = t3, $[10] = textOverflowProp, $[11] = weight) : (align = $[1], children = $[2], className = $[3], flex = $[4], restProps = $[5], t0 = $[6], t1 = $[7], t2 = $[8], t3 = $[9], textOverflowProp = $[10], weight = $[11]);
|
|
672
|
-
const accent = t0 === void 0 ? !1 : t0, As = t1 === void 0 ? "div" : t1, muted = t2 === void 0 ? !1 : t2, size2 = t3 === void 0 ?
|
|
660
|
+
const accent = t0 === void 0 ? !1 : t0, As = t1 === void 0 ? "div" : t1, muted = t2 === void 0 ? !1 : t2, size2 = t3 === void 0 ? 1 : t3;
|
|
673
661
|
let t4;
|
|
674
662
|
$[12] !== accent || $[13] !== align || $[14] !== className || $[15] !== flex || $[16] !== muted || $[17] !== size2 || $[18] !== weight ? (t4 = composeClassNames(className, text({
|
|
675
663
|
accent,
|
|
@@ -769,7 +757,7 @@ const Button = forwardRef(function(props, ref) {
|
|
|
769
757
|
paddingBottom,
|
|
770
758
|
paddingLeft,
|
|
771
759
|
paddingRight,
|
|
772
|
-
radius =
|
|
760
|
+
radius = 3,
|
|
773
761
|
selected,
|
|
774
762
|
space = props.gap ?? props.space ?? props.padding ?? 3,
|
|
775
763
|
// eslint-disable-line @typescript-eslint/no-unused-vars
|
|
@@ -792,56 +780,31 @@ const Button = forwardRef(function(props, ref) {
|
|
|
792
780
|
tone,
|
|
793
781
|
width
|
|
794
782
|
})), "data-disabled": loading || disabled ? "" : void 0, "data-selected": selected ? "" : void 0, disabled: !!(loading || disabled), href: disabled ? void 0 : href, ref, type, children: [
|
|
795
|
-
!!loading && /* @__PURE__ */ jsx(Box, { align
|
|
796
|
-
(IconComponent || text2 || IconRightComponent) && /* @__PURE__ */ jsxs(
|
|
797
|
-
|
|
798
|
-
|
|
799
|
-
|
|
800
|
-
|
|
801
|
-
|
|
802
|
-
|
|
803
|
-
|
|
804
|
-
|
|
805
|
-
|
|
806
|
-
|
|
807
|
-
|
|
808
|
-
|
|
809
|
-
|
|
810
|
-
|
|
811
|
-
|
|
812
|
-
|
|
813
|
-
|
|
814
|
-
|
|
815
|
-
|
|
816
|
-
|
|
817
|
-
|
|
818
|
-
|
|
819
|
-
|
|
820
|
-
IconRightComponent && /* @__PURE__ */ jsxs(Text, { as: "span", flex: "none", muted: !0, size: fontSize, children: [
|
|
821
|
-
isValidElement(IconRightComponent) && IconRightComponent,
|
|
822
|
-
isValidElementType(IconRightComponent) && /* @__PURE__ */ jsx(IconRightComponent, {})
|
|
823
|
-
] })
|
|
824
|
-
]
|
|
825
|
-
}
|
|
826
|
-
),
|
|
827
|
-
children && /* @__PURE__ */ jsx(
|
|
828
|
-
Box,
|
|
829
|
-
{
|
|
830
|
-
as: "span",
|
|
831
|
-
flex: 1,
|
|
832
|
-
gap,
|
|
833
|
-
gapX,
|
|
834
|
-
gapY,
|
|
835
|
-
padding,
|
|
836
|
-
paddingX,
|
|
837
|
-
paddingY,
|
|
838
|
-
paddingTop,
|
|
839
|
-
paddingBottom,
|
|
840
|
-
paddingLeft,
|
|
841
|
-
paddingRight,
|
|
842
|
-
children
|
|
843
|
-
}
|
|
844
|
-
)
|
|
783
|
+
!!loading && /* @__PURE__ */ jsx(Box, { align, as: "span", className: buttonLoadingBox(), display: "flex", flex: 1, justify, width: "fill", children: /* @__PURE__ */ jsx(Spinner, { size: fontSize }) }),
|
|
784
|
+
(IconComponent || text2 || IconRightComponent) && /* @__PURE__ */ jsxs(Box, { as: "span", direction, display: "flex", flex: 1, gap, gapX, gapY, justify, padding, paddingX, paddingY, paddingTop, paddingBottom, paddingLeft, paddingRight, width: "fill", wrap, children: [
|
|
785
|
+
IconComponent && /* @__PURE__ */ jsxs(Text, { as: "span", flex: "none", muted: !0, size: fontSize, children: [
|
|
786
|
+
isValidElement(IconComponent) && IconComponent,
|
|
787
|
+
isValidElementType(IconComponent) && /* @__PURE__ */ jsx(IconComponent, {})
|
|
788
|
+
] }),
|
|
789
|
+
text2 && /* @__PURE__ */ jsx(
|
|
790
|
+
Text,
|
|
791
|
+
{
|
|
792
|
+
align: textAlign,
|
|
793
|
+
as: "span",
|
|
794
|
+
flex: "none",
|
|
795
|
+
muted,
|
|
796
|
+
size: fontSize,
|
|
797
|
+
textOverflow: textOverflow2,
|
|
798
|
+
weight: textWeight,
|
|
799
|
+
children: text2
|
|
800
|
+
}
|
|
801
|
+
),
|
|
802
|
+
IconRightComponent && /* @__PURE__ */ jsxs(Text, { as: "span", flex: "none", muted: !0, size: fontSize, children: [
|
|
803
|
+
isValidElement(IconRightComponent) && IconRightComponent,
|
|
804
|
+
isValidElementType(IconRightComponent) && /* @__PURE__ */ jsx(IconRightComponent, {})
|
|
805
|
+
] })
|
|
806
|
+
] }),
|
|
807
|
+
children && /* @__PURE__ */ jsx(Box, { as: "span", direction, display: "flex", flex: 1, gap, gapX, gapY, padding, paddingX, paddingY, paddingTop, paddingBottom, paddingLeft, paddingRight, width: "fill", wrap, children })
|
|
845
808
|
] });
|
|
846
809
|
});
|
|
847
810
|
Button.displayName = "ForwardRef(Button)";
|
|
@@ -849,8 +812,8 @@ function useCard() {
|
|
|
849
812
|
return useContext(CardContext);
|
|
850
813
|
}
|
|
851
814
|
const Card = forwardRef(function(props, ref) {
|
|
852
|
-
const $ = c(
|
|
853
|
-
let asProp, className, pressed, restProps, schemeProp, selected, shadow, style, t0, t1, t2, t3;
|
|
815
|
+
const $ = c(48);
|
|
816
|
+
let asProp, className, pressed, restProps, schemeProp, selectable, selected, shadow, style, t0, t1, t2, t3;
|
|
854
817
|
$[0] !== props ? ({
|
|
855
818
|
__unstable_checkered: t0,
|
|
856
819
|
__unstable_focusRing: t1,
|
|
@@ -859,41 +822,48 @@ const Card = forwardRef(function(props, ref) {
|
|
|
859
822
|
pressed,
|
|
860
823
|
radius: t2,
|
|
861
824
|
scheme: schemeProp,
|
|
825
|
+
selectable,
|
|
862
826
|
selected,
|
|
863
827
|
shadow,
|
|
864
828
|
style,
|
|
865
829
|
tone: t3,
|
|
866
830
|
...restProps
|
|
867
|
-
} = props, $[0] = props, $[1] = asProp, $[2] = className, $[3] = pressed, $[4] = restProps, $[5] = schemeProp, $[6] =
|
|
868
|
-
const checkered = t0 === void 0 ? !1 : t0, focusRing = t1 === void 0 ? !1 : t1, radius = t2 === void 0 ? 0 : t2, toneProp = t3 === void 0 ? "
|
|
831
|
+
} = props, $[0] = props, $[1] = asProp, $[2] = className, $[3] = pressed, $[4] = restProps, $[5] = schemeProp, $[6] = selectable, $[7] = selected, $[8] = shadow, $[9] = style, $[10] = t0, $[11] = t1, $[12] = t2, $[13] = t3) : (asProp = $[1], className = $[2], pressed = $[3], restProps = $[4], schemeProp = $[5], selectable = $[6], selected = $[7], shadow = $[8], style = $[9], t0 = $[10], t1 = $[11], t2 = $[12], t3 = $[13]);
|
|
832
|
+
const checkered = t0 === void 0 ? !1 : t0, focusRing = t1 === void 0 ? !1 : t1, radius = t2 === void 0 ? 0 : t2, toneProp = t3 === void 0 ? "inherit" : t3, as = isValidElementType(asProp) ? asProp : "div", parent = useCard(), t4 = parent?.tone ?? "default", t5 = parent?.scheme ?? "light";
|
|
869
833
|
let t6;
|
|
870
|
-
$[
|
|
834
|
+
$[14] !== t4 || $[15] !== t5 ? (t6 = {
|
|
871
835
|
tone: t4,
|
|
872
836
|
scheme: t5
|
|
873
|
-
}, $[
|
|
874
|
-
const context = t6, tone = toneProp === "inherit" ? context.tone : toneProp, scheme = schemeProp === void 0 ? context.scheme : schemeProp, t7 = scheme === context.scheme ? void 0 : scheme;
|
|
875
|
-
let
|
|
876
|
-
$[
|
|
877
|
-
|
|
878
|
-
|
|
879
|
-
|
|
880
|
-
|
|
881
|
-
|
|
882
|
-
|
|
883
|
-
|
|
884
|
-
|
|
837
|
+
}, $[14] = t4, $[15] = t5, $[16] = t6) : t6 = $[16];
|
|
838
|
+
const context = t6, tone = toneProp === "inherit" ? context.tone : toneProp, scheme = schemeProp === void 0 ? context.scheme : schemeProp, t7 = scheme === context.scheme ? void 0 : scheme, t8 = tone === context.tone ? void 0 : tone;
|
|
839
|
+
let t9;
|
|
840
|
+
if ($[17] !== className || $[18] !== radius || $[19] !== selectable || $[20] !== shadow || $[21] !== t7 || $[22] !== t8) {
|
|
841
|
+
let t102;
|
|
842
|
+
$[24] !== radius || $[25] !== selectable ? (t102 = selectable && _selectable({
|
|
843
|
+
radius
|
|
844
|
+
}), $[24] = radius, $[25] = selectable, $[26] = t102) : t102 = $[26], t9 = composeClassNames(className, card({
|
|
845
|
+
scheme: t7,
|
|
846
|
+
shadow,
|
|
847
|
+
tone: t8
|
|
848
|
+
}), t102), $[17] = className, $[18] = radius, $[19] = selectable, $[20] = shadow, $[21] = t7, $[22] = t8, $[23] = t9;
|
|
849
|
+
} else
|
|
850
|
+
t9 = $[23];
|
|
851
|
+
const t10 = checkered ? "" : void 0, t11 = focusRing ? "" : void 0, t12 = pressed ? "" : void 0, t13 = selected ? "" : void 0;
|
|
852
|
+
let t14;
|
|
853
|
+
$[27] !== as || $[28] !== radius || $[29] !== ref || $[30] !== restProps || $[31] !== style || $[32] !== t10 || $[33] !== t11 || $[34] !== t12 || $[35] !== t13 || $[36] !== t9 ? (t14 = /* @__PURE__ */ jsx(Box, { "data-ui": "Card", ...restProps, as, className: t9, "data-checkered": t10, "data-focus-ring": t11, "data-pressed": t12, "data-selected": t13, radius, ref, style }), $[27] = as, $[28] = radius, $[29] = ref, $[30] = restProps, $[31] = style, $[32] = t10, $[33] = t11, $[34] = t12, $[35] = t13, $[36] = t9, $[37] = t14) : t14 = $[37];
|
|
854
|
+
let node = t14;
|
|
885
855
|
if (scheme === context.scheme && tone === context.tone)
|
|
886
856
|
return node;
|
|
887
|
-
const
|
|
888
|
-
let
|
|
889
|
-
if ($[
|
|
890
|
-
const
|
|
891
|
-
let
|
|
892
|
-
return $[
|
|
857
|
+
const t15 = parent?.compat_provider, t16 = tone ?? context.tone;
|
|
858
|
+
let t17;
|
|
859
|
+
if ($[38] !== node || $[39] !== scheme || $[40] !== t15 || $[41] !== t16 ? (t17 = /* @__PURE__ */ jsx(CardProvider, { compat_provider: t15, rendered: !0, scheme, tone: t16, children: node }), $[38] = node, $[39] = scheme, $[40] = t15, $[41] = t16, $[42] = t17) : t17 = $[42], node = t17, parent?.compat_provider) {
|
|
860
|
+
const t18 = tone ?? context.tone;
|
|
861
|
+
let t19;
|
|
862
|
+
return $[43] !== node || $[44] !== parent.compat_provider || $[45] !== scheme || $[46] !== t18 ? (t19 = createElement(parent.compat_provider, {
|
|
893
863
|
children: node,
|
|
894
864
|
scheme,
|
|
895
|
-
tone:
|
|
896
|
-
}), $[
|
|
865
|
+
tone: t18
|
|
866
|
+
}), $[43] = node, $[44] = parent.compat_provider, $[45] = scheme, $[46] = t18, $[47] = t19) : t19 = $[47], t19;
|
|
897
867
|
}
|
|
898
868
|
return node;
|
|
899
869
|
});
|
|
@@ -949,7 +919,7 @@ const LazyRefractor = lazy(() => import("./refractor.mjs")), Code = forwardRef(f
|
|
|
949
919
|
weight,
|
|
950
920
|
...restProps
|
|
951
921
|
} = props, $[0] = props, $[1] = children, $[2] = className, $[3] = languageProp, $[4] = restProps, $[5] = t0, $[6] = t1, $[7] = weight) : (children = $[1], className = $[2], languageProp = $[3], restProps = $[4], t0 = $[5], t1 = $[6], weight = $[7]);
|
|
952
|
-
const As = t0 === void 0 ? "pre" : t0, size2 = t1 === void 0 ?
|
|
922
|
+
const As = t0 === void 0 ? "pre" : t0, size2 = t1 === void 0 ? 1 : t1, language = typeof languageProp == "string" ? languageProp : void 0;
|
|
953
923
|
let t2;
|
|
954
924
|
$[8] !== className || $[9] !== size2 || $[10] !== weight ? (t2 = composeClassNames(className, code({
|
|
955
925
|
size: size2,
|
|
@@ -1025,7 +995,7 @@ const Heading = forwardRef(function(props, ref) {
|
|
|
1025
995
|
weight,
|
|
1026
996
|
...restProps
|
|
1027
997
|
} = props, $[0] = props, $[1] = align, $[2] = children, $[3] = className, $[4] = flex, $[5] = restProps, $[6] = t0, $[7] = t1, $[8] = t2, $[9] = t3, $[10] = textOverflowProp, $[11] = weight) : (align = $[1], children = $[2], className = $[3], flex = $[4], restProps = $[5], t0 = $[6], t1 = $[7], t2 = $[8], t3 = $[9], textOverflowProp = $[10], weight = $[11]);
|
|
1028
|
-
const accent = t0 === void 0 ? !1 : t0, As = t1 === void 0 ? "div" : t1, muted = t2 === void 0 ? !1 : t2, size2 = t3 === void 0 ?
|
|
998
|
+
const accent = t0 === void 0 ? !1 : t0, As = t1 === void 0 ? "div" : t1, muted = t2 === void 0 ? !1 : t2, size2 = t3 === void 0 ? 1 : t3;
|
|
1029
999
|
let t4;
|
|
1030
1000
|
$[12] !== accent || $[13] !== align || $[14] !== className || $[15] !== flex || $[16] !== muted || $[17] !== size2 || $[18] !== weight ? (t4 = composeClassNames(className, heading({
|
|
1031
1001
|
accent,
|
|
@@ -1080,13 +1050,13 @@ const KBD = forwardRef(function(props, ref) {
|
|
|
1080
1050
|
radius: t4,
|
|
1081
1051
|
...restProps
|
|
1082
1052
|
} = props, $[0] = props, $[1] = children, $[2] = className, $[3] = restProps, $[4] = t0, $[5] = t1, $[6] = t2, $[7] = t3, $[8] = t4) : (children = $[1], className = $[2], restProps = $[3], t0 = $[4], t1 = $[5], t2 = $[6], t3 = $[7], t4 = $[8]);
|
|
1083
|
-
const as = t0 === void 0 ? "kbd" : t0, display = t1 === void 0 ? "inline-block" : t1, fontSize = t2 === void 0 ?
|
|
1053
|
+
const as = t0 === void 0 ? "kbd" : t0, display = t1 === void 0 ? "inline-block" : t1, fontSize = t2 === void 0 ? 1 : t2, padding = t3 === void 0 ? 1 : t3, radius = t4 === void 0 ? 2 : t4;
|
|
1084
1054
|
let t5;
|
|
1085
1055
|
$[9] !== className || $[10] !== radius ? (t5 = composeClassNames(className, kbd({
|
|
1086
1056
|
radius
|
|
1087
1057
|
})), $[9] = className, $[10] = radius, $[11] = t5) : t5 = $[11];
|
|
1088
1058
|
let t6;
|
|
1089
|
-
$[12] !== children || $[13] !== fontSize ? (t6 = /* @__PURE__ */ jsx(Text, { as: "span", muted: !0, size: fontSize,
|
|
1059
|
+
$[12] !== children || $[13] !== fontSize ? (t6 = /* @__PURE__ */ jsx(Text, { as: "span", muted: !0, size: fontSize, children }), $[12] = children, $[13] = fontSize, $[14] = t6) : t6 = $[14];
|
|
1090
1060
|
let t7;
|
|
1091
1061
|
return $[15] !== as || $[16] !== display || $[17] !== padding || $[18] !== ref || $[19] !== restProps || $[20] !== t5 || $[21] !== t6 ? (t7 = /* @__PURE__ */ jsx(Box, { "data-ui": "KBD", ...restProps, as, className: t5, display, muted: !0, padding, ref, children: t6 }), $[15] = as, $[16] = display, $[17] = padding, $[18] = ref, $[19] = restProps, $[20] = t5, $[21] = t6, $[22] = t7) : t7 = $[22], t7;
|
|
1092
1062
|
});
|
|
@@ -1693,7 +1663,7 @@ function size(options) {
|
|
|
1693
1663
|
};
|
|
1694
1664
|
}
|
|
1695
1665
|
const MotionCard$1 = motion.create(Card), PopoverCard = memo(forwardRef(function(props, ref) {
|
|
1696
|
-
const $ = c(
|
|
1666
|
+
const $ = c(68);
|
|
1697
1667
|
let animate, arrow2, arrowRef, arrowX, arrowY, children, marginsProp, maxWidth, originX, originY, overflow, padding, placement, radius, referenceWidth, restProps, scheme, shadow, strategy, style, tone, xProp, yProp;
|
|
1698
1668
|
$[0] !== props ? ({
|
|
1699
1669
|
__unstable_margins: marginsProp,
|
|
@@ -1720,7 +1690,7 @@ const MotionCard$1 = motion.create(Card), PopoverCard = memo(forwardRef(function
|
|
|
1720
1690
|
y: yProp,
|
|
1721
1691
|
...restProps
|
|
1722
1692
|
} = props, $[0] = props, $[1] = animate, $[2] = arrow2, $[3] = arrowRef, $[4] = arrowX, $[5] = arrowY, $[6] = children, $[7] = marginsProp, $[8] = maxWidth, $[9] = originX, $[10] = originY, $[11] = overflow, $[12] = padding, $[13] = placement, $[14] = radius, $[15] = referenceWidth, $[16] = restProps, $[17] = scheme, $[18] = shadow, $[19] = strategy, $[20] = style, $[21] = tone, $[22] = xProp, $[23] = yProp) : (animate = $[1], arrow2 = $[2], arrowRef = $[3], arrowX = $[4], arrowY = $[5], children = $[6], marginsProp = $[7], maxWidth = $[8], originX = $[9], originY = $[10], overflow = $[11], padding = $[12], placement = $[13], radius = $[14], referenceWidth = $[15], restProps = $[16], scheme = $[17], shadow = $[18], strategy = $[19], style = $[20], tone = $[21], xProp = $[22], yProp = $[23]);
|
|
1723
|
-
const
|
|
1693
|
+
const layer = useLayer();
|
|
1724
1694
|
let t0;
|
|
1725
1695
|
t0 = marginsProp || DEFAULT_POPOVER_MARGINS;
|
|
1726
1696
|
const margins = t0, x = (xProp ?? 0) + margins[3], y = (yProp ?? 0) + margins[0];
|
|
@@ -1748,29 +1718,24 @@ const MotionCard$1 = motion.create(Card), PopoverCard = memo(forwardRef(function
|
|
|
1748
1718
|
right: void 0,
|
|
1749
1719
|
bottom: void 0
|
|
1750
1720
|
}, $[34] = t6, $[35] = t7, $[36] = t8) : t8 = $[36], t5 = t8;
|
|
1751
|
-
const arrowStyle = t5, t9 =
|
|
1721
|
+
const arrowStyle = t5, t9 = restProps;
|
|
1722
|
+
let t10;
|
|
1723
|
+
$[37] !== animate ? (t10 = animate ? ["hidden", "initial"] : void 0, $[37] = animate, $[38] = t10) : t10 = $[38];
|
|
1752
1724
|
let t11;
|
|
1753
|
-
$[
|
|
1754
|
-
|
|
1725
|
+
$[39] !== animate ? (t11 = animate ? ["visible", "scaleIn"] : void 0, $[39] = animate, $[40] = t11) : t11 = $[40];
|
|
1726
|
+
let t12;
|
|
1727
|
+
$[41] !== animate ? (t12 = animate ? ["hidden", "scaleOut"] : void 0, $[41] = animate, $[42] = t12) : t12 = $[42];
|
|
1728
|
+
let t13;
|
|
1729
|
+
$[43] !== children || $[44] !== padding ? (t13 = /* @__PURE__ */ jsx(Flex, { direction: "column", flex: 1, padding, children }), $[43] = children, $[44] = padding, $[45] = t13) : t13 = $[45];
|
|
1755
1730
|
let t14;
|
|
1756
|
-
$[
|
|
1731
|
+
$[46] !== maxWidth || $[47] !== overflow || $[48] !== t13 ? (t14 = /* @__PURE__ */ jsx(Flex, { "data-ui": "Popover__wrapper", direction: "column", flex: 1, maxWidth, overflow, children: t13 }), $[46] = maxWidth, $[47] = overflow, $[48] = t13, $[49] = t14) : t14 = $[49];
|
|
1757
1732
|
let t15;
|
|
1758
|
-
$[
|
|
1733
|
+
$[50] !== arrow2 || $[51] !== arrowRef || $[52] !== arrowStyle ? (t15 = arrow2 && /* @__PURE__ */ jsx(Arrow, { ref: arrowRef, style: arrowStyle, width: DEFAULT_POPOVER_ARROW_WIDTH, height: DEFAULT_POPOVER_ARROW_HEIGHT, radius: DEFAULT_POPOVER_ARROW_RADIUS }), $[50] = arrow2, $[51] = arrowRef, $[52] = arrowStyle, $[53] = t15) : t15 = $[53];
|
|
1759
1734
|
let t16;
|
|
1760
|
-
$[
|
|
1761
|
-
|
|
1762
|
-
|
|
1763
|
-
|
|
1764
|
-
$[47] !== maxWidth || $[48] !== overflow || $[49] !== t17 ? (t18 = /* @__PURE__ */ jsx(Flex, { "data-ui": "Popover__wrapper", direction: "column", flex: 1, maxWidth, overflow, children: t17 }), $[47] = maxWidth, $[48] = overflow, $[49] = t17, $[50] = t18) : t18 = $[50];
|
|
1765
|
-
let t19;
|
|
1766
|
-
$[51] !== arrow2 || $[52] !== arrowRef || $[53] !== arrowStyle ? (t19 = arrow2 && /* @__PURE__ */ jsx(Arrow, { ref: arrowRef, style: arrowStyle, width: DEFAULT_POPOVER_ARROW_WIDTH, height: DEFAULT_POPOVER_ARROW_HEIGHT, radius: DEFAULT_POPOVER_ARROW_RADIUS }), $[51] = arrow2, $[52] = arrowRef, $[53] = arrowStyle, $[54] = t19) : t19 = $[54];
|
|
1767
|
-
let t20;
|
|
1768
|
-
$[55] !== placement || $[56] !== radius || $[57] !== ref || $[58] !== rootStyle || $[59] !== scheme || $[60] !== shadow || $[61] !== t12 || $[62] !== t13 || $[63] !== t14 || $[64] !== t15 || $[65] !== t16 || $[66] !== t18 || $[67] !== t19 || $[68] !== tone ? (t20 = /* @__PURE__ */ jsxs(MotionCard$1, { className: t11, "data-ui": "Popover", ...t12, "data-context-tone": t13, "data-placement": placement, direction: "column", display: "flex", radius, ref, scheme, shadow, sizing: "border", style: rootStyle, tone, variants: POPOVER_MOTION_PROPS.card, transition: POPOVER_MOTION_PROPS.transition, initial: t14, animate: t15, exit: t16, children: [
|
|
1769
|
-
t18,
|
|
1770
|
-
t19
|
|
1771
|
-
] }), $[55] = placement, $[56] = radius, $[57] = ref, $[58] = rootStyle, $[59] = scheme, $[60] = shadow, $[61] = t12, $[62] = t13, $[63] = t14, $[64] = t15, $[65] = t16, $[66] = t18, $[67] = t19, $[68] = tone, $[69] = t20) : t20 = $[69];
|
|
1772
|
-
let t21;
|
|
1773
|
-
return $[70] !== t10 || $[71] !== t20 || $[72] !== t9 ? (t21 = /* @__PURE__ */ jsx(CardProvider, { tone: t9, scheme: t10, children: t20 }), $[70] = t10, $[71] = t20, $[72] = t9, $[73] = t21) : t21 = $[73], t21;
|
|
1735
|
+
return $[54] !== placement || $[55] !== radius || $[56] !== ref || $[57] !== rootStyle || $[58] !== scheme || $[59] !== shadow || $[60] !== t10 || $[61] !== t11 || $[62] !== t12 || $[63] !== t14 || $[64] !== t15 || $[65] !== t9 || $[66] !== tone ? (t16 = /* @__PURE__ */ jsxs(MotionCard$1, { className: "popover-card", "data-ui": "Popover", ...t9, "data-placement": placement, direction: "column", display: "flex", radius, ref, scheme, shadow, sizing: "border", style: rootStyle, tone, variants: POPOVER_MOTION_PROPS.card, transition: POPOVER_MOTION_PROPS.transition, initial: t10, animate: t11, exit: t12, children: [
|
|
1736
|
+
t14,
|
|
1737
|
+
t15
|
|
1738
|
+
] }), $[54] = placement, $[55] = radius, $[56] = ref, $[57] = rootStyle, $[58] = scheme, $[59] = shadow, $[60] = t10, $[61] = t11, $[62] = t12, $[63] = t14, $[64] = t15, $[65] = t9, $[66] = tone, $[67] = t16) : t16 = $[67], t16;
|
|
1774
1739
|
}));
|
|
1775
1740
|
PopoverCard.displayName = "Memo(ForwardRef(PopoverCard))";
|
|
1776
1741
|
const ViewportOverlay = () => {
|
|
@@ -1790,7 +1755,6 @@ const ViewportOverlay = () => {
|
|
|
1790
1755
|
__unstable_margins: margins = DEFAULT_POPOVER_MARGINS,
|
|
1791
1756
|
animate: _animate = !1,
|
|
1792
1757
|
arrow: arrowProp = !1,
|
|
1793
|
-
// eslint-disable-next-line @typescript-eslint/no-unused-vars
|
|
1794
1758
|
boundaryElement = boundaryElementContext.element,
|
|
1795
1759
|
children: childProp,
|
|
1796
1760
|
constrainSize = !1,
|
|
@@ -1816,7 +1780,7 @@ const ViewportOverlay = () => {
|
|
|
1816
1780
|
tone = "inherit",
|
|
1817
1781
|
width: widthProp = "auto",
|
|
1818
1782
|
// zOffset: zOffsetProp = layer.popover.zOffset,
|
|
1819
|
-
zOffset: zOffsetProp
|
|
1783
|
+
zOffset: zOffsetProp,
|
|
1820
1784
|
updateRef,
|
|
1821
1785
|
...restProps
|
|
1822
1786
|
} = props, animate = usePrefersReducedMotion() ? !1 : _animate, zOffset = useArrayProp(zOffsetProp), ref = useRef(null), arrowRef = useRef(null), rootBoundary = "viewport";
|
|
@@ -1969,7 +1933,7 @@ const Select = forwardRef(function(props, forwardedRef) {
|
|
|
1969
1933
|
space: t4,
|
|
1970
1934
|
...restProps
|
|
1971
1935
|
} = props, $[0] = props, $[1] = children, $[2] = customValidity, $[3] = disabled, $[4] = gap, $[5] = readOnly, $[6] = restProps, $[7] = t0, $[8] = t1, $[9] = t2, $[10] = t3, $[11] = t4) : (children = $[1], customValidity = $[2], disabled = $[3], gap = $[4], readOnly = $[5], restProps = $[6], t0 = $[7], t1 = $[8], t2 = $[9], t3 = $[10], t4 = $[11]);
|
|
1972
|
-
const border = t0 === void 0 ? !0 : t0, fontSize = t1 === void 0 ?
|
|
1936
|
+
const border = t0 === void 0 ? !0 : t0, fontSize = t1 === void 0 ? 1 : t1, padding = t2 === void 0 ? 2 : t2, radius = t3 === void 0 ? 2 : t3, space = t4 === void 0 ? 2 : t4, ref = useRef(null);
|
|
1973
1937
|
let t5;
|
|
1974
1938
|
$[12] === Symbol.for("react.memo_cache_sentinel") ? (t5 = () => ref.current, $[12] = t5) : t5 = $[12], useImperativeHandle(forwardedRef, t5), useCustomValidity(ref, customValidity);
|
|
1975
1939
|
const t6 = gap ?? space;
|
|
@@ -2003,20 +1967,17 @@ const Select = forwardRef(function(props, forwardedRef) {
|
|
|
2003
1967
|
});
|
|
2004
1968
|
Select.displayName = "ForwardRef(Select)";
|
|
2005
1969
|
const Stack = forwardRef(function(props, ref) {
|
|
2006
|
-
const $ = c(
|
|
2007
|
-
let as,
|
|
1970
|
+
const $ = c(10);
|
|
1971
|
+
let as, gap, restProps, space;
|
|
2008
1972
|
$[0] !== props ? ({
|
|
2009
1973
|
as,
|
|
2010
|
-
className,
|
|
2011
1974
|
gap,
|
|
2012
1975
|
space,
|
|
2013
1976
|
...restProps
|
|
2014
|
-
} = props, $[0] = props, $[1] = as, $[2] =
|
|
2015
|
-
|
|
2016
|
-
|
|
2017
|
-
|
|
2018
|
-
let t2;
|
|
2019
|
-
return $[8] !== as || $[9] !== ref || $[10] !== restProps || $[11] !== t0 || $[12] !== t1 ? (t2 = /* @__PURE__ */ jsx(Box, { "data-ui": "Stack", ...restProps, as, autoRows: "min", className: t0, display: "grid", gap: t1, ref }), $[8] = as, $[9] = ref, $[10] = restProps, $[11] = t0, $[12] = t1, $[13] = t2) : t2 = $[13], t2;
|
|
1977
|
+
} = props, $[0] = props, $[1] = as, $[2] = gap, $[3] = restProps, $[4] = space) : (as = $[1], gap = $[2], restProps = $[3], space = $[4]);
|
|
1978
|
+
const t0 = gap ?? space;
|
|
1979
|
+
let t1;
|
|
1980
|
+
return $[5] !== as || $[6] !== ref || $[7] !== restProps || $[8] !== t0 ? (t1 = /* @__PURE__ */ jsx(Box, { "data-ui": "Stack", ...restProps, as, direction: "column", display: "flex", gap: t0, ref }), $[5] = as, $[6] = ref, $[7] = restProps, $[8] = t0, $[9] = t1) : t1 = $[9], t1;
|
|
2020
1981
|
});
|
|
2021
1982
|
Stack.displayName = "ForwardRef(Stack)";
|
|
2022
1983
|
const Switch = forwardRef(function(props, forwardedRef) {
|
|
@@ -2132,7 +2093,7 @@ const CLEAR_BUTTON_BOX_STYLE = {
|
|
|
2132
2093
|
__unstable_disableFocusRing = t72, t0 = t82, className = t92, clearButton = t102, t1 = t112, t2 = t122, gap = t132, IconComponent = t142, IconRightComponent = t152, onClear = t162, t3 = t172, prefix = t182, t4 = t192, readOnly = t202, t5 = t212, suffix = t222, customValidity = t232, t6 = t242, width = t252, restProps = t262, $[0] = props, $[1] = IconComponent, $[2] = IconRightComponent, $[3] = __unstable_disableFocusRing, $[4] = className, $[5] = clearButton, $[6] = customValidity, $[7] = gap, $[8] = onClear, $[9] = prefix, $[10] = readOnly, $[11] = restProps, $[12] = suffix, $[13] = t0, $[14] = t1, $[15] = t2, $[16] = t3, $[17] = t4, $[18] = t5, $[19] = t6, $[20] = width;
|
|
2133
2094
|
} else
|
|
2134
2095
|
IconComponent = $[1], IconRightComponent = $[2], __unstable_disableFocusRing = $[3], className = $[4], clearButton = $[5], customValidity = $[6], gap = $[7], onClear = $[8], prefix = $[9], readOnly = $[10], restProps = $[11], suffix = $[12], t0 = $[13], t1 = $[14], t2 = $[15], t3 = $[16], t4 = $[17], t5 = $[18], t6 = $[19], width = $[20];
|
|
2135
|
-
const border = t0 === void 0 ? !0 : t0, disabled = t1 === void 0 ? !1 : t1, fontSize = t2 === void 0 ?
|
|
2096
|
+
const border = t0 === void 0 ? !0 : t0, disabled = t1 === void 0 ? !1 : t1, fontSize = t2 === void 0 ? 1 : t2, padding = t3 === void 0 ? 3 : t3, radius = t4 === void 0 ? 2 : t4, space = t5 === void 0 ? 3 : t5, type = t6 === void 0 ? "text" : t6, ref = useRef(null), paddingArray = useArrayProp(padding), withClearButton = !!clearButton;
|
|
2136
2097
|
let t7;
|
|
2137
2098
|
$[21] === Symbol.for("react.memo_cache_sentinel") ? (t7 = () => ref.current, $[21] = t7) : t7 = $[21], useImperativeHandle(forwardedRef, t7), useCustomValidity(ref, customValidity);
|
|
2138
2099
|
const handleClearMouseDown = _temp;
|
|
@@ -2333,6 +2294,8 @@ function useTooltipDelayGroup() {
|
|
|
2333
2294
|
}
|
|
2334
2295
|
const Tooltip = forwardRef(function(props, forwardedRef) {
|
|
2335
2296
|
const boundaryElementContext = useBoundaryElement(), {
|
|
2297
|
+
layer
|
|
2298
|
+
} = useTheme_v2(), {
|
|
2336
2299
|
animate: _animate = !1,
|
|
2337
2300
|
arrow: arrowProp = !1,
|
|
2338
2301
|
boundaryElement = boundaryElementContext?.element,
|
|
@@ -2348,7 +2311,7 @@ const Tooltip = forwardRef(function(props, forwardedRef) {
|
|
|
2348
2311
|
radius = 3,
|
|
2349
2312
|
scheme,
|
|
2350
2313
|
shadow = 2,
|
|
2351
|
-
zOffset =
|
|
2314
|
+
zOffset = layer.tooltip.zOffset,
|
|
2352
2315
|
tone,
|
|
2353
2316
|
...restProps
|
|
2354
2317
|
} = props, animate = usePrefersReducedMotion() ? !1 : _animate, fallbackPlacements = useArrayProp(fallbackPlacementsProp), ref = useRef(null), [referenceElement, setReferenceElement] = useState(null), arrowRef = useRef(null), rootBoundary = "viewport", [tooltipMaxWidth, setTooltipMaxWidth] = useState(0);
|
|
@@ -3099,7 +3062,6 @@ export {
|
|
|
3099
3062
|
TooltipDelayGroupContext,
|
|
3100
3063
|
TooltipDelayGroupProvider,
|
|
3101
3064
|
VirtualList,
|
|
3102
|
-
Z_OFFSETS,
|
|
3103
3065
|
_ResizeObserver,
|
|
3104
3066
|
_elementSizeObserver,
|
|
3105
3067
|
_getArrayProp,
|