@arkitektbedriftene/fe-lib 0.3.10 → 0.3.12
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/{Popover-2318823a.js → Badge-3f33be41.js} +486 -448
- package/dist/lib/rich-text/Editor.d.ts +3 -1
- package/dist/lib/ui/components/Badge.d.ts +118 -0
- package/dist/lib/ui/components/Popover.d.ts +120 -1
- package/dist/lib/ui/ui.d.ts +1 -0
- package/dist/rich-text.es.js +75 -72
- package/dist/ui.es.js +15 -14
- package/package.json +1 -1
- package/src/lib/rich-text/Editor.tsx +6 -2
- package/src/lib/ui/components/Badge.tsx +42 -0
- package/src/lib/ui/components/Popover.tsx +1 -1
- package/src/lib/ui/ui.ts +1 -0
|
@@ -1,56 +1,56 @@
|
|
|
1
1
|
import { j as G } from "./jsx-runtime-d0aa4c5b.js";
|
|
2
2
|
import * as y from "react";
|
|
3
|
-
import ve, { forwardRef as
|
|
3
|
+
import ve, { forwardRef as ct, useLayoutEffect as Yt, useEffect as Kt, useRef as vn, createContext as xn, useMemo as wn, useContext as Xt, isValidElement as $n, cloneElement as Sn } from "react";
|
|
4
4
|
import * as Rn from "react-dom";
|
|
5
|
-
import { createPortal as
|
|
6
|
-
var N = "colors", V = "sizes",
|
|
5
|
+
import { createPortal as En } from "react-dom";
|
|
6
|
+
var N = "colors", V = "sizes", E = "space", Cn = { gap: E, gridGap: E, columnGap: E, gridColumnGap: E, rowGap: E, gridRowGap: E, inset: E, insetBlock: E, insetBlockEnd: E, insetBlockStart: E, insetInline: E, insetInlineEnd: E, insetInlineStart: E, margin: E, marginTop: E, marginRight: E, marginBottom: E, marginLeft: E, marginBlock: E, marginBlockEnd: E, marginBlockStart: E, marginInline: E, marginInlineEnd: E, marginInlineStart: E, padding: E, paddingTop: E, paddingRight: E, paddingBottom: E, paddingLeft: E, paddingBlock: E, paddingBlockEnd: E, paddingBlockStart: E, paddingInline: E, paddingInlineEnd: E, paddingInlineStart: E, top: E, right: E, bottom: E, left: E, scrollMargin: E, scrollMarginTop: E, scrollMarginRight: E, scrollMarginBottom: E, scrollMarginLeft: E, scrollMarginX: E, scrollMarginY: E, scrollMarginBlock: E, scrollMarginBlockEnd: E, scrollMarginBlockStart: E, scrollMarginInline: E, scrollMarginInlineEnd: E, scrollMarginInlineStart: E, scrollPadding: E, scrollPaddingTop: E, scrollPaddingRight: E, scrollPaddingBottom: E, scrollPaddingLeft: E, scrollPaddingX: E, scrollPaddingY: E, scrollPaddingBlock: E, scrollPaddingBlockEnd: E, scrollPaddingBlockStart: E, scrollPaddingInline: E, scrollPaddingInlineEnd: E, scrollPaddingInlineStart: E, fontSize: "fontSizes", background: N, backgroundColor: N, backgroundImage: N, borderImage: N, border: N, borderBlock: N, borderBlockEnd: N, borderBlockStart: N, borderBottom: N, borderBottomColor: N, borderColor: N, borderInline: N, borderInlineEnd: N, borderInlineStart: N, borderLeft: N, borderLeftColor: N, borderRight: N, borderRightColor: N, borderTop: N, borderTopColor: N, caretColor: N, color: N, columnRuleColor: N, fill: N, outline: N, outlineColor: N, stroke: N, textDecorationColor: N, fontFamily: "fonts", fontWeight: "fontWeights", lineHeight: "lineHeights", letterSpacing: "letterSpacings", blockSize: V, minBlockSize: V, maxBlockSize: V, inlineSize: V, minInlineSize: V, maxInlineSize: V, width: V, minWidth: V, maxWidth: V, height: V, minHeight: V, maxHeight: V, flexBasis: V, gridTemplateColumns: V, gridTemplateRows: V, borderWidth: "borderWidths", borderTopWidth: "borderWidths", borderRightWidth: "borderWidths", borderBottomWidth: "borderWidths", borderLeftWidth: "borderWidths", borderStyle: "borderStyles", borderTopStyle: "borderStyles", borderRightStyle: "borderStyles", borderBottomStyle: "borderStyles", borderLeftStyle: "borderStyles", borderRadius: "radii", borderTopLeftRadius: "radii", borderTopRightRadius: "radii", borderBottomRightRadius: "radii", borderBottomLeftRadius: "radii", boxShadow: "shadows", textShadow: "shadows", transition: "transitions", zIndex: "zIndices" }, kn = (e, t) => typeof t == "function" ? { "()": Function.prototype.toString.call(t) } : t, Te = () => {
|
|
7
7
|
const e = /* @__PURE__ */ Object.create(null);
|
|
8
8
|
return (t, n, ...r) => {
|
|
9
9
|
const o = ((i) => JSON.stringify(i, kn))(t);
|
|
10
10
|
return o in e ? e[o] : e[o] = n(t, ...r);
|
|
11
11
|
};
|
|
12
|
-
},
|
|
12
|
+
}, ue = Symbol.for("sxs.internal"), ut = (e, t) => Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)), yt = (e) => {
|
|
13
13
|
for (const t in e)
|
|
14
14
|
return !0;
|
|
15
15
|
return !1;
|
|
16
16
|
}, { hasOwnProperty: Tn } = Object.prototype, rt = (e) => e.includes("-") ? e : e.replace(/[A-Z]/g, (t) => "-" + t.toLowerCase()), In = /\s+(?![^()]*\))/, xe = (e) => (t) => e(...typeof t == "string" ? String(t).split(In) : [t]), vt = { appearance: (e) => ({ WebkitAppearance: e, appearance: e }), backfaceVisibility: (e) => ({ WebkitBackfaceVisibility: e, backfaceVisibility: e }), backdropFilter: (e) => ({ WebkitBackdropFilter: e, backdropFilter: e }), backgroundClip: (e) => ({ WebkitBackgroundClip: e, backgroundClip: e }), boxDecorationBreak: (e) => ({ WebkitBoxDecorationBreak: e, boxDecorationBreak: e }), clipPath: (e) => ({ WebkitClipPath: e, clipPath: e }), content: (e) => ({ content: e.includes('"') || e.includes("'") || /^([A-Za-z]+\([^]*|[^]*-quote|inherit|initial|none|normal|revert|unset)$/.test(e) ? e : `"${e}"` }), hyphens: (e) => ({ WebkitHyphens: e, hyphens: e }), maskImage: (e) => ({ WebkitMaskImage: e, maskImage: e }), maskSize: (e) => ({ WebkitMaskSize: e, maskSize: e }), tabSize: (e) => ({ MozTabSize: e, tabSize: e }), textSizeAdjust: (e) => ({ WebkitTextSizeAdjust: e, textSizeAdjust: e }), userSelect: (e) => ({ WebkitUserSelect: e, userSelect: e }), marginBlock: xe((e, t) => ({ marginBlockStart: e, marginBlockEnd: t || e })), marginInline: xe((e, t) => ({ marginInlineStart: e, marginInlineEnd: t || e })), maxSize: xe((e, t) => ({ maxBlockSize: e, maxInlineSize: t || e })), minSize: xe((e, t) => ({ minBlockSize: e, minInlineSize: t || e })), paddingBlock: xe((e, t) => ({ paddingBlockStart: e, paddingBlockEnd: t || e })), paddingInline: xe((e, t) => ({ paddingInlineStart: e, paddingInlineEnd: t || e })) }, Ge = /([\d.]+)([^]*)/, Pn = (e, t) => e.length ? e.reduce((n, r) => (n.push(...t.map((o) => o.includes("&") ? o.replace(/&/g, /[ +>|~]/.test(r) && /&.*&/.test(o) ? `:is(${r})` : r) : r + " " + o)), n), []) : t, An = (e, t) => e in Bn && typeof t == "string" ? t.replace(/^((?:[^]*[^\w-])?)(fit-content|stretch)((?:[^\w-][^]*)?)$/, (n, r, o, i) => r + (o === "stretch" ? `-moz-available${i};${rt(e)}:${r}-webkit-fill-available` : `-moz-fit-content${i};${rt(e)}:${r}fit-content`) + i) : String(t), Bn = { blockSize: 1, height: 1, inlineSize: 1, maxBlockSize: 1, maxHeight: 1, maxInlineSize: 1, maxWidth: 1, minBlockSize: 1, minHeight: 1, minInlineSize: 1, minWidth: 1, width: 1 }, J = (e) => e ? e + "-" : "", Ut = (e, t, n) => e.replace(/([+-])?((?:\d+(?:\.\d*)?|\.\d+)(?:[Ee][+-]?\d+)?)?(\$|--)([$\w-]+)/g, (r, o, i, s, l) => s == "$" == !!i ? r : (o || s == "--" ? "calc(" : "") + "var(--" + (s === "$" ? J(t) + (l.includes("$") ? "" : J(n)) + l.replace(/\$/g, "-") : l) + ")" + (o || s == "--" ? "*" + (o || "") + (i || "1") + ")" : "")), On = /\s*,\s*(?![^()]*\))/, Dn = Object.prototype.toString, Re = (e, t, n, r, o) => {
|
|
17
17
|
let i, s, l;
|
|
18
|
-
const
|
|
18
|
+
const a = (c, m, d) => {
|
|
19
19
|
let f, u;
|
|
20
20
|
const g = (p) => {
|
|
21
21
|
for (f in p) {
|
|
22
22
|
const x = f.charCodeAt(0) === 64, P = x && Array.isArray(p[f]) ? p[f] : [p[f]];
|
|
23
23
|
for (u of P) {
|
|
24
|
-
const
|
|
25
|
-
if (
|
|
26
|
-
const I = r.utils[
|
|
24
|
+
const S = /[A-Z]/.test(h = f) ? h : h.replace(/-[^]/g, (I) => I[1].toUpperCase()), C = typeof u == "object" && u && u.toString === Dn && (!r.utils[S] || !m.length);
|
|
25
|
+
if (S in r.utils && !C) {
|
|
26
|
+
const I = r.utils[S];
|
|
27
27
|
if (I !== s) {
|
|
28
28
|
s = I, g(I(u)), s = null;
|
|
29
29
|
continue;
|
|
30
30
|
}
|
|
31
|
-
} else if (
|
|
32
|
-
const I = vt[
|
|
31
|
+
} else if (S in vt) {
|
|
32
|
+
const I = vt[S];
|
|
33
33
|
if (I !== l) {
|
|
34
34
|
l = I, g(I(u)), l = null;
|
|
35
35
|
continue;
|
|
36
36
|
}
|
|
37
37
|
}
|
|
38
|
-
if (x && (
|
|
38
|
+
if (x && ($ = f.slice(1) in r.media ? "@media " + r.media[f.slice(1)] : f, f = $.replace(/\(\s*([\w-]+)\s*(=|<|<=|>|>=)\s*([\w-]+)\s*(?:(<|<=|>|>=)\s*([\w-]+)\s*)?\)/g, (I, A, k, O, D, L) => {
|
|
39
39
|
const M = Ge.test(A), B = 0.0625 * (M ? -1 : 1), [b, v] = M ? [O, A] : [A, O];
|
|
40
40
|
return "(" + (k[0] === "=" ? "" : k[0] === ">" === M ? "max-" : "min-") + b + ":" + (k[0] !== "=" && k.length === 1 ? v.replace(Ge, (T, R, w) => Number(R) + B * (k === ">" ? 1 : -1) + w) : v) + (D ? ") and (" + (D[0] === ">" ? "min-" : "max-") + b + ":" + (D.length === 1 ? L.replace(Ge, (T, R, w) => Number(R) + B * (D === ">" ? -1 : 1) + w) : L) : "") + ")";
|
|
41
41
|
})), C) {
|
|
42
42
|
const I = x ? d.concat(f) : [...d], A = x ? [...m] : Pn(m, f.split(On));
|
|
43
|
-
i !== void 0 && o(xt(...i)), i = void 0,
|
|
43
|
+
i !== void 0 && o(xt(...i)), i = void 0, a(u, A, I);
|
|
44
44
|
} else
|
|
45
|
-
i === void 0 && (i = [[], m, d]), f = x || f.charCodeAt(0) !== 36 ? f : `--${J(r.prefix)}${f.slice(1).replace(/\$/g, "-")}`, u = C ? u : typeof u == "number" ? u &&
|
|
45
|
+
i === void 0 && (i = [[], m, d]), f = x || f.charCodeAt(0) !== 36 ? f : `--${J(r.prefix)}${f.slice(1).replace(/\$/g, "-")}`, u = C ? u : typeof u == "number" ? u && S in Mn ? String(u) + "px" : String(u) : Ut(An(S, u ?? ""), r.prefix, r.themeMap[S]), i[0].push(`${x ? `${f} ` : `${rt(f)}:`}${u}`);
|
|
46
46
|
}
|
|
47
47
|
}
|
|
48
|
-
var
|
|
48
|
+
var $, h;
|
|
49
49
|
};
|
|
50
|
-
g(
|
|
50
|
+
g(c), i !== void 0 && o(xt(...i)), i = void 0;
|
|
51
51
|
};
|
|
52
|
-
|
|
53
|
-
}, xt = (e, t, n) => `${n.map((r) => `${r}{`).join("")}${t.length ? `${t.join(",")}{` : ""}${e.join(";")}${t.length ? "}" : ""}${Array(n.length ? n.length + 1 : 0).join("}")}`, Mn = { animationDelay: 1, animationDuration: 1, backgroundSize: 1, blockSize: 1, border: 1, borderBlock: 1, borderBlockEnd: 1, borderBlockEndWidth: 1, borderBlockStart: 1, borderBlockStartWidth: 1, borderBlockWidth: 1, borderBottom: 1, borderBottomLeftRadius: 1, borderBottomRightRadius: 1, borderBottomWidth: 1, borderEndEndRadius: 1, borderEndStartRadius: 1, borderInlineEnd: 1, borderInlineEndWidth: 1, borderInlineStart: 1, borderInlineStartWidth: 1, borderInlineWidth: 1, borderLeft: 1, borderLeftWidth: 1, borderRadius: 1, borderRight: 1, borderRightWidth: 1, borderSpacing: 1, borderStartEndRadius: 1, borderStartStartRadius: 1, borderTop: 1, borderTopLeftRadius: 1, borderTopRightRadius: 1, borderTopWidth: 1, borderWidth: 1, bottom: 1, columnGap: 1, columnRule: 1, columnRuleWidth: 1, columnWidth: 1, containIntrinsicSize: 1, flexBasis: 1, fontSize: 1, gap: 1, gridAutoColumns: 1, gridAutoRows: 1, gridTemplateColumns: 1, gridTemplateRows: 1, height: 1, inlineSize: 1, inset: 1, insetBlock: 1, insetBlockEnd: 1, insetBlockStart: 1, insetInline: 1, insetInlineEnd: 1, insetInlineStart: 1, left: 1, letterSpacing: 1, margin: 1, marginBlock: 1, marginBlockEnd: 1, marginBlockStart: 1, marginBottom: 1, marginInline: 1, marginInlineEnd: 1, marginInlineStart: 1, marginLeft: 1, marginRight: 1, marginTop: 1, maxBlockSize: 1, maxHeight: 1, maxInlineSize: 1, maxWidth: 1, minBlockSize: 1, minHeight: 1, minInlineSize: 1, minWidth: 1, offsetDistance: 1, offsetRotate: 1, outline: 1, outlineOffset: 1, outlineWidth: 1, overflowClipMargin: 1, padding: 1, paddingBlock: 1, paddingBlockEnd: 1, paddingBlockStart: 1, paddingBottom: 1, paddingInline: 1, paddingInlineEnd: 1, paddingInlineStart: 1, paddingLeft: 1, paddingRight: 1, paddingTop: 1, perspective: 1, right: 1, rowGap: 1, scrollMargin: 1, scrollMarginBlock: 1, scrollMarginBlockEnd: 1, scrollMarginBlockStart: 1, scrollMarginBottom: 1, scrollMarginInline: 1, scrollMarginInlineEnd: 1, scrollMarginInlineStart: 1, scrollMarginLeft: 1, scrollMarginRight: 1, scrollMarginTop: 1, scrollPadding: 1, scrollPaddingBlock: 1, scrollPaddingBlockEnd: 1, scrollPaddingBlockStart: 1, scrollPaddingBottom: 1, scrollPaddingInline: 1, scrollPaddingInlineEnd: 1, scrollPaddingInlineStart: 1, scrollPaddingLeft: 1, scrollPaddingRight: 1, scrollPaddingTop: 1, shapeMargin: 1, textDecoration: 1, textDecorationThickness: 1, textIndent: 1, textUnderlineOffset: 1, top: 1, transitionDelay: 1, transitionDuration: 1, verticalAlign: 1, width: 1, wordSpacing: 1 }, wt = (e) => String.fromCharCode(e + (e > 25 ? 39 : 97)),
|
|
52
|
+
a(e, t, n);
|
|
53
|
+
}, xt = (e, t, n) => `${n.map((r) => `${r}{`).join("")}${t.length ? `${t.join(",")}{` : ""}${e.join(";")}${t.length ? "}" : ""}${Array(n.length ? n.length + 1 : 0).join("}")}`, Mn = { animationDelay: 1, animationDuration: 1, backgroundSize: 1, blockSize: 1, border: 1, borderBlock: 1, borderBlockEnd: 1, borderBlockEndWidth: 1, borderBlockStart: 1, borderBlockStartWidth: 1, borderBlockWidth: 1, borderBottom: 1, borderBottomLeftRadius: 1, borderBottomRightRadius: 1, borderBottomWidth: 1, borderEndEndRadius: 1, borderEndStartRadius: 1, borderInlineEnd: 1, borderInlineEndWidth: 1, borderInlineStart: 1, borderInlineStartWidth: 1, borderInlineWidth: 1, borderLeft: 1, borderLeftWidth: 1, borderRadius: 1, borderRight: 1, borderRightWidth: 1, borderSpacing: 1, borderStartEndRadius: 1, borderStartStartRadius: 1, borderTop: 1, borderTopLeftRadius: 1, borderTopRightRadius: 1, borderTopWidth: 1, borderWidth: 1, bottom: 1, columnGap: 1, columnRule: 1, columnRuleWidth: 1, columnWidth: 1, containIntrinsicSize: 1, flexBasis: 1, fontSize: 1, gap: 1, gridAutoColumns: 1, gridAutoRows: 1, gridTemplateColumns: 1, gridTemplateRows: 1, height: 1, inlineSize: 1, inset: 1, insetBlock: 1, insetBlockEnd: 1, insetBlockStart: 1, insetInline: 1, insetInlineEnd: 1, insetInlineStart: 1, left: 1, letterSpacing: 1, margin: 1, marginBlock: 1, marginBlockEnd: 1, marginBlockStart: 1, marginBottom: 1, marginInline: 1, marginInlineEnd: 1, marginInlineStart: 1, marginLeft: 1, marginRight: 1, marginTop: 1, maxBlockSize: 1, maxHeight: 1, maxInlineSize: 1, maxWidth: 1, minBlockSize: 1, minHeight: 1, minInlineSize: 1, minWidth: 1, offsetDistance: 1, offsetRotate: 1, outline: 1, outlineOffset: 1, outlineWidth: 1, overflowClipMargin: 1, padding: 1, paddingBlock: 1, paddingBlockEnd: 1, paddingBlockStart: 1, paddingBottom: 1, paddingInline: 1, paddingInlineEnd: 1, paddingInlineStart: 1, paddingLeft: 1, paddingRight: 1, paddingTop: 1, perspective: 1, right: 1, rowGap: 1, scrollMargin: 1, scrollMarginBlock: 1, scrollMarginBlockEnd: 1, scrollMarginBlockStart: 1, scrollMarginBottom: 1, scrollMarginInline: 1, scrollMarginInlineEnd: 1, scrollMarginInlineStart: 1, scrollMarginLeft: 1, scrollMarginRight: 1, scrollMarginTop: 1, scrollPadding: 1, scrollPaddingBlock: 1, scrollPaddingBlockEnd: 1, scrollPaddingBlockStart: 1, scrollPaddingBottom: 1, scrollPaddingInline: 1, scrollPaddingInlineEnd: 1, scrollPaddingInlineStart: 1, scrollPaddingLeft: 1, scrollPaddingRight: 1, scrollPaddingTop: 1, shapeMargin: 1, textDecoration: 1, textDecorationThickness: 1, textIndent: 1, textUnderlineOffset: 1, top: 1, transitionDelay: 1, transitionDuration: 1, verticalAlign: 1, width: 1, wordSpacing: 1 }, wt = (e) => String.fromCharCode(e + (e > 25 ? 39 : 97)), de = (e) => ((t) => {
|
|
54
54
|
let n, r = "";
|
|
55
55
|
for (n = Math.abs(t); n > 52; n = n / 52 | 0)
|
|
56
56
|
r = wt(n % 52) + r;
|
|
@@ -74,66 +74,66 @@ var N = "colors", V = "sizes", $ = "space", Cn = { gap: $, gridGap: $, columnGap
|
|
|
74
74
|
const { cssRules: o } = t.sheet;
|
|
75
75
|
return [].map.call(o, (i, s) => {
|
|
76
76
|
const { cssText: l } = i;
|
|
77
|
-
let
|
|
77
|
+
let a = "";
|
|
78
78
|
if (l.startsWith("--sxs"))
|
|
79
79
|
return "";
|
|
80
|
-
if (o[s - 1] && (
|
|
80
|
+
if (o[s - 1] && (a = o[s - 1].cssText).startsWith("--sxs")) {
|
|
81
81
|
if (!i.cssRules.length)
|
|
82
82
|
return "";
|
|
83
|
-
for (const
|
|
84
|
-
if (t.rules[
|
|
85
|
-
return `--sxs{--sxs:${[...t.rules[
|
|
86
|
-
return i.cssRules.length ? `${
|
|
83
|
+
for (const c in t.rules)
|
|
84
|
+
if (t.rules[c].group === i)
|
|
85
|
+
return `--sxs{--sxs:${[...t.rules[c].cache].join(" ")}}${l}`;
|
|
86
|
+
return i.cssRules.length ? `${a}${l}` : "";
|
|
87
87
|
}
|
|
88
88
|
return l;
|
|
89
89
|
}).join("");
|
|
90
90
|
}, r = () => {
|
|
91
91
|
if (t) {
|
|
92
|
-
const { rules: l, sheet:
|
|
93
|
-
if (!
|
|
94
|
-
for (; Object(Object(
|
|
95
|
-
|
|
96
|
-
|
|
92
|
+
const { rules: l, sheet: a } = t;
|
|
93
|
+
if (!a.deleteRule) {
|
|
94
|
+
for (; Object(Object(a.cssRules)[0]).type === 3; )
|
|
95
|
+
a.cssRules.splice(0, 1);
|
|
96
|
+
a.cssRules = [];
|
|
97
97
|
}
|
|
98
|
-
for (const
|
|
99
|
-
delete l[
|
|
98
|
+
for (const c in l)
|
|
99
|
+
delete l[c];
|
|
100
100
|
}
|
|
101
101
|
const o = Object(e).styleSheets || [];
|
|
102
102
|
for (const l of o)
|
|
103
103
|
if (Ln(l)) {
|
|
104
|
-
for (let
|
|
105
|
-
const m = Object(a
|
|
104
|
+
for (let a = 0, c = l.cssRules; c[a]; ++a) {
|
|
105
|
+
const m = Object(c[a]);
|
|
106
106
|
if (m.type !== 1)
|
|
107
107
|
continue;
|
|
108
|
-
const d = Object(a
|
|
108
|
+
const d = Object(c[a + 1]);
|
|
109
109
|
if (d.type !== 4)
|
|
110
110
|
continue;
|
|
111
|
-
++
|
|
111
|
+
++a;
|
|
112
112
|
const { cssText: f } = m;
|
|
113
113
|
if (!f.startsWith("--sxs"))
|
|
114
114
|
continue;
|
|
115
115
|
const u = f.slice(14, -3).trim().split(/\s+/), g = Ae[u[0]];
|
|
116
|
-
g && (t || (t = { sheet: l, reset: r, rules: {}, toString: n }), t.rules[g] = { group: d, index:
|
|
116
|
+
g && (t || (t = { sheet: l, reset: r, rules: {}, toString: n }), t.rules[g] = { group: d, index: a, cache: new Set(u) });
|
|
117
117
|
}
|
|
118
118
|
if (t)
|
|
119
119
|
break;
|
|
120
120
|
}
|
|
121
121
|
if (!t) {
|
|
122
|
-
const l = (
|
|
122
|
+
const l = (a, c) => ({ type: c, cssRules: [], insertRule(m, d) {
|
|
123
123
|
this.cssRules.splice(d, 0, l(m, { import: 3, undefined: 1 }[(m.toLowerCase().match(/^@([a-z]+)/) || [])[1]] || 4));
|
|
124
124
|
}, get cssText() {
|
|
125
|
-
return
|
|
125
|
+
return a === "@media{}" ? `@media{${[].map.call(this.cssRules, (m) => m.cssText).join("")}}` : a;
|
|
126
126
|
} });
|
|
127
127
|
t = { sheet: e ? (e.head || e).appendChild(document.createElement("style")).sheet : l("", "text/css"), rules: {}, reset: r, toString: n };
|
|
128
128
|
}
|
|
129
129
|
const { sheet: i, rules: s } = t;
|
|
130
130
|
for (let l = Ae.length - 1; l >= 0; --l) {
|
|
131
|
-
const
|
|
132
|
-
if (!s[
|
|
133
|
-
const
|
|
134
|
-
i.insertRule("@media{}", m), i.insertRule(`--sxs{--sxs:${l}}`, m), s[
|
|
131
|
+
const a = Ae[l];
|
|
132
|
+
if (!s[a]) {
|
|
133
|
+
const c = Ae[l + 1], m = s[c] ? s[c].index : i.cssRules.length;
|
|
134
|
+
i.insertRule("@media{}", m), i.insertRule(`--sxs{--sxs:${l}}`, m), s[a] = { group: i.cssRules[m + 1], index: m, cache: /* @__PURE__ */ new Set([l]) };
|
|
135
135
|
}
|
|
136
|
-
Nn(s[
|
|
136
|
+
Nn(s[a]);
|
|
137
137
|
}
|
|
138
138
|
};
|
|
139
139
|
return r(), t;
|
|
@@ -146,29 +146,29 @@ var N = "colors", V = "sizes", $ = "space", Cn = { gap: $, gridGap: $, columnGap
|
|
|
146
146
|
} catch {
|
|
147
147
|
}
|
|
148
148
|
};
|
|
149
|
-
}, Pe = Symbol(), Wn = Te(),
|
|
149
|
+
}, Pe = Symbol(), Wn = Te(), $t = (e, t) => Wn(e, () => (...n) => {
|
|
150
150
|
let r = { type: null, composers: /* @__PURE__ */ new Set() };
|
|
151
151
|
for (const o of n)
|
|
152
152
|
if (o != null)
|
|
153
|
-
if (o[
|
|
154
|
-
r.type == null && (r.type = o[
|
|
155
|
-
for (const i of o[
|
|
153
|
+
if (o[ue]) {
|
|
154
|
+
r.type == null && (r.type = o[ue].type);
|
|
155
|
+
for (const i of o[ue].composers)
|
|
156
156
|
r.composers.add(i);
|
|
157
157
|
} else
|
|
158
158
|
o.constructor !== Object || o.$$typeof ? r.type == null && (r.type = o) : r.composers.add(jn(o, e));
|
|
159
159
|
return r.type == null && (r.type = "span"), r.composers.size || r.composers.add(["PJLV", {}, [], [], {}, []]), zn(e, r, t);
|
|
160
160
|
}), jn = ({ variants: e, compoundVariants: t, defaultVariants: n, ...r }, o) => {
|
|
161
|
-
const i = `${J(o.prefix)}c-${
|
|
161
|
+
const i = `${J(o.prefix)}c-${de(r)}`, s = [], l = [], a = /* @__PURE__ */ Object.create(null), c = [];
|
|
162
162
|
for (const f in n)
|
|
163
|
-
|
|
163
|
+
a[f] = String(n[f]);
|
|
164
164
|
if (typeof e == "object" && e)
|
|
165
165
|
for (const f in e) {
|
|
166
|
-
m =
|
|
166
|
+
m = a, d = f, Tn.call(m, d) || (a[f] = "undefined");
|
|
167
167
|
const u = e[f];
|
|
168
168
|
for (const g in u) {
|
|
169
169
|
const p = { [f]: String(g) };
|
|
170
|
-
String(g) === "undefined" &&
|
|
171
|
-
const
|
|
170
|
+
String(g) === "undefined" && c.push(f);
|
|
171
|
+
const $ = u[g], h = [p, $, !yt($)];
|
|
172
172
|
s.push(h);
|
|
173
173
|
}
|
|
174
174
|
}
|
|
@@ -177,12 +177,12 @@ var N = "colors", V = "sizes", $ = "space", Cn = { gap: $, gridGap: $, columnGap
|
|
|
177
177
|
for (const f of t) {
|
|
178
178
|
let { css: u, ...g } = f;
|
|
179
179
|
u = typeof u == "object" && u || {};
|
|
180
|
-
for (const
|
|
181
|
-
g[
|
|
180
|
+
for (const $ in g)
|
|
181
|
+
g[$] = String(g[$]);
|
|
182
182
|
const p = [g, u, !yt(u)];
|
|
183
183
|
l.push(p);
|
|
184
184
|
}
|
|
185
|
-
return [i, r, s, l,
|
|
185
|
+
return [i, r, s, l, a, c];
|
|
186
186
|
}, zn = (e, t, n) => {
|
|
187
187
|
const [r, o, i, s] = Hn(t.composers), l = typeof t.type == "function" || t.type.$$typeof ? ((d) => {
|
|
188
188
|
function f() {
|
|
@@ -193,7 +193,7 @@ var N = "colors", V = "sizes", $ = "space", Cn = { gap: $, gridGap: $, columnGap
|
|
|
193
193
|
return f[Pe] = [], null;
|
|
194
194
|
}
|
|
195
195
|
return f[Pe] = [], f.rules = {}, Ae.forEach((u) => f.rules[u] = { apply: (g) => f[Pe].push([u, g]) }), f;
|
|
196
|
-
})(n) : null,
|
|
196
|
+
})(n) : null, a = (l || n).rules, c = `.${r}${o.length > 1 ? `:where(.${o.slice(1).join(".")})` : ""}`, m = (d) => {
|
|
197
197
|
d = typeof d == "object" && d || Vn;
|
|
198
198
|
const { css: f, ...u } = d, g = {};
|
|
199
199
|
for (const h in i)
|
|
@@ -203,17 +203,17 @@ var N = "colors", V = "sizes", $ = "space", Cn = { gap: $, gridGap: $, columnGap
|
|
|
203
203
|
} else
|
|
204
204
|
g[h] = i[h];
|
|
205
205
|
const p = /* @__PURE__ */ new Set([...o]);
|
|
206
|
-
for (const [h, x, P,
|
|
206
|
+
for (const [h, x, P, S] of t.composers) {
|
|
207
207
|
n.rules.styled.cache.has(h) || (n.rules.styled.cache.add(h), Re(x, [`.${h}`], [], e, (A) => {
|
|
208
|
-
|
|
208
|
+
a.styled.apply(A);
|
|
209
209
|
}));
|
|
210
|
-
const C =
|
|
210
|
+
const C = St(P, g, e.media), I = St(S, g, e.media, !0);
|
|
211
211
|
for (const A of C)
|
|
212
212
|
if (A !== void 0)
|
|
213
213
|
for (const [k, O, D] of A) {
|
|
214
|
-
const L = `${h}-${
|
|
214
|
+
const L = `${h}-${de(O)}-${k}`;
|
|
215
215
|
p.add(L);
|
|
216
|
-
const M = (D ? n.rules.resonevar : n.rules.onevar).cache, B = D ?
|
|
216
|
+
const M = (D ? n.rules.resonevar : n.rules.onevar).cache, B = D ? a.resonevar : a.onevar;
|
|
217
217
|
M.has(L) || (M.add(L), Re(O, [`.${L}`], [], e, (b) => {
|
|
218
218
|
B.apply(b);
|
|
219
219
|
}));
|
|
@@ -221,57 +221,57 @@ var N = "colors", V = "sizes", $ = "space", Cn = { gap: $, gridGap: $, columnGap
|
|
|
221
221
|
for (const A of I)
|
|
222
222
|
if (A !== void 0)
|
|
223
223
|
for (const [k, O] of A) {
|
|
224
|
-
const D = `${h}-${
|
|
224
|
+
const D = `${h}-${de(O)}-${k}`;
|
|
225
225
|
p.add(D), n.rules.allvar.cache.has(D) || (n.rules.allvar.cache.add(D), Re(O, [`.${D}`], [], e, (L) => {
|
|
226
|
-
|
|
226
|
+
a.allvar.apply(L);
|
|
227
227
|
}));
|
|
228
228
|
}
|
|
229
229
|
}
|
|
230
230
|
if (typeof f == "object" && f) {
|
|
231
|
-
const h = `${r}-i${
|
|
231
|
+
const h = `${r}-i${de(f)}-css`;
|
|
232
232
|
p.add(h), n.rules.inline.cache.has(h) || (n.rules.inline.cache.add(h), Re(f, [`.${h}`], [], e, (x) => {
|
|
233
|
-
|
|
233
|
+
a.inline.apply(x);
|
|
234
234
|
}));
|
|
235
235
|
}
|
|
236
236
|
for (const h of String(d.className || "").trim().split(/\s+/))
|
|
237
237
|
h && p.add(h);
|
|
238
|
-
const
|
|
239
|
-
return { type: t.type, className:
|
|
238
|
+
const $ = u.className = [...p].join(" ");
|
|
239
|
+
return { type: t.type, className: $, selector: c, props: u, toString: () => $, deferredInjector: l };
|
|
240
240
|
};
|
|
241
|
-
return ut(m, { className: r, selector:
|
|
241
|
+
return ut(m, { className: r, selector: c, [ue]: t, toString: () => (n.rules.styled.cache.has(r) || m(), r) });
|
|
242
242
|
}, Hn = (e) => {
|
|
243
243
|
let t = "";
|
|
244
244
|
const n = [], r = {}, o = [];
|
|
245
245
|
for (const [i, , , , s, l] of e) {
|
|
246
246
|
t === "" && (t = i), n.push(i), o.push(...l);
|
|
247
|
-
for (const
|
|
248
|
-
const
|
|
249
|
-
(r[
|
|
247
|
+
for (const a in s) {
|
|
248
|
+
const c = s[a];
|
|
249
|
+
(r[a] === void 0 || c !== "undefined" || l.includes(c)) && (r[a] = c);
|
|
250
250
|
}
|
|
251
251
|
}
|
|
252
252
|
return [t, n, r, new Set(o)];
|
|
253
|
-
},
|
|
253
|
+
}, St = (e, t, n, r) => {
|
|
254
254
|
const o = [];
|
|
255
255
|
e:
|
|
256
256
|
for (let [i, s, l] of e) {
|
|
257
257
|
if (l)
|
|
258
258
|
continue;
|
|
259
|
-
let
|
|
260
|
-
for (
|
|
261
|
-
const d = i[
|
|
262
|
-
let f = t[
|
|
259
|
+
let a, c = 0, m = !1;
|
|
260
|
+
for (a in i) {
|
|
261
|
+
const d = i[a];
|
|
262
|
+
let f = t[a];
|
|
263
263
|
if (f !== d) {
|
|
264
264
|
if (typeof f != "object" || !f)
|
|
265
265
|
continue e;
|
|
266
266
|
{
|
|
267
267
|
let u, g, p = 0;
|
|
268
|
-
for (const
|
|
269
|
-
if (d === String(f[
|
|
270
|
-
if (
|
|
271
|
-
const h =
|
|
272
|
-
(g = g || []).push(h in n ? n[h] :
|
|
268
|
+
for (const $ in f) {
|
|
269
|
+
if (d === String(f[$])) {
|
|
270
|
+
if ($ !== "@initial") {
|
|
271
|
+
const h = $.slice(1);
|
|
272
|
+
(g = g || []).push(h in n ? n[h] : $.replace(/^@media ?/, "")), m = !0;
|
|
273
273
|
}
|
|
274
|
-
|
|
274
|
+
c += p, u = !0;
|
|
275
275
|
}
|
|
276
276
|
++p;
|
|
277
277
|
}
|
|
@@ -280,14 +280,14 @@ var N = "colors", V = "sizes", $ = "space", Cn = { gap: $, gridGap: $, columnGap
|
|
|
280
280
|
}
|
|
281
281
|
}
|
|
282
282
|
}
|
|
283
|
-
(o[
|
|
283
|
+
(o[c] = o[c] || []).push([r ? "cv" : `${a}-${i[a]}`, s, m]);
|
|
284
284
|
}
|
|
285
285
|
return o;
|
|
286
286
|
}, Vn = {}, _n = Te(), Yn = (e, t) => _n(e, () => (...n) => {
|
|
287
287
|
const r = () => {
|
|
288
288
|
for (let o of n) {
|
|
289
289
|
o = typeof o == "object" && o || {};
|
|
290
|
-
let i =
|
|
290
|
+
let i = de(o);
|
|
291
291
|
if (!t.rules.global.cache.has(i)) {
|
|
292
292
|
if (t.rules.global.cache.add(i), "@import" in o) {
|
|
293
293
|
let s = [].indexOf.call(t.sheet.cssRules, t.rules.themed.group) - 1;
|
|
@@ -304,7 +304,7 @@ var N = "colors", V = "sizes", $ = "space", Cn = { gap: $, gridGap: $, columnGap
|
|
|
304
304
|
};
|
|
305
305
|
return ut(r, { toString: r });
|
|
306
306
|
}), Kn = Te(), Xn = (e, t) => Kn(e, () => (n) => {
|
|
307
|
-
const r = `${J(e.prefix)}k-${
|
|
307
|
+
const r = `${J(e.prefix)}k-${de(n)}`, o = () => {
|
|
308
308
|
if (!t.rules.global.cache.has(r)) {
|
|
309
309
|
t.rules.global.cache.add(r);
|
|
310
310
|
const i = [];
|
|
@@ -332,19 +332,19 @@ var N = "colors", V = "sizes", $ = "space", Cn = { gap: $, gridGap: $, columnGap
|
|
|
332
332
|
}
|
|
333
333
|
}, qn = Te(), Gn = (e, t) => qn(e, () => (n, r) => {
|
|
334
334
|
r = typeof n == "object" && n || Object(r);
|
|
335
|
-
const o = `.${n = (n = typeof n == "string" ? n : "") || `${J(e.prefix)}t-${
|
|
336
|
-
for (const
|
|
337
|
-
i[
|
|
338
|
-
for (const
|
|
339
|
-
const m = `--${J(e.prefix)}${
|
|
340
|
-
i[
|
|
335
|
+
const o = `.${n = (n = typeof n == "string" ? n : "") || `${J(e.prefix)}t-${de(r)}`}`, i = {}, s = [];
|
|
336
|
+
for (const a in r) {
|
|
337
|
+
i[a] = {};
|
|
338
|
+
for (const c in r[a]) {
|
|
339
|
+
const m = `--${J(e.prefix)}${a}-${c}`, d = Ut(String(r[a][c]), e.prefix, a);
|
|
340
|
+
i[a][c] = new Un(c, d, a, e.prefix), s.push(`${m}:${d}`);
|
|
341
341
|
}
|
|
342
342
|
}
|
|
343
343
|
const l = () => {
|
|
344
344
|
if (s.length && !t.rules.themed.cache.has(n)) {
|
|
345
345
|
t.rules.themed.cache.add(n);
|
|
346
|
-
const
|
|
347
|
-
t.rules.themed.apply(
|
|
346
|
+
const a = `${r === e.theme ? ":root," : ""}.${n}{${s.join(";")}}`;
|
|
347
|
+
t.rules.themed.apply(a);
|
|
348
348
|
}
|
|
349
349
|
return n;
|
|
350
350
|
};
|
|
@@ -356,26 +356,26 @@ var N = "colors", V = "sizes", $ = "space", Cn = { gap: $, gridGap: $, columnGap
|
|
|
356
356
|
let r = !1;
|
|
357
357
|
const o = Zn(n, (i) => {
|
|
358
358
|
r = !0;
|
|
359
|
-
const s = "prefix" in (i = typeof i == "object" && i || {}) ? String(i.prefix) : "", l = typeof i.media == "object" && i.media || {},
|
|
359
|
+
const s = "prefix" in (i = typeof i == "object" && i || {}) ? String(i.prefix) : "", l = typeof i.media == "object" && i.media || {}, a = typeof i.root == "object" ? i.root || null : globalThis.document || null, c = typeof i.theme == "object" && i.theme || {}, m = { prefix: s, media: l, theme: c, themeMap: typeof i.themeMap == "object" && i.themeMap || { ...Cn }, utils: typeof i.utils == "object" && i.utils || {} }, d = Fn(a), f = { css: $t(m, d), globalCss: Yn(m, d), keyframes: Xn(m, d), createTheme: Gn(m, d), reset() {
|
|
360
360
|
d.reset(), f.theme.toString();
|
|
361
361
|
}, theme: {}, sheet: d, config: m, prefix: s, getCssText: d.toString, toString: d.toString };
|
|
362
|
-
return String(f.theme = f.createTheme(
|
|
362
|
+
return String(f.theme = f.createTheme(c)), f;
|
|
363
363
|
});
|
|
364
364
|
return r || o.reset(), o;
|
|
365
365
|
})(e);
|
|
366
366
|
return t.styled = (({ config: n, sheet: r }) => Jn(n, () => {
|
|
367
|
-
const o =
|
|
367
|
+
const o = $t(n, r);
|
|
368
368
|
return (...i) => {
|
|
369
|
-
const s = o(...i), l = s[
|
|
370
|
-
const d =
|
|
369
|
+
const s = o(...i), l = s[ue].type, a = ve.forwardRef((c, m) => {
|
|
370
|
+
const d = c && c.as || l, { props: f, deferredInjector: u } = s(c);
|
|
371
371
|
return delete f.as, f.ref = m, u ? ve.createElement(ve.Fragment, null, ve.createElement(d, f), ve.createElement(u, null)) : ve.createElement(d, f);
|
|
372
372
|
});
|
|
373
|
-
return
|
|
373
|
+
return a.className = s.className, a.displayName = `Styled.${l.displayName || l.name || l}`, a.selector = s.selector, a.toString = () => s.selector, a[ue] = s[ue], a;
|
|
374
374
|
};
|
|
375
375
|
}))(t), t;
|
|
376
376
|
};
|
|
377
377
|
let Rt = 9999;
|
|
378
|
-
const Ze = () => (Rt--, Rt), { styled:
|
|
378
|
+
const Ze = () => (Rt--, Rt), { styled: re, css: qt, keyframes: Ie, globalCss: ni } = Qn({
|
|
379
379
|
theme: {
|
|
380
380
|
colors: {
|
|
381
381
|
gray50: "#F9FAFA",
|
|
@@ -516,9 +516,9 @@ const Ze = () => (Rt--, Rt), { styled: he, css: qt, keyframes: Ie, globalCss: ni
|
|
|
516
516
|
"100%": {
|
|
517
517
|
strokeDashoffset: 0
|
|
518
518
|
}
|
|
519
|
-
}), nr =
|
|
519
|
+
}), nr = re("svg", {
|
|
520
520
|
animation: `${er} 2s linear infinite`
|
|
521
|
-
}), rr =
|
|
521
|
+
}), rr = re("circle", {
|
|
522
522
|
animation: `${tr} 1.6s cubic-bezier(0.4, 0.15, 0.6, 0.85) infinite`,
|
|
523
523
|
fill: "transparent",
|
|
524
524
|
stroke: "currentColor",
|
|
@@ -527,7 +527,7 @@ const Ze = () => (Rt--, Rt), { styled: he, css: qt, keyframes: Ie, globalCss: ni
|
|
|
527
527
|
strokeLinecap: "round",
|
|
528
528
|
strokeMiterlimit: 10,
|
|
529
529
|
strokeWidth: 12
|
|
530
|
-
}), or =
|
|
530
|
+
}), or = re("div", {
|
|
531
531
|
lineHeight: 0,
|
|
532
532
|
flexShrink: 0,
|
|
533
533
|
variants: {
|
|
@@ -565,7 +565,7 @@ const Ze = () => (Rt--, Rt), { styled: he, css: qt, keyframes: Ie, globalCss: ni
|
|
|
565
565
|
size: "sm",
|
|
566
566
|
color: "dark"
|
|
567
567
|
}
|
|
568
|
-
}), ir =
|
|
568
|
+
}), ir = ct(
|
|
569
569
|
(e, t) => /* @__PURE__ */ G.jsx(
|
|
570
570
|
or,
|
|
571
571
|
{
|
|
@@ -589,7 +589,7 @@ const Ze = () => (Rt--, Rt), { styled: he, css: qt, keyframes: Ie, globalCss: ni
|
|
|
589
589
|
)
|
|
590
590
|
}
|
|
591
591
|
)
|
|
592
|
-
), sr =
|
|
592
|
+
), sr = re("button", {
|
|
593
593
|
appearance: "none",
|
|
594
594
|
margin: 0,
|
|
595
595
|
padding: 0,
|
|
@@ -734,7 +734,7 @@ const Ze = () => (Rt--, Rt), { styled: he, css: qt, keyframes: Ie, globalCss: ni
|
|
|
734
734
|
color: "secondary",
|
|
735
735
|
size: "md"
|
|
736
736
|
}
|
|
737
|
-
}), ri =
|
|
737
|
+
}), ri = ct(
|
|
738
738
|
({ children: e, disabled: t, isLoading: n, variant: r, color: o, ...i }, s) => (!o && r === "primary" && (o = "primary"), /* @__PURE__ */ G.jsxs(
|
|
739
739
|
sr,
|
|
740
740
|
{
|
|
@@ -750,7 +750,7 @@ const Ze = () => (Rt--, Rt), { styled: he, css: qt, keyframes: Ie, globalCss: ni
|
|
|
750
750
|
]
|
|
751
751
|
}
|
|
752
752
|
))
|
|
753
|
-
), lr =
|
|
753
|
+
), lr = re("div", {
|
|
754
754
|
padding: "$3",
|
|
755
755
|
borderRadius: "$md",
|
|
756
756
|
variants: {
|
|
@@ -789,7 +789,7 @@ const Ze = () => (Rt--, Rt), { styled: he, css: qt, keyframes: Ie, globalCss: ni
|
|
|
789
789
|
color: "info",
|
|
790
790
|
size: "md"
|
|
791
791
|
}
|
|
792
|
-
}), oi =
|
|
792
|
+
}), oi = ct(
|
|
793
793
|
({ children: e, ...t }, n) => /* @__PURE__ */ G.jsx(
|
|
794
794
|
lr,
|
|
795
795
|
{
|
|
@@ -799,10 +799,10 @@ const Ze = () => (Rt--, Rt), { styled: he, css: qt, keyframes: Ie, globalCss: ni
|
|
|
799
799
|
children: e
|
|
800
800
|
}
|
|
801
801
|
)
|
|
802
|
-
),
|
|
802
|
+
), ar = Ie({
|
|
803
803
|
"0%": { opacity: 0, transform: "translateY(0.5rem)" },
|
|
804
804
|
"100%": { opacity: 1, transform: "translateY(0)" }
|
|
805
|
-
}),
|
|
805
|
+
}), cr = Ie({
|
|
806
806
|
"0%": { opacity: 0, transform: "translateX(-0.5rem)" },
|
|
807
807
|
"100%": { opacity: 1, transform: "translateX(0)" }
|
|
808
808
|
}), ur = Ie({
|
|
@@ -824,10 +824,10 @@ const Ze = () => (Rt--, Rt), { styled: he, css: qt, keyframes: Ie, globalCss: ni
|
|
|
824
824
|
'&[data-state="open"]': {
|
|
825
825
|
'&[data-side="top"]': { animationName: ur },
|
|
826
826
|
'&[data-side="right"]': { animationName: dr },
|
|
827
|
-
'&[data-side="bottom"]': { animationName:
|
|
828
|
-
'&[data-side="left"]': { animationName:
|
|
827
|
+
'&[data-side="bottom"]': { animationName: ar },
|
|
828
|
+
'&[data-side="left"]': { animationName: cr }
|
|
829
829
|
}
|
|
830
|
-
}), gr =
|
|
830
|
+
}), gr = re(
|
|
831
831
|
"div",
|
|
832
832
|
fr,
|
|
833
833
|
mr
|
|
@@ -872,11 +872,11 @@ function dt(e) {
|
|
|
872
872
|
return n.transform !== "none" || n.perspective !== "none" || (n.containerType ? n.containerType !== "normal" : !1) || !t && (n.backdropFilter ? n.backdropFilter !== "none" : !1) || !t && (n.filter ? n.filter !== "none" : !1) || ["transform", "perspective", "filter"].some((r) => (n.willChange || "").includes(r)) || ["paint", "layout", "strict", "content"].some((r) => (n.contain || "").includes(r));
|
|
873
873
|
}
|
|
874
874
|
function hr(e) {
|
|
875
|
-
let t =
|
|
875
|
+
let t = ge(e);
|
|
876
876
|
for (; U(t) && !ke(t); ) {
|
|
877
877
|
if (dt(t))
|
|
878
878
|
return t;
|
|
879
|
-
t =
|
|
879
|
+
t = ge(t);
|
|
880
880
|
}
|
|
881
881
|
return null;
|
|
882
882
|
}
|
|
@@ -898,7 +898,7 @@ function Ye(e) {
|
|
|
898
898
|
scrollTop: e.pageYOffset
|
|
899
899
|
};
|
|
900
900
|
}
|
|
901
|
-
function
|
|
901
|
+
function ge(e) {
|
|
902
902
|
if (te(e) === "html")
|
|
903
903
|
return e;
|
|
904
904
|
const t = (
|
|
@@ -911,7 +911,7 @@ function me(e) {
|
|
|
911
911
|
return ot(t) ? t.host : t;
|
|
912
912
|
}
|
|
913
913
|
function Zt(e) {
|
|
914
|
-
const t =
|
|
914
|
+
const t = ge(e);
|
|
915
915
|
return ke(t) ? e.ownerDocument ? e.ownerDocument.body : e.body : U(t) && Oe(t) ? t : Zt(t);
|
|
916
916
|
}
|
|
917
917
|
function ee(e, t, n) {
|
|
@@ -928,7 +928,7 @@ function br(e) {
|
|
|
928
928
|
}
|
|
929
929
|
return t;
|
|
930
930
|
}
|
|
931
|
-
function
|
|
931
|
+
function fe(e, t) {
|
|
932
932
|
if (!e || !t)
|
|
933
933
|
return !1;
|
|
934
934
|
const n = t.getRootNode == null ? void 0 : t.getRootNode();
|
|
@@ -968,17 +968,17 @@ function Je(e, t) {
|
|
|
968
968
|
const n = e;
|
|
969
969
|
return n.target != null && t.contains(n.target);
|
|
970
970
|
}
|
|
971
|
-
function
|
|
971
|
+
function $e(e) {
|
|
972
972
|
return "composedPath" in e ? e.composedPath()[0] : e.target;
|
|
973
973
|
}
|
|
974
974
|
const wr = "input:not([type='hidden']):not([disabled]),[contenteditable]:not([contenteditable='false']),textarea:not([disabled])";
|
|
975
|
-
function
|
|
975
|
+
function $r(e) {
|
|
976
976
|
return U(e) && e.matches(wr);
|
|
977
977
|
}
|
|
978
|
-
const Ne = Math.min,
|
|
978
|
+
const Ne = Math.min, me = Math.max, We = Math.round, De = Math.floor, ne = (e) => ({
|
|
979
979
|
x: e,
|
|
980
980
|
y: e
|
|
981
|
-
}),
|
|
981
|
+
}), Sr = {
|
|
982
982
|
left: "right",
|
|
983
983
|
right: "left",
|
|
984
984
|
bottom: "top",
|
|
@@ -987,13 +987,13 @@ const Ne = Math.min, fe = Math.max, We = Math.round, De = Math.floor, ne = (e) =
|
|
|
987
987
|
start: "end",
|
|
988
988
|
end: "start"
|
|
989
989
|
};
|
|
990
|
-
function
|
|
991
|
-
return
|
|
990
|
+
function Et(e, t, n) {
|
|
991
|
+
return me(e, Ne(t, n));
|
|
992
992
|
}
|
|
993
993
|
function Ke(e, t) {
|
|
994
994
|
return typeof e == "function" ? e(t) : e;
|
|
995
995
|
}
|
|
996
|
-
function
|
|
996
|
+
function pe(e) {
|
|
997
997
|
return e.split("-")[0];
|
|
998
998
|
}
|
|
999
999
|
function Xe(e) {
|
|
@@ -1006,12 +1006,12 @@ function Qt(e) {
|
|
|
1006
1006
|
return e === "y" ? "height" : "width";
|
|
1007
1007
|
}
|
|
1008
1008
|
function Ue(e) {
|
|
1009
|
-
return ["top", "bottom"].includes(
|
|
1009
|
+
return ["top", "bottom"].includes(pe(e)) ? "y" : "x";
|
|
1010
1010
|
}
|
|
1011
1011
|
function en(e) {
|
|
1012
1012
|
return Jt(Ue(e));
|
|
1013
1013
|
}
|
|
1014
|
-
function
|
|
1014
|
+
function Er(e, t, n) {
|
|
1015
1015
|
n === void 0 && (n = !1);
|
|
1016
1016
|
const r = Xe(e), o = en(e), i = Qt(o);
|
|
1017
1017
|
let s = o === "x" ? r === (n ? "end" : "start") ? "right" : "left" : r === "start" ? "bottom" : "top";
|
|
@@ -1039,11 +1039,11 @@ function kr(e, t, n) {
|
|
|
1039
1039
|
}
|
|
1040
1040
|
function Tr(e, t, n, r) {
|
|
1041
1041
|
const o = Xe(e);
|
|
1042
|
-
let i = kr(
|
|
1042
|
+
let i = kr(pe(e), n === "start", r);
|
|
1043
1043
|
return o && (i = i.map((s) => s + "-" + o), t && (i = i.concat(i.map(it)))), i;
|
|
1044
1044
|
}
|
|
1045
1045
|
function je(e) {
|
|
1046
|
-
return e.replace(/left|right|bottom|top/g, (t) =>
|
|
1046
|
+
return e.replace(/left|right|bottom|top/g, (t) => Sr[t]);
|
|
1047
1047
|
}
|
|
1048
1048
|
function Ir(e) {
|
|
1049
1049
|
return {
|
|
@@ -1076,9 +1076,9 @@ function Ct(e, t, n) {
|
|
|
1076
1076
|
reference: r,
|
|
1077
1077
|
floating: o
|
|
1078
1078
|
} = e;
|
|
1079
|
-
const i = Ue(t), s = en(t), l = Qt(s),
|
|
1079
|
+
const i = Ue(t), s = en(t), l = Qt(s), a = pe(t), c = i === "y", m = r.x + r.width / 2 - o.width / 2, d = r.y + r.height / 2 - o.height / 2, f = r[l] / 2 - o[l] / 2;
|
|
1080
1080
|
let u;
|
|
1081
|
-
switch (
|
|
1081
|
+
switch (a) {
|
|
1082
1082
|
case "top":
|
|
1083
1083
|
u = {
|
|
1084
1084
|
x: m,
|
|
@@ -1111,10 +1111,10 @@ function Ct(e, t, n) {
|
|
|
1111
1111
|
}
|
|
1112
1112
|
switch (Xe(t)) {
|
|
1113
1113
|
case "start":
|
|
1114
|
-
u[s] -= f * (n &&
|
|
1114
|
+
u[s] -= f * (n && c ? -1 : 1);
|
|
1115
1115
|
break;
|
|
1116
1116
|
case "end":
|
|
1117
|
-
u[s] += f * (n &&
|
|
1117
|
+
u[s] += f * (n && c ? -1 : 1);
|
|
1118
1118
|
break;
|
|
1119
1119
|
}
|
|
1120
1120
|
return u;
|
|
@@ -1125,23 +1125,23 @@ const Ar = async (e, t, n) => {
|
|
|
1125
1125
|
strategy: o = "absolute",
|
|
1126
1126
|
middleware: i = [],
|
|
1127
1127
|
platform: s
|
|
1128
|
-
} = n, l = i.filter(Boolean),
|
|
1129
|
-
let
|
|
1128
|
+
} = n, l = i.filter(Boolean), a = await (s.isRTL == null ? void 0 : s.isRTL(t));
|
|
1129
|
+
let c = await s.getElementRects({
|
|
1130
1130
|
reference: e,
|
|
1131
1131
|
floating: t,
|
|
1132
1132
|
strategy: o
|
|
1133
1133
|
}), {
|
|
1134
1134
|
x: m,
|
|
1135
1135
|
y: d
|
|
1136
|
-
} = Ct(
|
|
1136
|
+
} = Ct(c, r, a), f = r, u = {}, g = 0;
|
|
1137
1137
|
for (let p = 0; p < l.length; p++) {
|
|
1138
1138
|
const {
|
|
1139
|
-
name:
|
|
1139
|
+
name: $,
|
|
1140
1140
|
fn: h
|
|
1141
1141
|
} = l[p], {
|
|
1142
1142
|
x,
|
|
1143
1143
|
y: P,
|
|
1144
|
-
data:
|
|
1144
|
+
data: S,
|
|
1145
1145
|
reset: C
|
|
1146
1146
|
} = await h({
|
|
1147
1147
|
x: m,
|
|
@@ -1150,7 +1150,7 @@ const Ar = async (e, t, n) => {
|
|
|
1150
1150
|
placement: f,
|
|
1151
1151
|
strategy: o,
|
|
1152
1152
|
middlewareData: u,
|
|
1153
|
-
rects:
|
|
1153
|
+
rects: c,
|
|
1154
1154
|
platform: s,
|
|
1155
1155
|
elements: {
|
|
1156
1156
|
reference: e,
|
|
@@ -1159,18 +1159,18 @@ const Ar = async (e, t, n) => {
|
|
|
1159
1159
|
});
|
|
1160
1160
|
m = x ?? m, d = P ?? d, u = {
|
|
1161
1161
|
...u,
|
|
1162
|
-
[
|
|
1163
|
-
...u[
|
|
1164
|
-
...
|
|
1162
|
+
[$]: {
|
|
1163
|
+
...u[$],
|
|
1164
|
+
...S
|
|
1165
1165
|
}
|
|
1166
|
-
}, C && g <= 50 && (g++, typeof C == "object" && (C.placement && (f = C.placement), C.rects && (
|
|
1166
|
+
}, C && g <= 50 && (g++, typeof C == "object" && (C.placement && (f = C.placement), C.rects && (c = C.rects === !0 ? await s.getElementRects({
|
|
1167
1167
|
reference: e,
|
|
1168
1168
|
floating: t,
|
|
1169
1169
|
strategy: o
|
|
1170
1170
|
}) : C.rects), {
|
|
1171
1171
|
x: m,
|
|
1172
1172
|
y: d
|
|
1173
|
-
} = Ct(
|
|
1173
|
+
} = Ct(c, f, a)), p = -1);
|
|
1174
1174
|
}
|
|
1175
1175
|
return {
|
|
1176
1176
|
x: m,
|
|
@@ -1189,23 +1189,23 @@ async function tn(e, t) {
|
|
|
1189
1189
|
platform: i,
|
|
1190
1190
|
rects: s,
|
|
1191
1191
|
elements: l,
|
|
1192
|
-
strategy:
|
|
1192
|
+
strategy: a
|
|
1193
1193
|
} = e, {
|
|
1194
|
-
boundary:
|
|
1194
|
+
boundary: c = "clippingAncestors",
|
|
1195
1195
|
rootBoundary: m = "viewport",
|
|
1196
1196
|
elementContext: d = "floating",
|
|
1197
1197
|
altBoundary: f = !1,
|
|
1198
1198
|
padding: u = 0
|
|
1199
|
-
} = Ke(t, e), g = Pr(u),
|
|
1200
|
-
element: (n = await (i.isElement == null ? void 0 : i.isElement(
|
|
1201
|
-
boundary:
|
|
1199
|
+
} = Ke(t, e), g = Pr(u), $ = l[f ? d === "floating" ? "reference" : "floating" : d], h = ze(await i.getClippingRect({
|
|
1200
|
+
element: (n = await (i.isElement == null ? void 0 : i.isElement($))) == null || n ? $ : $.contextElement || await (i.getDocumentElement == null ? void 0 : i.getDocumentElement(l.floating)),
|
|
1201
|
+
boundary: c,
|
|
1202
1202
|
rootBoundary: m,
|
|
1203
|
-
strategy:
|
|
1203
|
+
strategy: a
|
|
1204
1204
|
})), x = d === "floating" ? {
|
|
1205
1205
|
...s.floating,
|
|
1206
1206
|
x: r,
|
|
1207
1207
|
y: o
|
|
1208
|
-
} : s.reference, P = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(l.floating)),
|
|
1208
|
+
} : s.reference, P = await (i.getOffsetParent == null ? void 0 : i.getOffsetParent(l.floating)), S = await (i.isElement == null ? void 0 : i.isElement(P)) ? await (i.getScale == null ? void 0 : i.getScale(P)) || {
|
|
1209
1209
|
x: 1,
|
|
1210
1210
|
y: 1
|
|
1211
1211
|
} : {
|
|
@@ -1215,13 +1215,13 @@ async function tn(e, t) {
|
|
|
1215
1215
|
elements: l,
|
|
1216
1216
|
rect: x,
|
|
1217
1217
|
offsetParent: P,
|
|
1218
|
-
strategy:
|
|
1218
|
+
strategy: a
|
|
1219
1219
|
}) : x);
|
|
1220
1220
|
return {
|
|
1221
|
-
top: (h.top - C.top + g.top) /
|
|
1222
|
-
bottom: (C.bottom - h.bottom + g.bottom) /
|
|
1223
|
-
left: (h.left - C.left + g.left) /
|
|
1224
|
-
right: (C.right - h.right + g.right) /
|
|
1221
|
+
top: (h.top - C.top + g.top) / S.y,
|
|
1222
|
+
bottom: (C.bottom - h.bottom + g.bottom) / S.y,
|
|
1223
|
+
left: (h.left - C.left + g.left) / S.x,
|
|
1224
|
+
right: (C.right - h.right + g.right) / S.x
|
|
1225
1225
|
};
|
|
1226
1226
|
}
|
|
1227
1227
|
const Br = function(e) {
|
|
@@ -1235,8 +1235,8 @@ const Br = function(e) {
|
|
|
1235
1235
|
middlewareData: i,
|
|
1236
1236
|
rects: s,
|
|
1237
1237
|
initialPlacement: l,
|
|
1238
|
-
platform:
|
|
1239
|
-
elements:
|
|
1238
|
+
platform: a,
|
|
1239
|
+
elements: c
|
|
1240
1240
|
} = t, {
|
|
1241
1241
|
mainAxis: m = !0,
|
|
1242
1242
|
crossAxis: d = !0,
|
|
@@ -1244,16 +1244,16 @@ const Br = function(e) {
|
|
|
1244
1244
|
fallbackStrategy: u = "bestFit",
|
|
1245
1245
|
fallbackAxisSideDirection: g = "none",
|
|
1246
1246
|
flipAlignment: p = !0,
|
|
1247
|
-
|
|
1247
|
+
...$
|
|
1248
1248
|
} = Ke(e, t);
|
|
1249
1249
|
if ((n = i.arrow) != null && n.alignmentOffset)
|
|
1250
1250
|
return {};
|
|
1251
|
-
const h =
|
|
1252
|
-
!f && g !== "none" &&
|
|
1253
|
-
const C = [l, ...
|
|
1251
|
+
const h = pe(o), x = pe(l) === l, P = await (a.isRTL == null ? void 0 : a.isRTL(c.floating)), S = f || (x || !p ? [je(l)] : Cr(l));
|
|
1252
|
+
!f && g !== "none" && S.push(...Tr(l, p, g, P));
|
|
1253
|
+
const C = [l, ...S], I = await tn(t, $), A = [];
|
|
1254
1254
|
let k = ((r = i.flip) == null ? void 0 : r.overflows) || [];
|
|
1255
1255
|
if (m && A.push(I[h]), d) {
|
|
1256
|
-
const M =
|
|
1256
|
+
const M = Er(o, s, P);
|
|
1257
1257
|
A.push(I[M[0]], I[M[1]]);
|
|
1258
1258
|
}
|
|
1259
1259
|
if (k = [...k, {
|
|
@@ -1301,7 +1301,7 @@ async function Or(e, t) {
|
|
|
1301
1301
|
placement: n,
|
|
1302
1302
|
platform: r,
|
|
1303
1303
|
elements: o
|
|
1304
|
-
} = e, i = await (r.isRTL == null ? void 0 : r.isRTL(o.floating)), s =
|
|
1304
|
+
} = e, i = await (r.isRTL == null ? void 0 : r.isRTL(o.floating)), s = pe(n), l = Xe(n), a = Ue(n) === "y", c = ["left", "top"].includes(s) ? -1 : 1, m = i && a ? -1 : 1, d = Ke(t, e);
|
|
1305
1305
|
let {
|
|
1306
1306
|
mainAxis: f,
|
|
1307
1307
|
crossAxis: u,
|
|
@@ -1316,11 +1316,11 @@ async function Or(e, t) {
|
|
|
1316
1316
|
alignmentAxis: null,
|
|
1317
1317
|
...d
|
|
1318
1318
|
};
|
|
1319
|
-
return l && typeof g == "number" && (u = l === "end" ? g * -1 : g),
|
|
1319
|
+
return l && typeof g == "number" && (u = l === "end" ? g * -1 : g), a ? {
|
|
1320
1320
|
x: u * m,
|
|
1321
|
-
y: f *
|
|
1321
|
+
y: f * c
|
|
1322
1322
|
} : {
|
|
1323
|
-
x: f *
|
|
1323
|
+
x: f * c,
|
|
1324
1324
|
y: u * m
|
|
1325
1325
|
};
|
|
1326
1326
|
}
|
|
@@ -1335,12 +1335,12 @@ const Dr = function(e) {
|
|
|
1335
1335
|
y: i,
|
|
1336
1336
|
placement: s,
|
|
1337
1337
|
middlewareData: l
|
|
1338
|
-
} = t,
|
|
1338
|
+
} = t, a = await Or(t, e);
|
|
1339
1339
|
return s === ((n = l.offset) == null ? void 0 : n.placement) && (r = l.arrow) != null && r.alignmentOffset ? {} : {
|
|
1340
|
-
x: o +
|
|
1341
|
-
y: i +
|
|
1340
|
+
x: o + a.x,
|
|
1341
|
+
y: i + a.y,
|
|
1342
1342
|
data: {
|
|
1343
|
-
...
|
|
1343
|
+
...a,
|
|
1344
1344
|
placement: s
|
|
1345
1345
|
}
|
|
1346
1346
|
};
|
|
@@ -1359,30 +1359,30 @@ const Dr = function(e) {
|
|
|
1359
1359
|
mainAxis: i = !0,
|
|
1360
1360
|
crossAxis: s = !1,
|
|
1361
1361
|
limiter: l = {
|
|
1362
|
-
fn: (
|
|
1362
|
+
fn: ($) => {
|
|
1363
1363
|
let {
|
|
1364
1364
|
x: h,
|
|
1365
1365
|
y: x
|
|
1366
|
-
} =
|
|
1366
|
+
} = $;
|
|
1367
1367
|
return {
|
|
1368
1368
|
x: h,
|
|
1369
1369
|
y: x
|
|
1370
1370
|
};
|
|
1371
1371
|
}
|
|
1372
1372
|
},
|
|
1373
|
-
...
|
|
1374
|
-
} = Ke(e, t),
|
|
1373
|
+
...a
|
|
1374
|
+
} = Ke(e, t), c = {
|
|
1375
1375
|
x: n,
|
|
1376
1376
|
y: r
|
|
1377
|
-
}, m = await tn(t,
|
|
1378
|
-
let u =
|
|
1377
|
+
}, m = await tn(t, a), d = Ue(pe(o)), f = Jt(d);
|
|
1378
|
+
let u = c[f], g = c[d];
|
|
1379
1379
|
if (i) {
|
|
1380
|
-
const
|
|
1381
|
-
u =
|
|
1380
|
+
const $ = f === "y" ? "top" : "left", h = f === "y" ? "bottom" : "right", x = u + m[$], P = u - m[h];
|
|
1381
|
+
u = Et(x, u, P);
|
|
1382
1382
|
}
|
|
1383
1383
|
if (s) {
|
|
1384
|
-
const
|
|
1385
|
-
g =
|
|
1384
|
+
const $ = d === "y" ? "top" : "left", h = d === "y" ? "bottom" : "right", x = g + m[$], P = g - m[h];
|
|
1385
|
+
g = Et(x, g, P);
|
|
1386
1386
|
}
|
|
1387
1387
|
const p = l.fn({
|
|
1388
1388
|
...t,
|
|
@@ -1438,26 +1438,26 @@ function rn(e) {
|
|
|
1438
1438
|
function Fr(e, t, n) {
|
|
1439
1439
|
return t === void 0 && (t = !1), !n || t && n !== X(e) ? !1 : t;
|
|
1440
1440
|
}
|
|
1441
|
-
function
|
|
1441
|
+
function he(e, t, n, r) {
|
|
1442
1442
|
t === void 0 && (t = !1), n === void 0 && (n = !1);
|
|
1443
1443
|
const o = e.getBoundingClientRect(), i = mt(e);
|
|
1444
1444
|
let s = ne(1);
|
|
1445
1445
|
t && (r ? W(r) && (s = Ce(r)) : s = Ce(e));
|
|
1446
1446
|
const l = Fr(i, n, r) ? rn(i) : ne(0);
|
|
1447
|
-
let
|
|
1447
|
+
let a = (o.left + l.x) / s.x, c = (o.top + l.y) / s.y, m = o.width / s.x, d = o.height / s.y;
|
|
1448
1448
|
if (i) {
|
|
1449
1449
|
const f = X(i), u = r && W(r) ? X(r) : r;
|
|
1450
1450
|
let g = f, p = g.frameElement;
|
|
1451
1451
|
for (; p && r && u !== g; ) {
|
|
1452
|
-
const
|
|
1453
|
-
|
|
1452
|
+
const $ = Ce(p), h = p.getBoundingClientRect(), x = q(p), P = h.left + (p.clientLeft + parseFloat(x.paddingLeft)) * $.x, S = h.top + (p.clientTop + parseFloat(x.paddingTop)) * $.y;
|
|
1453
|
+
a *= $.x, c *= $.y, m *= $.x, d *= $.y, a += P, c += S, g = X(p), p = g.frameElement;
|
|
1454
1454
|
}
|
|
1455
1455
|
}
|
|
1456
1456
|
return ze({
|
|
1457
1457
|
width: m,
|
|
1458
1458
|
height: d,
|
|
1459
|
-
x:
|
|
1460
|
-
y:
|
|
1459
|
+
x: a,
|
|
1460
|
+
y: c
|
|
1461
1461
|
});
|
|
1462
1462
|
}
|
|
1463
1463
|
const Nr = [":popover-open", ":modal"];
|
|
@@ -1480,33 +1480,33 @@ function Wr(e) {
|
|
|
1480
1480
|
const i = o === "fixed", s = Q(r), l = t ? on(t.floating) : !1;
|
|
1481
1481
|
if (r === s || l && i)
|
|
1482
1482
|
return n;
|
|
1483
|
-
let
|
|
1483
|
+
let a = {
|
|
1484
1484
|
scrollLeft: 0,
|
|
1485
1485
|
scrollTop: 0
|
|
1486
|
-
},
|
|
1486
|
+
}, c = ne(1);
|
|
1487
1487
|
const m = ne(0), d = U(r);
|
|
1488
|
-
if ((d || !d && !i) && ((te(r) !== "body" || Oe(s)) && (
|
|
1489
|
-
const f =
|
|
1490
|
-
|
|
1488
|
+
if ((d || !d && !i) && ((te(r) !== "body" || Oe(s)) && (a = Ye(r)), U(r))) {
|
|
1489
|
+
const f = he(r);
|
|
1490
|
+
c = Ce(r), m.x = f.x + r.clientLeft, m.y = f.y + r.clientTop;
|
|
1491
1491
|
}
|
|
1492
1492
|
return {
|
|
1493
|
-
width: n.width *
|
|
1494
|
-
height: n.height *
|
|
1495
|
-
x: n.x *
|
|
1496
|
-
y: n.y *
|
|
1493
|
+
width: n.width * c.x,
|
|
1494
|
+
height: n.height * c.y,
|
|
1495
|
+
x: n.x * c.x - a.scrollLeft * c.x + m.x,
|
|
1496
|
+
y: n.y * c.y - a.scrollTop * c.y + m.y
|
|
1497
1497
|
};
|
|
1498
1498
|
}
|
|
1499
1499
|
function jr(e) {
|
|
1500
1500
|
return Array.from(e.getClientRects());
|
|
1501
1501
|
}
|
|
1502
1502
|
function sn(e) {
|
|
1503
|
-
return
|
|
1503
|
+
return he(Q(e)).left + Ye(e).scrollLeft;
|
|
1504
1504
|
}
|
|
1505
1505
|
function zr(e) {
|
|
1506
|
-
const t = Q(e), n = Ye(e), r = e.ownerDocument.body, o =
|
|
1506
|
+
const t = Q(e), n = Ye(e), r = e.ownerDocument.body, o = me(t.scrollWidth, t.clientWidth, r.scrollWidth, r.clientWidth), i = me(t.scrollHeight, t.clientHeight, r.scrollHeight, r.clientHeight);
|
|
1507
1507
|
let s = -n.scrollLeft + sn(e);
|
|
1508
1508
|
const l = -n.scrollTop;
|
|
1509
|
-
return q(r).direction === "rtl" && (s +=
|
|
1509
|
+
return q(r).direction === "rtl" && (s += me(t.clientWidth, r.clientWidth) - o), {
|
|
1510
1510
|
width: o,
|
|
1511
1511
|
height: i,
|
|
1512
1512
|
x: s,
|
|
@@ -1515,26 +1515,26 @@ function zr(e) {
|
|
|
1515
1515
|
}
|
|
1516
1516
|
function Hr(e, t) {
|
|
1517
1517
|
const n = X(e), r = Q(e), o = n.visualViewport;
|
|
1518
|
-
let i = r.clientWidth, s = r.clientHeight, l = 0,
|
|
1518
|
+
let i = r.clientWidth, s = r.clientHeight, l = 0, a = 0;
|
|
1519
1519
|
if (o) {
|
|
1520
1520
|
i = o.width, s = o.height;
|
|
1521
|
-
const
|
|
1522
|
-
(!
|
|
1521
|
+
const c = ft();
|
|
1522
|
+
(!c || c && t === "fixed") && (l = o.offsetLeft, a = o.offsetTop);
|
|
1523
1523
|
}
|
|
1524
1524
|
return {
|
|
1525
1525
|
width: i,
|
|
1526
1526
|
height: s,
|
|
1527
1527
|
x: l,
|
|
1528
|
-
y:
|
|
1528
|
+
y: a
|
|
1529
1529
|
};
|
|
1530
1530
|
}
|
|
1531
1531
|
function Vr(e, t) {
|
|
1532
|
-
const n =
|
|
1532
|
+
const n = he(e, !0, t === "fixed"), r = n.top + e.clientTop, o = n.left + e.clientLeft, i = U(e) ? Ce(e) : ne(1), s = e.clientWidth * i.x, l = e.clientHeight * i.y, a = o * i.x, c = r * i.y;
|
|
1533
1533
|
return {
|
|
1534
1534
|
width: s,
|
|
1535
1535
|
height: l,
|
|
1536
|
-
x:
|
|
1537
|
-
y:
|
|
1536
|
+
x: a,
|
|
1537
|
+
y: c
|
|
1538
1538
|
};
|
|
1539
1539
|
}
|
|
1540
1540
|
function kt(e, t, n) {
|
|
@@ -1556,7 +1556,7 @@ function kt(e, t, n) {
|
|
|
1556
1556
|
return ze(r);
|
|
1557
1557
|
}
|
|
1558
1558
|
function ln(e, t) {
|
|
1559
|
-
const n =
|
|
1559
|
+
const n = ge(e);
|
|
1560
1560
|
return n === t || !W(n) || ke(n) ? !1 : q(n).position === "fixed" || ln(n, t);
|
|
1561
1561
|
}
|
|
1562
1562
|
function _r(e, t) {
|
|
@@ -1565,10 +1565,10 @@ function _r(e, t) {
|
|
|
1565
1565
|
return n;
|
|
1566
1566
|
let r = ee(e, [], !1).filter((l) => W(l) && te(l) !== "body"), o = null;
|
|
1567
1567
|
const i = q(e).position === "fixed";
|
|
1568
|
-
let s = i ?
|
|
1568
|
+
let s = i ? ge(e) : e;
|
|
1569
1569
|
for (; W(s) && !ke(s); ) {
|
|
1570
|
-
const l = q(s),
|
|
1571
|
-
!
|
|
1570
|
+
const l = q(s), a = dt(s);
|
|
1571
|
+
!a && l.position === "fixed" && (o = null), (i ? !a && !o : !a && l.position === "static" && !!o && ["absolute", "fixed"].includes(o.position) || Oe(s) && !a && ln(e, s)) ? r = r.filter((m) => m !== s) : o = l, s = ge(s);
|
|
1572
1572
|
}
|
|
1573
1573
|
return t.set(e, r), r;
|
|
1574
1574
|
}
|
|
@@ -1579,15 +1579,15 @@ function Yr(e) {
|
|
|
1579
1579
|
rootBoundary: r,
|
|
1580
1580
|
strategy: o
|
|
1581
1581
|
} = e;
|
|
1582
|
-
const s = [...n === "clippingAncestors" ? _r(t, this._c) : [].concat(n), r], l = s[0],
|
|
1582
|
+
const s = [...n === "clippingAncestors" ? _r(t, this._c) : [].concat(n), r], l = s[0], a = s.reduce((c, m) => {
|
|
1583
1583
|
const d = kt(t, m, o);
|
|
1584
|
-
return
|
|
1584
|
+
return c.top = me(d.top, c.top), c.right = Ne(d.right, c.right), c.bottom = Ne(d.bottom, c.bottom), c.left = me(d.left, c.left), c;
|
|
1585
1585
|
}, kt(t, l, o));
|
|
1586
1586
|
return {
|
|
1587
|
-
width:
|
|
1588
|
-
height:
|
|
1589
|
-
x:
|
|
1590
|
-
y:
|
|
1587
|
+
width: a.right - a.left,
|
|
1588
|
+
height: a.bottom - a.top,
|
|
1589
|
+
x: a.left,
|
|
1590
|
+
y: a.top
|
|
1591
1591
|
};
|
|
1592
1592
|
}
|
|
1593
1593
|
function Kr(e) {
|
|
@@ -1601,21 +1601,21 @@ function Kr(e) {
|
|
|
1601
1601
|
};
|
|
1602
1602
|
}
|
|
1603
1603
|
function Xr(e, t, n) {
|
|
1604
|
-
const r = U(t), o = Q(t), i = n === "fixed", s =
|
|
1604
|
+
const r = U(t), o = Q(t), i = n === "fixed", s = he(e, !0, i, t);
|
|
1605
1605
|
let l = {
|
|
1606
1606
|
scrollLeft: 0,
|
|
1607
1607
|
scrollTop: 0
|
|
1608
1608
|
};
|
|
1609
|
-
const
|
|
1609
|
+
const a = ne(0);
|
|
1610
1610
|
if (r || !r && !i)
|
|
1611
1611
|
if ((te(t) !== "body" || Oe(o)) && (l = Ye(t)), r) {
|
|
1612
|
-
const d =
|
|
1613
|
-
|
|
1612
|
+
const d = he(t, !0, i, t);
|
|
1613
|
+
a.x = d.x + t.clientLeft, a.y = d.y + t.clientTop;
|
|
1614
1614
|
} else
|
|
1615
|
-
o && (
|
|
1616
|
-
const
|
|
1615
|
+
o && (a.x = sn(o));
|
|
1616
|
+
const c = s.left + l.scrollLeft - a.x, m = s.top + l.scrollTop - a.y;
|
|
1617
1617
|
return {
|
|
1618
|
-
x:
|
|
1618
|
+
x: c,
|
|
1619
1619
|
y: m,
|
|
1620
1620
|
width: s.width,
|
|
1621
1621
|
height: s.height
|
|
@@ -1624,7 +1624,7 @@ function Xr(e, t, n) {
|
|
|
1624
1624
|
function Tt(e, t) {
|
|
1625
1625
|
return !U(e) || q(e).position === "fixed" ? null : t ? t(e) : e.offsetParent;
|
|
1626
1626
|
}
|
|
1627
|
-
function
|
|
1627
|
+
function an(e, t) {
|
|
1628
1628
|
const n = X(e);
|
|
1629
1629
|
if (!U(e) || on(e))
|
|
1630
1630
|
return n;
|
|
@@ -1634,7 +1634,7 @@ function cn(e, t) {
|
|
|
1634
1634
|
return r && (te(r) === "html" || te(r) === "body" && q(r).position === "static" && !dt(r)) ? n : r || hr(e) || n;
|
|
1635
1635
|
}
|
|
1636
1636
|
const Ur = async function(e) {
|
|
1637
|
-
const t = this.getOffsetParent ||
|
|
1637
|
+
const t = this.getOffsetParent || an, n = this.getDimensions;
|
|
1638
1638
|
return {
|
|
1639
1639
|
reference: Xr(e.reference, await t(e.floating), e.strategy),
|
|
1640
1640
|
floating: {
|
|
@@ -1651,7 +1651,7 @@ const Gr = {
|
|
|
1651
1651
|
convertOffsetParentRelativeRectToViewportRelativeRect: Wr,
|
|
1652
1652
|
getDocumentElement: Q,
|
|
1653
1653
|
getClippingRect: Yr,
|
|
1654
|
-
getOffsetParent:
|
|
1654
|
+
getOffsetParent: an,
|
|
1655
1655
|
getElementRects: Ur,
|
|
1656
1656
|
getClientRects: jr,
|
|
1657
1657
|
getDimensions: Kr,
|
|
@@ -1666,24 +1666,24 @@ function Zr(e, t) {
|
|
|
1666
1666
|
var l;
|
|
1667
1667
|
clearTimeout(r), (l = n) == null || l.disconnect(), n = null;
|
|
1668
1668
|
}
|
|
1669
|
-
function s(l,
|
|
1670
|
-
l === void 0 && (l = !1),
|
|
1669
|
+
function s(l, a) {
|
|
1670
|
+
l === void 0 && (l = !1), a === void 0 && (a = 1), i();
|
|
1671
1671
|
const {
|
|
1672
|
-
left:
|
|
1672
|
+
left: c,
|
|
1673
1673
|
top: m,
|
|
1674
1674
|
width: d,
|
|
1675
1675
|
height: f
|
|
1676
1676
|
} = e.getBoundingClientRect();
|
|
1677
1677
|
if (l || t(), !d || !f)
|
|
1678
1678
|
return;
|
|
1679
|
-
const u = De(m), g = De(o.clientWidth - (
|
|
1680
|
-
rootMargin: -u + "px " + -g + "px " + -p + "px " +
|
|
1681
|
-
threshold:
|
|
1679
|
+
const u = De(m), g = De(o.clientWidth - (c + d)), p = De(o.clientHeight - (m + f)), $ = De(c), x = {
|
|
1680
|
+
rootMargin: -u + "px " + -g + "px " + -p + "px " + -$ + "px",
|
|
1681
|
+
threshold: me(0, Ne(1, a)) || 1
|
|
1682
1682
|
};
|
|
1683
1683
|
let P = !0;
|
|
1684
|
-
function
|
|
1684
|
+
function S(C) {
|
|
1685
1685
|
const I = C[0].intersectionRatio;
|
|
1686
|
-
if (I !==
|
|
1686
|
+
if (I !== a) {
|
|
1687
1687
|
if (!P)
|
|
1688
1688
|
return s();
|
|
1689
1689
|
I ? s(!1, I) : r = setTimeout(() => {
|
|
@@ -1693,13 +1693,13 @@ function Zr(e, t) {
|
|
|
1693
1693
|
P = !1;
|
|
1694
1694
|
}
|
|
1695
1695
|
try {
|
|
1696
|
-
n = new IntersectionObserver(
|
|
1696
|
+
n = new IntersectionObserver(S, {
|
|
1697
1697
|
...x,
|
|
1698
1698
|
// Handle <iframe>s
|
|
1699
1699
|
root: o.ownerDocument
|
|
1700
1700
|
});
|
|
1701
1701
|
} catch {
|
|
1702
|
-
n = new IntersectionObserver(
|
|
1702
|
+
n = new IntersectionObserver(S, x);
|
|
1703
1703
|
}
|
|
1704
1704
|
n.observe(e);
|
|
1705
1705
|
}
|
|
@@ -1712,33 +1712,33 @@ function Jr(e, t, n, r) {
|
|
|
1712
1712
|
ancestorResize: i = !0,
|
|
1713
1713
|
elementResize: s = typeof ResizeObserver == "function",
|
|
1714
1714
|
layoutShift: l = typeof IntersectionObserver == "function",
|
|
1715
|
-
animationFrame:
|
|
1716
|
-
} = r,
|
|
1715
|
+
animationFrame: a = !1
|
|
1716
|
+
} = r, c = mt(e), m = o || i ? [...c ? ee(c) : [], ...ee(t)] : [];
|
|
1717
1717
|
m.forEach((h) => {
|
|
1718
1718
|
o && h.addEventListener("scroll", n, {
|
|
1719
1719
|
passive: !0
|
|
1720
1720
|
}), i && h.addEventListener("resize", n);
|
|
1721
1721
|
});
|
|
1722
|
-
const d =
|
|
1722
|
+
const d = c && l ? Zr(c, n) : null;
|
|
1723
1723
|
let f = -1, u = null;
|
|
1724
1724
|
s && (u = new ResizeObserver((h) => {
|
|
1725
1725
|
let [x] = h;
|
|
1726
|
-
x && x.target ===
|
|
1726
|
+
x && x.target === c && u && (u.unobserve(t), cancelAnimationFrame(f), f = requestAnimationFrame(() => {
|
|
1727
1727
|
var P;
|
|
1728
1728
|
(P = u) == null || P.observe(t);
|
|
1729
1729
|
})), n();
|
|
1730
|
-
}),
|
|
1731
|
-
let g, p =
|
|
1732
|
-
|
|
1733
|
-
function
|
|
1734
|
-
const h =
|
|
1735
|
-
p && (h.x !== p.x || h.y !== p.y || h.width !== p.width || h.height !== p.height) && n(), p = h, g = requestAnimationFrame(
|
|
1730
|
+
}), c && !a && u.observe(c), u.observe(t));
|
|
1731
|
+
let g, p = a ? he(e) : null;
|
|
1732
|
+
a && $();
|
|
1733
|
+
function $() {
|
|
1734
|
+
const h = he(e);
|
|
1735
|
+
p && (h.x !== p.x || h.y !== p.y || h.width !== p.width || h.height !== p.height) && n(), p = h, g = requestAnimationFrame($);
|
|
1736
1736
|
}
|
|
1737
1737
|
return n(), () => {
|
|
1738
1738
|
var h;
|
|
1739
1739
|
m.forEach((x) => {
|
|
1740
1740
|
o && x.removeEventListener("scroll", n), i && x.removeEventListener("resize", n);
|
|
1741
|
-
}), d == null || d(), (h = u) == null || h.disconnect(), u = null,
|
|
1741
|
+
}), d == null || d(), (h = u) == null || h.disconnect(), u = null, a && cancelAnimationFrame(g);
|
|
1742
1742
|
};
|
|
1743
1743
|
}
|
|
1744
1744
|
const Qr = Mr, eo = Br, to = (e, t, n) => {
|
|
@@ -1786,11 +1786,11 @@ function He(e, t) {
|
|
|
1786
1786
|
}
|
|
1787
1787
|
return e !== e && t !== t;
|
|
1788
1788
|
}
|
|
1789
|
-
function
|
|
1789
|
+
function cn(e) {
|
|
1790
1790
|
return typeof window > "u" ? 1 : (e.ownerDocument.defaultView || window).devicePixelRatio || 1;
|
|
1791
1791
|
}
|
|
1792
1792
|
function It(e, t) {
|
|
1793
|
-
const n =
|
|
1793
|
+
const n = cn(e);
|
|
1794
1794
|
return Math.round(t * n) / n;
|
|
1795
1795
|
}
|
|
1796
1796
|
function Pt(e) {
|
|
@@ -1811,8 +1811,8 @@ function no(e) {
|
|
|
1811
1811
|
floating: s
|
|
1812
1812
|
} = {},
|
|
1813
1813
|
transform: l = !0,
|
|
1814
|
-
whileElementsMounted:
|
|
1815
|
-
open:
|
|
1814
|
+
whileElementsMounted: a,
|
|
1815
|
+
open: c
|
|
1816
1816
|
} = e, [m, d] = y.useState({
|
|
1817
1817
|
x: 0,
|
|
1818
1818
|
y: 0,
|
|
@@ -1822,11 +1822,11 @@ function no(e) {
|
|
|
1822
1822
|
isPositioned: !1
|
|
1823
1823
|
}), [f, u] = y.useState(r);
|
|
1824
1824
|
He(f, r) || u(r);
|
|
1825
|
-
const [g, p] = y.useState(null), [
|
|
1825
|
+
const [g, p] = y.useState(null), [$, h] = y.useState(null), x = y.useCallback((R) => {
|
|
1826
1826
|
R !== I.current && (I.current = R, p(R));
|
|
1827
1827
|
}, []), P = y.useCallback((R) => {
|
|
1828
1828
|
R !== A.current && (A.current = R, h(R));
|
|
1829
|
-
}, []),
|
|
1829
|
+
}, []), S = i || g, C = s || $, I = y.useRef(null), A = y.useRef(null), k = y.useRef(m), O = a != null, D = Pt(a), L = Pt(o), M = y.useCallback(() => {
|
|
1830
1830
|
if (!I.current || !A.current)
|
|
1831
1831
|
return;
|
|
1832
1832
|
const R = {
|
|
@@ -1845,30 +1845,30 @@ function no(e) {
|
|
|
1845
1845
|
});
|
|
1846
1846
|
}, [f, t, n, L]);
|
|
1847
1847
|
Me(() => {
|
|
1848
|
-
|
|
1848
|
+
c === !1 && k.current.isPositioned && (k.current.isPositioned = !1, d((R) => ({
|
|
1849
1849
|
...R,
|
|
1850
1850
|
isPositioned: !1
|
|
1851
1851
|
})));
|
|
1852
|
-
}, [
|
|
1852
|
+
}, [c]);
|
|
1853
1853
|
const B = y.useRef(!1);
|
|
1854
1854
|
Me(() => (B.current = !0, () => {
|
|
1855
1855
|
B.current = !1;
|
|
1856
1856
|
}), []), Me(() => {
|
|
1857
|
-
if (
|
|
1857
|
+
if (S && (I.current = S), C && (A.current = C), S && C) {
|
|
1858
1858
|
if (D.current)
|
|
1859
|
-
return D.current(
|
|
1859
|
+
return D.current(S, C, M);
|
|
1860
1860
|
M();
|
|
1861
1861
|
}
|
|
1862
|
-
}, [
|
|
1862
|
+
}, [S, C, M, D, O]);
|
|
1863
1863
|
const b = y.useMemo(() => ({
|
|
1864
1864
|
reference: I,
|
|
1865
1865
|
floating: A,
|
|
1866
1866
|
setReference: x,
|
|
1867
1867
|
setFloating: P
|
|
1868
1868
|
}), [x, P]), v = y.useMemo(() => ({
|
|
1869
|
-
reference:
|
|
1869
|
+
reference: S,
|
|
1870
1870
|
floating: C
|
|
1871
|
-
}), [
|
|
1871
|
+
}), [S, C]), T = y.useMemo(() => {
|
|
1872
1872
|
const R = {
|
|
1873
1873
|
position: n,
|
|
1874
1874
|
left: 0,
|
|
@@ -1880,7 +1880,7 @@ function no(e) {
|
|
|
1880
1880
|
return l ? {
|
|
1881
1881
|
...R,
|
|
1882
1882
|
transform: "translate(" + w + "px, " + F + "px)",
|
|
1883
|
-
...
|
|
1883
|
+
...cn(v.floating) >= 1.5 && {
|
|
1884
1884
|
willChange: "transform"
|
|
1885
1885
|
}
|
|
1886
1886
|
} : {
|
|
@@ -1925,10 +1925,10 @@ var ro = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
1925
1925
|
var s = i.shift();
|
|
1926
1926
|
if (!_e(s, !1))
|
|
1927
1927
|
if (s.tagName === "SLOT") {
|
|
1928
|
-
var l = s.assignedElements(),
|
|
1929
|
-
r.flatten ? o.push.apply(o,
|
|
1928
|
+
var l = s.assignedElements(), a = l.length ? l : s.children, c = e(a, !0, r);
|
|
1929
|
+
r.flatten ? o.push.apply(o, c) : o.push({
|
|
1930
1930
|
scopeParent: s,
|
|
1931
|
-
candidates:
|
|
1931
|
+
candidates: c
|
|
1932
1932
|
});
|
|
1933
1933
|
} else {
|
|
1934
1934
|
var m = Be.call(s, st);
|
|
@@ -1955,11 +1955,11 @@ var ro = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
1955
1955
|
}, lo = function(t, n) {
|
|
1956
1956
|
var r = fn(t);
|
|
1957
1957
|
return r < 0 && n && !dn(t) ? 0 : r;
|
|
1958
|
-
},
|
|
1958
|
+
}, ao = function(t, n) {
|
|
1959
1959
|
return t.tabIndex === n.tabIndex ? t.documentOrder - n.documentOrder : t.tabIndex - n.tabIndex;
|
|
1960
1960
|
}, mn = function(t) {
|
|
1961
1961
|
return t.tagName === "INPUT";
|
|
1962
|
-
},
|
|
1962
|
+
}, co = function(t) {
|
|
1963
1963
|
return mn(t) && t.type === "hidden";
|
|
1964
1964
|
}, uo = function(t) {
|
|
1965
1965
|
var n = t.tagName === "DETAILS" && Array.prototype.slice.apply(t.children).some(function(r) {
|
|
@@ -1993,10 +1993,10 @@ var ro = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
1993
1993
|
}, ho = function(t) {
|
|
1994
1994
|
var n, r = t && Ve(t), o = (n = r) === null || n === void 0 ? void 0 : n.host, i = !1;
|
|
1995
1995
|
if (r && r !== t) {
|
|
1996
|
-
var s, l,
|
|
1997
|
-
for (i = !!((s = o) !== null && s !== void 0 && (l = s.ownerDocument) !== null && l !== void 0 && l.contains(o) || t != null && (
|
|
1998
|
-
var
|
|
1999
|
-
r = Ve(o), o = (
|
|
1996
|
+
var s, l, a;
|
|
1997
|
+
for (i = !!((s = o) !== null && s !== void 0 && (l = s.ownerDocument) !== null && l !== void 0 && l.contains(o) || t != null && (a = t.ownerDocument) !== null && a !== void 0 && a.contains(t)); !i && o; ) {
|
|
1998
|
+
var c, m, d;
|
|
1999
|
+
r = Ve(o), o = (c = r) === null || c === void 0 ? void 0 : c.host, i = !!((m = o) !== null && m !== void 0 && (d = m.ownerDocument) !== null && d !== void 0 && d.contains(o));
|
|
2000
2000
|
}
|
|
2001
2001
|
}
|
|
2002
2002
|
return i;
|
|
@@ -2013,10 +2013,10 @@ var ro = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
2013
2013
|
if (!r || r === "full" || r === "legacy-full") {
|
|
2014
2014
|
if (typeof o == "function") {
|
|
2015
2015
|
for (var l = t; t; ) {
|
|
2016
|
-
var
|
|
2017
|
-
if (
|
|
2016
|
+
var a = t.parentElement, c = Ve(t);
|
|
2017
|
+
if (a && !a.shadowRoot && o(a) === !0)
|
|
2018
2018
|
return At(t);
|
|
2019
|
-
t.assignedSlot ? t = t.assignedSlot : !
|
|
2019
|
+
t.assignedSlot ? t = t.assignedSlot : !a && c !== t.ownerDocument ? t = c.host : t = a;
|
|
2020
2020
|
}
|
|
2021
2021
|
t = l;
|
|
2022
2022
|
}
|
|
@@ -2045,7 +2045,7 @@ var ro = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
2045
2045
|
return !(n.disabled || // we must do an inert look up to filter out any elements inside an inert ancestor
|
|
2046
2046
|
// because we're limited in the type of selectors we can use in JSDom (see related
|
|
2047
2047
|
// note related to `candidateSelectors`)
|
|
2048
|
-
_e(n) ||
|
|
2048
|
+
_e(n) || co(n) || bo(n, t) || // For a details element with a summary, the summary element gets the focus
|
|
2049
2049
|
uo(n) || yo(n));
|
|
2050
2050
|
}, Bt = function(t, n) {
|
|
2051
2051
|
return !(po(n) || fn(n) < 0 || !vo(t, n));
|
|
@@ -2055,15 +2055,15 @@ var ro = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
2055
2055
|
}, wo = function e(t) {
|
|
2056
2056
|
var n = [], r = [];
|
|
2057
2057
|
return t.forEach(function(o, i) {
|
|
2058
|
-
var s = !!o.scopeParent, l = s ? o.scopeParent : o,
|
|
2059
|
-
|
|
2058
|
+
var s = !!o.scopeParent, l = s ? o.scopeParent : o, a = lo(l, s), c = s ? e(o.candidates) : l;
|
|
2059
|
+
a === 0 ? s ? n.push.apply(n, c) : n.push(l) : r.push({
|
|
2060
2060
|
documentOrder: i,
|
|
2061
|
-
tabIndex:
|
|
2061
|
+
tabIndex: a,
|
|
2062
2062
|
item: o,
|
|
2063
2063
|
isScope: s,
|
|
2064
|
-
content:
|
|
2064
|
+
content: c
|
|
2065
2065
|
});
|
|
2066
|
-
}), r.sort(
|
|
2066
|
+
}), r.sort(ao).reduce(function(o, i) {
|
|
2067
2067
|
return i.isScope ? o.push.apply(o, i.content) : o.push(i.content), o;
|
|
2068
2068
|
}, []).concat(n);
|
|
2069
2069
|
}, gn = function(t, n) {
|
|
@@ -2076,13 +2076,13 @@ var ro = ["input:not([inert])", "select:not([inert])", "textarea:not([inert])",
|
|
|
2076
2076
|
shadowRootFilter: xo
|
|
2077
2077
|
}) : r = io(t, n.includeContainer, Bt.bind(null, n)), wo(r);
|
|
2078
2078
|
};
|
|
2079
|
-
const
|
|
2080
|
-
function
|
|
2079
|
+
const $o = y[/* @__PURE__ */ "useInsertionEffect".toString()], So = $o || ((e) => e());
|
|
2080
|
+
function Se(e) {
|
|
2081
2081
|
const t = y.useRef(() => {
|
|
2082
2082
|
if (process.env.NODE_ENV !== "production")
|
|
2083
2083
|
throw new Error("Cannot call an event handler while rendering.");
|
|
2084
2084
|
});
|
|
2085
|
-
return
|
|
2085
|
+
return So(() => {
|
|
2086
2086
|
t.current = e;
|
|
2087
2087
|
}), y.useCallback(function() {
|
|
2088
2088
|
for (var n = arguments.length, r = new Array(n), o = 0; o < n; o++)
|
|
@@ -2103,7 +2103,7 @@ function lt() {
|
|
|
2103
2103
|
}
|
|
2104
2104
|
let Qe = !1, Ro = 0;
|
|
2105
2105
|
const Ot = () => "floating-ui-" + Ro++;
|
|
2106
|
-
function
|
|
2106
|
+
function Eo() {
|
|
2107
2107
|
const [e, t] = y.useState(() => Qe ? Ot() : void 0);
|
|
2108
2108
|
return Z(() => {
|
|
2109
2109
|
e == null && t(Ot());
|
|
@@ -2111,7 +2111,7 @@ function $o() {
|
|
|
2111
2111
|
Qe || (Qe = !0);
|
|
2112
2112
|
}, []), e;
|
|
2113
2113
|
}
|
|
2114
|
-
const Co = y[/* @__PURE__ */ "useId".toString()], gt = Co ||
|
|
2114
|
+
const Co = y[/* @__PURE__ */ "useId".toString()], gt = Co || Eo;
|
|
2115
2115
|
function ko() {
|
|
2116
2116
|
const e = /* @__PURE__ */ new Map();
|
|
2117
2117
|
return {
|
|
@@ -2135,7 +2135,7 @@ const To = /* @__PURE__ */ y.createContext(null), Io = /* @__PURE__ */ y.createC
|
|
|
2135
2135
|
function qe(e) {
|
|
2136
2136
|
return "data-floating-ui-" + e;
|
|
2137
2137
|
}
|
|
2138
|
-
function
|
|
2138
|
+
function Ee(e) {
|
|
2139
2139
|
const t = vn(e);
|
|
2140
2140
|
return Z(() => {
|
|
2141
2141
|
t.current = e;
|
|
@@ -2156,34 +2156,34 @@ function Po(e, t) {
|
|
|
2156
2156
|
domReference: s,
|
|
2157
2157
|
floating: l
|
|
2158
2158
|
},
|
|
2159
|
-
refs:
|
|
2159
|
+
refs: a
|
|
2160
2160
|
} = e, {
|
|
2161
|
-
enabled:
|
|
2161
|
+
enabled: c = !0,
|
|
2162
2162
|
delay: m = 0,
|
|
2163
2163
|
handleClose: d = null,
|
|
2164
2164
|
mouseOnly: f = !1,
|
|
2165
2165
|
restMs: u = 0,
|
|
2166
2166
|
move: g = !0
|
|
2167
|
-
} = t, p = ht(),
|
|
2167
|
+
} = t, p = ht(), $ = pt(), h = Ee(d), x = Ee(m), P = y.useRef(), S = y.useRef(), C = y.useRef(), I = y.useRef(), A = y.useRef(!0), k = y.useRef(!1), O = y.useRef(() => {
|
|
2168
2168
|
}), D = y.useCallback(() => {
|
|
2169
2169
|
var b;
|
|
2170
2170
|
const v = (b = o.current.openEvent) == null ? void 0 : b.type;
|
|
2171
2171
|
return (v == null ? void 0 : v.includes("mouse")) && v !== "mousedown";
|
|
2172
2172
|
}, [o]);
|
|
2173
2173
|
y.useEffect(() => {
|
|
2174
|
-
if (!
|
|
2174
|
+
if (!c)
|
|
2175
2175
|
return;
|
|
2176
2176
|
function b(v) {
|
|
2177
2177
|
let {
|
|
2178
2178
|
open: T
|
|
2179
2179
|
} = v;
|
|
2180
|
-
T || (clearTimeout(
|
|
2180
|
+
T || (clearTimeout(S.current), clearTimeout(I.current), A.current = !0);
|
|
2181
2181
|
}
|
|
2182
2182
|
return i.on("openchange", b), () => {
|
|
2183
2183
|
i.off("openchange", b);
|
|
2184
2184
|
};
|
|
2185
|
-
}, [
|
|
2186
|
-
if (!
|
|
2185
|
+
}, [c, i]), y.useEffect(() => {
|
|
2186
|
+
if (!c || !h.current || !n)
|
|
2187
2187
|
return;
|
|
2188
2188
|
function b(T) {
|
|
2189
2189
|
D() && r(!1, T, "hover");
|
|
@@ -2192,30 +2192,30 @@ function Po(e, t) {
|
|
|
2192
2192
|
return v.addEventListener("mouseleave", b), () => {
|
|
2193
2193
|
v.removeEventListener("mouseleave", b);
|
|
2194
2194
|
};
|
|
2195
|
-
}, [l, n, r,
|
|
2195
|
+
}, [l, n, r, c, h, D]);
|
|
2196
2196
|
const L = y.useCallback(function(b, v, T) {
|
|
2197
2197
|
v === void 0 && (v = !0), T === void 0 && (T = "hover");
|
|
2198
2198
|
const R = et(x.current, "close", P.current);
|
|
2199
|
-
R && !C.current ? (clearTimeout(
|
|
2199
|
+
R && !C.current ? (clearTimeout(S.current), S.current = setTimeout(() => r(!1, b, T), R)) : v && (clearTimeout(S.current), r(!1, b, T));
|
|
2200
2200
|
}, [x, r]), M = y.useCallback(() => {
|
|
2201
2201
|
O.current(), C.current = void 0;
|
|
2202
2202
|
}, []), B = y.useCallback(() => {
|
|
2203
2203
|
if (k.current) {
|
|
2204
|
-
const b = ce(
|
|
2204
|
+
const b = ce(a.floating.current).body;
|
|
2205
2205
|
b.style.pointerEvents = "", b.removeAttribute(Dt), k.current = !1;
|
|
2206
2206
|
}
|
|
2207
|
-
}, [
|
|
2207
|
+
}, [a]);
|
|
2208
2208
|
return y.useEffect(() => {
|
|
2209
|
-
if (!
|
|
2209
|
+
if (!c)
|
|
2210
2210
|
return;
|
|
2211
2211
|
function b() {
|
|
2212
2212
|
return o.current.openEvent ? ["click", "mousedown"].includes(o.current.openEvent.type) : !1;
|
|
2213
2213
|
}
|
|
2214
2214
|
function v(w) {
|
|
2215
|
-
if (clearTimeout(
|
|
2215
|
+
if (clearTimeout(S.current), A.current = !1, f && !Fe(P.current) || u > 0 && et(x.current, "open") === 0)
|
|
2216
2216
|
return;
|
|
2217
2217
|
const F = et(x.current, "open", P.current);
|
|
2218
|
-
F ?
|
|
2218
|
+
F ? S.current = setTimeout(() => {
|
|
2219
2219
|
r(!0, w, "hover");
|
|
2220
2220
|
}, F) : r(!0, w, "hover");
|
|
2221
2221
|
}
|
|
@@ -2225,7 +2225,7 @@ function Po(e, t) {
|
|
|
2225
2225
|
O.current();
|
|
2226
2226
|
const F = ce(l);
|
|
2227
2227
|
if (clearTimeout(I.current), h.current) {
|
|
2228
|
-
n || clearTimeout(
|
|
2228
|
+
n || clearTimeout(S.current), C.current = h.current({
|
|
2229
2229
|
...e,
|
|
2230
2230
|
tree: p,
|
|
2231
2231
|
x: w.clientX,
|
|
@@ -2240,7 +2240,7 @@ function Po(e, t) {
|
|
|
2240
2240
|
};
|
|
2241
2241
|
return;
|
|
2242
2242
|
}
|
|
2243
|
-
(P.current === "touch" ? !
|
|
2243
|
+
(P.current === "touch" ? !fe(l, w.relatedTarget) : !0) && L(w);
|
|
2244
2244
|
}
|
|
2245
2245
|
function R(w) {
|
|
2246
2246
|
b() || h.current == null || h.current({
|
|
@@ -2261,24 +2261,24 @@ function Po(e, t) {
|
|
|
2261
2261
|
n && w.removeEventListener("mouseleave", R), l == null || l.removeEventListener("mouseleave", R), g && w.removeEventListener("mousemove", v), w.removeEventListener("mouseenter", v), w.removeEventListener("mouseleave", T);
|
|
2262
2262
|
};
|
|
2263
2263
|
}
|
|
2264
|
-
}, [s, l,
|
|
2264
|
+
}, [s, l, c, e, f, u, g, L, M, B, r, n, p, x, h, o]), Z(() => {
|
|
2265
2265
|
var b;
|
|
2266
|
-
if (
|
|
2266
|
+
if (c && n && (b = h.current) != null && b.__options.blockPointerEvents && D()) {
|
|
2267
2267
|
const T = ce(l).body;
|
|
2268
2268
|
if (T.setAttribute(Dt, ""), T.style.pointerEvents = "none", k.current = !0, W(s) && l) {
|
|
2269
2269
|
var v;
|
|
2270
|
-
const R = s, w = p == null || (v = p.nodesRef.current.find((F) => F.id ===
|
|
2270
|
+
const R = s, w = p == null || (v = p.nodesRef.current.find((F) => F.id === $)) == null || (v = v.context) == null ? void 0 : v.elements.floating;
|
|
2271
2271
|
return w && (w.style.pointerEvents = ""), R.style.pointerEvents = "auto", l.style.pointerEvents = "auto", () => {
|
|
2272
2272
|
R.style.pointerEvents = "", l.style.pointerEvents = "";
|
|
2273
2273
|
};
|
|
2274
2274
|
}
|
|
2275
2275
|
}
|
|
2276
|
-
}, [
|
|
2276
|
+
}, [c, n, $, l, s, p, h, D]), Z(() => {
|
|
2277
2277
|
n || (P.current = void 0, M(), B());
|
|
2278
2278
|
}, [n, M, B]), y.useEffect(() => () => {
|
|
2279
|
-
M(), clearTimeout(
|
|
2280
|
-
}, [
|
|
2281
|
-
if (!
|
|
2279
|
+
M(), clearTimeout(S.current), clearTimeout(I.current), B();
|
|
2280
|
+
}, [c, s, M, B]), y.useMemo(() => {
|
|
2281
|
+
if (!c)
|
|
2282
2282
|
return {};
|
|
2283
2283
|
function b(v) {
|
|
2284
2284
|
P.current = v.pointerType;
|
|
@@ -2295,14 +2295,14 @@ function Po(e, t) {
|
|
|
2295
2295
|
},
|
|
2296
2296
|
floating: {
|
|
2297
2297
|
onMouseEnter() {
|
|
2298
|
-
clearTimeout(
|
|
2298
|
+
clearTimeout(S.current);
|
|
2299
2299
|
},
|
|
2300
2300
|
onMouseLeave(v) {
|
|
2301
2301
|
L(v.nativeEvent, !1);
|
|
2302
2302
|
}
|
|
2303
2303
|
}
|
|
2304
2304
|
};
|
|
2305
|
-
}, [
|
|
2305
|
+
}, [c, u, n, r, L]);
|
|
2306
2306
|
}
|
|
2307
2307
|
function Le(e, t) {
|
|
2308
2308
|
let n = e.filter((o) => {
|
|
@@ -2342,7 +2342,7 @@ function Bo() {
|
|
|
2342
2342
|
}
|
|
2343
2343
|
function tt(e, t) {
|
|
2344
2344
|
const n = t || e.currentTarget, r = e.relatedTarget;
|
|
2345
|
-
return !r || !
|
|
2345
|
+
return !r || !fe(n, r);
|
|
2346
2346
|
}
|
|
2347
2347
|
function Oo(e) {
|
|
2348
2348
|
gn(e, pn()).forEach((n) => {
|
|
@@ -2401,20 +2401,20 @@ function Lo(e) {
|
|
|
2401
2401
|
}, [r]), Z(() => {
|
|
2402
2402
|
if (l.current)
|
|
2403
2403
|
return;
|
|
2404
|
-
const
|
|
2405
|
-
if (!
|
|
2404
|
+
const a = t ? document.getElementById(t) : null;
|
|
2405
|
+
if (!a)
|
|
2406
2406
|
return;
|
|
2407
|
-
const
|
|
2408
|
-
|
|
2407
|
+
const c = document.createElement("div");
|
|
2408
|
+
c.id = i, c.setAttribute(Ft, ""), a.appendChild(c), l.current = c, o(c);
|
|
2409
2409
|
}, [t, i]), Z(() => {
|
|
2410
2410
|
if (l.current)
|
|
2411
2411
|
return;
|
|
2412
|
-
let
|
|
2413
|
-
|
|
2414
|
-
let
|
|
2415
|
-
t && (
|
|
2412
|
+
let a = n || (s == null ? void 0 : s.portalNode);
|
|
2413
|
+
a && !W(a) && (a = a.current), a = a || document.body;
|
|
2414
|
+
let c = null;
|
|
2415
|
+
t && (c = document.createElement("div"), c.id = t, a.appendChild(c));
|
|
2416
2416
|
const m = document.createElement("div");
|
|
2417
|
-
m.id = i, m.setAttribute(Ft, ""),
|
|
2417
|
+
m.id = i, m.setAttribute(Ft, ""), a = c || a, a.appendChild(m), l.current = m, o(m);
|
|
2418
2418
|
}, [t, n, i, s]), r;
|
|
2419
2419
|
}
|
|
2420
2420
|
function Fo(e) {
|
|
@@ -2427,7 +2427,7 @@ function Fo(e) {
|
|
|
2427
2427
|
const i = Lo({
|
|
2428
2428
|
id: n,
|
|
2429
2429
|
root: r
|
|
2430
|
-
}), [s, l] = y.useState(null),
|
|
2430
|
+
}), [s, l] = y.useState(null), a = y.useRef(null), c = y.useRef(null), m = y.useRef(null), d = y.useRef(null), f = (
|
|
2431
2431
|
// The FocusManager and therefore floating element are currently open/
|
|
2432
2432
|
// rendered.
|
|
2433
2433
|
!!s && // Guards are only for non-modal focus management.
|
|
@@ -2446,8 +2446,8 @@ function Fo(e) {
|
|
|
2446
2446
|
}, [i, o, s == null ? void 0 : s.modal]), /* @__PURE__ */ y.createElement(yn.Provider, {
|
|
2447
2447
|
value: y.useMemo(() => ({
|
|
2448
2448
|
preserveTabOrder: o,
|
|
2449
|
-
beforeOutsideRef:
|
|
2450
|
-
afterOutsideRef:
|
|
2449
|
+
beforeOutsideRef: a,
|
|
2450
|
+
afterOutsideRef: c,
|
|
2451
2451
|
beforeInsideRef: m,
|
|
2452
2452
|
afterInsideRef: d,
|
|
2453
2453
|
portalNode: i,
|
|
@@ -2455,7 +2455,7 @@ function Fo(e) {
|
|
|
2455
2455
|
}), [o, i])
|
|
2456
2456
|
}, f && i && /* @__PURE__ */ y.createElement(Lt, {
|
|
2457
2457
|
"data-type": "outside",
|
|
2458
|
-
ref:
|
|
2458
|
+
ref: a,
|
|
2459
2459
|
onFocus: (u) => {
|
|
2460
2460
|
if (tt(u, i)) {
|
|
2461
2461
|
var g;
|
|
@@ -2468,9 +2468,9 @@ function Fo(e) {
|
|
|
2468
2468
|
}), f && i && /* @__PURE__ */ y.createElement("span", {
|
|
2469
2469
|
"aria-owns": i.id,
|
|
2470
2470
|
style: bn
|
|
2471
|
-
}), i && /* @__PURE__ */
|
|
2471
|
+
}), i && /* @__PURE__ */ En(t, i), f && i && /* @__PURE__ */ y.createElement(Lt, {
|
|
2472
2472
|
"data-type": "outside",
|
|
2473
|
-
ref:
|
|
2473
|
+
ref: c,
|
|
2474
2474
|
onFocus: (u) => {
|
|
2475
2475
|
if (tt(u, i)) {
|
|
2476
2476
|
var g;
|
|
@@ -2487,7 +2487,7 @@ function Nt(e) {
|
|
|
2487
2487
|
return U(e.target) && e.target.tagName === "BUTTON";
|
|
2488
2488
|
}
|
|
2489
2489
|
function Wt(e) {
|
|
2490
|
-
return
|
|
2490
|
+
return $r(e);
|
|
2491
2491
|
}
|
|
2492
2492
|
function Wo(e, t) {
|
|
2493
2493
|
t === void 0 && (t = {});
|
|
@@ -2501,8 +2501,8 @@ function Wo(e, t) {
|
|
|
2501
2501
|
} = e, {
|
|
2502
2502
|
enabled: s = !0,
|
|
2503
2503
|
event: l = "click",
|
|
2504
|
-
toggle:
|
|
2505
|
-
ignoreMouse:
|
|
2504
|
+
toggle: a = !0,
|
|
2505
|
+
ignoreMouse: c = !1,
|
|
2506
2506
|
keyboardHandlers: m = !0
|
|
2507
2507
|
} = t, d = y.useRef(), f = y.useRef(!1);
|
|
2508
2508
|
return y.useMemo(() => s ? {
|
|
@@ -2511,23 +2511,23 @@ function Wo(e, t) {
|
|
|
2511
2511
|
d.current = u.pointerType;
|
|
2512
2512
|
},
|
|
2513
2513
|
onMouseDown(u) {
|
|
2514
|
-
u.button === 0 && (Fe(d.current, !0) &&
|
|
2514
|
+
u.button === 0 && (Fe(d.current, !0) && c || l !== "click" && (n && a && (!o.current.openEvent || o.current.openEvent.type === "mousedown") ? r(!1, u.nativeEvent, "click") : (u.preventDefault(), r(!0, u.nativeEvent, "click"))));
|
|
2515
2515
|
},
|
|
2516
2516
|
onClick(u) {
|
|
2517
2517
|
if (l === "mousedown" && d.current) {
|
|
2518
2518
|
d.current = void 0;
|
|
2519
2519
|
return;
|
|
2520
2520
|
}
|
|
2521
|
-
Fe(d.current, !0) &&
|
|
2521
|
+
Fe(d.current, !0) && c || (n && a && (!o.current.openEvent || o.current.openEvent.type === "click") ? r(!1, u.nativeEvent, "click") : r(!0, u.nativeEvent, "click"));
|
|
2522
2522
|
},
|
|
2523
2523
|
onKeyDown(u) {
|
|
2524
|
-
d.current = void 0, !(u.defaultPrevented || !m || Nt(u)) && (u.key === " " && !Wt(i) && (u.preventDefault(), f.current = !0), u.key === "Enter" && r(!(n &&
|
|
2524
|
+
d.current = void 0, !(u.defaultPrevented || !m || Nt(u)) && (u.key === " " && !Wt(i) && (u.preventDefault(), f.current = !0), u.key === "Enter" && r(!(n && a), u.nativeEvent, "click"));
|
|
2525
2525
|
},
|
|
2526
2526
|
onKeyUp(u) {
|
|
2527
|
-
u.defaultPrevented || !m || Nt(u) || Wt(i) || u.key === " " && f.current && (f.current = !1, r(!(n &&
|
|
2527
|
+
u.defaultPrevented || !m || Nt(u) || Wt(i) || u.key === " " && f.current && (f.current = !1, r(!(n && a), u.nativeEvent, "click"));
|
|
2528
2528
|
}
|
|
2529
2529
|
}
|
|
2530
|
-
} : {}, [s, o, l,
|
|
2530
|
+
} : {}, [s, o, l, c, m, i, a, n, r]);
|
|
2531
2531
|
}
|
|
2532
2532
|
const jo = {
|
|
2533
2533
|
pointerdown: "onPointerDown",
|
|
@@ -2555,25 +2555,25 @@ function Ho(e, t) {
|
|
|
2555
2555
|
domReference: s,
|
|
2556
2556
|
floating: l
|
|
2557
2557
|
},
|
|
2558
|
-
dataRef:
|
|
2558
|
+
dataRef: a
|
|
2559
2559
|
} = e, {
|
|
2560
|
-
enabled:
|
|
2560
|
+
enabled: c = !0,
|
|
2561
2561
|
escapeKey: m = !0,
|
|
2562
2562
|
outsidePress: d = !0,
|
|
2563
2563
|
outsidePressEvent: f = "pointerdown",
|
|
2564
2564
|
referencePress: u = !1,
|
|
2565
2565
|
referencePressEvent: g = "pointerdown",
|
|
2566
2566
|
ancestorScroll: p = !1,
|
|
2567
|
-
bubbles:
|
|
2567
|
+
bubbles: $,
|
|
2568
2568
|
capture: h
|
|
2569
|
-
} = t, x = ht(), P =
|
|
2569
|
+
} = t, x = ht(), P = Se(typeof d == "function" ? d : () => !1), S = typeof d == "function" ? P : d, C = y.useRef(!1), I = y.useRef(!1), {
|
|
2570
2570
|
escapeKey: A,
|
|
2571
2571
|
outsidePress: k
|
|
2572
|
-
} = jt(
|
|
2572
|
+
} = jt($), {
|
|
2573
2573
|
escapeKey: O,
|
|
2574
2574
|
outsidePress: D
|
|
2575
|
-
} = jt(h), L =
|
|
2576
|
-
if (!n || !
|
|
2575
|
+
} = jt(h), L = Se((v) => {
|
|
2576
|
+
if (!n || !c || !m || v.key !== "Escape")
|
|
2577
2577
|
return;
|
|
2578
2578
|
const T = x ? Le(x.nodesRef.current, o) : [];
|
|
2579
2579
|
if (!A && (v.stopPropagation(), T.length > 0)) {
|
|
@@ -2588,36 +2588,36 @@ function Ho(e, t) {
|
|
|
2588
2588
|
return;
|
|
2589
2589
|
}
|
|
2590
2590
|
r(!1, vr(v) ? v.nativeEvent : v, "escape-key");
|
|
2591
|
-
}), M =
|
|
2591
|
+
}), M = Se((v) => {
|
|
2592
2592
|
var T;
|
|
2593
2593
|
const R = () => {
|
|
2594
2594
|
var w;
|
|
2595
|
-
L(v), (w =
|
|
2595
|
+
L(v), (w = $e(v)) == null || w.removeEventListener("keydown", R);
|
|
2596
2596
|
};
|
|
2597
|
-
(T =
|
|
2598
|
-
}), B =
|
|
2597
|
+
(T = $e(v)) == null || T.addEventListener("keydown", R);
|
|
2598
|
+
}), B = Se((v) => {
|
|
2599
2599
|
const T = C.current;
|
|
2600
2600
|
C.current = !1;
|
|
2601
2601
|
const R = I.current;
|
|
2602
|
-
if (I.current = !1, f === "click" && R || T || typeof
|
|
2602
|
+
if (I.current = !1, f === "click" && R || T || typeof S == "function" && !S(v))
|
|
2603
2603
|
return;
|
|
2604
|
-
const w =
|
|
2604
|
+
const w = $e(v), F = "[" + qe("inert") + "]", _ = ce(l).querySelectorAll(F);
|
|
2605
2605
|
let K = W(w) ? w : null;
|
|
2606
2606
|
for (; K && !ke(K); ) {
|
|
2607
|
-
const z =
|
|
2607
|
+
const z = ge(K);
|
|
2608
2608
|
if (ke(z) || !W(z))
|
|
2609
2609
|
break;
|
|
2610
2610
|
K = z;
|
|
2611
2611
|
}
|
|
2612
2612
|
if (_.length && W(w) && !xr(w) && // Clicked on a direct ancestor (e.g. FloatingOverlay).
|
|
2613
|
-
!
|
|
2613
|
+
!fe(w, l) && // If the target root element contains none of the markers, then the
|
|
2614
2614
|
// element was injected after the floating element rendered.
|
|
2615
|
-
Array.from(_).every((z) => !
|
|
2615
|
+
Array.from(_).every((z) => !fe(K, z)))
|
|
2616
2616
|
return;
|
|
2617
2617
|
if (U(w) && l) {
|
|
2618
2618
|
const z = w.clientWidth > 0 && w.scrollWidth > w.clientWidth, Y = w.clientHeight > 0 && w.scrollHeight > w.clientHeight;
|
|
2619
|
-
let
|
|
2620
|
-
if (Y && q(w).direction === "rtl" && (
|
|
2619
|
+
let ie = Y && v.offsetX > w.clientWidth;
|
|
2620
|
+
if (Y && q(w).direction === "rtl" && (ie = v.offsetX <= w.offsetWidth - w.clientWidth), ie || z && v.offsetY > w.clientHeight)
|
|
2621
2621
|
return;
|
|
2622
2622
|
}
|
|
2623
2623
|
const be = x && Le(x.nodesRef.current, o).some((z) => {
|
|
@@ -2626,12 +2626,12 @@ function Ho(e, t) {
|
|
|
2626
2626
|
});
|
|
2627
2627
|
if (Je(v, l) || Je(v, s) || be)
|
|
2628
2628
|
return;
|
|
2629
|
-
const
|
|
2630
|
-
if (
|
|
2629
|
+
const oe = x ? Le(x.nodesRef.current, o) : [];
|
|
2630
|
+
if (oe.length > 0) {
|
|
2631
2631
|
let z = !0;
|
|
2632
|
-
if (
|
|
2633
|
-
var
|
|
2634
|
-
if ((
|
|
2632
|
+
if (oe.forEach((Y) => {
|
|
2633
|
+
var ie;
|
|
2634
|
+
if ((ie = Y.context) != null && ie.open && !Y.context.dataRef.current.__outsidePressBubbles) {
|
|
2635
2635
|
z = !1;
|
|
2636
2636
|
return;
|
|
2637
2637
|
}
|
|
@@ -2639,23 +2639,23 @@ function Ho(e, t) {
|
|
|
2639
2639
|
return;
|
|
2640
2640
|
}
|
|
2641
2641
|
r(!1, v, "outside-press");
|
|
2642
|
-
}), b =
|
|
2642
|
+
}), b = Se((v) => {
|
|
2643
2643
|
var T;
|
|
2644
2644
|
const R = () => {
|
|
2645
2645
|
var w;
|
|
2646
|
-
B(v), (w =
|
|
2646
|
+
B(v), (w = $e(v)) == null || w.removeEventListener(f, R);
|
|
2647
2647
|
};
|
|
2648
|
-
(T =
|
|
2648
|
+
(T = $e(v)) == null || T.addEventListener(f, R);
|
|
2649
2649
|
});
|
|
2650
2650
|
return y.useEffect(() => {
|
|
2651
|
-
if (!n || !
|
|
2651
|
+
if (!n || !c)
|
|
2652
2652
|
return;
|
|
2653
|
-
|
|
2653
|
+
a.current.__escapeKeyBubbles = A, a.current.__outsidePressBubbles = k;
|
|
2654
2654
|
function v(w) {
|
|
2655
2655
|
r(!1, w, "ancestor-scroll");
|
|
2656
2656
|
}
|
|
2657
2657
|
const T = ce(l);
|
|
2658
|
-
m && T.addEventListener("keydown", O ? M : L, O),
|
|
2658
|
+
m && T.addEventListener("keydown", O ? M : L, O), S && T.addEventListener(f, D ? b : B, D);
|
|
2659
2659
|
let R = [];
|
|
2660
2660
|
return p && (W(s) && (R = ee(s)), W(l) && (R = R.concat(ee(l))), !W(i) && i && i.contextElement && (R = R.concat(ee(i.contextElement)))), R = R.filter((w) => {
|
|
2661
2661
|
var F;
|
|
@@ -2665,13 +2665,13 @@ function Ho(e, t) {
|
|
|
2665
2665
|
passive: !0
|
|
2666
2666
|
});
|
|
2667
2667
|
}), () => {
|
|
2668
|
-
m && T.removeEventListener("keydown", O ? M : L, O),
|
|
2668
|
+
m && T.removeEventListener("keydown", O ? M : L, O), S && T.removeEventListener(f, D ? b : B, D), R.forEach((w) => {
|
|
2669
2669
|
w.removeEventListener("scroll", v);
|
|
2670
2670
|
});
|
|
2671
2671
|
};
|
|
2672
|
-
}, [
|
|
2672
|
+
}, [a, l, s, i, m, S, f, n, r, p, c, A, k, L, O, M, B, D, b]), y.useEffect(() => {
|
|
2673
2673
|
C.current = !1;
|
|
2674
|
-
}, [
|
|
2674
|
+
}, [S, f]), y.useMemo(() => c ? {
|
|
2675
2675
|
reference: {
|
|
2676
2676
|
onKeyDown: L,
|
|
2677
2677
|
[jo[g]]: (v) => {
|
|
@@ -2690,10 +2690,10 @@ function Ho(e, t) {
|
|
|
2690
2690
|
C.current = !0;
|
|
2691
2691
|
}
|
|
2692
2692
|
}
|
|
2693
|
-
} : {}, [
|
|
2693
|
+
} : {}, [c, u, f, g, r, L]);
|
|
2694
2694
|
}
|
|
2695
|
-
let
|
|
2696
|
-
process.env.NODE_ENV !== "production" && (
|
|
2695
|
+
let at;
|
|
2696
|
+
process.env.NODE_ENV !== "production" && (at = /* @__PURE__ */ new Set());
|
|
2697
2697
|
function Vo(e) {
|
|
2698
2698
|
var t;
|
|
2699
2699
|
e === void 0 && (e = {});
|
|
@@ -2707,43 +2707,43 @@ function Vo(e) {
|
|
|
2707
2707
|
const k = "Floating UI: Cannot pass a virtual element to the `elements.reference` option, as it must be a real DOM element. Use `refs.setPositionReference` instead.";
|
|
2708
2708
|
if ((i = e.elements) != null && i.reference && !W(e.elements.reference)) {
|
|
2709
2709
|
var s;
|
|
2710
|
-
if (!((s =
|
|
2710
|
+
if (!((s = at) != null && s.has(k))) {
|
|
2711
2711
|
var l;
|
|
2712
|
-
(l =
|
|
2712
|
+
(l = at) == null || l.add(k), console.error(k);
|
|
2713
2713
|
}
|
|
2714
2714
|
}
|
|
2715
2715
|
}
|
|
2716
|
-
const [
|
|
2717
|
-
k && (
|
|
2716
|
+
const [a, c] = y.useState(null), m = ((t = e.elements) == null ? void 0 : t.reference) || a, d = no(e), f = ht(), u = pt() != null, g = Se((k, O, D) => {
|
|
2717
|
+
k && ($.current.openEvent = O), h.emit("openchange", {
|
|
2718
2718
|
open: k,
|
|
2719
2719
|
event: O,
|
|
2720
2720
|
reason: D,
|
|
2721
2721
|
nested: u
|
|
2722
2722
|
}), r == null || r(k, O, D);
|
|
2723
|
-
}), p = y.useRef(null),
|
|
2723
|
+
}), p = y.useRef(null), $ = y.useRef({}), h = y.useState(() => ko())[0], x = gt(), P = y.useCallback((k) => {
|
|
2724
2724
|
const O = W(k) ? {
|
|
2725
2725
|
getBoundingClientRect: () => k.getBoundingClientRect(),
|
|
2726
2726
|
contextElement: k
|
|
2727
2727
|
} : k;
|
|
2728
2728
|
d.refs.setReference(O);
|
|
2729
|
-
}, [d.refs]),
|
|
2730
|
-
(W(k) || k === null) && (p.current = k,
|
|
2729
|
+
}, [d.refs]), S = y.useCallback((k) => {
|
|
2730
|
+
(W(k) || k === null) && (p.current = k, c(k)), (W(d.refs.reference.current) || d.refs.reference.current === null || // Don't allow setting virtual elements using the old technique back to
|
|
2731
2731
|
// `null` to support `positionReference` + an unstable `reference`
|
|
2732
2732
|
// callback ref.
|
|
2733
2733
|
k !== null && !W(k)) && d.refs.setReference(k);
|
|
2734
2734
|
}, [d.refs]), C = y.useMemo(() => ({
|
|
2735
2735
|
...d.refs,
|
|
2736
|
-
setReference:
|
|
2736
|
+
setReference: S,
|
|
2737
2737
|
setPositionReference: P,
|
|
2738
2738
|
domReference: p
|
|
2739
|
-
}), [d.refs,
|
|
2739
|
+
}), [d.refs, S, P]), I = y.useMemo(() => ({
|
|
2740
2740
|
...d.elements,
|
|
2741
2741
|
domReference: m
|
|
2742
2742
|
}), [d.elements, m]), A = y.useMemo(() => ({
|
|
2743
2743
|
...d,
|
|
2744
2744
|
refs: C,
|
|
2745
2745
|
elements: I,
|
|
2746
|
-
dataRef:
|
|
2746
|
+
dataRef: $,
|
|
2747
2747
|
nodeId: o,
|
|
2748
2748
|
floatingId: x,
|
|
2749
2749
|
events: h,
|
|
@@ -2768,9 +2768,9 @@ function nt(e, t, n) {
|
|
|
2768
2768
|
const {
|
|
2769
2769
|
[zt]: s,
|
|
2770
2770
|
[Ht]: l,
|
|
2771
|
-
...
|
|
2771
|
+
...a
|
|
2772
2772
|
} = e;
|
|
2773
|
-
i =
|
|
2773
|
+
i = a;
|
|
2774
2774
|
}
|
|
2775
2775
|
return {
|
|
2776
2776
|
...n === "floating" && {
|
|
@@ -2780,20 +2780,20 @@ function nt(e, t, n) {
|
|
|
2780
2780
|
...t.map((s) => {
|
|
2781
2781
|
const l = s ? s[n] : null;
|
|
2782
2782
|
return typeof l == "function" ? e ? l(e) : null : l;
|
|
2783
|
-
}).concat(e).reduce((s, l) => (l && Object.entries(l).forEach((
|
|
2784
|
-
let [
|
|
2785
|
-
if (!(o && [zt, Ht].includes(
|
|
2786
|
-
if (
|
|
2787
|
-
if (r.has(
|
|
2783
|
+
}).concat(e).reduce((s, l) => (l && Object.entries(l).forEach((a) => {
|
|
2784
|
+
let [c, m] = a;
|
|
2785
|
+
if (!(o && [zt, Ht].includes(c)))
|
|
2786
|
+
if (c.indexOf("on") === 0) {
|
|
2787
|
+
if (r.has(c) || r.set(c, []), typeof m == "function") {
|
|
2788
2788
|
var d;
|
|
2789
|
-
(d = r.get(
|
|
2789
|
+
(d = r.get(c)) == null || d.push(m), s[c] = function() {
|
|
2790
2790
|
for (var f, u = arguments.length, g = new Array(u), p = 0; p < u; p++)
|
|
2791
2791
|
g[p] = arguments[p];
|
|
2792
|
-
return (f = r.get(
|
|
2792
|
+
return (f = r.get(c)) == null ? void 0 : f.map(($) => $(...g)).find(($) => $ !== void 0);
|
|
2793
2793
|
};
|
|
2794
2794
|
}
|
|
2795
2795
|
} else
|
|
2796
|
-
s[
|
|
2796
|
+
s[c] = m;
|
|
2797
2797
|
}), s), {})
|
|
2798
2798
|
};
|
|
2799
2799
|
}
|
|
@@ -2823,7 +2823,7 @@ function Ko(e, t) {
|
|
|
2823
2823
|
} = e, {
|
|
2824
2824
|
enabled: i = !0,
|
|
2825
2825
|
role: s = "dialog"
|
|
2826
|
-
} = t, l = (n = Yo.get(s)) != null ? n : s,
|
|
2826
|
+
} = t, l = (n = Yo.get(s)) != null ? n : s, a = gt(), m = pt() != null;
|
|
2827
2827
|
return y.useMemo(() => {
|
|
2828
2828
|
if (!i)
|
|
2829
2829
|
return {};
|
|
@@ -2847,7 +2847,7 @@ function Ko(e, t) {
|
|
|
2847
2847
|
role: "combobox"
|
|
2848
2848
|
},
|
|
2849
2849
|
...l === "menu" && {
|
|
2850
|
-
id:
|
|
2850
|
+
id: a
|
|
2851
2851
|
},
|
|
2852
2852
|
...l === "menu" && m && {
|
|
2853
2853
|
role: "menuitem"
|
|
@@ -2862,7 +2862,7 @@ function Ko(e, t) {
|
|
|
2862
2862
|
floating: {
|
|
2863
2863
|
...d,
|
|
2864
2864
|
...l === "menu" && {
|
|
2865
|
-
"aria-labelledby":
|
|
2865
|
+
"aria-labelledby": a
|
|
2866
2866
|
}
|
|
2867
2867
|
},
|
|
2868
2868
|
item(f) {
|
|
@@ -2893,7 +2893,7 @@ function Ko(e, t) {
|
|
|
2893
2893
|
return {};
|
|
2894
2894
|
}
|
|
2895
2895
|
};
|
|
2896
|
-
}, [i, s, l, r, o,
|
|
2896
|
+
}, [i, s, l, r, o, a, m]);
|
|
2897
2897
|
}
|
|
2898
2898
|
const Vt = (e) => e.replace(/[A-Z]+(?![a-z])|[A-Z]/g, (t, n) => (n ? "-" : "") + t.toLowerCase());
|
|
2899
2899
|
function we(e, t) {
|
|
@@ -2917,7 +2917,7 @@ function Uo(e, t) {
|
|
|
2917
2917
|
}
|
|
2918
2918
|
} = e, {
|
|
2919
2919
|
duration: o = 250
|
|
2920
|
-
} = t, s = (typeof o == "number" ? o : o.close) || 0, [l,
|
|
2920
|
+
} = t, s = (typeof o == "number" ? o : o.close) || 0, [l, a] = y.useState(!1), [c, m] = y.useState("unmounted"), d = Xo(n, s);
|
|
2921
2921
|
return Z(() => {
|
|
2922
2922
|
l && !d && m("unmounted");
|
|
2923
2923
|
}, [l, d]), Z(() => {
|
|
@@ -2931,11 +2931,11 @@ function Uo(e, t) {
|
|
|
2931
2931
|
cancelAnimationFrame(f);
|
|
2932
2932
|
};
|
|
2933
2933
|
}
|
|
2934
|
-
|
|
2934
|
+
a(!0), m("close");
|
|
2935
2935
|
}
|
|
2936
2936
|
}, [n, r]), {
|
|
2937
2937
|
isMounted: d,
|
|
2938
|
-
status:
|
|
2938
|
+
status: c
|
|
2939
2939
|
};
|
|
2940
2940
|
}
|
|
2941
2941
|
function qo(e, t) {
|
|
@@ -2948,30 +2948,30 @@ function qo(e, t) {
|
|
|
2948
2948
|
close: o,
|
|
2949
2949
|
common: i,
|
|
2950
2950
|
duration: s = 250
|
|
2951
|
-
} = t, l = e.placement,
|
|
2952
|
-
side:
|
|
2951
|
+
} = t, l = e.placement, a = l.split("-")[0], c = y.useMemo(() => ({
|
|
2952
|
+
side: a,
|
|
2953
2953
|
placement: l
|
|
2954
|
-
}), [
|
|
2955
|
-
...we(i,
|
|
2956
|
-
...we(n,
|
|
2954
|
+
}), [a, l]), m = typeof s == "number", d = (m ? s : s.open) || 0, f = (m ? s : s.close) || 0, [u, g] = y.useState(() => ({
|
|
2955
|
+
...we(i, c),
|
|
2956
|
+
...we(n, c)
|
|
2957
2957
|
})), {
|
|
2958
2958
|
isMounted: p,
|
|
2959
|
-
status:
|
|
2959
|
+
status: $
|
|
2960
2960
|
} = Uo(e, {
|
|
2961
2961
|
duration: s
|
|
2962
|
-
}), h =
|
|
2962
|
+
}), h = Ee(n), x = Ee(r), P = Ee(o), S = Ee(i);
|
|
2963
2963
|
return Z(() => {
|
|
2964
|
-
const C = we(h.current,
|
|
2965
|
-
if (
|
|
2964
|
+
const C = we(h.current, c), I = we(P.current, c), A = we(S.current, c), k = we(x.current, c) || Object.keys(C).reduce((O, D) => (O[D] = "", O), {});
|
|
2965
|
+
if ($ === "initial" && g((O) => ({
|
|
2966
2966
|
transitionProperty: O.transitionProperty,
|
|
2967
2967
|
...A,
|
|
2968
2968
|
...C
|
|
2969
|
-
})),
|
|
2969
|
+
})), $ === "open" && g({
|
|
2970
2970
|
transitionProperty: Object.keys(k).map(Vt).join(","),
|
|
2971
2971
|
transitionDuration: d + "ms",
|
|
2972
2972
|
...A,
|
|
2973
2973
|
...k
|
|
2974
|
-
}),
|
|
2974
|
+
}), $ === "close") {
|
|
2975
2975
|
const O = I || C;
|
|
2976
2976
|
g({
|
|
2977
2977
|
transitionProperty: Object.keys(O).map(Vt).join(","),
|
|
@@ -2980,7 +2980,7 @@ function qo(e, t) {
|
|
|
2980
2980
|
...O
|
|
2981
2981
|
});
|
|
2982
2982
|
}
|
|
2983
|
-
}, [f, P, h, x,
|
|
2983
|
+
}, [f, P, h, x, S, d, $, c]), {
|
|
2984
2984
|
isMounted: p,
|
|
2985
2985
|
styles: u
|
|
2986
2986
|
};
|
|
@@ -2990,8 +2990,8 @@ function _t(e, t) {
|
|
|
2990
2990
|
let o = !1;
|
|
2991
2991
|
const i = t.length;
|
|
2992
2992
|
for (let s = 0, l = i - 1; s < i; l = s++) {
|
|
2993
|
-
const [
|
|
2994
|
-
|
|
2993
|
+
const [a, c] = t[s] || [0, 0], [m, d] = t[l] || [0, 0];
|
|
2994
|
+
c >= r != d >= r && n <= (m - a) * (r - c) / (d - c) + a && (o = !o);
|
|
2995
2995
|
}
|
|
2996
2996
|
return o;
|
|
2997
2997
|
}
|
|
@@ -3005,13 +3005,13 @@ function Zo(e) {
|
|
|
3005
3005
|
blockPointerEvents: n = !1,
|
|
3006
3006
|
requireIntent: r = !0
|
|
3007
3007
|
} = e;
|
|
3008
|
-
let o, i = !1, s = null, l = null,
|
|
3009
|
-
function
|
|
3010
|
-
const u = performance.now(), g = u -
|
|
3008
|
+
let o, i = !1, s = null, l = null, a = performance.now();
|
|
3009
|
+
function c(d, f) {
|
|
3010
|
+
const u = performance.now(), g = u - a;
|
|
3011
3011
|
if (s === null || l === null || g === 0)
|
|
3012
|
-
return s = d, l = f,
|
|
3013
|
-
const p = d - s,
|
|
3014
|
-
return s = d, l = f,
|
|
3012
|
+
return s = d, l = f, a = u, null;
|
|
3013
|
+
const p = d - s, $ = f - l, x = Math.sqrt(p * p + $ * $) / g;
|
|
3014
|
+
return s = d, l = f, a = u, x;
|
|
3015
3015
|
}
|
|
3016
3016
|
const m = (d) => {
|
|
3017
3017
|
let {
|
|
@@ -3019,30 +3019,30 @@ function Zo(e) {
|
|
|
3019
3019
|
y: u,
|
|
3020
3020
|
placement: g,
|
|
3021
3021
|
elements: p,
|
|
3022
|
-
onClose:
|
|
3022
|
+
onClose: $,
|
|
3023
3023
|
nodeId: h,
|
|
3024
3024
|
tree: x
|
|
3025
3025
|
} = d;
|
|
3026
|
-
return function(
|
|
3026
|
+
return function(S) {
|
|
3027
3027
|
function C() {
|
|
3028
|
-
clearTimeout(o),
|
|
3028
|
+
clearTimeout(o), $();
|
|
3029
3029
|
}
|
|
3030
3030
|
if (clearTimeout(o), !p.domReference || !p.floating || g == null || f == null || u == null)
|
|
3031
3031
|
return;
|
|
3032
3032
|
const {
|
|
3033
3033
|
clientX: I,
|
|
3034
3034
|
clientY: A
|
|
3035
|
-
} =
|
|
3035
|
+
} = S, k = [I, A], O = $e(S), D = S.type === "mouseleave", L = fe(p.floating, O), M = fe(p.domReference, O), B = p.domReference.getBoundingClientRect(), b = p.floating.getBoundingClientRect(), v = g.split("-")[0], T = f > b.right - b.width / 2, R = u > b.bottom - b.height / 2, w = Go(k, B), F = b.width > B.width, _ = b.height > B.height, K = (F ? B : b).left, be = (F ? B : b).right, oe = (_ ? B : b).top, z = (_ ? B : b).bottom;
|
|
3036
3036
|
if (L && (i = !0, !D))
|
|
3037
3037
|
return;
|
|
3038
3038
|
if (M && (i = !1), M && !D) {
|
|
3039
3039
|
i = !0;
|
|
3040
3040
|
return;
|
|
3041
3041
|
}
|
|
3042
|
-
if (D && W(
|
|
3042
|
+
if (D && W(S.relatedTarget) && fe(p.floating, S.relatedTarget) || x && Le(x.nodesRef.current, h).some((se) => {
|
|
3043
3043
|
let {
|
|
3044
3044
|
context: j
|
|
3045
|
-
} =
|
|
3045
|
+
} = se;
|
|
3046
3046
|
return j == null ? void 0 : j.open;
|
|
3047
3047
|
}))
|
|
3048
3048
|
return;
|
|
@@ -3057,30 +3057,30 @@ function Zo(e) {
|
|
|
3057
3057
|
Y = [[K, b.top + 1], [K, B.bottom - 1], [be, B.bottom - 1], [be, b.top + 1]];
|
|
3058
3058
|
break;
|
|
3059
3059
|
case "left":
|
|
3060
|
-
Y = [[b.right - 1, z], [b.right - 1,
|
|
3060
|
+
Y = [[b.right - 1, z], [b.right - 1, oe], [B.left + 1, oe], [B.left + 1, z]];
|
|
3061
3061
|
break;
|
|
3062
3062
|
case "right":
|
|
3063
|
-
Y = [[B.right - 1, z], [B.right - 1,
|
|
3063
|
+
Y = [[B.right - 1, z], [B.right - 1, oe], [b.left + 1, oe], [b.left + 1, z]];
|
|
3064
3064
|
break;
|
|
3065
3065
|
}
|
|
3066
|
-
function
|
|
3067
|
-
let [j, H] =
|
|
3066
|
+
function ie(se) {
|
|
3067
|
+
let [j, H] = se;
|
|
3068
3068
|
switch (v) {
|
|
3069
3069
|
case "top": {
|
|
3070
|
-
const
|
|
3071
|
-
return [
|
|
3070
|
+
const le = [F ? j + t / 2 : T ? j + t * 4 : j - t * 4, H + t + 1], ae = [F ? j - t / 2 : T ? j + t * 4 : j - t * 4, H + t + 1], ye = [[b.left, T || F ? b.bottom - t : b.top], [b.right, T ? F ? b.bottom - t : b.top : b.bottom - t]];
|
|
3071
|
+
return [le, ae, ...ye];
|
|
3072
3072
|
}
|
|
3073
3073
|
case "bottom": {
|
|
3074
|
-
const
|
|
3075
|
-
return [
|
|
3074
|
+
const le = [F ? j + t / 2 : T ? j + t * 4 : j - t * 4, H - t], ae = [F ? j - t / 2 : T ? j + t * 4 : j - t * 4, H - t], ye = [[b.left, T || F ? b.top + t : b.bottom], [b.right, T ? F ? b.top + t : b.bottom : b.top + t]];
|
|
3075
|
+
return [le, ae, ...ye];
|
|
3076
3076
|
}
|
|
3077
3077
|
case "left": {
|
|
3078
|
-
const
|
|
3079
|
-
return [...[[R || _ ? b.right - t : b.left, b.top], [R ? _ ? b.right - t : b.left : b.right - t, b.bottom]],
|
|
3078
|
+
const le = [j + t + 1, _ ? H + t / 2 : R ? H + t * 4 : H - t * 4], ae = [j + t + 1, _ ? H - t / 2 : R ? H + t * 4 : H - t * 4];
|
|
3079
|
+
return [...[[R || _ ? b.right - t : b.left, b.top], [R ? _ ? b.right - t : b.left : b.right - t, b.bottom]], le, ae];
|
|
3080
3080
|
}
|
|
3081
3081
|
case "right": {
|
|
3082
|
-
const
|
|
3083
|
-
return [
|
|
3082
|
+
const le = [j - t, _ ? H + t / 2 : R ? H + t * 4 : H - t * 4], ae = [j - t, _ ? H - t / 2 : R ? H + t * 4 : H - t * 4], ye = [[R || _ ? b.left + t : b.right, b.top], [R ? _ ? b.left + t : b.right : b.left + t, b.bottom]];
|
|
3083
|
+
return [le, ae, ...ye];
|
|
3084
3084
|
}
|
|
3085
3085
|
}
|
|
3086
3086
|
}
|
|
@@ -3088,11 +3088,11 @@ function Zo(e) {
|
|
|
3088
3088
|
if (i && !w)
|
|
3089
3089
|
return C();
|
|
3090
3090
|
if (!D && r) {
|
|
3091
|
-
const
|
|
3092
|
-
if (
|
|
3091
|
+
const se = c(S.clientX, S.clientY);
|
|
3092
|
+
if (se !== null && se < 0.1)
|
|
3093
3093
|
return C();
|
|
3094
3094
|
}
|
|
3095
|
-
_t([I, A],
|
|
3095
|
+
_t([I, A], ie([f, u])) ? !i && r && (o = window.setTimeout(C, 40)) : C();
|
|
3096
3096
|
}
|
|
3097
3097
|
};
|
|
3098
3098
|
};
|
|
@@ -3100,7 +3100,7 @@ function Zo(e) {
|
|
|
3100
3100
|
blockPointerEvents: n
|
|
3101
3101
|
}, m;
|
|
3102
3102
|
}
|
|
3103
|
-
const Jo =
|
|
3103
|
+
const Jo = re("div"), bt = xn(
|
|
3104
3104
|
{}
|
|
3105
3105
|
), ii = ({
|
|
3106
3106
|
children: e,
|
|
@@ -3112,37 +3112,37 @@ const Jo = he("div"), bt = xn(
|
|
|
3112
3112
|
placement: s = "bottom",
|
|
3113
3113
|
role: l = "dialog"
|
|
3114
3114
|
}) => {
|
|
3115
|
-
const { refs:
|
|
3115
|
+
const { refs: a, floatingStyles: c, context: m } = Vo({
|
|
3116
3116
|
open: n,
|
|
3117
3117
|
onOpenChange: r,
|
|
3118
3118
|
placement: s,
|
|
3119
3119
|
whileElementsMounted: Jr,
|
|
3120
3120
|
middleware: [Dr(t), eo(), Qr()]
|
|
3121
3121
|
}), { isMounted: d, styles: f } = qo(m, {
|
|
3122
|
-
initial: ({ side:
|
|
3122
|
+
initial: ({ side: S }) => ({
|
|
3123
3123
|
opacity: 0,
|
|
3124
3124
|
transform: {
|
|
3125
3125
|
top: "translateY(-0.5rem)",
|
|
3126
3126
|
right: "translateX(0.5rem)",
|
|
3127
3127
|
bottom: "translateY(0.5rem)",
|
|
3128
3128
|
left: "translateX(-0.5rem)"
|
|
3129
|
-
}[
|
|
3129
|
+
}[S]
|
|
3130
3130
|
})
|
|
3131
3131
|
}), u = Wo(m, { enabled: o === "click" }), g = Po(m, {
|
|
3132
3132
|
enabled: o === "hover",
|
|
3133
3133
|
delay: i,
|
|
3134
3134
|
handleClose: Zo()
|
|
3135
|
-
}), p = Ho(m),
|
|
3135
|
+
}), p = Ho(m), $ = Ko(m, { role: l }), { getFloatingProps: h, getReferenceProps: x } = _o([
|
|
3136
3136
|
u,
|
|
3137
3137
|
g,
|
|
3138
3138
|
p,
|
|
3139
|
-
|
|
3139
|
+
$
|
|
3140
3140
|
]), P = wn(
|
|
3141
3141
|
() => ({
|
|
3142
3142
|
getFloatingProps: h,
|
|
3143
3143
|
getReferenceProps: x,
|
|
3144
|
-
floatingStyles:
|
|
3145
|
-
refs:
|
|
3144
|
+
floatingStyles: c,
|
|
3145
|
+
refs: a,
|
|
3146
3146
|
isMounted: d,
|
|
3147
3147
|
transitionStyles: f
|
|
3148
3148
|
}),
|
|
@@ -3150,15 +3150,15 @@ const Jo = he("div"), bt = xn(
|
|
|
3150
3150
|
h,
|
|
3151
3151
|
x,
|
|
3152
3152
|
d,
|
|
3153
|
-
c,
|
|
3154
3153
|
a,
|
|
3154
|
+
c,
|
|
3155
3155
|
f
|
|
3156
3156
|
]
|
|
3157
3157
|
);
|
|
3158
3158
|
return /* @__PURE__ */ G.jsx(bt.Provider, { value: P, children: e });
|
|
3159
3159
|
}, si = ({ children: e }) => {
|
|
3160
3160
|
const { getReferenceProps: t, refs: n } = Xt(bt);
|
|
3161
|
-
return /* @__PURE__ */ G.jsx(G.Fragment, { children:
|
|
3161
|
+
return /* @__PURE__ */ G.jsx(G.Fragment, { children: $n(e) && Sn(e, {
|
|
3162
3162
|
ref: n.setReference,
|
|
3163
3163
|
...t()
|
|
3164
3164
|
}) });
|
|
@@ -3182,7 +3182,44 @@ const Jo = he("div"), bt = xn(
|
|
|
3182
3182
|
children: /* @__PURE__ */ G.jsx(gr, { ...t, style: s, children: e })
|
|
3183
3183
|
}
|
|
3184
3184
|
) }) : null;
|
|
3185
|
-
}
|
|
3185
|
+
}, ai = re("span", {
|
|
3186
|
+
flex: "0 0 auto",
|
|
3187
|
+
display: "inline-flex",
|
|
3188
|
+
padding: "$1 $2",
|
|
3189
|
+
fontSize: "$xs",
|
|
3190
|
+
fontWeight: "$medium",
|
|
3191
|
+
lineHeight: "1",
|
|
3192
|
+
whiteSpace: "nowrap",
|
|
3193
|
+
borderRadius: "$sm",
|
|
3194
|
+
overflow: "hidden",
|
|
3195
|
+
variants: {
|
|
3196
|
+
color: {
|
|
3197
|
+
success: {
|
|
3198
|
+
backgroundColor: "$green200",
|
|
3199
|
+
color: "$green800"
|
|
3200
|
+
},
|
|
3201
|
+
warning: {
|
|
3202
|
+
backgroundColor: "$yellow100",
|
|
3203
|
+
color: "$yellow700"
|
|
3204
|
+
},
|
|
3205
|
+
danger: {
|
|
3206
|
+
backgroundColor: "$red200",
|
|
3207
|
+
color: "$red800"
|
|
3208
|
+
},
|
|
3209
|
+
primary: {
|
|
3210
|
+
backgroundColor: "$blue200",
|
|
3211
|
+
color: "$blue800"
|
|
3212
|
+
},
|
|
3213
|
+
secondary: {
|
|
3214
|
+
backgroundColor: "$gray200",
|
|
3215
|
+
color: "$gray800"
|
|
3216
|
+
}
|
|
3217
|
+
}
|
|
3218
|
+
},
|
|
3219
|
+
defaultVariants: {
|
|
3220
|
+
color: "primary"
|
|
3221
|
+
}
|
|
3222
|
+
});
|
|
3186
3223
|
export {
|
|
3187
3224
|
oi as A,
|
|
3188
3225
|
Jo as B,
|
|
@@ -3193,7 +3230,8 @@ export {
|
|
|
3193
3230
|
li as b,
|
|
3194
3231
|
qt as c,
|
|
3195
3232
|
ri as d,
|
|
3233
|
+
ai as e,
|
|
3196
3234
|
ni as g,
|
|
3197
3235
|
Ie as k,
|
|
3198
|
-
|
|
3236
|
+
re as s
|
|
3199
3237
|
};
|