@graphty/compact-mantine 0.9.21 → 0.9.22
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/index.cjs +50 -41
- package/dist/index.js +268 -259
- package/package.json +1 -1
package/dist/index.js
CHANGED
|
@@ -1,5 +1,5 @@
|
|
|
1
|
-
import { DEFAULT_THEME as fa, CloseButton as Sr, ActionIconGroup as Ai, ActionIcon as He, Button as ba, ColorSwatch as ga, RangeSlider as Ni, Radio as Ei, Slider as Ci, Switch as xa, Checkbox as Tr, SegmentedControl as Ar, Kbd as va, Card as zi, Indicator as Ii, ThemeIcon as Li, Avatar as on, Pill as Pi, Badge as Oi, Text as jt, RingProgress as Ri, Progress as ur, Loader as Di, VisuallyHidden as at, InputClearButton as Mi, Combobox as
|
|
2
|
-
import Ye, { createElement as co, useContext as dt, useMemo as he, createContext as
|
|
1
|
+
import { DEFAULT_THEME as fa, CloseButton as Sr, ActionIconGroup as Ai, ActionIcon as He, Button as ba, ColorSwatch as ga, RangeSlider as Ni, Radio as Ei, Slider as Ci, Switch as xa, Checkbox as Tr, SegmentedControl as Ar, Kbd as va, Card as zi, Indicator as Ii, ThemeIcon as Li, Avatar as on, Pill as Pi, Badge as Oi, Text as jt, RingProgress as Ri, Progress as ur, Loader as Di, VisuallyHidden as at, InputClearButton as Mi, Combobox as Ht, JsonInput as Hi, FileInput as Bi, PillsInput as Fi, TagsInput as Vi, MultiSelect as Ui, Autocomplete as Gi, PasswordInput as qi, Textarea as Wi, NativeSelect as ji, Select as Ho, NumberInput as Yi, TextInput as Ct, InputWrapper as Ki, Tabs as ro, Stepper as Xi, Pagination as Ji, NavLink as Zi, Burger as Qi, Anchor as _i, ScrollArea as Nr, Notification as wa, Drawer as rn, Modal as nn, HoverCard as $i, Popover as ec, Tooltip as lt, Menu as Oe, mergeMantineTheme as tc, createTheme as oc, parseColor as no, HueSlider as rc, AlphaSlider as nc, convertHsvaTo as ya, isColorValid as ac, Box as O, useDirection as ic, useMantineTheme as ka, UnstyledButton as it, Table as Ot, useInputWrapperContext as cc, Group as Sa, useCombobox as sc, Input as lc, Portal as dc, useComputedColorScheme as uc, rem as Zt } from "@mantine/core";
|
|
2
|
+
import Ye, { createElement as co, useContext as dt, useMemo as he, createContext as It, useCallback as ce, useId as ze, useRef as K, useEffect as Se, useState as me, isValidElement as Ta, cloneElement as Er, forwardRef as et, useInsertionEffect as mc, useLayoutEffect as so, useImperativeHandle as pc } from "react";
|
|
3
3
|
import { jsxs as v, jsx as o, Fragment as Z } from "react/jsx-runtime";
|
|
4
4
|
import { useMove as hc, clampUseMovePosition as fc, useUncontrolled as xe, useIsomorphicEffect as bc, useId as uo, useMergedRef as gc, useHover as xc, useMediaQuery as Aa, useElementSize as vc } from "@mantine/hooks";
|
|
5
5
|
import { createPortal as wc, flushSync as yc } from "react-dom";
|
|
@@ -797,20 +797,20 @@ const ys = {
|
|
|
797
797
|
"field-edge-hover": Y("#e6e6e6", "#444444"),
|
|
798
798
|
/** the selected segment's inset edge (= border) */
|
|
799
799
|
"segment-edge": Y("#e6e6e6", "#444444")
|
|
800
|
-
}, ke = (e) => `var(--mantine-primary-color-${e})`,
|
|
800
|
+
}, ke = (e) => `var(--mantine-primary-color-${e})`, ft = (e, t, r) => `color-mix(in srgb, ${e} ${t}%, ${r})`, ks = {
|
|
801
801
|
"bg-brand": { light: ke(6), dark: ke(8) },
|
|
802
802
|
"bg-brand-hover": { light: ke(7), dark: ke(9) },
|
|
803
|
-
"bg-brand-pressed": { light:
|
|
804
|
-
"bg-selected": { light: ke(0), dark:
|
|
805
|
-
"bg-selected-hover": { light: ke(1), dark:
|
|
806
|
-
"bg-selected-secondary": { light:
|
|
807
|
-
"bg-selected-pressed": { light: ke(2), dark:
|
|
808
|
-
"bg-info": { light: ke(0), dark:
|
|
803
|
+
"bg-brand-pressed": { light: ft(ke(7), 85, "#000000"), dark: ft(ke(9), 85, "#000000") },
|
|
804
|
+
"bg-selected": { light: ke(0), dark: ft(ke(8), 25, "#2c2c2c") },
|
|
805
|
+
"bg-selected-hover": { light: ke(1), dark: ft(ke(8), 35, "#2c2c2c") },
|
|
806
|
+
"bg-selected-secondary": { light: ft(ke(0), 50, "#ffffff"), dark: ft(ke(8), 15, "#2c2c2c") },
|
|
807
|
+
"bg-selected-pressed": { light: ke(2), dark: ft(ke(8), 25, "#2c2c2c") },
|
|
808
|
+
"bg-info": { light: ke(0), dark: ft(ke(8), 25, "#2c2c2c") },
|
|
809
809
|
"text-brand": { light: ke(7), dark: ke(4) },
|
|
810
810
|
"icon-brand": { light: ke(7), dark: ke(4) },
|
|
811
811
|
"border-selected": { light: ke(6), dark: ke(8) },
|
|
812
812
|
"border-selected-strong": { light: ke(7), dark: ke(4) },
|
|
813
|
-
"text-highlight": { light:
|
|
813
|
+
"text-highlight": { light: ft(ke(6), 40, "transparent"), dark: ft(ke(6), 40, "transparent") }
|
|
814
814
|
}, Ss = {
|
|
815
815
|
// Owner's list.
|
|
816
816
|
"text-secondary": { light: "#0000008c", dark: "#ffffffb2" },
|
|
@@ -1197,12 +1197,12 @@ const Xe = {
|
|
|
1197
1197
|
stroke: "none"
|
|
1198
1198
|
}, el = {
|
|
1199
1199
|
sizeSmallest: (e) => /* @__PURE__ */ v(Z, { children: [
|
|
1200
|
-
/* @__PURE__ */ o("circle", { cx: "
|
|
1201
|
-
/* @__PURE__ */ o("circle", { cx: "10.
|
|
1200
|
+
/* @__PURE__ */ o("circle", { cx: "3", cy: "11.25", r: "1.75", ...e ? Xe : {} }),
|
|
1201
|
+
/* @__PURE__ */ o("circle", { cx: "10.25", cy: "9.25", r: "3.75", ...e ? Xe : {} })
|
|
1202
1202
|
] }),
|
|
1203
1203
|
sizeLargest: (e) => /* @__PURE__ */ v(Z, { children: [
|
|
1204
|
-
/* @__PURE__ */ o("circle", { cx: "
|
|
1205
|
-
/* @__PURE__ */ o("circle", { cx: "
|
|
1204
|
+
/* @__PURE__ */ o("circle", { cx: "2.5", cy: "12", r: "1", ...e ? Xe : {} }),
|
|
1205
|
+
/* @__PURE__ */ o("circle", { cx: "9.5", cy: "8.5", r: "4.5", ...e ? Xe : {} })
|
|
1206
1206
|
] }),
|
|
1207
1207
|
width: (e) => /* @__PURE__ */ v(Z, { children: [
|
|
1208
1208
|
/* @__PURE__ */ o("line", { x1: "2.5", y1: "8", x2: "13.5", y2: "8" }),
|
|
@@ -1631,7 +1631,7 @@ const ul = {
|
|
|
1631
1631
|
flip: !0,
|
|
1632
1632
|
shift: { padding: Oo },
|
|
1633
1633
|
size: { padding: Oo, apply: dl }
|
|
1634
|
-
}, ml = { mainAxis: 4, alignmentAxis: -8 },
|
|
1634
|
+
}, ml = { mainAxis: 4, alignmentAxis: -8 }, qt = { duration: 0 }, hr = 1e3, Ro = 300, Ga = 8.5, qa = 6, pl = qa - Ga / 2, hl = {
|
|
1635
1635
|
tooltip: "cm-tooltip",
|
|
1636
1636
|
arrow: "cm-tooltip-arrow"
|
|
1637
1637
|
}, wn = {
|
|
@@ -1713,18 +1713,18 @@ const Kt = typeof ResizeObserver > "u" ? null : new ResizeObserver((e) => {
|
|
|
1713
1713
|
for (const { target: t } of e)
|
|
1714
1714
|
t.isConnected ? gr(t) : Kt == null || Kt.unobserve(t);
|
|
1715
1715
|
});
|
|
1716
|
-
let
|
|
1716
|
+
let gt = null;
|
|
1717
1717
|
function Lr() {
|
|
1718
|
-
|
|
1718
|
+
gt && (cancelAnimationFrame(gt.frame), gt = null);
|
|
1719
1719
|
}
|
|
1720
1720
|
function Sn(e, t) {
|
|
1721
|
-
if ((
|
|
1721
|
+
if ((gt == null ? void 0 : gt.menu) === e && gt.direction === t)
|
|
1722
1722
|
return;
|
|
1723
1723
|
Lr();
|
|
1724
1724
|
const r = () => {
|
|
1725
|
-
|
|
1725
|
+
gt && (e.scrollTop += t * yl, gt.frame = requestAnimationFrame(r));
|
|
1726
1726
|
};
|
|
1727
|
-
|
|
1727
|
+
gt = { menu: e, direction: t, frame: requestAnimationFrame(r) };
|
|
1728
1728
|
}
|
|
1729
1729
|
function Nl(e) {
|
|
1730
1730
|
const t = e.target instanceof Element ? e.target.closest(".cm-menu") : null;
|
|
@@ -1778,7 +1778,7 @@ function Qt(e, t, r) {
|
|
|
1778
1778
|
"--input-line-height": r
|
|
1779
1779
|
};
|
|
1780
1780
|
}
|
|
1781
|
-
function
|
|
1781
|
+
function xt(e, t, r, n) {
|
|
1782
1782
|
return {
|
|
1783
1783
|
"--input-height": e,
|
|
1784
1784
|
"--input-fz": r,
|
|
@@ -1786,7 +1786,7 @@ function wt(e, t, r, n) {
|
|
|
1786
1786
|
"--input-padding-y": t
|
|
1787
1787
|
};
|
|
1788
1788
|
}
|
|
1789
|
-
const
|
|
1789
|
+
const Rt = {
|
|
1790
1790
|
compactSize: "sm",
|
|
1791
1791
|
sizes: {
|
|
1792
1792
|
xs: Qt("20px", "11px", "16px"),
|
|
@@ -1798,20 +1798,20 @@ const Mt = {
|
|
|
1798
1798
|
}, Tn = {
|
|
1799
1799
|
compactSize: "sm",
|
|
1800
1800
|
sizes: {
|
|
1801
|
-
xs:
|
|
1802
|
-
sm:
|
|
1803
|
-
md:
|
|
1804
|
-
lg:
|
|
1805
|
-
xl:
|
|
1801
|
+
xs: xt("48px", "4px", "11px", "16px"),
|
|
1802
|
+
sm: xt("56px", "4px", "11px", "16px"),
|
|
1803
|
+
md: xt("64px", "4px", "13px", "22px"),
|
|
1804
|
+
lg: xt("72px", "6px", "15px", "25px"),
|
|
1805
|
+
xl: xt("88px", "8px", "24px", "32px")
|
|
1806
1806
|
}
|
|
1807
1807
|
}, Xo = {
|
|
1808
1808
|
compactSize: "sm",
|
|
1809
1809
|
sizes: {
|
|
1810
|
-
xs:
|
|
1811
|
-
sm:
|
|
1812
|
-
md:
|
|
1813
|
-
lg:
|
|
1814
|
-
xl:
|
|
1810
|
+
xs: xt("20px", "0px", "11px", "16px"),
|
|
1811
|
+
sm: xt("24px", "2px", "11px", "16px"),
|
|
1812
|
+
md: xt("32px", "6px", "13px", "24px"),
|
|
1813
|
+
lg: xt("36px", "8px", "15px", "25px"),
|
|
1814
|
+
xl: xt("44px", "12px", "24px", "32px")
|
|
1815
1815
|
}
|
|
1816
1816
|
}, El = {
|
|
1817
1817
|
compactSize: "xs",
|
|
@@ -1897,7 +1897,7 @@ const Ya = {
|
|
|
1897
1897
|
return `${e}th`;
|
|
1898
1898
|
}
|
|
1899
1899
|
}
|
|
1900
|
-
}, Cl = "en", vr =
|
|
1900
|
+
}, Cl = "en", vr = It(Ya), wr = It(void 0);
|
|
1901
1901
|
function zl(e) {
|
|
1902
1902
|
return e !== void 0 && e !== "" ? e : typeof document < "u" && document.documentElement.lang !== "" ? document.documentElement.lang : typeof navigator < "u" && navigator.language !== "" ? navigator.language : Cl;
|
|
1903
1903
|
}
|
|
@@ -1960,12 +1960,12 @@ function Hl(e, t) {
|
|
|
1960
1960
|
const a = Dl.exec(n);
|
|
1961
1961
|
return a === null ? Number.NaN : Number(a[0]);
|
|
1962
1962
|
}
|
|
1963
|
-
function
|
|
1963
|
+
function Lt(e) {
|
|
1964
1964
|
const t = Jt(), r = JSON.stringify(e ?? {});
|
|
1965
1965
|
return he(() => new Intl.NumberFormat(t, e), [t, r]);
|
|
1966
1966
|
}
|
|
1967
1967
|
function Bl() {
|
|
1968
|
-
const e = Jt(), t = Ee(), r =
|
|
1968
|
+
const e = Jt(), t = Ee(), r = Lt(), n = he(() => new Intl.PluralRules(e, { type: "ordinal" }), [e]);
|
|
1969
1969
|
return ce(
|
|
1970
1970
|
(a) => t.ordinal(r.format(a), n.select(a)),
|
|
1971
1971
|
[t, r, n]
|
|
@@ -2004,7 +2004,7 @@ const Wl = {
|
|
|
2004
2004
|
description: "cm-field-description",
|
|
2005
2005
|
error: "cm-field-error"
|
|
2006
2006
|
};
|
|
2007
|
-
function
|
|
2007
|
+
function kt(e, t = "") {
|
|
2008
2008
|
return (r, n) => {
|
|
2009
2009
|
const a = ql(n.variant, e);
|
|
2010
2010
|
return a === "none" ? {} : {
|
|
@@ -2028,7 +2028,7 @@ const jl = {
|
|
|
2028
2028
|
inputField: "cm-input-pills-field"
|
|
2029
2029
|
};
|
|
2030
2030
|
function So(e, t = "", r = {}) {
|
|
2031
|
-
const n =
|
|
2031
|
+
const n = kt(e, t);
|
|
2032
2032
|
return (a, i) => ({
|
|
2033
2033
|
...n(a, i),
|
|
2034
2034
|
...jl,
|
|
@@ -2051,10 +2051,10 @@ const Kl = {
|
|
|
2051
2051
|
// Every field's wrapper is also styled under this name (Mantine's useStyles names it
|
|
2052
2052
|
// ["InputWrapper", "Select"]), so this one entry themes the label of every field.
|
|
2053
2053
|
InputWrapper: Ki.extend({ classNames: Wl }),
|
|
2054
|
-
TextInput:
|
|
2054
|
+
TextInput: Ct.extend({
|
|
2055
2055
|
defaultProps: { size: "sm", variant: "filled" },
|
|
2056
|
-
vars: (e, t) => ({ root: {}, wrapper: fe(
|
|
2057
|
-
classNames:
|
|
2056
|
+
vars: (e, t) => ({ root: {}, wrapper: fe(Rt, t == null ? void 0 : t.size) }),
|
|
2057
|
+
classNames: kt("filled")
|
|
2058
2058
|
}),
|
|
2059
2059
|
// No stepper chevrons (spec 6.1): ArrowUp / ArrowDown still step. `hideControls={false}`
|
|
2060
2060
|
// brings Mantine's steppers back for a caller who asks.
|
|
@@ -2062,10 +2062,10 @@ const Kl = {
|
|
|
2062
2062
|
defaultProps: { size: "sm", variant: "filled", hideControls: !0 },
|
|
2063
2063
|
vars: (e, t) => ({
|
|
2064
2064
|
root: {},
|
|
2065
|
-
wrapper: fe(
|
|
2065
|
+
wrapper: fe(Rt, t == null ? void 0 : t.size),
|
|
2066
2066
|
controls: {}
|
|
2067
2067
|
}),
|
|
2068
|
-
classNames:
|
|
2068
|
+
classNames: kt("filled")
|
|
2069
2069
|
}),
|
|
2070
2070
|
// The APG combobox: role="combobox" plus aria-expanded (from ComboboxTarget below), so a
|
|
2071
2071
|
// screen reader hears the list open and the highlight move (aria-activedescendant).
|
|
@@ -2077,13 +2077,13 @@ const Kl = {
|
|
|
2077
2077
|
role: "combobox",
|
|
2078
2078
|
...Yl
|
|
2079
2079
|
},
|
|
2080
|
-
vars: (e, t) => (gn(), cl(), To(
|
|
2080
|
+
vars: (e, t) => (gn(), cl(), To(Rt, t == null ? void 0 : t.size)),
|
|
2081
2081
|
classNames: So("outlined", "cm-select")
|
|
2082
2082
|
}),
|
|
2083
2083
|
NativeSelect: ji.extend({
|
|
2084
2084
|
defaultProps: { size: "sm", variant: "outlined", rightSection: Jo },
|
|
2085
|
-
vars: (e, t) => (gn(), { root: {}, wrapper: fe(
|
|
2086
|
-
classNames:
|
|
2085
|
+
vars: (e, t) => (gn(), { root: {}, wrapper: fe(Rt, t == null ? void 0 : t.size) }),
|
|
2086
|
+
classNames: kt("outlined", "cm-select")
|
|
2087
2087
|
}),
|
|
2088
2088
|
Textarea: Wi.extend({
|
|
2089
2089
|
defaultProps: { size: "sm", variant: "filled" },
|
|
@@ -2100,7 +2100,7 @@ const Kl = {
|
|
|
2100
2100
|
} : {}
|
|
2101
2101
|
}
|
|
2102
2102
|
}),
|
|
2103
|
-
classNames:
|
|
2103
|
+
classNames: kt("filled")
|
|
2104
2104
|
}),
|
|
2105
2105
|
PasswordInput: qi.extend({
|
|
2106
2106
|
defaultProps: {
|
|
@@ -2114,17 +2114,17 @@ const Kl = {
|
|
|
2114
2114
|
},
|
|
2115
2115
|
vars: (e, t) => ({
|
|
2116
2116
|
root: { "--psi-button-size": "24px", "--psi-icon-size": "12px" },
|
|
2117
|
-
wrapper: fe(
|
|
2117
|
+
wrapper: fe(Rt, t == null ? void 0 : t.size)
|
|
2118
2118
|
}),
|
|
2119
2119
|
classNames: (e, t) => ({
|
|
2120
|
-
...
|
|
2120
|
+
...kt("filled")(e, t),
|
|
2121
2121
|
innerInput: "cm-input-inner",
|
|
2122
2122
|
visibilityToggle: "cm-input-toggle"
|
|
2123
2123
|
})
|
|
2124
2124
|
}),
|
|
2125
2125
|
Autocomplete: Gi.extend({
|
|
2126
2126
|
defaultProps: { size: "sm", variant: "filled", role: "combobox", ...Zo },
|
|
2127
|
-
vars: (e, t) => To(
|
|
2127
|
+
vars: (e, t) => To(Rt, t == null ? void 0 : t.size),
|
|
2128
2128
|
classNames: So("filled")
|
|
2129
2129
|
}),
|
|
2130
2130
|
MultiSelect: Ui.extend({
|
|
@@ -2140,13 +2140,13 @@ const Kl = {
|
|
|
2140
2140
|
PillsInput: Fi.extend({
|
|
2141
2141
|
defaultProps: { size: "sm", variant: "filled" },
|
|
2142
2142
|
vars: (e, t) => ({ root: {}, wrapper: fe(Xo, t == null ? void 0 : t.size) }),
|
|
2143
|
-
classNames:
|
|
2143
|
+
classNames: kt("filled", "cm-pills-field")
|
|
2144
2144
|
}),
|
|
2145
2145
|
FileInput: Bi.extend({
|
|
2146
2146
|
defaultProps: { size: "sm", variant: "filled" },
|
|
2147
|
-
vars: (e, t) => ({ root: {}, wrapper: fe(
|
|
2147
|
+
vars: (e, t) => ({ root: {}, wrapper: fe(Rt, t == null ? void 0 : t.size) }),
|
|
2148
2148
|
classNames: (e, t) => ({
|
|
2149
|
-
...
|
|
2149
|
+
...kt("filled")(e, t),
|
|
2150
2150
|
placeholder: "cm-input-placeholder"
|
|
2151
2151
|
})
|
|
2152
2152
|
}),
|
|
@@ -2165,16 +2165,16 @@ const Kl = {
|
|
|
2165
2165
|
} : {}
|
|
2166
2166
|
}
|
|
2167
2167
|
}),
|
|
2168
|
-
classNames:
|
|
2168
|
+
classNames: kt("filled")
|
|
2169
2169
|
}),
|
|
2170
2170
|
// Mantine's combobox targets omit aria-expanded unless asked; every themed target states it.
|
|
2171
2171
|
// What every field's list falls back to for a key its caller's comboboxProps leaves out:
|
|
2172
2172
|
// Mantine replaces a field's whole comboboxProps default with the caller's object, and only
|
|
2173
2173
|
// the Combobox underneath merges key by key (listboxComboboxProps).
|
|
2174
|
-
Combobox:
|
|
2174
|
+
Combobox: Ht.extend({
|
|
2175
2175
|
defaultProps: { ...al() }
|
|
2176
2176
|
}),
|
|
2177
|
-
ComboboxTarget:
|
|
2177
|
+
ComboboxTarget: Ht.Target.extend({
|
|
2178
2178
|
defaultProps: { withExpandedAttribute: !0 }
|
|
2179
2179
|
}),
|
|
2180
2180
|
// The clear (x) of a field: a CloseButton, 16px in the 24px trailing slot (spec 6.2).
|
|
@@ -2333,7 +2333,7 @@ const _l = {
|
|
|
2333
2333
|
offset: 4,
|
|
2334
2334
|
loop: !0,
|
|
2335
2335
|
trapFocus: !0,
|
|
2336
|
-
transitionProps:
|
|
2336
|
+
transitionProps: qt,
|
|
2337
2337
|
middlewares: ul
|
|
2338
2338
|
},
|
|
2339
2339
|
classNames: ll,
|
|
@@ -2350,7 +2350,7 @@ const _l = {
|
|
|
2350
2350
|
closeDelay: 0,
|
|
2351
2351
|
offset: ml,
|
|
2352
2352
|
floatingStrategy: "fixed",
|
|
2353
|
-
transitionProps:
|
|
2353
|
+
transitionProps: qt,
|
|
2354
2354
|
middlewares: { flip: !0, shift: { padding: Oo, crossAxis: !0 } }
|
|
2355
2355
|
}
|
|
2356
2356
|
}),
|
|
@@ -2373,7 +2373,7 @@ const _l = {
|
|
|
2373
2373
|
arrowSize: Ga,
|
|
2374
2374
|
openDelay: hr,
|
|
2375
2375
|
closeDelay: Ro,
|
|
2376
|
-
transitionProps:
|
|
2376
|
+
transitionProps: qt,
|
|
2377
2377
|
events: { hover: !0, focus: !0, touch: !1 },
|
|
2378
2378
|
middlewares: { flip: !0, shift: { padding: Oo } }
|
|
2379
2379
|
},
|
|
@@ -2391,14 +2391,14 @@ const _l = {
|
|
|
2391
2391
|
Popover: ec.extend({
|
|
2392
2392
|
defaultProps: {
|
|
2393
2393
|
zIndex: Yt,
|
|
2394
|
-
transitionProps:
|
|
2394
|
+
transitionProps: qt
|
|
2395
2395
|
},
|
|
2396
2396
|
classNames: wn
|
|
2397
2397
|
}),
|
|
2398
2398
|
HoverCard: $i.extend({
|
|
2399
2399
|
defaultProps: {
|
|
2400
2400
|
zIndex: Yt,
|
|
2401
|
-
transitionProps:
|
|
2401
|
+
transitionProps: qt
|
|
2402
2402
|
},
|
|
2403
2403
|
classNames: wn
|
|
2404
2404
|
}),
|
|
@@ -2407,7 +2407,7 @@ const _l = {
|
|
|
2407
2407
|
defaultProps: {
|
|
2408
2408
|
centered: !0,
|
|
2409
2409
|
withOverlay: !1,
|
|
2410
|
-
transitionProps:
|
|
2410
|
+
transitionProps: qt,
|
|
2411
2411
|
// Mantine's close button is an icon with no text and no label, so it has no
|
|
2412
2412
|
// accessible name (axe: button-name). A caller's own closeButtonProps still win.
|
|
2413
2413
|
closeButtonProps: { "aria-label": "Close" }
|
|
@@ -2683,7 +2683,7 @@ ${vd} {
|
|
|
2683
2683
|
__proto__: null,
|
|
2684
2684
|
default: wd,
|
|
2685
2685
|
highContrastBlock: Pr
|
|
2686
|
-
}, Symbol.toStringTag, { value: "Module" })),
|
|
2686
|
+
}, Symbol.toStringTag, { value: "Module" })), Wt = ':is(:hover, [data-state="hover"])', Nt = ':is(:active, [data-state="press"])', Et = ':is(:focus-visible, [data-state="focus"])', rt = ":not(:disabled, [data-disabled], [data-loading])", Dt = ":is(:disabled, [data-disabled]):not([data-loading])", zn = ':is([data-variant="default"], [data-variant="outline"], [data-variant="danger-outline"])', Qo = ':is([data-variant="default"], [aria-haspopup]:not([aria-haspopup="false"]))', _o = ':is([aria-expanded="true"], [aria-pressed="true"])', _t = '.cm-ai-group > .cm-action-icon:is([data-variant="subtle"], [data-variant="default"], [data-variant="joined"])', kd = `
|
|
2687
2687
|
/* ---------- Button (4.1) ---------- */
|
|
2688
2688
|
.cm-button {
|
|
2689
2689
|
display: inline-flex;
|
|
@@ -2724,16 +2724,16 @@ ${vd} {
|
|
|
2724
2724
|
padding-inline-start: 4px;
|
|
2725
2725
|
color: var(--cm-btn-shortcut, inherit);
|
|
2726
2726
|
}
|
|
2727
|
-
.cm-button${
|
|
2727
|
+
.cm-button${Wt}${rt} {
|
|
2728
2728
|
background-color: var(--button-hover);
|
|
2729
2729
|
color: var(--button-hover-color, var(--button-color));
|
|
2730
2730
|
}
|
|
2731
|
-
.cm-button${
|
|
2731
|
+
.cm-button${Nt}${rt} {
|
|
2732
2732
|
background-color: var(--cm-btn-pressed, var(--button-hover));
|
|
2733
2733
|
color: var(--cm-btn-pressed-color, var(--button-color));
|
|
2734
2734
|
}
|
|
2735
|
-
.cm-button${
|
|
2736
|
-
.cm-button${
|
|
2735
|
+
.cm-button${Nt}${rt} .cm-button-section[data-position="right"] { color: var(--cm-btn-pressed-color); }
|
|
2736
|
+
.cm-button${Et} {
|
|
2737
2737
|
outline: 1px solid var(--cm-border-selected);
|
|
2738
2738
|
outline-offset: 1px;
|
|
2739
2739
|
}
|
|
@@ -2749,19 +2749,19 @@ ${vd} {
|
|
|
2749
2749
|
outline: 1px solid transparent;
|
|
2750
2750
|
outline-offset: 1px;
|
|
2751
2751
|
}
|
|
2752
|
-
.cm-button${zn}${
|
|
2752
|
+
.cm-button${zn}${Et} {
|
|
2753
2753
|
outline: 1px solid var(--cm-btn-outline, transparent);
|
|
2754
2754
|
outline-offset: -1px;
|
|
2755
2755
|
}
|
|
2756
|
-
.cm-button${zn}${
|
|
2757
|
-
.cm-button${
|
|
2756
|
+
.cm-button${zn}${Et}::before { outline-color: var(--cm-border-selected); }
|
|
2757
|
+
.cm-button${Dt} {
|
|
2758
2758
|
background: var(--cm-btn-disabled-bg, var(--mantine-color-disabled));
|
|
2759
2759
|
color: var(--cm-btn-disabled-color, var(--mantine-color-disabled-color));
|
|
2760
2760
|
outline-color: var(--cm-btn-disabled-outline, transparent);
|
|
2761
2761
|
border: var(--button-bd, 1px solid transparent);
|
|
2762
2762
|
cursor: auto;
|
|
2763
2763
|
}
|
|
2764
|
-
.cm-button${
|
|
2764
|
+
.cm-button${Dt} .cm-button-section[data-position="right"] { color: inherit; }
|
|
2765
2765
|
/* Loading: width unchanged, the label fades out, a 16px spinner fades in centered (2.8). */
|
|
2766
2766
|
.cm-button[data-loading] { cursor: progress; }
|
|
2767
2767
|
.cm-button[data-loading] .cm-button-inner { opacity: 0; transform: none; }
|
|
@@ -2787,12 +2787,12 @@ ${vd} {
|
|
|
2787
2787
|
outline-offset: -1px;
|
|
2788
2788
|
}
|
|
2789
2789
|
.cm-action-icon-icon { transition: none; }
|
|
2790
|
-
.cm-action-icon${
|
|
2790
|
+
.cm-action-icon${Wt}${rt} {
|
|
2791
2791
|
background-color: var(--ai-hover);
|
|
2792
2792
|
color: var(--ai-hover-color, var(--ai-color));
|
|
2793
2793
|
}
|
|
2794
|
-
.cm-action-icon${
|
|
2795
|
-
.cm-action-icon${
|
|
2794
|
+
.cm-action-icon${Nt}${rt} { background-color: var(--cm-ai-pressed, var(--ai-hover)); }
|
|
2795
|
+
.cm-action-icon${Et} {
|
|
2796
2796
|
outline: 1px solid var(--cm-border-selected);
|
|
2797
2797
|
outline-offset: 1px;
|
|
2798
2798
|
}
|
|
@@ -2805,26 +2805,26 @@ ${vd} {
|
|
|
2805
2805
|
outline: 1px solid transparent;
|
|
2806
2806
|
outline-offset: 1px;
|
|
2807
2807
|
}
|
|
2808
|
-
.cm-action-icon${Qo}${
|
|
2808
|
+
.cm-action-icon${Qo}${Et} {
|
|
2809
2809
|
outline: 1px solid var(--cm-ai-outline, transparent);
|
|
2810
2810
|
outline-offset: -1px;
|
|
2811
2811
|
}
|
|
2812
|
-
.cm-action-icon${Qo}${
|
|
2812
|
+
.cm-action-icon${Qo}${Et}::before { outline-color: var(--cm-border-selected); }
|
|
2813
2813
|
/* Open (aria-expanded) and toggled on (aria-pressed): selected ground, brand glyph. */
|
|
2814
2814
|
.cm-action-icon${_o}:not(:disabled, [data-disabled]) {
|
|
2815
2815
|
background-color: var(--cm-bg-selected);
|
|
2816
2816
|
color: var(--cm-icon-brand);
|
|
2817
2817
|
}
|
|
2818
|
-
.cm-action-icon${_o}${
|
|
2819
|
-
.cm-action-icon${_o}${
|
|
2820
|
-
.cm-action-icon${
|
|
2818
|
+
.cm-action-icon${_o}${Wt}${rt} { background-color: var(--cm-bg-selected-secondary); }
|
|
2819
|
+
.cm-action-icon${_o}${Nt}${rt} { background-color: var(--cm-bg-selected); }
|
|
2820
|
+
.cm-action-icon${Dt} {
|
|
2821
2821
|
background: var(--cm-ai-disabled-bg, transparent);
|
|
2822
2822
|
color: var(--cm-ai-disabled-color, var(--cm-icon-disabled));
|
|
2823
2823
|
outline-color: var(--cm-ai-disabled-outline, var(--cm-ai-outline, transparent));
|
|
2824
2824
|
border: var(--ai-bd, 1px solid transparent);
|
|
2825
2825
|
cursor: auto;
|
|
2826
2826
|
}
|
|
2827
|
-
.cm-action-icon[aria-pressed="true"]${
|
|
2827
|
+
.cm-action-icon[aria-pressed="true"]${Dt} { background: var(--cm-bg-selected); }
|
|
2828
2828
|
.cm-action-icon[data-loading] { cursor: progress; }
|
|
2829
2829
|
.cm-action-icon[data-loading] .cm-action-icon-icon { opacity: 0; transform: none; }
|
|
2830
2830
|
.cm-action-icon-loader {
|
|
@@ -2849,9 +2849,9 @@ ${_t} {
|
|
|
2849
2849
|
outline-color: transparent;
|
|
2850
2850
|
}
|
|
2851
2851
|
${_t}::before { content: none; }
|
|
2852
|
-
${_t}${
|
|
2853
|
-
${_t}${
|
|
2854
|
-
${_t}${
|
|
2852
|
+
${_t}${Wt}${rt},
|
|
2853
|
+
${_t}${Nt}${rt} { background-color: var(--cm-bg-pressed); }
|
|
2854
|
+
${_t}${Et} {
|
|
2855
2855
|
outline: 1px solid var(--cm-border-selected);
|
|
2856
2856
|
outline-offset: -1px;
|
|
2857
2857
|
}
|
|
@@ -2867,9 +2867,9 @@ ${_t}${zt} {
|
|
|
2867
2867
|
outline: 1px solid transparent;
|
|
2868
2868
|
outline-offset: -1px;
|
|
2869
2869
|
}
|
|
2870
|
-
.cm-close-button${
|
|
2871
|
-
.cm-close-button${
|
|
2872
|
-
.cm-close-button${
|
|
2870
|
+
.cm-close-button${Wt}:not(:disabled, [data-disabled]) { background-color: var(--cm-bg-transparent-hover); }
|
|
2871
|
+
.cm-close-button${Nt}:not(:disabled, [data-disabled]) { background-color: var(--cm-bg-transparent-pressed); }
|
|
2872
|
+
.cm-close-button${Et} {
|
|
2873
2873
|
outline: 1px solid var(--cm-border-selected);
|
|
2874
2874
|
outline-offset: 1px;
|
|
2875
2875
|
}
|
|
@@ -2889,17 +2889,15 @@ ${_t}${zt} {
|
|
|
2889
2889
|
background-color: var(--ai-bg);
|
|
2890
2890
|
color: var(--ai-color);
|
|
2891
2891
|
}
|
|
2892
|
-
.cm-toggle-icon[data-swap][aria-pressed="true"]${
|
|
2893
|
-
.cm-toggle-icon[data-swap][aria-pressed="true"]${
|
|
2894
|
-
.cm-toggle-icon[data-swap][aria-pressed="true"]${
|
|
2895
|
-
/* Disabled
|
|
2896
|
-
|
|
2897
|
-
|
|
2898
|
-
|
|
2899
|
-
.cm-toggle-icon
|
|
2900
|
-
.cm-toggle-icon:not([data-swap])[aria-pressed="true"]${
|
|
2901
|
-
.cm-toggle-icon:not([data-swap])[aria-pressed="true"]${mt}${Ct} { background-color: var(--cm-bg-selected-secondary); }
|
|
2902
|
-
.cm-toggle-icon:not([data-swap])[aria-pressed="true"]${mt}${gt} { background-color: var(--cm-bg-selected); }
|
|
2892
|
+
.cm-toggle-icon[data-swap][aria-pressed="true"]${Wt}${rt} { background-color: var(--ai-hover); }
|
|
2893
|
+
.cm-toggle-icon[data-swap][aria-pressed="true"]${Nt}${rt} { background-color: var(--cm-ai-pressed); }
|
|
2894
|
+
.cm-toggle-icon[data-swap][aria-pressed="true"]${Dt} { background: transparent; }
|
|
2895
|
+
/* Disabled (spec 4.4, "disabled off / on"): the glyph takes --cm-icon-disabled and an "on" toggle
|
|
2896
|
+
sits on --cm-bg-disabled (the swap variant is never filled); the pointer states paint nothing.
|
|
2897
|
+
Figma's capture (bc/toggle-icon-off|on-disabled--*) draws it like the enabled toggle, which left
|
|
2898
|
+
a disabled toggle indistinguishable from an enabled one (issue #2102); the spec text wins. */
|
|
2899
|
+
.cm-toggle-icon${Dt} { color: var(--cm-icon-disabled); }
|
|
2900
|
+
.cm-toggle-icon:not([data-swap])[aria-pressed="true"]${Dt} { background: var(--cm-bg-disabled); }
|
|
2903
2901
|
|
|
2904
2902
|
/* ---------- SplitButton (4.5) ---------- */
|
|
2905
2903
|
.cm-split {
|
|
@@ -2916,7 +2914,7 @@ ${_t}${zt} {
|
|
|
2916
2914
|
}
|
|
2917
2915
|
/* Hovering either half lights both, so they read as one control with a 1px seam. */
|
|
2918
2916
|
.cm-split:is(:hover, [data-state="hover"]) > .cm-action-icon${rt} { background-color: var(--cm-bg-transparent-hover); }
|
|
2919
|
-
.cm-split > .cm-action-icon${
|
|
2917
|
+
.cm-split > .cm-action-icon${Nt}${rt} { background-color: var(--cm-bg-transparent-pressed); }
|
|
2920
2918
|
/* The chevron while its menu is open: selected ground, brand caret, square (header-and-modes/present-dropdown-open #73). */
|
|
2921
2919
|
.cm-split > .cm-split-chevron[aria-expanded="true"]:not(:disabled, [data-disabled]) {
|
|
2922
2920
|
background-color: var(--cm-bg-selected);
|
|
@@ -3723,8 +3721,19 @@ ${_t}${zt} {
|
|
|
3723
3721
|
.cm-input-wrapper[data-disabled],
|
|
3724
3722
|
.cm-input-wrapper:has(:disabled) {
|
|
3725
3723
|
--input-color: var(--cm-text-disabled);
|
|
3724
|
+
--input-placeholder-color: var(--cm-text-disabled);
|
|
3726
3725
|
--input-section-color: var(--cm-text-disabled);
|
|
3727
3726
|
}
|
|
3727
|
+
/* A disabled field's placeholder dims with its value (spec 6, bc/number-input-disabled): an
|
|
3728
|
+
empty disabled field otherwise reads exactly like an enabled one. Set on the pseudo-element
|
|
3729
|
+
itself, so a caller's inline --input-placeholder-color (PanelField sets one) cannot undo it. */
|
|
3730
|
+
.cm-input-wrapper .cm-input:disabled::placeholder,
|
|
3731
|
+
.cm-input-wrapper .cm-input:disabled ::placeholder,
|
|
3732
|
+
.cm-input-wrapper:is([data-disabled], :has(:disabled)) .cm-input-inner::placeholder,
|
|
3733
|
+
.cm-input-wrapper:is([data-disabled], :has(:disabled)) .cm-input-placeholder,
|
|
3734
|
+
.cm-field:is([data-disabled], :has(:disabled)) ::placeholder {
|
|
3735
|
+
color: var(--cm-text-disabled);
|
|
3736
|
+
}
|
|
3728
3737
|
.cm-input-wrapper .cm-input-section {
|
|
3729
3738
|
color: var(--input-section-color);
|
|
3730
3739
|
}
|
|
@@ -6674,11 +6683,11 @@ function Fd(e = {}) {
|
|
|
6674
6683
|
return e.highContrast ? `${Ln}
|
|
6675
6684
|
${Pr(":root, :host")}` : Ln;
|
|
6676
6685
|
}
|
|
6677
|
-
let
|
|
6686
|
+
let yt = null;
|
|
6678
6687
|
function Fo(e = {}) {
|
|
6679
6688
|
if (typeof document > "u")
|
|
6680
6689
|
return;
|
|
6681
|
-
|
|
6690
|
+
yt != null && yt.isConnected || (yt = document.head.querySelector(`style[${Pn}]`), yt || (yt = document.createElement("style"), yt.setAttribute(Pn, ""), yt.textContent = Fd(), document.head.appendChild(yt)));
|
|
6682
6691
|
const t = e.highContrast ? "high" : "figma", r = document.documentElement;
|
|
6683
6692
|
r.getAttribute(On) !== t && r.setAttribute(On, t);
|
|
6684
6693
|
}
|
|
@@ -6760,18 +6769,18 @@ function Yd(e) {
|
|
|
6760
6769
|
return /^#?([A-Fa-f0-9]{3}|[A-Fa-f0-9]{4}|[A-Fa-f0-9]{6}|[A-Fa-f0-9]{8})$/.test(e);
|
|
6761
6770
|
}
|
|
6762
6771
|
const Kd = 224;
|
|
6763
|
-
function
|
|
6772
|
+
function vt(e) {
|
|
6764
6773
|
if (!Yd(e))
|
|
6765
6774
|
return;
|
|
6766
6775
|
let t = e.replace("#", "");
|
|
6767
6776
|
return t.length <= 4 && (t = t.replace(/./g, "$&$&")), t.length === 6 && (t += "ff"), `#${t.toUpperCase()}`;
|
|
6768
6777
|
}
|
|
6769
6778
|
function Xd(e) {
|
|
6770
|
-
const t =
|
|
6779
|
+
const t = vt(e);
|
|
6771
6780
|
return t === void 0 ? !1 : [1, 3, 5].every((r) => Number.parseInt(t.slice(r, r + 2), 16) >= Kd);
|
|
6772
6781
|
}
|
|
6773
6782
|
function Jd(e, t, r) {
|
|
6774
|
-
const n =
|
|
6783
|
+
const n = vt(e) ?? "#000000FF", a = vt(t) ?? "#000000FF", i = (l) => {
|
|
6775
6784
|
const c = Number.parseInt(n.slice(l, l + 2), 16), d = Number.parseInt(a.slice(l, l + 2), 16);
|
|
6776
6785
|
return Math.round(c + (d - c) * r).toString(16).padStart(2, "0");
|
|
6777
6786
|
};
|
|
@@ -6810,14 +6819,14 @@ function po({
|
|
|
6810
6819
|
describedBy: d === void 0 ? void 0 : i
|
|
6811
6820
|
};
|
|
6812
6821
|
}
|
|
6813
|
-
function
|
|
6822
|
+
function St(e) {
|
|
6814
6823
|
const t = K(void 0);
|
|
6815
6824
|
Se(() => {
|
|
6816
6825
|
process.env.NODE_ENV === "production" || e === void 0 || t.current !== e && (t.current = e, console.warn(e));
|
|
6817
6826
|
}, [e]);
|
|
6818
6827
|
}
|
|
6819
6828
|
function Rr({ color: e, variant: t }) {
|
|
6820
|
-
const r =
|
|
6829
|
+
const r = vt(e) ?? "#000000FF", n = r.slice(0, 7), a = !r.endsWith("FF");
|
|
6821
6830
|
return /* @__PURE__ */ o(
|
|
6822
6831
|
ga,
|
|
6823
6832
|
{
|
|
@@ -6852,7 +6861,7 @@ function Qa({
|
|
|
6852
6861
|
onFocus: c,
|
|
6853
6862
|
onBlur: d
|
|
6854
6863
|
}) {
|
|
6855
|
-
const s =
|
|
6864
|
+
const s = Lt({ maximumFractionDigits: 2 }), u = mo(), [p, h] = me(s.format(e)), b = K(null), y = K(null);
|
|
6856
6865
|
Se(() => {
|
|
6857
6866
|
h(s.format(e));
|
|
6858
6867
|
}, [e, s]);
|
|
@@ -6951,29 +6960,29 @@ const tu = {
|
|
|
6951
6960
|
{ value: "hsl", label: "HSL" },
|
|
6952
6961
|
{ value: "hsb", label: "HSB" }
|
|
6953
6962
|
];
|
|
6954
|
-
function
|
|
6963
|
+
function bt(e, t) {
|
|
6955
6964
|
return Math.min(t, Math.max(0, e));
|
|
6956
6965
|
}
|
|
6957
|
-
function
|
|
6966
|
+
function Mt(e) {
|
|
6958
6967
|
return ya("hexa", e).toUpperCase();
|
|
6959
6968
|
}
|
|
6960
6969
|
function Eo(e, t) {
|
|
6961
|
-
return t === "hex" ?
|
|
6970
|
+
return t === "hex" ? Mt(e).slice(1, 7) : t === "hsb" ? [e.h, e.s, e.v].map((n) => Math.round(n)).join(", ") : (ya(t, e).match(/[\d.]+/g) ?? []).map((n) => Math.round(Number(n))).join(", ");
|
|
6962
6971
|
}
|
|
6963
6972
|
function ru(e, t, r) {
|
|
6964
6973
|
if (t === "hex") {
|
|
6965
6974
|
const i = e.trim().replace("#", "");
|
|
6966
6975
|
if (i.length !== 3 && i.length !== 6)
|
|
6967
6976
|
return;
|
|
6968
|
-
const l =
|
|
6977
|
+
const l = vt(i);
|
|
6969
6978
|
return l === void 0 ? void 0 : { ...no(l.slice(0, 7)), a: r };
|
|
6970
6979
|
}
|
|
6971
6980
|
const n = e.split(/[\s,]+/).filter(Boolean).map(Number);
|
|
6972
6981
|
if (n.length !== 3 || n.some(Number.isNaN))
|
|
6973
6982
|
return;
|
|
6974
6983
|
if (t === "hsb")
|
|
6975
|
-
return { h:
|
|
6976
|
-
const a = t === "rgb" ? `rgb(${
|
|
6984
|
+
return { h: bt(n[0], 360), s: bt(n[1], 100), v: bt(n[2], 100), a: r };
|
|
6985
|
+
const a = t === "rgb" ? `rgb(${bt(n[0], 255)}, ${bt(n[1], 255)}, ${bt(n[2], 255)})` : `hsl(${bt(n[0], 360)}, ${bt(n[1], 100)}%, ${bt(n[2], 100)}%)`;
|
|
6977
6986
|
return ac(a) ? { ...no(a), a: r } : void 0;
|
|
6978
6987
|
}
|
|
6979
6988
|
function Dn(e, t, r) {
|
|
@@ -6986,7 +6995,7 @@ function Dn(e, t, r) {
|
|
|
6986
6995
|
Home: 0,
|
|
6987
6996
|
End: e
|
|
6988
6997
|
};
|
|
6989
|
-
n.key in l && (n.preventDefault(), n.stopPropagation(), r(Math.round(
|
|
6998
|
+
n.key in l && (n.preventDefault(), n.stopPropagation(), r(Math.round(bt(l[n.key], e) / a) * a));
|
|
6990
6999
|
};
|
|
6991
7000
|
}
|
|
6992
7001
|
function nu() {
|
|
@@ -7013,22 +7022,22 @@ function _a({
|
|
|
7013
7022
|
onPaintTypeChange: d,
|
|
7014
7023
|
labels: s
|
|
7015
7024
|
}) {
|
|
7016
|
-
const u = { ...tu, ...s }, [p, h] = me(() => no(
|
|
7025
|
+
const u = { ...tu, ...s }, [p, h] = me(() => no(vt(e) ?? "#000000FF")), b = K(p);
|
|
7017
7026
|
b.current = p;
|
|
7018
7027
|
const [y, w] = me(i), [A, f] = me(Eo(p, y));
|
|
7019
7028
|
Se(() => {
|
|
7020
|
-
const R =
|
|
7021
|
-
R !== void 0 && R !==
|
|
7029
|
+
const R = vt(e);
|
|
7030
|
+
R !== void 0 && R !== Mt(b.current) && h(no(R));
|
|
7022
7031
|
}, [e]), Se(() => {
|
|
7023
7032
|
f(Eo(p, y));
|
|
7024
7033
|
}, [p, y]);
|
|
7025
7034
|
const x = (R) => n ? R : R.slice(0, 7), N = (R) => {
|
|
7026
7035
|
const L = { ...R, a: n ? R.a : 1 };
|
|
7027
|
-
h(L), b.current = L, t(x(
|
|
7036
|
+
h(L), b.current = L, t(x(Mt(L)));
|
|
7028
7037
|
}, S = () => {
|
|
7029
|
-
r == null || r(x(
|
|
7038
|
+
r == null || r(x(Mt(b.current)));
|
|
7030
7039
|
}, m = (R) => {
|
|
7031
|
-
const L =
|
|
7040
|
+
const L = vt(R);
|
|
7032
7041
|
if (L === void 0)
|
|
7033
7042
|
return;
|
|
7034
7043
|
const T = no(n ? L : L.slice(0, 7));
|
|
@@ -7058,13 +7067,13 @@ function _a({
|
|
|
7058
7067
|
f(Eo(b.current, y));
|
|
7059
7068
|
return;
|
|
7060
7069
|
}
|
|
7061
|
-
|
|
7070
|
+
Mt(R) !== Mt(b.current) && (N(R), S());
|
|
7062
7071
|
}, V = typeof window > "u" ? void 0 : window.EyeDropper, W = () => {
|
|
7063
7072
|
V !== void 0 && new V().open().then((R) => {
|
|
7064
7073
|
m(`${R.sRGBHex}${Or(b.current.a * 100)}`);
|
|
7065
7074
|
}).catch(() => {
|
|
7066
7075
|
});
|
|
7067
|
-
}, $ =
|
|
7076
|
+
}, $ = Mt(p).slice(0, 7), H = Math.round(p.a * 100), re = l !== void 0 && c === "gradient";
|
|
7068
7077
|
return /* @__PURE__ */ v("div", { className: "cm-color-picker", "data-testid": "color-picker-panel", children: [
|
|
7069
7078
|
l !== void 0 && /* @__PURE__ */ o("div", { className: "cm-color-picker-types", children: /* @__PURE__ */ o(
|
|
7070
7079
|
Ar,
|
|
@@ -7235,7 +7244,7 @@ function _a({
|
|
|
7235
7244
|
] })
|
|
7236
7245
|
] });
|
|
7237
7246
|
}
|
|
7238
|
-
const $a =
|
|
7247
|
+
const $a = It(null);
|
|
7239
7248
|
function iu() {
|
|
7240
7249
|
return dt($a);
|
|
7241
7250
|
}
|
|
@@ -7294,14 +7303,14 @@ function uu(e, t = !0) {
|
|
|
7294
7303
|
};
|
|
7295
7304
|
}, [e, t]);
|
|
7296
7305
|
}
|
|
7297
|
-
const ei =
|
|
7306
|
+
const ei = It(null);
|
|
7298
7307
|
function eh({ id: e, children: t }) {
|
|
7299
7308
|
return /* @__PURE__ */ o(ei.Provider, { value: e, children: t });
|
|
7300
7309
|
}
|
|
7301
7310
|
function mu() {
|
|
7302
7311
|
return dt(ei);
|
|
7303
7312
|
}
|
|
7304
|
-
const Dr =
|
|
7313
|
+
const Dr = It(null), Mr = It(null);
|
|
7305
7314
|
function Vo() {
|
|
7306
7315
|
const e = dt(Dr);
|
|
7307
7316
|
if (!e)
|
|
@@ -7536,7 +7545,7 @@ function hu({ children: e }) {
|
|
|
7536
7545
|
/* @__PURE__ */ o("div", { ref: r, "data-popout-portal-container": !0, style: { display: "contents" } })
|
|
7537
7546
|
] });
|
|
7538
7547
|
}
|
|
7539
|
-
function
|
|
7548
|
+
function wt() {
|
|
7540
7549
|
return ic().dir;
|
|
7541
7550
|
}
|
|
7542
7551
|
function $e(e) {
|
|
@@ -7773,7 +7782,7 @@ function Au(e, t) {
|
|
|
7773
7782
|
return `${e}-panel-${t ?? ""}`;
|
|
7774
7783
|
}
|
|
7775
7784
|
function Nu(e) {
|
|
7776
|
-
var ut,
|
|
7785
|
+
var ut, mt;
|
|
7777
7786
|
const {
|
|
7778
7787
|
width: t,
|
|
7779
7788
|
height: r,
|
|
@@ -7790,7 +7799,7 @@ function Nu(e) {
|
|
|
7790
7799
|
onDragStart: b,
|
|
7791
7800
|
onDrag: y,
|
|
7792
7801
|
onDragEnd: w
|
|
7793
|
-
} = e, { isOpen: A, close: f, triggerRef: x, id: N, parentId: S, region: m, exclusive: z = !0 } = Vo(), { getZIndex: E, portalContainer: C, register: V, unregister: W, bringToFront: $, closeDescendants: H } = oi(), re = iu(), R =
|
|
7802
|
+
} = e, { isOpen: A, close: f, triggerRef: x, id: N, parentId: S, region: m, exclusive: z = !0 } = Vo(), { getZIndex: E, portalContainer: C, register: V, unregister: W, bringToFront: $, closeDescendants: H } = oi(), re = iu(), R = wt(), L = ze(), T = `popout-panel-${N}`, j = `popout-title-${L}`, P = `popout-tabs-${L}`, [D, ee] = me(null), G = K(!1), J = K(null), ie = K(null), de = ce(() => {
|
|
7794
7803
|
$(N);
|
|
7795
7804
|
}, [$, N]), { dragTriggerProps: pe, dragOffset: Be, resetDragOffset: Re, hasDragged: X, consumeDragClick: be } = xu({
|
|
7796
7805
|
isOpen: A,
|
|
@@ -7847,8 +7856,8 @@ function Nu(e) {
|
|
|
7847
7856
|
direction: R
|
|
7848
7857
|
});
|
|
7849
7858
|
if (typeof window < "u") {
|
|
7850
|
-
const tt = window.innerHeight - We,
|
|
7851
|
-
ye.top = Math.max(0, Math.min(ye.top, tt)), ye.left = Math.max(0, Math.min(ye.left,
|
|
7859
|
+
const tt = window.innerHeight - We, pt = window.innerWidth - Je;
|
|
7860
|
+
ye.top = Math.max(0, Math.min(ye.top, tt)), ye.left = Math.max(0, Math.min(ye.left, pt));
|
|
7852
7861
|
}
|
|
7853
7862
|
ye.left = (ye.left - De.x) / De.scaleX, ye.top = (ye.top - De.y) / De.scaleY, ee((tt) => (tt == null ? void 0 : tt.left) === ye.left && tt.top === ye.top ? tt : ye);
|
|
7854
7863
|
}, [Ce, t, r, d, s, g, R]);
|
|
@@ -7898,7 +7907,7 @@ function Nu(e) {
|
|
|
7898
7907
|
const Ge = E(N), qe = {
|
|
7899
7908
|
left: ((D == null ? void 0 : D.left) ?? 0) + Be.left,
|
|
7900
7909
|
top: ((D == null ? void 0 : D.top) ?? 0) + Be.top
|
|
7901
|
-
},
|
|
7910
|
+
}, At = /* @__PURE__ */ v(
|
|
7902
7911
|
O,
|
|
7903
7912
|
{
|
|
7904
7913
|
ref: J,
|
|
@@ -7946,7 +7955,7 @@ function Nu(e) {
|
|
|
7946
7955
|
role: "tabpanel",
|
|
7947
7956
|
id: Au(P, Ne),
|
|
7948
7957
|
"aria-labelledby": Tu(P, Ne),
|
|
7949
|
-
children: (
|
|
7958
|
+
children: (mt = ve == null ? void 0 : ve.tabs.find((ae) => ae.id === Ne)) == null ? void 0 : mt.content
|
|
7950
7959
|
}
|
|
7951
7960
|
) : /* @__PURE__ */ o(O, { "data-testid": "popout-panel-content", children: i })
|
|
7952
7961
|
]
|
|
@@ -7955,7 +7964,7 @@ function Nu(e) {
|
|
|
7955
7964
|
return wc(
|
|
7956
7965
|
/* @__PURE__ */ v(Z, { children: [
|
|
7957
7966
|
/* @__PURE__ */ o("div", { ref: ie, "aria-hidden": "true", style: { position: "fixed", left: 0, top: 0 } }),
|
|
7958
|
-
|
|
7967
|
+
At
|
|
7959
7968
|
] }),
|
|
7960
7969
|
C
|
|
7961
7970
|
);
|
|
@@ -8034,7 +8043,7 @@ function rh({
|
|
|
8034
8043
|
showReset: y = !0
|
|
8035
8044
|
}) {
|
|
8036
8045
|
const w = Ee(), A = ze(), f = po({ name: c, disabled: s, disabledReason: u }), x = l !== void 0;
|
|
8037
|
-
|
|
8046
|
+
St(
|
|
8038
8047
|
x && (a !== void 0 || i !== void 0) ? "CompactColorInput was given onChange together with onColorChange or onOpacityChange. Only onChange is called; drop the other callbacks." : void 0
|
|
8039
8048
|
);
|
|
8040
8049
|
const [N, S] = xe({
|
|
@@ -8055,7 +8064,7 @@ function rh({
|
|
|
8055
8064
|
const J = G.length === Un, ie = G.slice(0, er).toUpperCase(), de = J && d, pe = de ? Ja(G.slice(er, Un)) : m;
|
|
8056
8065
|
S(ie), de && z(pe), l == null || l(ie, pe);
|
|
8057
8066
|
}, T = (G) => {
|
|
8058
|
-
const J = re.trim().replace("#", ""), ie = J.length === 3 || J.length === 6 ?
|
|
8067
|
+
const J = re.trim().replace("#", ""), ie = J.length === 3 || J.length === 6 ? vt(J) : void 0, de = ie == null ? void 0 : ie.slice(0, er);
|
|
8059
8068
|
de !== void 0 && de !== W.toUpperCase() ? (S(de, G), l == null || l(de, m, G)) : R(H(W));
|
|
8060
8069
|
}, j = (G, J) => {
|
|
8061
8070
|
z(G, J), l == null || l(N, G, J);
|
|
@@ -8286,7 +8295,7 @@ function Ru({
|
|
|
8286
8295
|
function bo(e) {
|
|
8287
8296
|
return e != null && e !== !1;
|
|
8288
8297
|
}
|
|
8289
|
-
function
|
|
8298
|
+
function Tt({ children: e }) {
|
|
8290
8299
|
return /* @__PURE__ */ o(
|
|
8291
8300
|
O,
|
|
8292
8301
|
{
|
|
@@ -8355,13 +8364,13 @@ function ah(e) {
|
|
|
8355
8364
|
summary: p,
|
|
8356
8365
|
children: h,
|
|
8357
8366
|
collapsible: b = !0
|
|
8358
|
-
} = e, y = Ee(), w =
|
|
8367
|
+
} = e, y = Ee(), w = wt(), A = ze(), f = ze(), x = ze(), N = ze(), [S, m] = xe({
|
|
8359
8368
|
value: n,
|
|
8360
8369
|
defaultValue: a,
|
|
8361
8370
|
finalValue: !0,
|
|
8362
8371
|
onChange: i
|
|
8363
8372
|
}), z = !c && Ye.Children.toArray(h).length > 0, E = s != null, C = z && b, V = z && (!b || S), W = C && !S && p !== void 0 && p !== null && p !== "";
|
|
8364
|
-
|
|
8373
|
+
St(
|
|
8365
8374
|
c || z ? void 0 : `ControlSection "${t}" was given no children, and it holds the rows of a section. Pass the rows, set "empty" to draw it as a single row with a "+", or do not render it: a section header whose chevron opens onto nothing is a dead end for the reader.`
|
|
8366
8375
|
);
|
|
8367
8376
|
const $ = (T) => {
|
|
@@ -8454,7 +8463,7 @@ function ah(e) {
|
|
|
8454
8463
|
),
|
|
8455
8464
|
E && /* @__PURE__ */ o(Ru, { label: t, children: s }),
|
|
8456
8465
|
u != null && /* @__PURE__ */ o(O, { "data-testid": "control-section-actions", className: "cm-section-actions", children: u }),
|
|
8457
|
-
c && d !== void 0 && /* @__PURE__ */ o(
|
|
8466
|
+
c && d !== void 0 && /* @__PURE__ */ o(Tt, { children: /* @__PURE__ */ o(
|
|
8458
8467
|
He,
|
|
8459
8468
|
{
|
|
8460
8469
|
type: "button",
|
|
@@ -8493,7 +8502,7 @@ function ah(e) {
|
|
|
8493
8502
|
}
|
|
8494
8503
|
function ih(e) {
|
|
8495
8504
|
Le();
|
|
8496
|
-
const { label: t, opened: r, defaultOpened: n, onOpenChange: a, children: i } = e, l = Ee(), c =
|
|
8505
|
+
const { label: t, opened: r, defaultOpened: n, onOpenChange: a, children: i } = e, l = Ee(), c = wt(), d = ze(), s = ze(), [u, p] = xe({
|
|
8497
8506
|
value: r,
|
|
8498
8507
|
defaultValue: n,
|
|
8499
8508
|
finalValue: !1,
|
|
@@ -8560,7 +8569,7 @@ function Mu(e) {
|
|
|
8560
8569
|
return he(() => ({ ...t, ...e }), [t, e]);
|
|
8561
8570
|
}
|
|
8562
8571
|
const je = -1;
|
|
8563
|
-
function
|
|
8572
|
+
function Ft(e, t, r) {
|
|
8564
8573
|
return Math.min(Math.max(e, t), r);
|
|
8565
8574
|
}
|
|
8566
8575
|
function Hu(e, t, r, n, a) {
|
|
@@ -8573,23 +8582,23 @@ function Hu(e, t, r, n, a) {
|
|
|
8573
8582
|
if (t === p)
|
|
8574
8583
|
return { row: e.row, column: Math.max(e.column - 1, 0) };
|
|
8575
8584
|
if (t === "ArrowDown")
|
|
8576
|
-
return { row:
|
|
8585
|
+
return { row: Ft(e.row + 1, je, d), column: e.column };
|
|
8577
8586
|
if (t === "ArrowUp")
|
|
8578
|
-
return { row:
|
|
8587
|
+
return { row: Ft(e.row - 1, je, d), column: e.column };
|
|
8579
8588
|
if (t === "Home")
|
|
8580
8589
|
return a.jumpToEnd ? { row: je, column: 0 } : { row: e.row, column: 0 };
|
|
8581
8590
|
if (t === "End")
|
|
8582
8591
|
return a.jumpToEnd ? { row: Math.max(d, je), column: s } : { row: e.row, column: s };
|
|
8583
8592
|
if (t === "PageDown")
|
|
8584
|
-
return { row:
|
|
8593
|
+
return { row: Ft(Math.max(e.row, 0) + c, 0, Math.max(d, 0)), column: e.column };
|
|
8585
8594
|
if (t === "PageUp")
|
|
8586
|
-
return { row:
|
|
8595
|
+
return { row: Ft(Math.max(e.row, 0) - c, 0, Math.max(d, 0)), column: e.column };
|
|
8587
8596
|
}
|
|
8588
8597
|
function Bu(e, t) {
|
|
8589
8598
|
const r = t.rowCount - 1, n = Math.max(t.columnCount - 1, 0);
|
|
8590
8599
|
return {
|
|
8591
|
-
row:
|
|
8592
|
-
column:
|
|
8600
|
+
row: Ft(e.row, je, Math.max(r, je)),
|
|
8601
|
+
column: Ft(e.column, 0, n)
|
|
8593
8602
|
};
|
|
8594
8603
|
}
|
|
8595
8604
|
function Co(e, t) {
|
|
@@ -8693,7 +8702,7 @@ function Ku(e, t) {
|
|
|
8693
8702
|
onFocus: D,
|
|
8694
8703
|
onBlur: ee,
|
|
8695
8704
|
empty: G
|
|
8696
|
-
} = e, J = Mu(u), ie =
|
|
8705
|
+
} = e, J = Mu(u), ie = wt(), de = Jt(), pe = Lt(), Be = Fl({ numeric: !0, sensitivity: "variant" }), Re = he(() => new Intl.DateTimeFormat(de), [de]), X = he(
|
|
8697
8706
|
() => ({ number: pe, date: Re, yes: J.yes, no: J.no }),
|
|
8698
8707
|
[pe, Re, J.yes, J.no]
|
|
8699
8708
|
), [be, ge] = xe({
|
|
@@ -8759,10 +8768,10 @@ function Ku(e, t) {
|
|
|
8759
8768
|
sortFn: (M, q) => Gu(k.value(M.original), k.value(q.original), Be)
|
|
8760
8769
|
})),
|
|
8761
8770
|
[l, Be]
|
|
8762
|
-
),
|
|
8771
|
+
), At = JSON.stringify(ve), ut = he(
|
|
8763
8772
|
() => ve.map((k) => ({ id: k.id, desc: k.desc })),
|
|
8764
|
-
[
|
|
8765
|
-
),
|
|
8773
|
+
[At]
|
|
8774
|
+
), mt = he(() => {
|
|
8766
8775
|
const k = {};
|
|
8767
8776
|
for (const M of Ne)
|
|
8768
8777
|
k[M] = !1;
|
|
@@ -8794,7 +8803,7 @@ function Ku(e, t) {
|
|
|
8794
8803
|
},
|
|
8795
8804
|
state: {
|
|
8796
8805
|
sorting: ut,
|
|
8797
|
-
columnVisibility:
|
|
8806
|
+
columnVisibility: mt,
|
|
8798
8807
|
columnOrder: le,
|
|
8799
8808
|
rowSelection: ae,
|
|
8800
8809
|
globalFilter: Fe
|
|
@@ -8807,7 +8816,7 @@ function Ku(e, t) {
|
|
|
8807
8816
|
);
|
|
8808
8817
|
},
|
|
8809
8818
|
onColumnVisibilityChange: (k) => {
|
|
8810
|
-
const M = wo(k,
|
|
8819
|
+
const M = wo(k, mt);
|
|
8811
8820
|
B(Object.keys(M).filter((q) => !M[q]));
|
|
8812
8821
|
},
|
|
8813
8822
|
onColumnOrderChange: (k) => {
|
|
@@ -8822,19 +8831,19 @@ function Ku(e, t) {
|
|
|
8822
8831
|
}, Ze = [
|
|
8823
8832
|
...We.filter((k) => Me(k.id)),
|
|
8824
8833
|
...We.filter((k) => !Me(k.id))
|
|
8825
|
-
], Qe = n ?? Je.length, se = Ze.length, ye = he(() => Je.map((k) => k.id), [Je]), _e = K(null), tt = K(null),
|
|
8834
|
+
], Qe = n ?? Je.length, se = Ze.length, ye = he(() => Je.map((k) => k.id), [Je]), _e = K(null), tt = K(null), pt = Na({
|
|
8826
8835
|
count: Qe,
|
|
8827
8836
|
getScrollElement: () => _e.current,
|
|
8828
8837
|
estimateSize: () => h,
|
|
8829
8838
|
gap: zo,
|
|
8830
8839
|
getItemKey: (k) => ye[k - Pe] ?? k,
|
|
8831
8840
|
overscan: y
|
|
8832
|
-
}), Uo =
|
|
8841
|
+
}), Uo = pt.getVirtualItems(), Gr = (($r = Uo[0]) == null ? void 0 : $r.index) ?? 0, qr = (((en = Uo.at(-1)) == null ? void 0 : en.index) ?? -1) + 1;
|
|
8833
8842
|
Se(() => {
|
|
8834
8843
|
i == null || i(Gr, qr);
|
|
8835
8844
|
}, [Gr, qr]);
|
|
8836
|
-
const [Wr,
|
|
8837
|
-
k.row >= 0 &&
|
|
8845
|
+
const [Wr, Ut] = me({ row: je, column: 0 }), [vi, jr] = me(null), ot = he(() => Bu(Wr, { rowCount: Qe, columnCount: se }), [Wr, Qe, se]), Go = K(!1), qo = K(void 0), Yr = (k) => {
|
|
8846
|
+
k.row >= 0 && pt.scrollToIndex(k.row), Go.current = !0, Ut((M) => Co(M, k) ? M : k);
|
|
8838
8847
|
};
|
|
8839
8848
|
so(() => {
|
|
8840
8849
|
var q;
|
|
@@ -8867,11 +8876,11 @@ function Ku(e, t) {
|
|
|
8867
8876
|
const k = ((q = _e.current) == null ? void 0 : q.clientHeight) ?? 0, M = Math.floor((k === 0 ? h * 10 : k) / h);
|
|
8868
8877
|
return Math.max(1, M - 1);
|
|
8869
8878
|
}, ki = (k) => {
|
|
8870
|
-
var Ke,
|
|
8879
|
+
var Ke, Pt;
|
|
8871
8880
|
if (!(k.target instanceof Node) || ((Ke = tt.current) == null ? void 0 : Ke.contains(k.target)) !== !0)
|
|
8872
8881
|
return;
|
|
8873
8882
|
const M = ot.row === je ? Ze[ot.column] : void 0;
|
|
8874
|
-
if (M !== void 0 && ((
|
|
8883
|
+
if (M !== void 0 && ((Pt = _.get(M.id)) == null ? void 0 : Pt.menu) !== void 0 && (k.altKey && k.key === "ArrowDown" || k.shiftKey && k.key === "F10" || k.key === "ContextMenu")) {
|
|
8875
8884
|
k.preventDefault(), k.stopPropagation(), jr(M.id);
|
|
8876
8885
|
return;
|
|
8877
8886
|
}
|
|
@@ -8893,7 +8902,7 @@ function Ku(e, t) {
|
|
|
8893
8902
|
t,
|
|
8894
8903
|
() => ({
|
|
8895
8904
|
scrollToRow: (k) => {
|
|
8896
|
-
k >= 0 && k < Qe &&
|
|
8905
|
+
k >= 0 && k < Qe && pt.scrollToIndex(k);
|
|
8897
8906
|
},
|
|
8898
8907
|
setColumnHidden: (k, M) => {
|
|
8899
8908
|
var q;
|
|
@@ -8901,13 +8910,13 @@ function Ku(e, t) {
|
|
|
8901
8910
|
},
|
|
8902
8911
|
moveColumn: (k, M) => {
|
|
8903
8912
|
const q = De.getAllLeafColumns().map((Te) => Te.id), ue = q.indexOf(k);
|
|
8904
|
-
ue !== -1 && (q.splice(ue, 1), q.splice(
|
|
8913
|
+
ue !== -1 && (q.splice(ue, 1), q.splice(Ft(M, 0, q.length), 0, k), De.setColumnOrder(q));
|
|
8905
8914
|
},
|
|
8906
8915
|
clearSelection: () => {
|
|
8907
8916
|
qo.current = void 0, ge([]);
|
|
8908
8917
|
}
|
|
8909
8918
|
}),
|
|
8910
|
-
[De,
|
|
8919
|
+
[De, pt, Qe, ge]
|
|
8911
8920
|
);
|
|
8912
8921
|
const Si = Ze.reduce(
|
|
8913
8922
|
(k, M) => {
|
|
@@ -8943,7 +8952,7 @@ function Ku(e, t) {
|
|
|
8943
8952
|
children: [
|
|
8944
8953
|
L && /* @__PURE__ */ v(O, { style: { display: "flex", alignItems: "center", gap: I.GUTTER }, children: [
|
|
8945
8954
|
/* @__PURE__ */ o(
|
|
8946
|
-
|
|
8955
|
+
Ct,
|
|
8947
8956
|
{
|
|
8948
8957
|
"data-testid": "data-table-search",
|
|
8949
8958
|
type: "search",
|
|
@@ -8988,7 +8997,7 @@ function Ku(e, t) {
|
|
|
8988
8997
|
] }),
|
|
8989
8998
|
/* @__PURE__ */ v(O, { ref: _e, "data-testid": "data-table-viewport", className: "cm-dt-viewport", style: { height: p }, children: [
|
|
8990
8999
|
/* @__PURE__ */ v(
|
|
8991
|
-
|
|
9000
|
+
Ot,
|
|
8992
9001
|
{
|
|
8993
9002
|
ref: tt,
|
|
8994
9003
|
role: "grid",
|
|
@@ -9006,8 +9015,8 @@ function Ku(e, t) {
|
|
|
9006
9015
|
className: "cm-dt-table",
|
|
9007
9016
|
style: { minWidth: Si + zo * (se + 1) },
|
|
9008
9017
|
children: [
|
|
9009
|
-
/* @__PURE__ */ o(
|
|
9010
|
-
const q = _.get(k.id), ue = k.getCanSort(), Te = k.getIsSorted(), Ke = ot.row === je && ot.column === M,
|
|
9018
|
+
/* @__PURE__ */ o(Ot.Thead, { className: "cm-dt-head", children: /* @__PURE__ */ o(Ot.Tr, { role: "row", "aria-rowindex": 1, className: "cm-dt-row", style: { height: b }, children: Ze.map((k, M) => {
|
|
9019
|
+
const q = _.get(k.id), ue = k.getCanSort(), Te = k.getIsSorted(), Ke = ot.row === je && ot.column === M, Pt = Te === !1 ? -1 : k.getSortIndex(), xo = Ke ? 0 : -1, Gt = (q == null ? void 0 : q.menu) !== void 0 && q.menu !== null, vo = /* @__PURE__ */ v(Z, { children: [
|
|
9011
9020
|
(q == null ? void 0 : q.icon) !== void 0 && q.icon !== null && /* @__PURE__ */ o(
|
|
9012
9021
|
"span",
|
|
9013
9022
|
{
|
|
@@ -9044,7 +9053,7 @@ function Ku(e, t) {
|
|
|
9044
9053
|
children: /* @__PURE__ */ o(we, { name: "caretDown", size: I.CHEVRON })
|
|
9045
9054
|
}
|
|
9046
9055
|
),
|
|
9047
|
-
ut.length > 1 &&
|
|
9056
|
+
ut.length > 1 && Pt >= 0 && // Where this column comes in a sort
|
|
9048
9057
|
// by several columns, drawn for the
|
|
9049
9058
|
// eye only: every column already
|
|
9050
9059
|
// announces its own direction
|
|
@@ -9056,11 +9065,11 @@ function Ku(e, t) {
|
|
|
9056
9065
|
"data-testid": "data-table-sort-priority",
|
|
9057
9066
|
"aria-hidden": "true",
|
|
9058
9067
|
className: "cm-dt-sort-priority",
|
|
9059
|
-
children: pe.format(
|
|
9068
|
+
children: pe.format(Pt + 1)
|
|
9060
9069
|
}
|
|
9061
9070
|
)
|
|
9062
9071
|
] }), ct = /* @__PURE__ */ v(
|
|
9063
|
-
|
|
9072
|
+
Ot.Th,
|
|
9064
9073
|
{
|
|
9065
9074
|
scope: "col",
|
|
9066
9075
|
"data-testid": "data-table-header",
|
|
@@ -9070,10 +9079,10 @@ function Ku(e, t) {
|
|
|
9070
9079
|
"data-grid-column": ue ? void 0 : M,
|
|
9071
9080
|
tabIndex: ue ? void 0 : xo,
|
|
9072
9081
|
className: "cm-dt-cell cm-dt-header",
|
|
9073
|
-
"data-with-menu":
|
|
9082
|
+
"data-with-menu": Gt && !ue ? "" : void 0,
|
|
9074
9083
|
onFocus: ue ? void 0 : () => {
|
|
9075
|
-
|
|
9076
|
-
(
|
|
9084
|
+
Ut(
|
|
9085
|
+
(ht) => Co(ht, { row: je, column: M }) ? ht : { row: je, column: M }
|
|
9077
9086
|
);
|
|
9078
9087
|
},
|
|
9079
9088
|
style: { ...Jr(q, M), gap: I.GUTTER / 2 },
|
|
@@ -9093,29 +9102,29 @@ function Ku(e, t) {
|
|
|
9093
9102
|
"data-grid-row": je,
|
|
9094
9103
|
"data-grid-column": M,
|
|
9095
9104
|
tabIndex: xo,
|
|
9096
|
-
onClick: (
|
|
9097
|
-
|
|
9105
|
+
onClick: (ht) => {
|
|
9106
|
+
Ut({ row: je, column: M }), wi(k, ht);
|
|
9098
9107
|
},
|
|
9099
9108
|
onFocus: () => {
|
|
9100
|
-
|
|
9101
|
-
(
|
|
9109
|
+
Ut(
|
|
9110
|
+
(ht) => Co(ht, { row: je, column: M }) ? ht : { row: je, column: M }
|
|
9102
9111
|
);
|
|
9103
9112
|
},
|
|
9104
9113
|
className: "cm-dt-sort",
|
|
9105
9114
|
"data-align": (q == null ? void 0 : q.align) === "end" ? "end" : void 0,
|
|
9106
|
-
"data-with-menu":
|
|
9115
|
+
"data-with-menu": Gt ? "" : void 0,
|
|
9107
9116
|
children: vo
|
|
9108
9117
|
}
|
|
9109
9118
|
)
|
|
9110
9119
|
) : vo,
|
|
9111
|
-
|
|
9120
|
+
Gt && /* @__PURE__ */ v(
|
|
9112
9121
|
Oe,
|
|
9113
9122
|
{
|
|
9114
9123
|
opened: vi === k.id,
|
|
9115
|
-
onChange: (
|
|
9116
|
-
jr(
|
|
9124
|
+
onChange: (ht) => {
|
|
9125
|
+
jr(ht ? k.id : null);
|
|
9117
9126
|
const jo = document.activeElement;
|
|
9118
|
-
!
|
|
9127
|
+
!ht && (jo === null || jo === document.body || jo.closest('[role="menu"]') !== null) && Yr({ row: je, column: M });
|
|
9119
9128
|
},
|
|
9120
9129
|
returnFocus: !1,
|
|
9121
9130
|
position: "bottom-end",
|
|
@@ -9144,13 +9153,13 @@ function Ku(e, t) {
|
|
|
9144
9153
|
);
|
|
9145
9154
|
return ue ? ct : /* @__PURE__ */ o(Ye.Fragment, { children: Kn(q == null ? void 0 : q.headerTooltip, ct) }, k.id);
|
|
9146
9155
|
}) }) }),
|
|
9147
|
-
/* @__PURE__ */ o(
|
|
9156
|
+
/* @__PURE__ */ o(Ot.Tbody, { style: { display: "block", position: "relative", height: pt.getTotalSize() }, children: Uo.map((k) => {
|
|
9148
9157
|
const M = Je[k.index - Pe];
|
|
9149
9158
|
if (M === void 0)
|
|
9150
9159
|
return null;
|
|
9151
9160
|
const q = be.includes(M.id);
|
|
9152
9161
|
return /* @__PURE__ */ o(
|
|
9153
|
-
|
|
9162
|
+
Ot.Tr,
|
|
9154
9163
|
{
|
|
9155
9164
|
role: "row",
|
|
9156
9165
|
"data-testid": "data-table-row",
|
|
@@ -9174,25 +9183,25 @@ function Ku(e, t) {
|
|
|
9174
9183
|
transform: `translateY(${String(k.start)}px)`
|
|
9175
9184
|
},
|
|
9176
9185
|
children: Ze.map((ue, Te) => {
|
|
9177
|
-
const Ke = _.get(ue.id),
|
|
9186
|
+
const Ke = _.get(ue.id), Pt = ot.row === k.index && ot.column === Te, xo = Ke == null ? void 0 : Ke.value(M.original), Gt = qn(xo, X), vo = (Ke == null ? void 0 : Ke.cell) === void 0 ? /* @__PURE__ */ o("span", { className: "cm-dt-text", dir: "auto", children: Gt }) : Ke.cell(M.original);
|
|
9178
9187
|
return /* @__PURE__ */ o(
|
|
9179
|
-
|
|
9188
|
+
Ot.Td,
|
|
9180
9189
|
{
|
|
9181
9190
|
role: "gridcell",
|
|
9182
9191
|
"data-testid": "data-table-cell",
|
|
9183
9192
|
"aria-colindex": Te + 1,
|
|
9184
9193
|
"data-grid-row": k.index,
|
|
9185
9194
|
"data-grid-column": Te,
|
|
9186
|
-
tabIndex:
|
|
9195
|
+
tabIndex: Pt ? 0 : -1,
|
|
9187
9196
|
className: "cm-dt-cell",
|
|
9188
|
-
title: (Ke == null ? void 0 : Ke.cell) === void 0 ?
|
|
9197
|
+
title: (Ke == null ? void 0 : Ke.cell) === void 0 ? Gt : void 0,
|
|
9189
9198
|
onFocus: () => {
|
|
9190
|
-
|
|
9199
|
+
Ut(
|
|
9191
9200
|
(ct) => Co(ct, { row: k.index, column: Te }) ? ct : { row: k.index, column: Te }
|
|
9192
9201
|
);
|
|
9193
9202
|
},
|
|
9194
9203
|
onClick: (ct) => {
|
|
9195
|
-
|
|
9204
|
+
Ut({ row: k.index, column: Te }), go(
|
|
9196
9205
|
k.index,
|
|
9197
9206
|
{
|
|
9198
9207
|
extend: ct.shiftKey,
|
|
@@ -9316,7 +9325,7 @@ function em({ color: e, onCommit: t, ariaLabel: r }) {
|
|
|
9316
9325
|
}, [n]);
|
|
9317
9326
|
const l = (c) => {
|
|
9318
9327
|
var u;
|
|
9319
|
-
const d = a.trim().replace("#", ""), s = d.length === 3 || d.length === 6 ? (u =
|
|
9328
|
+
const d = a.trim().replace("#", ""), s = d.length === 3 || d.length === 6 ? (u = vt(d)) == null ? void 0 : u.slice(0, 7) : void 0;
|
|
9320
9329
|
if (s === void 0 || s === `#${n}`) {
|
|
9321
9330
|
i(n);
|
|
9322
9331
|
return;
|
|
@@ -9404,7 +9413,7 @@ function sh({
|
|
|
9404
9413
|
labels: u
|
|
9405
9414
|
}) {
|
|
9406
9415
|
var Ne;
|
|
9407
|
-
const p = Ee(), h = { ...$u, ...u }, b =
|
|
9416
|
+
const p = Ee(), h = { ...$u, ...u }, b = Lt({ maximumFractionDigits: 0 }), y = ze(), w = ze(), A = he(() => Ju(), []), [f, x] = xe({
|
|
9408
9417
|
value: e,
|
|
9409
9418
|
defaultValue: t,
|
|
9410
9419
|
finalValue: A,
|
|
@@ -9838,7 +9847,7 @@ function ai(e, t, r) {
|
|
|
9838
9847
|
};
|
|
9839
9848
|
}
|
|
9840
9849
|
function Br(e) {
|
|
9841
|
-
const { value: t, display: r, onCommit: n, parse: a, suffix: i, min: l, max: c, step: d = 1, decimalScale: s, locked: u = !1 } = e, p = e.format ??
|
|
9850
|
+
const { value: t, display: r, onCommit: n, parse: a, suffix: i, min: l, max: c, step: d = 1, decimalScale: s, locked: u = !1 } = e, p = e.format ?? String, [h, b] = me(null), y = K(null), w = (C) => {
|
|
9842
9851
|
y.current = C, b(C);
|
|
9843
9852
|
}, A = K(!1), f = K(0), x = K(null), N = (C) => {
|
|
9844
9853
|
const V = im(am(C), l, c);
|
|
@@ -9971,7 +9980,7 @@ function uh({
|
|
|
9971
9980
|
"data-disabled": s ? "true" : void 0,
|
|
9972
9981
|
children: [
|
|
9973
9982
|
/* @__PURE__ */ o(
|
|
9974
|
-
|
|
9983
|
+
Ct,
|
|
9975
9984
|
{
|
|
9976
9985
|
"data-testid": "style-number-input-field",
|
|
9977
9986
|
label: e,
|
|
@@ -10326,7 +10335,7 @@ const bh = et(function(t, r) {
|
|
|
10326
10335
|
openLabel: x = "Open list",
|
|
10327
10336
|
className: N,
|
|
10328
10337
|
style: S
|
|
10329
|
-
} = t, m = mo(), z =
|
|
10338
|
+
} = t, m = mo(), z = wt(), [E, C] = xe({ value: a, defaultValue: i, finalValue: "", onChange: l }), [V, W] = me(null), [$, H] = me(void 0), re = K(null), R = gc(r, re), L = uo(), T = sc({
|
|
10330
10339
|
onDropdownOpen: () => {
|
|
10331
10340
|
requestAnimationFrame(() => {
|
|
10332
10341
|
T.getSelectedOptionIndex() === -1 && T.selectActiveOption(), H(j());
|
|
@@ -10411,7 +10420,7 @@ const bh = et(function(t, r) {
|
|
|
10411
10420
|
)
|
|
10412
10421
|
] });
|
|
10413
10422
|
return /* @__PURE__ */ v(
|
|
10414
|
-
|
|
10423
|
+
Ht,
|
|
10415
10424
|
{
|
|
10416
10425
|
store: T,
|
|
10417
10426
|
onOptionSubmit: (X) => {
|
|
@@ -10421,8 +10430,8 @@ const bh = et(function(t, r) {
|
|
|
10421
10430
|
keepMounted: !1,
|
|
10422
10431
|
disabled: A,
|
|
10423
10432
|
children: [
|
|
10424
|
-
/* @__PURE__ */ o(
|
|
10425
|
-
|
|
10433
|
+
/* @__PURE__ */ o(Ht.Target, { withKeyboardNavigation: !1, withAriaAttributes: !1, children: /* @__PURE__ */ o(
|
|
10434
|
+
Ct,
|
|
10426
10435
|
{
|
|
10427
10436
|
ref: R,
|
|
10428
10437
|
...d ? pe : de,
|
|
@@ -10447,9 +10456,9 @@ const bh = et(function(t, r) {
|
|
|
10447
10456
|
rightSectionPointerEvents: "all"
|
|
10448
10457
|
}
|
|
10449
10458
|
) }),
|
|
10450
|
-
/* @__PURE__ */ o(
|
|
10459
|
+
/* @__PURE__ */ o(Ht.Dropdown, { className: "cm-menu-surface cm-menu cm-listbox", children: /* @__PURE__ */ o(Ht.Options, { id: L, "aria-label": n, children: c.map(
|
|
10451
10460
|
(X, be) => Zn(X) ? /* @__PURE__ */ o("div", { role: "separator", className: "cm-listbox-separator" }, `separator-${String(be)}`) : /* @__PURE__ */ v(
|
|
10452
|
-
|
|
10461
|
+
Ht.Option,
|
|
10453
10462
|
{
|
|
10454
10463
|
value: X.value,
|
|
10455
10464
|
disabled: X.disabled,
|
|
@@ -10498,7 +10507,7 @@ const bh = et(function(t, r) {
|
|
|
10498
10507
|
var re;
|
|
10499
10508
|
S("", H), (re = C.current) == null || re.focus();
|
|
10500
10509
|
}, $ = /* @__PURE__ */ o(
|
|
10501
|
-
|
|
10510
|
+
Ct,
|
|
10502
10511
|
{
|
|
10503
10512
|
...f,
|
|
10504
10513
|
ref: V,
|
|
@@ -10762,7 +10771,7 @@ function km(e) {
|
|
|
10762
10771
|
function Sm(e) {
|
|
10763
10772
|
return typeof e == "object" && e !== null && "message" in e;
|
|
10764
10773
|
}
|
|
10765
|
-
const ii =
|
|
10774
|
+
const ii = It(null);
|
|
10766
10775
|
function kh({ children: e, bottom: t = 76, zIndex: r }) {
|
|
10767
10776
|
const [n, a] = me(null), i = K(void 0), l = K(0), c = ce(() => {
|
|
10768
10777
|
clearTimeout(i.current), a(null);
|
|
@@ -10918,7 +10927,7 @@ const Nh = et(function({
|
|
|
10918
10927
|
...f
|
|
10919
10928
|
}, x) {
|
|
10920
10929
|
Le();
|
|
10921
|
-
const N = $e(
|
|
10930
|
+
const N = $e(wt()), S = n ?? a, [m, z] = xe({ value: r, defaultValue: n, finalValue: a, onChange: l }), E = K(null), C = t === "start" || t === "end", V = t === "end" ? 1 : -1;
|
|
10922
10931
|
let W = t === "bottom" ? 1 : -1;
|
|
10923
10932
|
C && (W = N ? -V : V);
|
|
10924
10933
|
const $ = (D) => Math.min(i, Math.max(a, Math.round(D))), H = (D, ee) => {
|
|
@@ -11007,7 +11016,7 @@ function ci({
|
|
|
11007
11016
|
s ? t(((h = i.current) == null ? void 0 : h.value) ?? e) : r == null || r(), u && (p != null && p.isConnected) && p.focus();
|
|
11008
11017
|
};
|
|
11009
11018
|
return /* @__PURE__ */ o(
|
|
11010
|
-
|
|
11019
|
+
Ct,
|
|
11011
11020
|
{
|
|
11012
11021
|
ref: i,
|
|
11013
11022
|
"aria-label": n,
|
|
@@ -11522,7 +11531,7 @@ function Ih({
|
|
|
11522
11531
|
g.preventDefault();
|
|
11523
11532
|
}
|
|
11524
11533
|
}, X = (g) => {
|
|
11525
|
-
var Fe, Ge, qe,
|
|
11534
|
+
var Fe, Ge, qe, At, ut, mt;
|
|
11526
11535
|
const F = g.target, te = F.closest("[role='treeitem']");
|
|
11527
11536
|
if (te !== null && te !== F && F.closest(".cm-tree-actions") !== null) {
|
|
11528
11537
|
Re(g, te);
|
|
@@ -11559,7 +11568,7 @@ function Ih({
|
|
|
11559
11568
|
_.expanded ? ie(_.node.id, !1) : _.parentId !== null && J(_.parentId);
|
|
11560
11569
|
break;
|
|
11561
11570
|
case "Home":
|
|
11562
|
-
J((
|
|
11571
|
+
J((At = m[0]) == null ? void 0 : At.node.id);
|
|
11563
11572
|
break;
|
|
11564
11573
|
case "End":
|
|
11565
11574
|
J((ut = m[m.length - 1]) == null ? void 0 : ut.node.id);
|
|
@@ -11587,7 +11596,7 @@ function Ih({
|
|
|
11587
11596
|
const ae = Date.now(), le = j.current;
|
|
11588
11597
|
le.text = ae - le.at > Fm ? g.key : le.text + g.key, le.at = ae;
|
|
11589
11598
|
const Ie = le.text.toLocaleLowerCase(), Ve = le.text.length === 1 ? Q + 1 : Q, Pe = [...m.slice(Ve), ...m.slice(0, Ve)];
|
|
11590
|
-
J((
|
|
11599
|
+
J((mt = Pe.find((De) => De.node.name.toLocaleLowerCase().startsWith(Ie))) == null ? void 0 : mt.node.id);
|
|
11591
11600
|
} else
|
|
11592
11601
|
Ce = !1;
|
|
11593
11602
|
}
|
|
@@ -11767,7 +11776,7 @@ function Fr(e) {
|
|
|
11767
11776
|
c.key === "Home" ? b = 0 : c.key === "End" && (b = p.length - 1), p[b].focus();
|
|
11768
11777
|
} };
|
|
11769
11778
|
}
|
|
11770
|
-
function
|
|
11779
|
+
function Vt() {
|
|
11771
11780
|
const e = ka();
|
|
11772
11781
|
Fo(e.other.compact);
|
|
11773
11782
|
}
|
|
@@ -11783,7 +11792,7 @@ function qm() {
|
|
|
11783
11792
|
) });
|
|
11784
11793
|
}
|
|
11785
11794
|
function Lh({ label: e, children: t, menuProps: r, className: n, ...a }) {
|
|
11786
|
-
|
|
11795
|
+
Vt();
|
|
11787
11796
|
const i = Ee(), l = e ?? i.help, c = /* @__PURE__ */ o(
|
|
11788
11797
|
it,
|
|
11789
11798
|
{
|
|
@@ -11817,7 +11826,7 @@ function Vr({
|
|
|
11817
11826
|
] });
|
|
11818
11827
|
}
|
|
11819
11828
|
const Wm = et(function({ label: t, icon: r, shortcut: n, selected: a, tooltipPosition: i = "top", disabledReason: l, className: c, onClick: d, ...s }, u) {
|
|
11820
|
-
|
|
11829
|
+
Vt();
|
|
11821
11830
|
const p = l !== void 0;
|
|
11822
11831
|
return /* @__PURE__ */ o(
|
|
11823
11832
|
lt,
|
|
@@ -11842,7 +11851,7 @@ const Wm = et(function({ label: t, icon: r, shortcut: n, selected: a, tooltipPos
|
|
|
11842
11851
|
);
|
|
11843
11852
|
}), jm = 500;
|
|
11844
11853
|
function Ym({ footer: e, children: t, className: r, onKeyDown: n, onFocus: a, ...i }) {
|
|
11845
|
-
|
|
11854
|
+
Vt();
|
|
11846
11855
|
const l = Ee(), c = Fr("vertical");
|
|
11847
11856
|
return /* @__PURE__ */ v(
|
|
11848
11857
|
O,
|
|
@@ -11948,7 +11957,7 @@ function Rh({
|
|
|
11948
11957
|
...w
|
|
11949
11958
|
}) {
|
|
11950
11959
|
var L;
|
|
11951
|
-
|
|
11960
|
+
Vt();
|
|
11952
11961
|
const A = Ee(), f = uo(), x = d ?? `${f}-list`, N = K(null), [S, m] = xe({
|
|
11953
11962
|
value: n,
|
|
11954
11963
|
defaultValue: "",
|
|
@@ -12094,7 +12103,7 @@ function Qm({
|
|
|
12094
12103
|
onFocus: a,
|
|
12095
12104
|
...i
|
|
12096
12105
|
}) {
|
|
12097
|
-
|
|
12106
|
+
Vt();
|
|
12098
12107
|
const l = Fr("horizontal");
|
|
12099
12108
|
return /* @__PURE__ */ o(
|
|
12100
12109
|
O,
|
|
@@ -12152,7 +12161,7 @@ function Mh({
|
|
|
12152
12161
|
...c
|
|
12153
12162
|
}) {
|
|
12154
12163
|
var N;
|
|
12155
|
-
|
|
12164
|
+
Vt();
|
|
12156
12165
|
const d = Ee(), s = uo(), u = K([]), [p, h] = xe({
|
|
12157
12166
|
value: t,
|
|
12158
12167
|
defaultValue: r,
|
|
@@ -12284,7 +12293,7 @@ function ep({
|
|
|
12284
12293
|
onFocus: a,
|
|
12285
12294
|
...i
|
|
12286
12295
|
}) {
|
|
12287
|
-
|
|
12296
|
+
Vt();
|
|
12288
12297
|
const l = Ee(), c = Fr("horizontal");
|
|
12289
12298
|
return /* @__PURE__ */ o(
|
|
12290
12299
|
O,
|
|
@@ -12393,7 +12402,7 @@ function Bh({
|
|
|
12393
12402
|
function li(e, t) {
|
|
12394
12403
|
return e !== void 0 ? e : t === void 0 ? "off" : "polite";
|
|
12395
12404
|
}
|
|
12396
|
-
function
|
|
12405
|
+
function zt(e, t) {
|
|
12397
12406
|
const r = li(e, t);
|
|
12398
12407
|
return r === "off" ? { "aria-busy": t } : { "aria-live": r, "aria-atomic": !0, "aria-busy": t };
|
|
12399
12408
|
}
|
|
@@ -12419,11 +12428,11 @@ function Fh(e) {
|
|
|
12419
12428
|
onClick: u,
|
|
12420
12429
|
onFocus: p,
|
|
12421
12430
|
onBlur: h
|
|
12422
|
-
} = e, b =
|
|
12431
|
+
} = e, b = zt(a, n), { hovered: y, ref: w } = xc(), A = Aa(rp) ?? !1, [f, x] = me(!1), N = ze(), S = f || (c ?? (d === "always" || y || A)), m = i !== void 0 || l !== void 0, z = np(t), E = r !== void 0 && r !== z, C = r ?? z, V = m && t !== void 0, W = E ? /* @__PURE__ */ v(Z, { children: [
|
|
12423
12432
|
/* @__PURE__ */ o("span", { "aria-hidden": "true", children: t }),
|
|
12424
12433
|
/* @__PURE__ */ o(at, { "data-testid": "action-row-state-full", children: r })
|
|
12425
12434
|
] }) : t;
|
|
12426
|
-
|
|
12435
|
+
St(
|
|
12427
12436
|
u !== void 0 && t === void 0 ? "ActionRow was given onClick but no state, and its own activation is carried by the text it reports. That text is also what names the row for a screen reader, so a row with nothing to report has nothing to activate. Give the row a state, or put the action on a control in actions." : void 0
|
|
12428
12437
|
);
|
|
12429
12438
|
const $ = (T) => {
|
|
@@ -12568,7 +12577,7 @@ function Vh({
|
|
|
12568
12577
|
trailing: d
|
|
12569
12578
|
}) {
|
|
12570
12579
|
Le();
|
|
12571
|
-
const s = ze(), u =
|
|
12580
|
+
const s = ze(), u = Lt({ maximumFractionDigits: 20 }), p = typeof t == "number" ? u.format(t) : t, h = i !== void 0, b = n != null, y = t != null, w = bo(d), A = a ? !0 : void 0, f = (N) => {
|
|
12572
12581
|
i == null || i(N, lo(N));
|
|
12573
12582
|
}, x = /* @__PURE__ */ v(Z, { children: [
|
|
12574
12583
|
b && /* @__PURE__ */ o("span", { className: "cm-data-row-icon", "data-testid": "data-row-icon", children: n }),
|
|
@@ -12610,7 +12619,7 @@ function Vh({
|
|
|
12610
12619
|
children: x
|
|
12611
12620
|
}
|
|
12612
12621
|
),
|
|
12613
|
-
w && /* @__PURE__ */ o(
|
|
12622
|
+
w && /* @__PURE__ */ o(Tt, { children: d })
|
|
12614
12623
|
]
|
|
12615
12624
|
}
|
|
12616
12625
|
);
|
|
@@ -12629,7 +12638,7 @@ function Uh({
|
|
|
12629
12638
|
defaultValue: n,
|
|
12630
12639
|
finalValue: "none",
|
|
12631
12640
|
onChange: a
|
|
12632
|
-
}), d =
|
|
12641
|
+
}), d = Lt(), s = a !== void 0, u = l !== "none", p = (f) => {
|
|
12633
12642
|
c(l === "ascending" ? "descending" : "ascending", f);
|
|
12634
12643
|
}, h = /* @__PURE__ */ v(Z, { children: [
|
|
12635
12644
|
/* @__PURE__ */ o("span", { className: "cm-data-row-header-label", "data-testid": "data-row-header-label", title: e, children: e }),
|
|
@@ -12673,7 +12682,7 @@ function Uh({
|
|
|
12673
12682
|
function di({ children: e }) {
|
|
12674
12683
|
return Le(), /* @__PURE__ */ o("span", { className: "cm-rank-chip", "data-testid": "rank-chip", children: e });
|
|
12675
12684
|
}
|
|
12676
|
-
const $n = 2, ap = 1, ip = 16, cp = 2, sp = 1, lp = 1, dp = 64, ui = 4, ea = ui / 2, mi = 4,
|
|
12685
|
+
const $n = 2, ap = 1, ip = 16, cp = 2, sp = 1, lp = 1, dp = 64, ui = 4, ea = ui / 2, mi = 4, Bt = 100, up = 1, pi = "var(--cm-icon-secondary)", kr = 100;
|
|
12677
12686
|
function Mo({ children: e, end: t, id: r }) {
|
|
12678
12687
|
return /* @__PURE__ */ o(
|
|
12679
12688
|
O,
|
|
@@ -12716,12 +12725,12 @@ function fi({ caption: e, rows: t, testId: r }) {
|
|
|
12716
12725
|
function mp(e, t) {
|
|
12717
12726
|
if (e.length === 0)
|
|
12718
12727
|
return null;
|
|
12719
|
-
const r =
|
|
12728
|
+
const r = Bt / 2;
|
|
12720
12729
|
if (e.length === 1)
|
|
12721
|
-
return `0,${r} ${
|
|
12730
|
+
return `0,${r} ${Bt},${r}`;
|
|
12722
12731
|
const n = Math.min(...e), i = Math.max(...e) - n, l = e.length - 1;
|
|
12723
12732
|
return e.map((c, d) => {
|
|
12724
|
-
const s = bu(d / l,
|
|
12733
|
+
const s = bu(d / l, Bt, t), u = i === 0 ? r : Bt - (c - n) / i * Bt;
|
|
12725
12734
|
return `${s},${u}`;
|
|
12726
12735
|
}).join(" ");
|
|
12727
12736
|
}
|
|
@@ -12739,7 +12748,7 @@ function Gh({
|
|
|
12739
12748
|
trailing: l
|
|
12740
12749
|
}) {
|
|
12741
12750
|
Le();
|
|
12742
|
-
const c =
|
|
12751
|
+
const c = Lt(), d = bi(), s = e.reduce((p, h) => Math.max(p, h.count, 0), 0), u = e.map((p, h) => ({
|
|
12743
12752
|
id: `${p.label}-${String(h)}`,
|
|
12744
12753
|
header: p.label,
|
|
12745
12754
|
// The raw count, not the clamped one the bar draws: the table is the
|
|
@@ -12765,7 +12774,7 @@ function Gh({
|
|
|
12765
12774
|
O,
|
|
12766
12775
|
{
|
|
12767
12776
|
"data-testid": "histogram-chart",
|
|
12768
|
-
...
|
|
12777
|
+
...zt(i, a),
|
|
12769
12778
|
style: {
|
|
12770
12779
|
flex: "1 1 auto",
|
|
12771
12780
|
minWidth: 0,
|
|
@@ -12851,7 +12860,7 @@ function Gh({
|
|
|
12851
12860
|
}
|
|
12852
12861
|
),
|
|
12853
12862
|
/* @__PURE__ */ o(fi, { caption: t, rows: u, testId: "histogram-values" }),
|
|
12854
|
-
bo(l) && /* @__PURE__ */ o(
|
|
12863
|
+
bo(l) && /* @__PURE__ */ o(Tt, { children: l })
|
|
12855
12864
|
]
|
|
12856
12865
|
}
|
|
12857
12866
|
);
|
|
@@ -12866,7 +12875,7 @@ function qh({
|
|
|
12866
12875
|
trailing: l
|
|
12867
12876
|
}) {
|
|
12868
12877
|
Le();
|
|
12869
|
-
const c =
|
|
12878
|
+
const c = wt(), d = Lt(), s = bi(), u = mp(e, c), p = e.map((h, b) => ({
|
|
12870
12879
|
id: `point-${String(b)}`,
|
|
12871
12880
|
// Positions count from one, the way a reader counts them, and are
|
|
12872
12881
|
// formatted for the locale so a series longer than a thousand points
|
|
@@ -12890,7 +12899,7 @@ function qh({
|
|
|
12890
12899
|
O,
|
|
12891
12900
|
{
|
|
12892
12901
|
"data-testid": "sparkline-chart",
|
|
12893
|
-
...
|
|
12902
|
+
...zt(i, a),
|
|
12894
12903
|
style: {
|
|
12895
12904
|
flex: "1 1 auto",
|
|
12896
12905
|
minWidth: 0,
|
|
@@ -12924,7 +12933,7 @@ function qh({
|
|
|
12924
12933
|
"data-testid": "sparkline-plot",
|
|
12925
12934
|
width: "100%",
|
|
12926
12935
|
height: I.CONTROL_HEIGHT,
|
|
12927
|
-
viewBox: `0 0 ${String(
|
|
12936
|
+
viewBox: `0 0 ${String(Bt)} ${String(Bt)}`,
|
|
12928
12937
|
preserveAspectRatio: "none",
|
|
12929
12938
|
fill: "none",
|
|
12930
12939
|
stroke: "currentColor",
|
|
@@ -12946,7 +12955,7 @@ function qh({
|
|
|
12946
12955
|
}
|
|
12947
12956
|
),
|
|
12948
12957
|
/* @__PURE__ */ o(fi, { caption: t, rows: p, testId: "sparkline-values" }),
|
|
12949
|
-
bo(l) && /* @__PURE__ */ o(
|
|
12958
|
+
bo(l) && /* @__PURE__ */ o(Tt, { children: l })
|
|
12950
12959
|
]
|
|
12951
12960
|
}
|
|
12952
12961
|
);
|
|
@@ -12977,7 +12986,7 @@ function Wh({
|
|
|
12977
12986
|
role: w ? "button" : void 0,
|
|
12978
12987
|
tabIndex: w ? 0 : void 0,
|
|
12979
12988
|
className: w ? "cm-row-target" : void 0,
|
|
12980
|
-
...
|
|
12989
|
+
...zt(i, a),
|
|
12981
12990
|
onClick: x,
|
|
12982
12991
|
onKeyDown: N,
|
|
12983
12992
|
onDoubleClick: c,
|
|
@@ -13061,7 +13070,7 @@ function Wh({
|
|
|
13061
13070
|
}
|
|
13062
13071
|
);
|
|
13063
13072
|
}
|
|
13064
|
-
const gi =
|
|
13073
|
+
const gi = It(!1);
|
|
13065
13074
|
function ta({ showLabels: e = !1, children: t }) {
|
|
13066
13075
|
return /* @__PURE__ */ o(gi.Provider, { value: e, children: t });
|
|
13067
13076
|
}
|
|
@@ -13180,7 +13189,7 @@ function jh({
|
|
|
13180
13189
|
}) {
|
|
13181
13190
|
Le();
|
|
13182
13191
|
const s = Ur(), u = Ye.useId(), p = t.filter((z) => z.grow === !0).length;
|
|
13183
|
-
|
|
13192
|
+
St(xp(e, t.length)), St(vp(e, p));
|
|
13184
13193
|
const h = t.findIndex((z) => z.grow === !0), b = h === -1 ? 0 : h, y = l !== void 0, w = li(i, a) !== "off", A = y || w, f = y ? void 0 : u, x = A ? void 0 : u, N = A || s, S = {
|
|
13185
13194
|
display: "flex",
|
|
13186
13195
|
alignItems: "center",
|
|
@@ -13256,7 +13265,7 @@ function jh({
|
|
|
13256
13265
|
"data-testid": "compound-row-box",
|
|
13257
13266
|
"data-interactive": "true",
|
|
13258
13267
|
className: "cm-compound cm-field",
|
|
13259
|
-
...
|
|
13268
|
+
...zt(i, a),
|
|
13260
13269
|
onClick: l,
|
|
13261
13270
|
onFocus: c,
|
|
13262
13271
|
onBlur: d,
|
|
@@ -13273,14 +13282,14 @@ function jh({
|
|
|
13273
13282
|
"data-testid": "compound-row-box",
|
|
13274
13283
|
"data-interactive": "false",
|
|
13275
13284
|
className: "cm-compound",
|
|
13276
|
-
...
|
|
13285
|
+
...zt(i, a),
|
|
13277
13286
|
onFocus: c,
|
|
13278
13287
|
onBlur: d,
|
|
13279
13288
|
style: S,
|
|
13280
13289
|
children: m
|
|
13281
13290
|
}
|
|
13282
13291
|
),
|
|
13283
|
-
/* @__PURE__ */ o(
|
|
13292
|
+
/* @__PURE__ */ o(Tt, { children: n })
|
|
13284
13293
|
]
|
|
13285
13294
|
}
|
|
13286
13295
|
);
|
|
@@ -13328,7 +13337,7 @@ const wp = I.VALUE_INSET - I.GLYPH_SLOT, ra = 8, yp = "Use arrow keys to change
|
|
|
13328
13337
|
className: R,
|
|
13329
13338
|
onKeyDown: L,
|
|
13330
13339
|
...T
|
|
13331
|
-
} = t, j = Ur(), P = Ee(), D = mo(), ee =
|
|
13340
|
+
} = t, j = Ur(), P = Ee(), D = mo(), ee = wt(), G = Aa("(pointer: coarse)"), { ref: J, width: ie } = vc(), [de, pe] = xe({
|
|
13332
13341
|
value: l === null ? "" : l,
|
|
13333
13342
|
defaultValue: c,
|
|
13334
13343
|
finalValue: "",
|
|
@@ -13351,14 +13360,14 @@ const wp = I.VALUE_INSET - I.GLYPH_SLOT, ra = 8, yp = "Use arrow keys to change
|
|
|
13351
13360
|
max: f,
|
|
13352
13361
|
step: x,
|
|
13353
13362
|
locked: C || be
|
|
13354
|
-
}),
|
|
13363
|
+
}), At = ai(Ce, $e(ee), {
|
|
13355
13364
|
onStart: (se) => {
|
|
13356
13365
|
var ye, _e;
|
|
13357
13366
|
S == null || S(se), ne && ((_e = (ye = qe.scrub).onStart) == null || _e.call(ye, se));
|
|
13358
13367
|
},
|
|
13359
13368
|
onMove: (se, ye, _e) => {
|
|
13360
|
-
var tt,
|
|
13361
|
-
m == null || m(se, _e), ne && ((
|
|
13369
|
+
var tt, pt;
|
|
13370
|
+
m == null || m(se, _e), ne && ((pt = (tt = qe.scrub).onMove) == null || pt.call(tt, se, ye, _e));
|
|
13362
13371
|
},
|
|
13363
13372
|
onEnd: (se) => {
|
|
13364
13373
|
var ye, _e;
|
|
@@ -13366,7 +13375,7 @@ const wp = I.VALUE_INSET - I.GLYPH_SLOT, ra = 8, yp = "Use arrow keys to change
|
|
|
13366
13375
|
}
|
|
13367
13376
|
}), ut = (se) => {
|
|
13368
13377
|
C || E == null || E(se);
|
|
13369
|
-
},
|
|
13378
|
+
}, mt = (se) => {
|
|
13370
13379
|
L == null || L(se), !(E === void 0 || C || se.defaultPrevented) && (X || (se.key === "Enter" || se.key === " " && be) && (se.preventDefault(), E(se)));
|
|
13371
13380
|
}, ae = (se, ye) => {
|
|
13372
13381
|
pe(se, ye);
|
|
@@ -13391,7 +13400,7 @@ const wp = I.VALUE_INSET - I.GLYPH_SLOT, ra = 8, yp = "Use arrow keys to change
|
|
|
13391
13400
|
"data-testid": "panel-field-slot",
|
|
13392
13401
|
className: "cm-scrub-slot",
|
|
13393
13402
|
"data-scrub": Ce ? "true" : void 0,
|
|
13394
|
-
...
|
|
13403
|
+
...At,
|
|
13395
13404
|
style: {
|
|
13396
13405
|
position: "relative",
|
|
13397
13406
|
flex: "0 0 auto",
|
|
@@ -13487,7 +13496,7 @@ const wp = I.VALUE_INSET - I.GLYPH_SLOT, ra = 8, yp = "Use arrow keys to change
|
|
|
13487
13496
|
disabled: C,
|
|
13488
13497
|
readOnly: be,
|
|
13489
13498
|
onClick: ut,
|
|
13490
|
-
onKeyDown:
|
|
13499
|
+
onKeyDown: mt,
|
|
13491
13500
|
// A drop-down is Figma's outlined select trigger; every other field is
|
|
13492
13501
|
// the filled field.
|
|
13493
13502
|
variant: Re ? "outlined" : "filled",
|
|
@@ -13560,7 +13569,7 @@ const wp = I.VALUE_INSET - I.GLYPH_SLOT, ra = 8, yp = "Use arrow keys to change
|
|
|
13560
13569
|
if (Q) {
|
|
13561
13570
|
const se = N === "" ? {} : { "aria-description": N };
|
|
13562
13571
|
return /* @__PURE__ */ o(
|
|
13563
|
-
|
|
13572
|
+
Ct,
|
|
13564
13573
|
{
|
|
13565
13574
|
...Qe,
|
|
13566
13575
|
...qe.inputProps,
|
|
@@ -13581,7 +13590,7 @@ const wp = I.VALUE_INSET - I.GLYPH_SLOT, ra = 8, yp = "Use arrow keys to change
|
|
|
13581
13590
|
}
|
|
13582
13591
|
}
|
|
13583
13592
|
) : /* @__PURE__ */ o(
|
|
13584
|
-
|
|
13593
|
+
Ct,
|
|
13585
13594
|
{
|
|
13586
13595
|
...Qe,
|
|
13587
13596
|
value: Ue ? "" : ge,
|
|
@@ -13618,7 +13627,7 @@ const Yh = et(function({
|
|
|
13618
13627
|
}, u) {
|
|
13619
13628
|
Le();
|
|
13620
13629
|
const p = Ur(), h = Np(t), b = h.length;
|
|
13621
|
-
|
|
13630
|
+
St(
|
|
13622
13631
|
b === 0 || b > Tp ? `FieldRow was given ${String(b)} ${b === 1 ? "field" : "fields"}, and it holds one field, or two side by side. A row with none is an empty 32px gap, and a third field has nowhere to go in the 240px panel the row is measured for. Put the extra fields on rows of their own.` : void 0
|
|
13623
13632
|
);
|
|
13624
13633
|
const y = n ?? c, A = i ?? (y !== void 0 || d !== void 0 ? "group" : void 0), f = bo(r);
|
|
@@ -13689,7 +13698,7 @@ const Yh = et(function({
|
|
|
13689
13698
|
children: /* @__PURE__ */ o(ta, { showLabels: !1, children: lr(E) })
|
|
13690
13699
|
}
|
|
13691
13700
|
),
|
|
13692
|
-
/* @__PURE__ */ o(
|
|
13701
|
+
/* @__PURE__ */ o(Tt, { children: C === 0 ? r : null })
|
|
13693
13702
|
]
|
|
13694
13703
|
},
|
|
13695
13704
|
sa(E, C)
|
|
@@ -13757,7 +13766,7 @@ const Yh = et(function({
|
|
|
13757
13766
|
},
|
|
13758
13767
|
sa(E, C)
|
|
13759
13768
|
)),
|
|
13760
|
-
/* @__PURE__ */ o(
|
|
13769
|
+
/* @__PURE__ */ o(Tt, { children: r })
|
|
13761
13770
|
]
|
|
13762
13771
|
}
|
|
13763
13772
|
);
|
|
@@ -13797,9 +13806,9 @@ function Pp(e, t) {
|
|
|
13797
13806
|
}
|
|
13798
13807
|
function Kh({ variant: e, children: t, onDetails: r, busy: n, live: a }) {
|
|
13799
13808
|
Le();
|
|
13800
|
-
const i = Ee(), l =
|
|
13801
|
-
|
|
13802
|
-
const s =
|
|
13809
|
+
const i = Ee(), l = wt(), c = ze(), d = ze();
|
|
13810
|
+
St(Lp(e, t)), St(Pp(e, r));
|
|
13811
|
+
const s = zt(a, n);
|
|
13803
13812
|
return e === "reading" ? /* @__PURE__ */ o(jt, { ...s, "data-testid": "prose-block", "data-variant": e, className: "cm-prose", children: t }) : e === "departure" ? /* @__PURE__ */ v(
|
|
13804
13813
|
O,
|
|
13805
13814
|
{
|
|
@@ -13915,7 +13924,7 @@ function Xh({
|
|
|
13915
13924
|
trailing: s
|
|
13916
13925
|
}) {
|
|
13917
13926
|
Le();
|
|
13918
|
-
const u = Ee(), p =
|
|
13927
|
+
const u = Ee(), p = wt(), h = ze(), b = n === "color", y = i === void 0 ? void 0 : Hp[i], w = y === void 0 ? void 0 : u[y], A = `${h}-label`, f = `${h}-min`, x = `${h}-max`, N = `${h}-scale`, S = [
|
|
13919
13928
|
r === void 0 ? void 0 : A,
|
|
13920
13929
|
f,
|
|
13921
13930
|
x,
|
|
@@ -13960,7 +13969,7 @@ function Xh({
|
|
|
13960
13969
|
"data-testid": "ramp-row-figure",
|
|
13961
13970
|
role: "img",
|
|
13962
13971
|
"aria-labelledby": S.join(" "),
|
|
13963
|
-
...
|
|
13972
|
+
...zt(c, l),
|
|
13964
13973
|
style: {
|
|
13965
13974
|
flex: "1 1 auto",
|
|
13966
13975
|
minWidth: 0,
|
|
@@ -14003,7 +14012,7 @@ function Xh({
|
|
|
14003
14012
|
display: "flex",
|
|
14004
14013
|
marginInlineStart: I.TRAIL_GAP - dr
|
|
14005
14014
|
},
|
|
14006
|
-
children: /* @__PURE__ */ o(
|
|
14015
|
+
children: /* @__PURE__ */ o(Tt, { children: z })
|
|
14007
14016
|
}
|
|
14008
14017
|
)
|
|
14009
14018
|
]
|
|
@@ -14125,14 +14134,14 @@ function Jh({
|
|
|
14125
14134
|
),
|
|
14126
14135
|
S.description !== void 0 && /* @__PURE__ */ o(at, { id: S.describedBy, children: S.description }),
|
|
14127
14136
|
z,
|
|
14128
|
-
/* @__PURE__ */ o(
|
|
14137
|
+
/* @__PURE__ */ o(Tt, { children: i })
|
|
14129
14138
|
]
|
|
14130
14139
|
}
|
|
14131
14140
|
);
|
|
14132
14141
|
}
|
|
14133
14142
|
function Zh({ children: e, label: t, labelledBy: r }) {
|
|
14134
14143
|
const n = Ye.Children.toArray(e).length;
|
|
14135
|
-
return
|
|
14144
|
+
return St(
|
|
14136
14145
|
n < Up ? `ToggleRowGroup was given ${String(n)} ${n === 1 ? "row" : "rows"}, and it holds two or more. A single checkbox on a row of its own interrupts a column of rows to say one bit: put it in the trailing slot of the row it modifies, or make it one tile of a group of icon buttons. Rendering it anyway.` : void 0
|
|
14137
14146
|
), /* @__PURE__ */ o(
|
|
14138
14147
|
O,
|
|
@@ -14244,7 +14253,7 @@ export {
|
|
|
14244
14253
|
Bh as ToolGroup,
|
|
14245
14254
|
Hh as Toolbar,
|
|
14246
14255
|
Th as TooltipShortcut,
|
|
14247
|
-
|
|
14256
|
+
Tt as TrailingSlot,
|
|
14248
14257
|
Ih as Tree,
|
|
14249
14258
|
Um as TreeItem,
|
|
14250
14259
|
Jp as UI_GLYPH_NAMES,
|
|
@@ -14269,7 +14278,7 @@ export {
|
|
|
14269
14278
|
Yd as isValidHex,
|
|
14270
14279
|
Jd as mixHex,
|
|
14271
14280
|
zh as moveTreeItem,
|
|
14272
|
-
|
|
14281
|
+
vt as normalizeHexa,
|
|
14273
14282
|
Or as opacityToAlphaHex,
|
|
14274
14283
|
Ja as parseAlphaFromHexa,
|
|
14275
14284
|
_p as parseHexaColor,
|
|
@@ -14278,10 +14287,10 @@ export {
|
|
|
14278
14287
|
$p as toHexaColor,
|
|
14279
14288
|
Qh as useActualColorScheme,
|
|
14280
14289
|
Fl as useCollator,
|
|
14281
|
-
|
|
14290
|
+
wt as useDirection,
|
|
14282
14291
|
Ee as useLabels,
|
|
14283
14292
|
Jt as useLocale,
|
|
14284
|
-
|
|
14293
|
+
Lt as useNumberFormatter,
|
|
14285
14294
|
mo as useNumberParser,
|
|
14286
14295
|
Bl as useOrdinalFormatter,
|
|
14287
14296
|
Ur as usePanelLabels,
|