@mt-gloss/ui 0.1.155 → 0.1.156
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/{Expandable-DIkXAgji.js → Expandable-DkTVmeXf.js} +460 -458
- package/catalog.js +2 -2
- package/index.js +2 -2
- package/package.json +1 -1
|
@@ -1,13 +1,13 @@
|
|
|
1
1
|
import { jsxs as c, jsx as e, Fragment as Ge } from "react/jsx-runtime";
|
|
2
2
|
import * as cr from "react";
|
|
3
|
-
import _e, { useId as Ve, useState as O, useCallback as N, createContext as Yt, useContext as Ut, useRef as
|
|
4
|
-
import { S as
|
|
3
|
+
import _e, { useId as Ve, useState as O, useCallback as N, createContext as Yt, useContext as Ut, useRef as me, useEffect as se, useMemo as Q, useSyncExternalStore as Yn, useReducer as Un, forwardRef as Xn, useImperativeHandle as Zn } from "react";
|
|
4
|
+
import { S as Z, E as Ze, C as E, e as qn, R as Ce, h as Jn, i as Qn, j as es, af as ts, M as rs, p as as, a9 as ns, ag as ye, N as ss, O as Ha, P as Ga, Q as os, V as ls, W as is, X as cs, Y as ds, _ as us, a1 as ms, a2 as ps, a3 as gs, a8 as fs, a4 as hs, a5 as bs, L as ys, K as vs, f as _s, g as xs, $ as Ns, a0 as Ss, k as Cs, q as ks, v as ws, r as Ds, U as Nt, w as Is, x as Ts, s as Es, y as Ps, t as Bs, ad as Ms, ae as As, z as Rs, A as zs, D as Fs, F as $s, G as Os, H as Ls, I as Hs, J as Gs, c as Tt, d as qe, Z as Va, B as Vs, ab as Ws, b as Wa, T as Me, aa as js, ac as fa } from "./UIContext-CGQI_KJk.js";
|
|
5
5
|
import { easings as nt, durations as st } from "@mt-gloss/tokens";
|
|
6
|
-
import { formatValue as Ks, isInRange as Ys, isSameDay as er, formatMarketDates as Us, DEFAULT_MARKET_PRESETS as tr, isMarketActive as kt, getDateRangeForPreset as Xe, detectPreset as rr,
|
|
6
|
+
import { formatValue as Ks, isInRange as Ys, isSameDay as er, formatMarketDates as Us, DEFAULT_MARKET_PRESETS as tr, isMarketActive as kt, getDateRangeForPreset as Xe, detectPreset as rr, ROLLING_OPTIONS as Sr, PERIOD_OPTIONS as Cr, getDateRangeDisplayInfo as Ot, formatDateRangeSmart as yt, toUppercasePresetId as ar, generateMarketId as Xs } from "@mt-gloss/utils";
|
|
7
7
|
import { B as be, b as Zs, a as qs } from "./BaseText-Dxbk1JJa.js";
|
|
8
8
|
import { u as Js, a as Qs, b as eo, M as dt } from "./TimeframeQuickBar-CHl409rH.js";
|
|
9
9
|
import { useGridApiRef as to, DataGridPro as ro } from "@mui/x-data-grid-pro";
|
|
10
|
-
import { Chip as
|
|
10
|
+
import { Chip as Wr, Tooltip as xt, MenuItem as dr, Menu as ao, Box as ue, IconButton as et, Select as ha, Typography as De, Button as at, Collapse as no, Popover as so, Dialog as oo, DialogTitle as lo, DialogContent as io, TextField as nr, DialogActions as co, Tabs as uo, Tab as mo } from "@mui/material";
|
|
11
11
|
import po from "@mui/icons-material/Person";
|
|
12
12
|
import go from "@mui/icons-material/Business";
|
|
13
13
|
import fo from "@mui/icons-material/BarChart";
|
|
@@ -22,14 +22,14 @@ import So from "@mui/icons-material/History";
|
|
|
22
22
|
import Co from "@mui/icons-material/People";
|
|
23
23
|
import ko from "@mui/icons-material/ViewList";
|
|
24
24
|
import wo from "@mui/icons-material/Timeline";
|
|
25
|
-
import
|
|
25
|
+
import jr from "@mui/icons-material/Edit";
|
|
26
26
|
import Do from "@mui/icons-material/Storefront";
|
|
27
27
|
import Io from "@mui/icons-material/LocalOffer";
|
|
28
28
|
import To from "@mui/icons-material/AttachMoney";
|
|
29
29
|
import ja from "@mui/icons-material/OpenInNew";
|
|
30
30
|
import ba from "@mui/icons-material/CalendarToday";
|
|
31
|
-
import
|
|
32
|
-
import
|
|
31
|
+
import kr from "@mui/icons-material/ExpandMore";
|
|
32
|
+
import Ar from "@mui/icons-material/Place";
|
|
33
33
|
import Lt from "@mui/icons-material/Add";
|
|
34
34
|
import Vt from "@mui/icons-material/Check";
|
|
35
35
|
import It from "@mui/icons-material/Close";
|
|
@@ -85,11 +85,11 @@ const pl = {
|
|
|
85
85
|
elevation: Ze.ButtonDefault
|
|
86
86
|
}
|
|
87
87
|
}, gl = {
|
|
88
|
-
xs: { padding:
|
|
89
|
-
sm: { padding:
|
|
90
|
-
md: { padding:
|
|
91
|
-
lg: { padding:
|
|
92
|
-
xl: { padding:
|
|
88
|
+
xs: { padding: Z.Xs, paddingX: Z.Sm, fontSize: "0.75rem", fontWeight: "500", minHeight: "24px", gap: Z.Xs },
|
|
89
|
+
sm: { padding: Z.Xs, paddingX: Z.Sm, fontSize: "0.8125rem", fontWeight: "500", minHeight: "30px", gap: Z.Xs },
|
|
90
|
+
md: { padding: Z.Sm, paddingX: Z.Md, fontSize: "0.875rem", fontWeight: "500", minHeight: "36px", gap: Z.Sm },
|
|
91
|
+
lg: { padding: Z.Sm, paddingX: Z.Lg, fontSize: "0.9375rem", fontWeight: "500", minHeight: "42px", gap: Z.Sm },
|
|
92
|
+
xl: { padding: Z.Md, paddingX: Z.Xl, fontSize: "1rem", fontWeight: "500", minHeight: "48px", gap: Z.Md }
|
|
93
93
|
}, fl = {
|
|
94
94
|
radius: Ce.Md
|
|
95
95
|
};
|
|
@@ -726,7 +726,7 @@ const Ll = {
|
|
|
726
726
|
helperText: f,
|
|
727
727
|
id: S,
|
|
728
728
|
name: T
|
|
729
|
-
} = t, w = Ve(), I = S || w, M =
|
|
729
|
+
} = t, w = Ve(), I = S || w, M = me(null), [g, B] = O(s), [k, C] = O(null), x = n !== void 0, H = x ? n : g, A = (H[0] - i) / (d - i) * 100, P = (H[1] - i) / (d - i) * 100, D = N((F) => {
|
|
730
730
|
const K = Math.min(d, Math.max(i, F));
|
|
731
731
|
return Math.round((Math.round((K - i) / u) * u + i) * 1e3) / 1e3;
|
|
732
732
|
}, [i, d, u]), G = N((F, K = !1) => {
|
|
@@ -808,7 +808,7 @@ function en(r = {}) {
|
|
|
808
808
|
initialFocus: s,
|
|
809
809
|
allowOutsideClick: l = !1,
|
|
810
810
|
onEscape: o
|
|
811
|
-
} = r, i =
|
|
811
|
+
} = r, i = me(null), d = me(null), u = N(() => {
|
|
812
812
|
if (!i.current) return [];
|
|
813
813
|
const b = i.current.querySelectorAll(Vl);
|
|
814
814
|
return Array.from(b).filter((y) => y.offsetParent !== null && !y.hidden);
|
|
@@ -874,28 +874,28 @@ function en(r = {}) {
|
|
|
874
874
|
const Wl = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], jl = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"], vt = (r, t) => r.getFullYear() === t.getFullYear() && r.getMonth() === t.getMonth() && r.getDate() === t.getDate(), xa = (r, t) => new Date(r, t + 1, 0).getDate(), Kl = (r, t) => new Date(r, t, 1).getDay(), Yl = (r, t) => {
|
|
875
875
|
const a = r.getDate(), n = r.getMonth() + 1, s = r.getFullYear();
|
|
876
876
|
return t.replace("DD", String(a).padStart(2, "0")).replace("D", String(a)).replace("MM", String(n).padStart(2, "0")).replace("M", String(n)).replace("YYYY", String(s)).replace("YY", String(s).slice(-2));
|
|
877
|
-
},
|
|
877
|
+
}, wr = (r, t, a, n, s) => t && r < t || a && r > a || n?.some((l) => vt(l, r)) ? !0 : s?.(r) ?? !1, Ul = (r, t, a, n, s, l, o, i) => {
|
|
878
878
|
const d = [], u = /* @__PURE__ */ new Date(), h = xa(r, t), p = (Kl(r, t) - n + 7) % 7, b = t === 0 ? 11 : t - 1, y = t === 0 ? r - 1 : r, v = xa(y, b);
|
|
879
879
|
for (let T = p - 1; T >= 0; T--) {
|
|
880
880
|
const w = new Date(y, b, v - T);
|
|
881
|
-
d.push({ date: w, isCurrentMonth: !1, isToday: vt(w, u), isSelected: a ? vt(w, a) : !1, isDisabled:
|
|
881
|
+
d.push({ date: w, isCurrentMonth: !1, isToday: vt(w, u), isSelected: a ? vt(w, a) : !1, isDisabled: wr(w, s, l, o, i) });
|
|
882
882
|
}
|
|
883
883
|
for (let T = 1; T <= h; T++) {
|
|
884
884
|
const w = new Date(r, t, T);
|
|
885
|
-
d.push({ date: w, isCurrentMonth: !0, isToday: vt(w, u), isSelected: a ? vt(w, a) : !1, isDisabled:
|
|
885
|
+
d.push({ date: w, isCurrentMonth: !0, isToday: vt(w, u), isSelected: a ? vt(w, a) : !1, isDisabled: wr(w, s, l, o, i) });
|
|
886
886
|
}
|
|
887
887
|
const _ = t === 11 ? 0 : t + 1, f = t === 11 ? r + 1 : r, S = 42 - d.length;
|
|
888
888
|
for (let T = 1; T <= S; T++) {
|
|
889
889
|
const w = new Date(f, _, T);
|
|
890
|
-
d.push({ date: w, isCurrentMonth: !1, isToday: vt(w, u), isSelected: a ? vt(w, a) : !1, isDisabled:
|
|
890
|
+
d.push({ date: w, isCurrentMonth: !1, isToday: vt(w, u), isSelected: a ? vt(w, a) : !1, isDisabled: wr(w, s, l, o, i) });
|
|
891
891
|
}
|
|
892
892
|
return d;
|
|
893
893
|
}, Xl = {
|
|
894
|
-
xs: { padding:
|
|
895
|
-
sm: { padding:
|
|
896
|
-
md: { padding:
|
|
897
|
-
lg: { padding:
|
|
898
|
-
xl: { padding:
|
|
894
|
+
xs: { padding: Z.Xs },
|
|
895
|
+
sm: { padding: Z.Sm },
|
|
896
|
+
md: { padding: Z.Md },
|
|
897
|
+
lg: { padding: Z.Lg },
|
|
898
|
+
xl: { padding: Z.Xl }
|
|
899
899
|
}, Zl = {
|
|
900
900
|
default: E.BorderDefault,
|
|
901
901
|
error: E.BorderError,
|
|
@@ -924,7 +924,7 @@ const Wl = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], jl = ["January", "
|
|
|
924
924
|
required: S,
|
|
925
925
|
id: T,
|
|
926
926
|
name: w
|
|
927
|
-
} = t, I = Ve(), M = T || I, g =
|
|
927
|
+
} = t, I = Ve(), M = T || I, g = me(null), [B, k] = O(!1), [C, x] = O(l), H = s !== void 0, A = H ? s : C, [P, D] = O(() => A || /* @__PURE__ */ new Date());
|
|
928
928
|
se(() => {
|
|
929
929
|
A && D(A);
|
|
930
930
|
}, [A]);
|
|
@@ -1005,18 +1005,18 @@ const Wl = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], jl = ["January", "
|
|
|
1005
1005
|
] });
|
|
1006
1006
|
};
|
|
1007
1007
|
ql.displayName = "PresetDatePicker";
|
|
1008
|
-
const
|
|
1008
|
+
const Rr = (r) => {
|
|
1009
1009
|
const t = r.match(/^(\d{1,2}):(\d{2})(?::(\d{2}))?$/);
|
|
1010
1010
|
return t ? { h: parseInt(t[1], 10), m: parseInt(t[2], 10), s: t[3] ? parseInt(t[3], 10) : 0 } : null;
|
|
1011
1011
|
}, Na = (r, t, a) => {
|
|
1012
|
-
const n =
|
|
1012
|
+
const n = Rr(r);
|
|
1013
1013
|
if (!n) return "";
|
|
1014
1014
|
let { h: s, m: l, s: o } = n, i = "";
|
|
1015
1015
|
t === "12h" && (i = s >= 12 ? " PM" : " AM", s = s % 12 || 12);
|
|
1016
1016
|
const d = String(s).padStart(2, "0"), u = String(l).padStart(2, "0"), h = String(o).padStart(2, "0");
|
|
1017
1017
|
return a ? `${d}:${u}:${h}${i}` : `${d}:${u}${i}`;
|
|
1018
1018
|
}, Jl = (r, t, a) => {
|
|
1019
|
-
const n = [], s = t ?
|
|
1019
|
+
const n = [], s = t ? Rr(t) : null, l = a ? Rr(a) : null;
|
|
1020
1020
|
for (let o = 0; o < 24; o++)
|
|
1021
1021
|
for (let i = 0; i < 60; i += r) {
|
|
1022
1022
|
const d = o * 60 + i;
|
|
@@ -1024,11 +1024,11 @@ const Mr = (r) => {
|
|
|
1024
1024
|
}
|
|
1025
1025
|
return n;
|
|
1026
1026
|
}, Ql = {
|
|
1027
|
-
xs: { padding:
|
|
1028
|
-
sm: { padding:
|
|
1029
|
-
md: { padding:
|
|
1030
|
-
lg: { padding:
|
|
1031
|
-
xl: { padding:
|
|
1027
|
+
xs: { padding: Z.Xs, cellHeight: "28px" },
|
|
1028
|
+
sm: { padding: Z.Sm, cellHeight: "32px" },
|
|
1029
|
+
md: { padding: Z.Md, cellHeight: "36px" },
|
|
1030
|
+
lg: { padding: Z.Lg, cellHeight: "40px" },
|
|
1031
|
+
xl: { padding: Z.Xl, cellHeight: "44px" }
|
|
1032
1032
|
}, ei = {
|
|
1033
1033
|
default: E.BorderDefault,
|
|
1034
1034
|
error: E.BorderError,
|
|
@@ -1055,7 +1055,7 @@ const Mr = (r) => {
|
|
|
1055
1055
|
clearable: _ = !0,
|
|
1056
1056
|
id: f,
|
|
1057
1057
|
name: S
|
|
1058
|
-
} = t, T = Ve(), w = f || T, I =
|
|
1058
|
+
} = t, T = Ve(), w = f || T, I = me(null), [M, g] = O(!1), [B, k] = O(l), C = s !== void 0, x = C ? s : B, H = Q(() => Jl(u, h, m), [u, h, m]), A = N((Y) => {
|
|
1059
1059
|
C || k(Y), o?.(Y), g(!1);
|
|
1060
1060
|
}, [C, o]), P = N((Y) => {
|
|
1061
1061
|
Y.stopPropagation(), C || k(""), o?.("");
|
|
@@ -1093,16 +1093,16 @@ const Mr = (r) => {
|
|
|
1093
1093
|
] });
|
|
1094
1094
|
};
|
|
1095
1095
|
ti.displayName = "PresetTimePicker";
|
|
1096
|
-
const ri = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], ai = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"],
|
|
1096
|
+
const ri = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], ai = ["January", "February", "March", "April", "May", "June", "July", "August", "September", "October", "November", "December"], Dr = (r, t) => r.getFullYear() === t.getFullYear() && r.getMonth() === t.getMonth() && r.getDate() === t.getDate(), Sa = (r, t) => new Date(r, t + 1, 0).getDate(), ni = (r, t) => new Date(r, t, 1).getDay(), Ir = (r, t) => {
|
|
1097
1097
|
const a = r.getDate(), n = r.getMonth() + 1, s = r.getFullYear();
|
|
1098
1098
|
return t.replace("DD", String(a).padStart(2, "0")).replace("D", String(a)).replace("MM", String(n).padStart(2, "0")).replace("M", String(n)).replace("YYYY", String(s)).replace("YY", String(s).slice(-2));
|
|
1099
1099
|
}, Ca = (r, t, a, n, s, l) => {
|
|
1100
1100
|
const o = [], i = /* @__PURE__ */ new Date(), d = Sa(r, t), h = (ni(r, t) - n + 7) % 7, m = t === 0 ? 11 : t - 1, p = t === 0 ? r - 1 : r, b = Sa(p, m), y = (f, S) => {
|
|
1101
|
-
const T = a.start ?
|
|
1101
|
+
const T = a.start ? Dr(f, a.start) : !1, w = a.end ? Dr(f, a.end) : !1;
|
|
1102
1102
|
return {
|
|
1103
1103
|
date: f,
|
|
1104
1104
|
isCurrentMonth: S,
|
|
1105
|
-
isToday:
|
|
1105
|
+
isToday: Dr(f, i),
|
|
1106
1106
|
isSelected: T || w,
|
|
1107
1107
|
isDisabled: !!(s && f < s || l && f > l),
|
|
1108
1108
|
isRangeStart: T,
|
|
@@ -1116,11 +1116,11 @@ const ri = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], ai = ["January", "
|
|
|
1116
1116
|
for (let f = 1; f <= 42 - o.length; f++) o.push(y(new Date(_, v, f), !1));
|
|
1117
1117
|
return o;
|
|
1118
1118
|
}, si = {
|
|
1119
|
-
xs: { gap:
|
|
1120
|
-
sm: { gap:
|
|
1121
|
-
md: { gap:
|
|
1122
|
-
lg: { gap:
|
|
1123
|
-
xl: { gap:
|
|
1119
|
+
xs: { gap: Z.Sm },
|
|
1120
|
+
sm: { gap: Z.Sm },
|
|
1121
|
+
md: { gap: Z.Md },
|
|
1122
|
+
lg: { gap: Z.Lg },
|
|
1123
|
+
xl: { gap: Z.Xl }
|
|
1124
1124
|
}, tn = ({
|
|
1125
1125
|
ref: r,
|
|
1126
1126
|
...t
|
|
@@ -1145,7 +1145,7 @@ const ri = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], ai = ["January", "
|
|
|
1145
1145
|
clearable: S = !0,
|
|
1146
1146
|
id: T,
|
|
1147
1147
|
name: w
|
|
1148
|
-
} = t, I = Ve(), M = T || I, g =
|
|
1148
|
+
} = t, I = Ve(), M = T || I, g = me(null), [B, k] = O(!1), [C, x] = O(l), [H, A] = O(!1), P = s !== void 0, D = P ? s : C, [G, j] = O(() => D.start || /* @__PURE__ */ new Date()), Y = Q(() => {
|
|
1149
1149
|
const oe = new Date(G);
|
|
1150
1150
|
return oe.setMonth(oe.getMonth() + 1), oe;
|
|
1151
1151
|
}, [G]), V = en({ enabled: B, onEscape: () => k(!1) }), z = Q(() => Ca(G.getFullYear(), G.getMonth(), D, y, i, d), [G, D, y, i, d]), L = Q(() => Ca(Y.getFullYear(), Y.getMonth(), D, y, i, d), [Y, D, y, i, d]), W = Q(() => {
|
|
@@ -1179,7 +1179,7 @@ const ri = ["Sun", "Mon", "Tue", "Wed", "Thu", "Fri", "Sat"], ai = ["January", "
|
|
|
1179
1179
|
};
|
|
1180
1180
|
return document.addEventListener("mousedown", oe), () => document.removeEventListener("mousedown", oe);
|
|
1181
1181
|
}, [B]);
|
|
1182
|
-
const q = Q(() => !D.start && !D.end ? "" : D.start && !D.end ? `${
|
|
1182
|
+
const q = Q(() => !D.start && !D.end ? "" : D.start && !D.end ? `${Ir(D.start, p)} - ...` : D.start && D.end ? `${Ir(D.start, p)} - ${Ir(D.end, p)}` : "", [D, p]), J = {
|
|
1183
1183
|
bg: E.BgSurface,
|
|
1184
1184
|
borderColor: a === "error" ? E.BorderError : a === "success" ? E.BorderSuccess : E.BorderDefault,
|
|
1185
1185
|
radius: Ce.Md,
|
|
@@ -1231,11 +1231,11 @@ const oi = () => Math.random().toString(36).slice(2, 11), ka = (r) => {
|
|
|
1231
1231
|
const t = 1024, a = ["B", "KB", "MB", "GB"], n = Math.floor(Math.log(r) / Math.log(t));
|
|
1232
1232
|
return `${parseFloat((r / Math.pow(t, n)).toFixed(1))} ${a[n]}`;
|
|
1233
1233
|
}, li = {
|
|
1234
|
-
xs: { padding:
|
|
1235
|
-
sm: { padding:
|
|
1236
|
-
md: { padding:
|
|
1237
|
-
lg: { padding:
|
|
1238
|
-
xl: { padding:
|
|
1234
|
+
xs: { padding: Z.Sm, minHeight: "80px" },
|
|
1235
|
+
sm: { padding: Z.Sm, minHeight: "100px" },
|
|
1236
|
+
md: { padding: Z.Md, minHeight: "120px" },
|
|
1237
|
+
lg: { padding: Z.Lg, minHeight: "150px" },
|
|
1238
|
+
xl: { padding: Z.Xl, minHeight: "180px" }
|
|
1239
1239
|
}, rn = ({
|
|
1240
1240
|
ref: r,
|
|
1241
1241
|
...t
|
|
@@ -1258,7 +1258,7 @@ const oi = () => Math.random().toString(36).slice(2, 11), ka = (r) => {
|
|
|
1258
1258
|
onError: _,
|
|
1259
1259
|
id: f,
|
|
1260
1260
|
name: S
|
|
1261
|
-
} = t, T = Ve(), w = f || T, I =
|
|
1261
|
+
} = t, T = Ve(), w = f || T, I = me(null), [M, g] = O([]), [B, k] = O(!1), C = s !== void 0, x = C ? s : M, H = N((V) => {
|
|
1262
1262
|
C || g(V), l?.(V);
|
|
1263
1263
|
}, [C, l]), A = N((V) => {
|
|
1264
1264
|
if (d && V.size > d) return `File size exceeds ${ka(d)}`;
|
|
@@ -1414,7 +1414,7 @@ const ii = [
|
|
|
1414
1414
|
helperText: m,
|
|
1415
1415
|
id: p,
|
|
1416
1416
|
name: b
|
|
1417
|
-
} = t, y = Ve(), v = p || y, _ =
|
|
1417
|
+
} = t, y = Ve(), v = p || y, _ = me(null), [f, S] = O(!1), [T, w] = O(s), I = n !== void 0, M = I ? n : T, g = sr(M) || { r: 59, g: 130, b: 246 }, B = N((P, D, G) => {
|
|
1418
1418
|
const j = wa(P, D, G, o);
|
|
1419
1419
|
I || w(j), l?.(j);
|
|
1420
1420
|
}, [o, I, l]), k = N((P) => {
|
|
@@ -1463,11 +1463,11 @@ const ii = [
|
|
|
1463
1463
|
};
|
|
1464
1464
|
ui.displayName = "PresetColorPicker";
|
|
1465
1465
|
const mi = {
|
|
1466
|
-
xs: { starSize: "14px", gap:
|
|
1466
|
+
xs: { starSize: "14px", gap: Z.None },
|
|
1467
1467
|
sm: { starSize: "18px", gap: "1px" },
|
|
1468
1468
|
md: { starSize: "22px", gap: "2px" },
|
|
1469
1469
|
lg: { starSize: "28px", gap: "3px" },
|
|
1470
|
-
xl: { starSize: "34px", gap:
|
|
1470
|
+
xl: { starSize: "34px", gap: Z.Xs }
|
|
1471
1471
|
}, pi = {
|
|
1472
1472
|
activeColor: "#f59e0b",
|
|
1473
1473
|
inactiveColor: E.Gray300,
|
|
@@ -1526,7 +1526,7 @@ const hi = ({
|
|
|
1526
1526
|
dropdownIcon: i,
|
|
1527
1527
|
leftIcon: d
|
|
1528
1528
|
}) => {
|
|
1529
|
-
const [u, h] = O(!1), m =
|
|
1529
|
+
const [u, h] = O(!1), m = me(null), p = me(null);
|
|
1530
1530
|
se(() => {
|
|
1531
1531
|
const f = (S) => {
|
|
1532
1532
|
m.current && !m.current.contains(S.target) && p.current && !p.current.contains(S.target) && h(!1);
|
|
@@ -1587,8 +1587,8 @@ const bi = {
|
|
|
1587
1587
|
color: E.TextPrimary
|
|
1588
1588
|
}
|
|
1589
1589
|
}, yi = {
|
|
1590
|
-
sm: { padding:
|
|
1591
|
-
md: { padding:
|
|
1590
|
+
sm: { padding: Z.Xs, fontSize: "0.6875rem", maxWidth: "180px" },
|
|
1591
|
+
md: { padding: Z.Sm, fontSize: "0.75rem", maxWidth: "240px" }
|
|
1592
1592
|
}, vi = {
|
|
1593
1593
|
radius: Ce.Sm,
|
|
1594
1594
|
arrowSize: "6px"
|
|
@@ -1624,11 +1624,11 @@ const xi = {
|
|
|
1624
1624
|
error: { borderColor: E.BorderError },
|
|
1625
1625
|
success: { borderColor: E.BorderSuccess }
|
|
1626
1626
|
}, Ni = {
|
|
1627
|
-
xs: { padding:
|
|
1628
|
-
sm: { padding:
|
|
1629
|
-
md: { padding:
|
|
1630
|
-
lg: { padding:
|
|
1631
|
-
xl: { padding:
|
|
1627
|
+
xs: { padding: Z.Xs, paddingX: Z.Sm, fontSize: "0.75rem", minHeight: "28px" },
|
|
1628
|
+
sm: { padding: Z.Xs, paddingX: Z.Sm, fontSize: "0.8125rem", minHeight: "32px" },
|
|
1629
|
+
md: { padding: Z.Sm, paddingX: Z.Md, fontSize: "0.875rem", minHeight: "36px" },
|
|
1630
|
+
lg: { padding: Z.Sm, paddingX: Z.Md, fontSize: "0.9375rem", minHeight: "42px" },
|
|
1631
|
+
xl: { padding: Z.Md, paddingX: Z.Lg, fontSize: "1rem", minHeight: "48px" }
|
|
1632
1632
|
}, Si = {
|
|
1633
1633
|
bg: E.BgSurface,
|
|
1634
1634
|
color: E.TextPrimary,
|
|
@@ -1707,11 +1707,11 @@ const Ci = {
|
|
|
1707
1707
|
error: { borderColor: E.BorderError },
|
|
1708
1708
|
success: { borderColor: E.BorderSuccess }
|
|
1709
1709
|
}, ki = {
|
|
1710
|
-
xs: { padding:
|
|
1711
|
-
sm: { padding:
|
|
1712
|
-
md: { padding:
|
|
1713
|
-
lg: { padding:
|
|
1714
|
-
xl: { padding:
|
|
1710
|
+
xs: { padding: Z.Xs, paddingX: Z.Sm, fontSize: "0.75rem", minHeight: "60px" },
|
|
1711
|
+
sm: { padding: Z.Xs, paddingX: Z.Sm, fontSize: "0.8125rem", minHeight: "72px" },
|
|
1712
|
+
md: { padding: Z.Sm, paddingX: Z.Md, fontSize: "0.875rem", minHeight: "84px" },
|
|
1713
|
+
lg: { padding: Z.Sm, paddingX: Z.Md, fontSize: "0.9375rem", minHeight: "96px" },
|
|
1714
|
+
xl: { padding: Z.Md, paddingX: Z.Lg, fontSize: "1rem", minHeight: "108px" }
|
|
1715
1715
|
}, wi = {
|
|
1716
1716
|
bg: E.BgSurface,
|
|
1717
1717
|
color: E.TextPrimary,
|
|
@@ -1749,7 +1749,7 @@ const Ci = {
|
|
|
1749
1749
|
"gloss-preset-textarea",
|
|
1750
1750
|
`gloss-preset-textarea--${_}`,
|
|
1751
1751
|
`gloss-preset-textarea--${n}`
|
|
1752
|
-
].filter(Boolean).join(" "), T =
|
|
1752
|
+
].filter(Boolean).join(" "), T = me(null), w = N((g) => {
|
|
1753
1753
|
if (!g || !h) return;
|
|
1754
1754
|
g.style.height = "auto";
|
|
1755
1755
|
const B = getComputedStyle(g), k = parseFloat(B.lineHeight) || parseFloat(B.fontSize) * 1.2, C = parseFloat(B.paddingTop) || 0, x = parseFloat(B.paddingBottom) || 0, H = parseFloat(B.borderTopWidth) || 0, A = parseFloat(B.borderBottomWidth) || 0, P = C + x + H + A, D = m ? k * m + P : 0, G = p ? k * p + P : 1 / 0, j = Math.min(Math.max(g.scrollHeight, D), G);
|
|
@@ -1775,11 +1775,11 @@ const Ci = {
|
|
|
1775
1775
|
};
|
|
1776
1776
|
nn.displayName = "PresetTextarea";
|
|
1777
1777
|
const Di = {
|
|
1778
|
-
xs: { padding:
|
|
1779
|
-
sm: { padding:
|
|
1780
|
-
md: { padding:
|
|
1781
|
-
lg: { padding:
|
|
1782
|
-
xl: { padding:
|
|
1778
|
+
xs: { padding: Z.Xs, fontSize: "0.75rem", minHeight: "28px" },
|
|
1779
|
+
sm: { padding: Z.Sm, fontSize: "0.8125rem", minHeight: "32px" },
|
|
1780
|
+
md: { padding: Z.Md, fontSize: "0.875rem", minHeight: "36px" },
|
|
1781
|
+
lg: { padding: Z.Lg, fontSize: "1rem", minHeight: "40px" },
|
|
1782
|
+
xl: { padding: Z.Xl, fontSize: "1.125rem", minHeight: "44px" }
|
|
1783
1783
|
}, Ii = {
|
|
1784
1784
|
default: E.BorderDefault,
|
|
1785
1785
|
error: E.BorderError,
|
|
@@ -1892,11 +1892,11 @@ const Bi = {
|
|
|
1892
1892
|
ssn: { mask: "000-00-0000", lazy: !0 },
|
|
1893
1893
|
currency: { mask: Number, scale: 2, thousandsSeparator: ",", radix: ".", mapToRadix: ["."], normalizeZeros: !0, padFractionalZeros: !0 }
|
|
1894
1894
|
}, Mi = {
|
|
1895
|
-
xs: { padding:
|
|
1896
|
-
sm: { padding:
|
|
1897
|
-
md: { padding:
|
|
1898
|
-
lg: { padding:
|
|
1899
|
-
xl: { padding:
|
|
1895
|
+
xs: { padding: Z.Xs, fontSize: "0.75rem", minHeight: "28px" },
|
|
1896
|
+
sm: { padding: Z.Sm, fontSize: "0.8125rem", minHeight: "32px" },
|
|
1897
|
+
md: { padding: Z.Md, fontSize: "0.875rem", minHeight: "36px" },
|
|
1898
|
+
lg: { padding: Z.Lg, fontSize: "1rem", minHeight: "40px" },
|
|
1899
|
+
xl: { padding: Z.Xl, fontSize: "1.125rem", minHeight: "44px" }
|
|
1900
1900
|
}, Ai = {
|
|
1901
1901
|
default: E.BorderDefault,
|
|
1902
1902
|
error: E.BorderError,
|
|
@@ -1921,7 +1921,7 @@ const Bi = {
|
|
|
1921
1921
|
required: y,
|
|
1922
1922
|
id: v,
|
|
1923
1923
|
name: _
|
|
1924
|
-
} = t, f =
|
|
1924
|
+
} = t, f = me(null), S = me(null), T = typeof s == "string" ? Bi[s] : s, w = N((g) => {
|
|
1925
1925
|
f.current = g, typeof r == "function" ? r(g) : r && (r.current = g);
|
|
1926
1926
|
}, [r]);
|
|
1927
1927
|
se(() => {
|
|
@@ -1988,11 +1988,11 @@ const Ri = {
|
|
|
1988
1988
|
borderColor: E.BorderSuccess
|
|
1989
1989
|
}
|
|
1990
1990
|
}, zi = {
|
|
1991
|
-
xs: { padding:
|
|
1992
|
-
sm: { padding:
|
|
1993
|
-
md: { padding:
|
|
1994
|
-
lg: { padding:
|
|
1995
|
-
xl: { padding:
|
|
1991
|
+
xs: { padding: Z.Xs, fontSize: "0.75rem", minHeight: "24px" },
|
|
1992
|
+
sm: { padding: Z.Xs, fontSize: "0.8125rem", minHeight: "30px" },
|
|
1993
|
+
md: { padding: Z.Sm, fontSize: "0.875rem", minHeight: "36px" },
|
|
1994
|
+
lg: { padding: Z.Sm, fontSize: "0.9375rem", minHeight: "42px" },
|
|
1995
|
+
xl: { padding: Z.Md, fontSize: "1rem", minHeight: "48px" }
|
|
1996
1996
|
}, Fi = {
|
|
1997
1997
|
bg: E.BgSurface,
|
|
1998
1998
|
radius: Ce.Md
|
|
@@ -2041,11 +2041,11 @@ const $i = Yt("md"), Oi = {
|
|
|
2041
2041
|
elevation: "none"
|
|
2042
2042
|
}
|
|
2043
2043
|
}, Li = {
|
|
2044
|
-
xs: { padding:
|
|
2045
|
-
sm: { padding:
|
|
2046
|
-
md: { padding:
|
|
2047
|
-
lg: { padding:
|
|
2048
|
-
xl: { padding:
|
|
2044
|
+
xs: { padding: Z.Xs },
|
|
2045
|
+
sm: { padding: Z.Sm },
|
|
2046
|
+
md: { padding: Z.Md },
|
|
2047
|
+
lg: { padding: Z.Lg },
|
|
2048
|
+
xl: { padding: Z.Xl }
|
|
2049
2049
|
}, Hi = {
|
|
2050
2050
|
radius: Ce.Lg
|
|
2051
2051
|
}, sn = ({
|
|
@@ -2222,7 +2222,7 @@ const Ji = {
|
|
|
2222
2222
|
md: { fontSize: "0.8125rem", padding: "4px", paddingX: "10px" },
|
|
2223
2223
|
lg: { fontSize: "0.875rem", padding: "5px", paddingX: "12px" },
|
|
2224
2224
|
xl: { fontSize: "0.9375rem", padding: "6px", paddingX: "14px" }
|
|
2225
|
-
},
|
|
2225
|
+
}, Kr = ({
|
|
2226
2226
|
ref: r,
|
|
2227
2227
|
...t
|
|
2228
2228
|
}) => {
|
|
@@ -2296,7 +2296,7 @@ const Ji = {
|
|
|
2296
2296
|
}
|
|
2297
2297
|
);
|
|
2298
2298
|
};
|
|
2299
|
-
|
|
2299
|
+
Kr.displayName = "PresetChip";
|
|
2300
2300
|
const ec = {
|
|
2301
2301
|
borderColor: E.BorderDefault,
|
|
2302
2302
|
radius: Ce.None
|
|
@@ -2338,8 +2338,8 @@ const nc = ({
|
|
|
2338
2338
|
};
|
|
2339
2339
|
nc.displayName = "PresetAccordionContent";
|
|
2340
2340
|
const sc = {
|
|
2341
|
-
sm: { padding:
|
|
2342
|
-
md: { padding:
|
|
2341
|
+
sm: { padding: Z.Xs, minWidth: "140px" },
|
|
2342
|
+
md: { padding: Z.Sm, minWidth: "180px" }
|
|
2343
2343
|
}, oc = {
|
|
2344
2344
|
bg: E.BgSurface,
|
|
2345
2345
|
borderColor: E.BorderDefault,
|
|
@@ -2393,7 +2393,7 @@ function ic({ label: r, open: t, onOpenChange: a, showCount: n = "never", childr
|
|
|
2393
2393
|
}
|
|
2394
2394
|
ic.displayName = "PresetMenuGroup";
|
|
2395
2395
|
const cc = {
|
|
2396
|
-
padding:
|
|
2396
|
+
padding: Z.Sm,
|
|
2397
2397
|
hoverBg: E.BgHover
|
|
2398
2398
|
}, dc = ({
|
|
2399
2399
|
ref: r,
|
|
@@ -2430,7 +2430,7 @@ uc.displayName = "PresetMenuDivider";
|
|
|
2430
2430
|
function mc(r) {
|
|
2431
2431
|
const { trigger: t, items: a, value: n, onChange: s, ...l } = r, o = { ...l };
|
|
2432
2432
|
delete o.className, delete o.style;
|
|
2433
|
-
const [i, d] = O(!1), u =
|
|
2433
|
+
const [i, d] = O(!1), u = me(null), m = a.find((b) => b.value === n)?.label || t || "Select...";
|
|
2434
2434
|
se(() => {
|
|
2435
2435
|
const b = (y) => {
|
|
2436
2436
|
u.current && !u.current.contains(y.target) && d(!1);
|
|
@@ -2502,7 +2502,7 @@ const ln = ({
|
|
|
2502
2502
|
] });
|
|
2503
2503
|
};
|
|
2504
2504
|
ln.displayName = "AsyncLoader";
|
|
2505
|
-
const
|
|
2505
|
+
const Tr = {
|
|
2506
2506
|
fade: {
|
|
2507
2507
|
enter: {
|
|
2508
2508
|
from: { opacity: 0 },
|
|
@@ -2615,7 +2615,7 @@ function pc({
|
|
|
2615
2615
|
...m
|
|
2616
2616
|
}) {
|
|
2617
2617
|
delete m.className, delete m.style;
|
|
2618
|
-
const [p, b] = O(r ? "entered" : "exited"), [y, v] = O(r), _ =
|
|
2618
|
+
const [p, b] = O(r ? "entered" : "exited"), [y, v] = O(r), _ = me(null), f = me(null), S = typeof t == "string" ? Tr[t] : t, T = a ?? (typeof t == "string" ? Tr[t]?.duration : st.normal) ?? st.normal, w = n ?? (typeof t == "string" ? Tr[t]?.easing : nt.easeOut) ?? nt.easeOut, I = N(() => {
|
|
2619
2619
|
_.current && (clearTimeout(_.current), _.current = null), f.current && (cancelAnimationFrame(f.current), f.current = null);
|
|
2620
2620
|
}, []);
|
|
2621
2621
|
if (se(() => (I(), r ? (v(!0), o?.(), f.current = requestAnimationFrame(() => {
|
|
@@ -2793,7 +2793,7 @@ const dn = _e.memo(({
|
|
|
2793
2793
|
a(r);
|
|
2794
2794
|
}, [r, a]);
|
|
2795
2795
|
return /* @__PURE__ */ e(
|
|
2796
|
-
|
|
2796
|
+
Wr,
|
|
2797
2797
|
{
|
|
2798
2798
|
label: t,
|
|
2799
2799
|
size: l,
|
|
@@ -2831,7 +2831,7 @@ const ir = _e.memo(({
|
|
|
2831
2831
|
exposeTabRefs: l,
|
|
2832
2832
|
connectorActive: o
|
|
2833
2833
|
}) => {
|
|
2834
|
-
const i =
|
|
2834
|
+
const i = me(null), d = me({}), [u, h] = O(null), [m, p] = O({ left: 0, width: 0 }), [b, y] = O({ left: 0, width: 0 }), v = (f) => {
|
|
2835
2835
|
const S = d.current[f], T = i.current;
|
|
2836
2836
|
if (!S || !T) return { left: 0, width: 0 };
|
|
2837
2837
|
const w = S.getBoundingClientRect(), I = T.getBoundingClientRect();
|
|
@@ -3197,34 +3197,34 @@ const xc = ({
|
|
|
3197
3197
|
);
|
|
3198
3198
|
};
|
|
3199
3199
|
xc.displayName = "SkeletonCard";
|
|
3200
|
-
let
|
|
3201
|
-
const
|
|
3200
|
+
let zr = null;
|
|
3201
|
+
const Fr = /* @__PURE__ */ new Set();
|
|
3202
3202
|
function Nc(r) {
|
|
3203
|
-
return
|
|
3204
|
-
|
|
3203
|
+
return Fr.add(r), () => {
|
|
3204
|
+
Fr.delete(r);
|
|
3205
3205
|
};
|
|
3206
3206
|
}
|
|
3207
|
-
function
|
|
3208
|
-
return
|
|
3207
|
+
function Er() {
|
|
3208
|
+
return zr;
|
|
3209
3209
|
}
|
|
3210
|
-
function
|
|
3211
|
-
|
|
3210
|
+
function Pr(r) {
|
|
3211
|
+
zr !== r && (zr = r, Fr.forEach((t) => t()));
|
|
3212
3212
|
}
|
|
3213
3213
|
function Sc(r, t, a) {
|
|
3214
3214
|
const n = Ve(), s = t ?? n, l = Yn(
|
|
3215
3215
|
Nc,
|
|
3216
|
-
|
|
3216
|
+
Er,
|
|
3217
3217
|
// SSR fallback — no menu active on server render.
|
|
3218
3218
|
() => null
|
|
3219
|
-
), o =
|
|
3219
|
+
), o = me(a);
|
|
3220
3220
|
return se(() => {
|
|
3221
3221
|
o.current = a;
|
|
3222
3222
|
}, [a]), se(() => {
|
|
3223
3223
|
r && l !== null && l !== s && o.current(!1);
|
|
3224
3224
|
}, [l, s, r]), se(() => {
|
|
3225
|
-
r ?
|
|
3225
|
+
r ? Pr(s) : Er() === s && Pr(null);
|
|
3226
3226
|
}, [r, s]), se(() => () => {
|
|
3227
|
-
|
|
3227
|
+
Er() === s && Pr(null);
|
|
3228
3228
|
}, [s]), { menuId: s, activeMenuId: l };
|
|
3229
3229
|
}
|
|
3230
3230
|
const Ye = {
|
|
@@ -3469,7 +3469,7 @@ const un = (r) => {
|
|
|
3469
3469
|
left: ce ? `${d}px` : "50%",
|
|
3470
3470
|
transform: "translateX(-50%)",
|
|
3471
3471
|
transition: ce ? `left ${Ye.ANCHOR_X_MS}ms ease-out` : void 0
|
|
3472
|
-
}, te =
|
|
3472
|
+
}, te = me(null);
|
|
3473
3473
|
se(() => () => {
|
|
3474
3474
|
te.current !== null && (clearTimeout(te.current), te.current = null);
|
|
3475
3475
|
}, []);
|
|
@@ -3489,7 +3489,7 @@ const un = (r) => {
|
|
|
3489
3489
|
Y(!!ee), l(ee);
|
|
3490
3490
|
}, [s, l]), [Ee, Je] = O(
|
|
3491
3491
|
{}
|
|
3492
|
-
), xe =
|
|
3492
|
+
), xe = me(
|
|
3493
3493
|
{}
|
|
3494
3494
|
);
|
|
3495
3495
|
se(() => () => {
|
|
@@ -3497,7 +3497,7 @@ const un = (r) => {
|
|
|
3497
3497
|
for (const ve of ee) clearTimeout(ve);
|
|
3498
3498
|
xe.current = {};
|
|
3499
3499
|
}, []);
|
|
3500
|
-
const
|
|
3500
|
+
const ae = N((ee) => {
|
|
3501
3501
|
const ve = ee.id;
|
|
3502
3502
|
xe.current[ve] || (xe.current[ve] = []), Je((ze) => ({ ...ze, [ve]: "pressed" }));
|
|
3503
3503
|
const We = setTimeout(() => {
|
|
@@ -3517,9 +3517,9 @@ const un = (r) => {
|
|
|
3517
3517
|
ee.onClick();
|
|
3518
3518
|
return;
|
|
3519
3519
|
}
|
|
3520
|
-
|
|
3520
|
+
ae(ee);
|
|
3521
3521
|
},
|
|
3522
|
-
[
|
|
3522
|
+
[ae]
|
|
3523
3523
|
), [Pe, Oe] = O(null);
|
|
3524
3524
|
return /* @__PURE__ */ e(tl, { children: /* @__PURE__ */ e(
|
|
3525
3525
|
_t.div,
|
|
@@ -4003,11 +4003,11 @@ const ot = function({
|
|
|
4003
4003
|
onFlipChange: q,
|
|
4004
4004
|
clickShadowSlot: J
|
|
4005
4005
|
}) {
|
|
4006
|
-
const [pe, ie] = O(!1), [oe, ce] = O(!1), [re, te] = O(!1), fe = U ?? re, Ne =
|
|
4007
|
-
xe.current = null,
|
|
4006
|
+
const [pe, ie] = O(!1), [oe, ce] = O(!1), [re, te] = O(!1), fe = U ?? re, Ne = me(!1), Ue = me(null), Ee = L !== void 0 ? L : pe, Je = z ?? Ue, xe = me(null), ae = me(null), Se = t ?? a, Pe = N(() => {
|
|
4007
|
+
xe.current = null, ae.current = null, U !== void 0 ? q?.(!0) : te(!0);
|
|
4008
4008
|
}, [U, q]), Oe = N(() => {
|
|
4009
4009
|
if (x) {
|
|
4010
|
-
const Te =
|
|
4010
|
+
const Te = ae.current;
|
|
4011
4011
|
if (Te !== null && Te.length < 2)
|
|
4012
4012
|
return;
|
|
4013
4013
|
U !== void 0 ? q?.(!1) : te(!1), Te && Te.length >= 2 && H && H(Te);
|
|
@@ -4148,7 +4148,7 @@ const ot = function({
|
|
|
4148
4148
|
title: k,
|
|
4149
4149
|
currentStackedTimeframes: A,
|
|
4150
4150
|
onSelectStackedTimeframes: (Te) => {
|
|
4151
|
-
|
|
4151
|
+
ae.current = Te;
|
|
4152
4152
|
}
|
|
4153
4153
|
}
|
|
4154
4154
|
)
|
|
@@ -4266,7 +4266,7 @@ const Uc = function(t) {
|
|
|
4266
4266
|
sparklineInset: _ = "padded",
|
|
4267
4267
|
slotToActionStripConfig: f,
|
|
4268
4268
|
onSlotActionStripConfigChange: S
|
|
4269
|
-
} = t, T = h || i[i.length - 1] || "YTD", w = p ? "gloss-metric-data-stale" : "gloss-metric-data-fresh", I =
|
|
4269
|
+
} = t, T = h || i[i.length - 1] || "YTD", w = p ? "gloss-metric-data-stale" : "gloss-metric-data-fresh", I = me(!1);
|
|
4270
4270
|
se(() => {
|
|
4271
4271
|
if (I.current) return;
|
|
4272
4272
|
const z = "onTableAction" in t;
|
|
@@ -4291,7 +4291,7 @@ const Uc = function(t) {
|
|
|
4291
4291
|
S?.(z, W);
|
|
4292
4292
|
},
|
|
4293
4293
|
[y, f, S]
|
|
4294
|
-
), g =
|
|
4294
|
+
), g = me(null), B = N(() => {
|
|
4295
4295
|
g.current !== null && (clearTimeout(g.current), g.current = null);
|
|
4296
4296
|
}, []);
|
|
4297
4297
|
se(() => () => {
|
|
@@ -4310,7 +4310,7 @@ const Uc = function(t) {
|
|
|
4310
4310
|
B(), C(z, L);
|
|
4311
4311
|
},
|
|
4312
4312
|
[C, B]
|
|
4313
|
-
), H = !!y || !!f, A = !!v || !!f, P =
|
|
4313
|
+
), H = !!y || !!f, A = !!v || !!f, P = me(null), { capacity: D } = Js(P), G = b != null ? Yc(b) : D, j = Q(() => i.map((z, L) => {
|
|
4314
4314
|
const W = o.find((U) => U.timeframe === z) || o[L], F = W?.value ?? null, K = Ks(F, { prefix: n, suffix: s, abbreviated: !0 });
|
|
4315
4315
|
return {
|
|
4316
4316
|
timeframe: z,
|
|
@@ -4458,7 +4458,7 @@ Uc.displayName = "StackedGroupCard";
|
|
|
4458
4458
|
function Xc(r) {
|
|
4459
4459
|
return r <= 4 ? 22 : r <= 6 ? 18 : r <= 8 ? 15 : 13;
|
|
4460
4460
|
}
|
|
4461
|
-
const
|
|
4461
|
+
const $r = {
|
|
4462
4462
|
state: "idle",
|
|
4463
4463
|
activeCardId: null,
|
|
4464
4464
|
activeDimensionId: null,
|
|
@@ -4482,11 +4482,11 @@ function Zc(r, t) {
|
|
|
4482
4482
|
};
|
|
4483
4483
|
case "COMMIT_CONFIG":
|
|
4484
4484
|
return r.state !== "configuring" ? r : {
|
|
4485
|
-
|
|
4485
|
+
...$r,
|
|
4486
4486
|
dirtyState: {}
|
|
4487
4487
|
};
|
|
4488
4488
|
case "CANCEL_CONFIG":
|
|
4489
|
-
return r.state !== "configuring" ? r : {
|
|
4489
|
+
return r.state !== "configuring" ? r : { ...$r };
|
|
4490
4490
|
case "SET_DIRTY":
|
|
4491
4491
|
return {
|
|
4492
4492
|
...r,
|
|
@@ -4504,7 +4504,7 @@ function Zc(r, t) {
|
|
|
4504
4504
|
}
|
|
4505
4505
|
}
|
|
4506
4506
|
function qc(r) {
|
|
4507
|
-
const [t, a] = Un(Zc,
|
|
4507
|
+
const [t, a] = Un(Zc, $r), { onCommit: n } = r ?? {}, s = N((u, h) => {
|
|
4508
4508
|
if (!u) {
|
|
4509
4509
|
(typeof process > "u" || process.env.NODE_ENV !== "production") && console.warn(
|
|
4510
4510
|
"[useFlipAndStage] beginConfig called with null or empty cardId — ignoring."
|
|
@@ -5053,7 +5053,7 @@ const Ta = () => /* @__PURE__ */ c(
|
|
|
5053
5053
|
whiteSpace: "nowrap",
|
|
5054
5054
|
overflow: "hidden",
|
|
5055
5055
|
textOverflow: "ellipsis"
|
|
5056
|
-
},
|
|
5056
|
+
}, Or = _e.memo(({
|
|
5057
5057
|
value: r,
|
|
5058
5058
|
onChange: t,
|
|
5059
5059
|
onSelect: a,
|
|
@@ -5063,7 +5063,7 @@ const Ta = () => /* @__PURE__ */ c(
|
|
|
5063
5063
|
fading: o,
|
|
5064
5064
|
options: i
|
|
5065
5065
|
}) => {
|
|
5066
|
-
const [d, u] = O(!1), [h, m] = O(-1), p =
|
|
5066
|
+
const [d, u] = O(!1), [h, m] = O(-1), p = me(null), b = me(null), y = me(null), v = _e.useCallback((g) => g.label || g.name || g.id, []), _ = _e.useMemo(() => {
|
|
5067
5067
|
if (!i || i.length === 0) return [];
|
|
5068
5068
|
if (!r.trim()) return i.slice(0, Ea);
|
|
5069
5069
|
const g = r.toLowerCase();
|
|
@@ -5222,7 +5222,7 @@ const Ta = () => /* @__PURE__ */ c(
|
|
|
5222
5222
|
}
|
|
5223
5223
|
);
|
|
5224
5224
|
});
|
|
5225
|
-
|
|
5225
|
+
Or.displayName = "FilterInput";
|
|
5226
5226
|
const pd = "left 0.35s cubic-bezier(0.4, 0, 0.2, 1), width 0.35s cubic-bezier(0.4, 0, 0.2, 1)", wt = "0.35s cubic-bezier(0.16, 1, 0.3, 1)", Dt = "0.25s cubic-bezier(0.4, 0, 1, 1)", fn = _e.memo(({
|
|
5227
5227
|
showRow2: r,
|
|
5228
5228
|
showItemFilter: t,
|
|
@@ -5265,7 +5265,7 @@ const pd = "left 0.35s cubic-bezier(0.4, 0, 0.2, 1), width 0.35s cubic-bezier(0.
|
|
|
5265
5265
|
transition: `transform ${t ? wt : Dt}, opacity ${t ? wt : Dt}`,
|
|
5266
5266
|
pointerEvents: t ? "auto" : "none"
|
|
5267
5267
|
}, children: /* @__PURE__ */ e(
|
|
5268
|
-
|
|
5268
|
+
Or,
|
|
5269
5269
|
{
|
|
5270
5270
|
value: l,
|
|
5271
5271
|
onChange: o,
|
|
@@ -5286,7 +5286,7 @@ const pd = "left 0.35s cubic-bezier(0.4, 0, 0.2, 1), width 0.35s cubic-bezier(0.
|
|
|
5286
5286
|
transition: `${pd}, transform ${a ? wt : Dt}, opacity ${a ? wt : Dt}`,
|
|
5287
5287
|
pointerEvents: a ? "auto" : "none"
|
|
5288
5288
|
}, children: /* @__PURE__ */ e(
|
|
5289
|
-
|
|
5289
|
+
Or,
|
|
5290
5290
|
{
|
|
5291
5291
|
value: p,
|
|
5292
5292
|
onChange: b,
|
|
@@ -5300,7 +5300,7 @@ const pd = "left 0.35s cubic-bezier(0.4, 0, 0.2, 1), width 0.35s cubic-bezier(0.
|
|
|
5300
5300
|
) })
|
|
5301
5301
|
] }) }));
|
|
5302
5302
|
fn.displayName = "Row2FilterTray";
|
|
5303
|
-
const or = "left 0.35s cubic-bezier(0.4, 0, 0.2, 1), width 0.35s cubic-bezier(0.4, 0, 0.2, 1)", gd = "0.35s cubic-bezier(0.16, 1, 0.3, 1)", fd = "0.25s cubic-bezier(0.4, 0, 1, 1)",
|
|
5303
|
+
const or = "left 0.35s cubic-bezier(0.4, 0, 0.2, 1), width 0.35s cubic-bezier(0.4, 0, 0.2, 1)", gd = "0.35s cubic-bezier(0.16, 1, 0.3, 1)", fd = "0.25s cubic-bezier(0.4, 0, 1, 1)", Lr = _e.memo(({
|
|
5304
5304
|
pillLeft: r,
|
|
5305
5305
|
pillWidth: t,
|
|
5306
5306
|
pillTop: a,
|
|
@@ -5366,7 +5366,7 @@ const or = "left 0.35s cubic-bezier(0.4, 0, 0.2, 1), width 0.35s cubic-bezier(0.
|
|
|
5366
5366
|
} })
|
|
5367
5367
|
] });
|
|
5368
5368
|
});
|
|
5369
|
-
|
|
5369
|
+
Lr.displayName = "FusedShape";
|
|
5370
5370
|
const hd = {
|
|
5371
5371
|
itemPill: { left: 0, width: 0, top: 0, height: 0 },
|
|
5372
5372
|
itemFilter: { left: 0, width: 0, top: 0, height: 32 },
|
|
@@ -5453,11 +5453,11 @@ const yd = _e.memo(({
|
|
|
5453
5453
|
]
|
|
5454
5454
|
}), [p]), S = Q(() => ({
|
|
5455
5455
|
id: "dimension",
|
|
5456
|
-
tabs: b || d.map((
|
|
5457
|
-
id:
|
|
5458
|
-
label:
|
|
5456
|
+
tabs: b || d.map((ae) => ({
|
|
5457
|
+
id: ae.id,
|
|
5458
|
+
label: ae.label || ae.name || ae.id
|
|
5459
5459
|
}))
|
|
5460
|
-
}), [b, d]), [T, w] = O(!1), [I, M] = O(!1), [g, B] = O(null), [k, C] = O(null), [x, H] = O(""), [A, P] = O(""), [D, G] = O(!1), j = v.entity === "items" && T, Y = I, V = j || Y, z =
|
|
5460
|
+
}), [b, d]), [T, w] = O(!1), [I, M] = O(!1), [g, B] = O(null), [k, C] = O(null), [x, H] = O(""), [A, P] = O(""), [D, G] = O(!1), j = v.entity === "items" && T, Y = I, V = j || Y, z = me(null), L = me(null), W = me(null), F = me(null), K = me({}), U = me({}), q = bd(
|
|
5461
5461
|
z,
|
|
5462
5462
|
L,
|
|
5463
5463
|
W,
|
|
@@ -5468,48 +5468,48 @@ const yd = _e.memo(({
|
|
|
5468
5468
|
V,
|
|
5469
5469
|
g,
|
|
5470
5470
|
k
|
|
5471
|
-
), J =
|
|
5471
|
+
), J = me(v.dimension), pe = me(null);
|
|
5472
5472
|
se(() => (J.current !== v.dimension && (pe.current && clearTimeout(pe.current), G(!0), pe.current = setTimeout(() => G(!1), 150)), J.current = v.dimension, () => {
|
|
5473
5473
|
pe.current && clearTimeout(pe.current);
|
|
5474
5474
|
}), [v.dimension]);
|
|
5475
|
-
const ie =
|
|
5475
|
+
const ie = me({ id: null, name: null }), oe = me({ id: null, name: null });
|
|
5476
5476
|
se(() => {
|
|
5477
|
-
const
|
|
5478
|
-
(
|
|
5477
|
+
const ae = r.entity?.id ?? null, Se = r.entity?.name ?? null, Pe = r.byItem?.id ?? null, Oe = r.byItem?.name ?? null;
|
|
5478
|
+
(ae !== ie.current.id || Se !== ie.current.name) && (ie.current = { id: ae, name: Se }, ae && Se ? (C(Se), M(!0), P("")) : C(null)), (Pe !== oe.current.id || Oe !== oe.current.name) && (oe.current = { id: Pe, name: Oe }, Pe && Oe ? (B(Oe), w(!0), H("")) : B(null));
|
|
5479
5479
|
}, [r.entity?.id, r.entity?.name, r.byItem?.id, r.byItem?.name]);
|
|
5480
|
-
const ce = N((
|
|
5481
|
-
|
|
5480
|
+
const ce = N((ae, Se) => {
|
|
5481
|
+
ae === "metric" ? a(Se) : ae === "entity" ? (t(Se), Se !== "items" && w(!1)) : ae === "dimension" && n(Se);
|
|
5482
5482
|
}, [a, t, n]), re = N(() => {
|
|
5483
|
-
v.entity === "items" && w((
|
|
5483
|
+
v.entity === "items" && w((ae) => !ae);
|
|
5484
5484
|
}, [v.entity]), te = N(() => {
|
|
5485
|
-
M((
|
|
5486
|
-
}, []), fe = N((
|
|
5487
|
-
B(
|
|
5485
|
+
M((ae) => !ae);
|
|
5486
|
+
}, []), fe = N((ae) => {
|
|
5487
|
+
B(ae), H(""), l(ae, ae);
|
|
5488
5488
|
}, [l]), Ne = N(() => {
|
|
5489
5489
|
B(null), l(null, null);
|
|
5490
|
-
}, [l]), Ue = N((
|
|
5491
|
-
C(
|
|
5490
|
+
}, [l]), Ue = N((ae) => {
|
|
5491
|
+
C(ae), P(""), s(ae, ae);
|
|
5492
5492
|
}, [s]), Ee = N(() => {
|
|
5493
5493
|
C(null), s(null, null);
|
|
5494
|
-
}, [s]), Je = N((
|
|
5495
|
-
const Se =
|
|
5496
|
-
B(Se), H(""), l(
|
|
5497
|
-
}, [l]), xe = N((
|
|
5498
|
-
const Se =
|
|
5499
|
-
C(Se), P(""), s(
|
|
5494
|
+
}, [s]), Je = N((ae) => {
|
|
5495
|
+
const Se = ae.label || ae.name || ae.id;
|
|
5496
|
+
B(Se), H(""), l(ae.id, Se);
|
|
5497
|
+
}, [l]), xe = N((ae) => {
|
|
5498
|
+
const Se = ae.label || ae.name || ae.id;
|
|
5499
|
+
C(Se), P(""), s(ae.id, Se);
|
|
5500
5500
|
}, [s]);
|
|
5501
5501
|
return /* @__PURE__ */ c("div", { ref: z, className: "gloss-chart-control-bar", children: [
|
|
5502
|
-
q.tracks.map((
|
|
5502
|
+
q.tracks.map((ae, Se) => /* @__PURE__ */ e(
|
|
5503
5503
|
"div",
|
|
5504
5504
|
{
|
|
5505
5505
|
className: "gloss-chart-control-bar__track",
|
|
5506
|
-
style: { left:
|
|
5506
|
+
style: { left: ae.left, top: ae.top, width: ae.width, height: ae.height }
|
|
5507
5507
|
},
|
|
5508
5508
|
Se
|
|
5509
5509
|
)),
|
|
5510
5510
|
/* @__PURE__ */ c("div", { className: "gloss-chart-control-bar__shapes", children: [
|
|
5511
5511
|
/* @__PURE__ */ e(
|
|
5512
|
-
|
|
5512
|
+
Lr,
|
|
5513
5513
|
{
|
|
5514
5514
|
pillLeft: q.itemPill.left,
|
|
5515
5515
|
pillWidth: q.itemPill.width,
|
|
@@ -5523,7 +5523,7 @@ const yd = _e.memo(({
|
|
|
5523
5523
|
}
|
|
5524
5524
|
),
|
|
5525
5525
|
/* @__PURE__ */ e(
|
|
5526
|
-
|
|
5526
|
+
Lr,
|
|
5527
5527
|
{
|
|
5528
5528
|
pillLeft: q.entityPill.left,
|
|
5529
5529
|
pillWidth: q.entityPill.width,
|
|
@@ -6044,7 +6044,7 @@ const xd = {
|
|
|
6044
6044
|
People: Co,
|
|
6045
6045
|
ViewList: ko,
|
|
6046
6046
|
Timeline: wo,
|
|
6047
|
-
Edit:
|
|
6047
|
+
Edit: jr,
|
|
6048
6048
|
Storefront: Do,
|
|
6049
6049
|
LocalOffer: Io,
|
|
6050
6050
|
AttachMoney: To,
|
|
@@ -6259,7 +6259,7 @@ const kd = ["S", "M", "T", "W", "T", "F", "S"], Ba = {
|
|
|
6259
6259
|
if (s !== void 0) return s;
|
|
6260
6260
|
const F = /* @__PURE__ */ new Date();
|
|
6261
6261
|
return F.setHours(23, 59, 59, 999), F;
|
|
6262
|
-
}, [s]), [p, b] = O(() => r ? new Date(r.getFullYear(), r.getMonth(), 1) : /* @__PURE__ */ new Date()), [y, v] = O(!1), [_, f] = O(null), S =
|
|
6262
|
+
}, [s]), [p, b] = O(() => r ? new Date(r.getFullYear(), r.getMonth(), 1) : /* @__PURE__ */ new Date()), [y, v] = O(!1), [_, f] = O(null), S = me(!1);
|
|
6263
6263
|
se(() => {
|
|
6264
6264
|
if (S.current) {
|
|
6265
6265
|
S.current = !1;
|
|
@@ -6307,7 +6307,7 @@ const kd = ["S", "M", "T", "W", "T", "F", "S"], Ba = {
|
|
|
6307
6307
|
for (let U = 0; U < M; U++)
|
|
6308
6308
|
F.push(
|
|
6309
6309
|
/* @__PURE__ */ e(
|
|
6310
|
-
|
|
6310
|
+
ue,
|
|
6311
6311
|
{
|
|
6312
6312
|
className: "mini-calendar__day mini-calendar__day--empty"
|
|
6313
6313
|
},
|
|
@@ -6319,7 +6319,7 @@ const kd = ["S", "M", "T", "W", "T", "F", "S"], Ba = {
|
|
|
6319
6319
|
const q = new Date(T, w, U), J = P(q), pe = D(q), ie = G(q), oe = j(q), ce = Y(q), re = H(q), te = er(q, K), fe = ["mini-calendar__day"];
|
|
6320
6320
|
ce ? (fe.push("mini-calendar__day--disabled"), ie ? fe.push("mini-calendar__day--disabled-end") : J && fe.push("mini-calendar__day--disabled-in-range"), re && fe.push("mini-calendar__day--market")) : (oe ? fe.push("mini-calendar__day--single") : pe ? fe.push("mini-calendar__day--start") : ie ? fe.push("mini-calendar__day--end") : J && fe.push("mini-calendar__day--in-range"), (oe || pe || ie || J) && (u === "secondary" ? fe.push("mini-calendar__day--secondary") : u === "tertiary" && fe.push("mini-calendar__day--tertiary")), te && !pe && !ie && !oe && fe.push("mini-calendar__day--today"), re && fe.push("mini-calendar__day--market"));
|
|
6321
6321
|
const Ne = /* @__PURE__ */ e(
|
|
6322
|
-
|
|
6322
|
+
ue,
|
|
6323
6323
|
{
|
|
6324
6324
|
component: "button",
|
|
6325
6325
|
onClick: ce ? void 0 : () => V(U),
|
|
@@ -6359,7 +6359,7 @@ const kd = ["S", "M", "T", "W", "T", "F", "S"], Ba = {
|
|
|
6359
6359
|
return F;
|
|
6360
6360
|
}, [T, w, I, M, P, D, G, j, Y, H, A, V, z, u]);
|
|
6361
6361
|
return /* @__PURE__ */ c(
|
|
6362
|
-
|
|
6362
|
+
ue,
|
|
6363
6363
|
{
|
|
6364
6364
|
className: "mini-calendar",
|
|
6365
6365
|
onMouseLeave: L,
|
|
@@ -6372,9 +6372,9 @@ const kd = ["S", "M", "T", "W", "T", "F", "S"], Ba = {
|
|
|
6372
6372
|
"--dot-offset": `${h.dotOffset}px`
|
|
6373
6373
|
},
|
|
6374
6374
|
children: [
|
|
6375
|
-
/* @__PURE__ */ c(
|
|
6375
|
+
/* @__PURE__ */ c(ue, { className: "mini-calendar__header", children: [
|
|
6376
6376
|
/* @__PURE__ */ e(et, { onClick: B, size: "small", sx: { p: 0.5 }, children: /* @__PURE__ */ e(Po, { fontSize: "small" }) }),
|
|
6377
|
-
i ? /* @__PURE__ */ c(
|
|
6377
|
+
i ? /* @__PURE__ */ c(ue, { sx: { display: "flex", alignItems: "center", gap: 0.5 }, children: [
|
|
6378
6378
|
/* @__PURE__ */ e(
|
|
6379
6379
|
ha,
|
|
6380
6380
|
{
|
|
@@ -6430,18 +6430,18 @@ const kd = ["S", "M", "T", "W", "T", "F", "S"], Ba = {
|
|
|
6430
6430
|
] }) : /* @__PURE__ */ e(De, { variant: "body2", fontWeight: 500, children: g }),
|
|
6431
6431
|
/* @__PURE__ */ e(et, { onClick: k, size: "small", sx: { p: 0.5 }, children: /* @__PURE__ */ e(Bo, { fontSize: "small" }) })
|
|
6432
6432
|
] }),
|
|
6433
|
-
/* @__PURE__ */ e(
|
|
6434
|
-
|
|
6433
|
+
/* @__PURE__ */ e(ue, { className: "mini-calendar__grid", children: kd.map((F, K) => /* @__PURE__ */ e(
|
|
6434
|
+
ue,
|
|
6435
6435
|
{
|
|
6436
6436
|
className: "mini-calendar__day-header",
|
|
6437
6437
|
children: F
|
|
6438
6438
|
},
|
|
6439
6439
|
`header-${K}`
|
|
6440
6440
|
)) }),
|
|
6441
|
-
/* @__PURE__ */ e(
|
|
6442
|
-
(o || y) && /* @__PURE__ */ c(
|
|
6443
|
-
o && /* @__PURE__ */ c(
|
|
6444
|
-
/* @__PURE__ */ e(
|
|
6441
|
+
/* @__PURE__ */ e(ue, { className: "mini-calendar__grid", children: W }),
|
|
6442
|
+
(o || y) && /* @__PURE__ */ c(ue, { className: "mini-calendar__legend", children: [
|
|
6443
|
+
o && /* @__PURE__ */ c(ue, { className: "mini-calendar__legend-item", children: [
|
|
6444
|
+
/* @__PURE__ */ e(ue, { className: "mini-calendar__legend-dot mini-calendar__legend-dot--market" }),
|
|
6445
6445
|
/* @__PURE__ */ e(De, { variant: "caption", color: "text.secondary", children: "Market event" })
|
|
6446
6446
|
] }),
|
|
6447
6447
|
y && /* @__PURE__ */ e(De, { variant: "caption", color: "primary", children: "Select end date" })
|
|
@@ -6464,7 +6464,7 @@ const Ht = ({
|
|
|
6464
6464
|
d.stopPropagation(), s && s(r);
|
|
6465
6465
|
};
|
|
6466
6466
|
return /* @__PURE__ */ c(
|
|
6467
|
-
|
|
6467
|
+
ue,
|
|
6468
6468
|
{
|
|
6469
6469
|
onClick: o,
|
|
6470
6470
|
sx: {
|
|
@@ -6489,7 +6489,7 @@ const Ht = ({
|
|
|
6489
6489
|
},
|
|
6490
6490
|
children: [
|
|
6491
6491
|
/* @__PURE__ */ e(
|
|
6492
|
-
|
|
6492
|
+
Ar,
|
|
6493
6493
|
{
|
|
6494
6494
|
fontSize: "small",
|
|
6495
6495
|
sx: {
|
|
@@ -6498,8 +6498,8 @@ const Ht = ({
|
|
|
6498
6498
|
}
|
|
6499
6499
|
}
|
|
6500
6500
|
),
|
|
6501
|
-
/* @__PURE__ */ c(
|
|
6502
|
-
/* @__PURE__ */ c(
|
|
6501
|
+
/* @__PURE__ */ c(ue, { sx: { flex: 1, minWidth: 0 }, children: [
|
|
6502
|
+
/* @__PURE__ */ c(ue, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
|
|
6503
6503
|
/* @__PURE__ */ e(
|
|
6504
6504
|
De,
|
|
6505
6505
|
{
|
|
@@ -6513,7 +6513,7 @@ const Ht = ({
|
|
|
6513
6513
|
}
|
|
6514
6514
|
),
|
|
6515
6515
|
r.active && /* @__PURE__ */ e(
|
|
6516
|
-
|
|
6516
|
+
Wr,
|
|
6517
6517
|
{
|
|
6518
6518
|
label: "Live",
|
|
6519
6519
|
size: "small",
|
|
@@ -6557,7 +6557,7 @@ const Ht = ({
|
|
|
6557
6557
|
p: 0.5,
|
|
6558
6558
|
flexShrink: 0
|
|
6559
6559
|
},
|
|
6560
|
-
children: /* @__PURE__ */ e(
|
|
6560
|
+
children: /* @__PURE__ */ e(jr, { fontSize: "small", sx: { fontSize: 16 } })
|
|
6561
6561
|
}
|
|
6562
6562
|
)
|
|
6563
6563
|
]
|
|
@@ -6600,21 +6600,21 @@ const Id = {
|
|
|
6600
6600
|
se(() => {
|
|
6601
6601
|
T(null);
|
|
6602
6602
|
}, [f.pinnedPreset]);
|
|
6603
|
-
const I =
|
|
6603
|
+
const I = me(null), [M, g] = O(null), [B, k] = O("calendar"), [C, x] = O(null), [H, A] = O(null), P = me(null), [D, G] = O(() => f.lastPreset || "mtd"), [j, Y] = O(null), [V, z] = O(null), [L, W] = O(null), [F, K] = O(null), [U, q] = O(null), [J, pe] = O(() => a ? v ?? f.compareEnabled ?? !1 : !1), ie = v ?? J, oe = N((R) => {
|
|
6604
6604
|
pe(R), _?.(R);
|
|
6605
|
-
}, [_]), [ce, re] = O("A"), [te, fe] = O(() => f.lastPresetB ?? null), [Ne, Ue] = O(null), [Ee, Je] = O(null), [xe,
|
|
6606
|
-
const R = m || tr, $ = p || [],
|
|
6607
|
-
...
|
|
6608
|
-
active: kt(
|
|
6605
|
+
}, [_]), [ce, re] = O("A"), [te, fe] = O(() => f.lastPresetB ?? null), [Ne, Ue] = O(null), [Ee, Je] = O(null), [xe, ae] = O(null), [Se, Pe] = O(null), [Oe, ee] = O(null), [ve, We] = O(null), [ze, je] = O(null), [ut, Te] = O(null), [Ae, Fe] = O(null), [mt, Qe] = O(null), [bt, Ke] = O(null), [we, Le] = O(1), [St, pt] = O(!1), [In, Tn] = O(void 0), Be = L !== null ? L : D, Pt = L !== null ? F : j, gt = L !== null ? U : V, lt = xe !== null ? xe : te, Bt = xe !== null ? Se : Ne, Mt = xe !== null ? Oe : Ee, it = Ae !== null ? Ae : ve, At = Ae !== null ? mt : ze, Rt = Ae !== null ? bt : ut, ta = L !== null && (L !== D || F !== j || U !== V), [ge, br] = O(() => {
|
|
6606
|
+
const R = m || tr, $ = p || [], X = new Set($.map((de) => de.id)), le = R.filter((de) => !X.has(de.id)).map((de) => ({ ...de, active: kt(de) })), ne = $.map((de) => ({
|
|
6607
|
+
...de,
|
|
6608
|
+
active: kt(de)
|
|
6609
6609
|
}));
|
|
6610
|
-
return [...
|
|
6610
|
+
return [...le, ...ne].sort((de, Re) => de.startDate.getTime() - Re.startDate.getTime());
|
|
6611
6611
|
});
|
|
6612
6612
|
se(() => {
|
|
6613
|
-
const R = m || tr, $ = p || [],
|
|
6614
|
-
...
|
|
6615
|
-
active: kt(
|
|
6613
|
+
const R = m || tr, $ = p || [], X = new Set($.map((de) => de.id)), le = R.filter((de) => !X.has(de.id)).map((de) => ({ ...de, active: kt(de) })), ne = $.map((de) => ({
|
|
6614
|
+
...de,
|
|
6615
|
+
active: kt(de)
|
|
6616
6616
|
}));
|
|
6617
|
-
br([...
|
|
6617
|
+
br([...le, ...ne].sort((de, Re) => de.startDate.getTime() - Re.startDate.getTime()));
|
|
6618
6618
|
}, [m, p]);
|
|
6619
6619
|
const [zt, En] = O(!1), [$e, Ft] = O({
|
|
6620
6620
|
label: "",
|
|
@@ -6624,17 +6624,17 @@ const Id = {
|
|
|
6624
6624
|
}), { pastAndCurrentEvents: yr, futureEvents: vr } = Q(() => {
|
|
6625
6625
|
const R = /* @__PURE__ */ new Date();
|
|
6626
6626
|
R.setHours(0, 0, 0, 0);
|
|
6627
|
-
const $ = [],
|
|
6628
|
-
return ge.forEach((
|
|
6629
|
-
|
|
6630
|
-
}), { pastAndCurrentEvents: $, futureEvents:
|
|
6631
|
-
}, [ge]), { defaultMarketEvents:
|
|
6632
|
-
const R = m || tr, $ = new Set(R.map((
|
|
6627
|
+
const $ = [], X = [];
|
|
6628
|
+
return ge.forEach((le) => {
|
|
6629
|
+
le.startDate > R ? X.push(le) : $.push(le);
|
|
6630
|
+
}), { pastAndCurrentEvents: $, futureEvents: X };
|
|
6631
|
+
}, [ge]), { defaultMarketEvents: ra, customRanges: aa, futureDefaultEvents: Zt, futureCustomRanges: na } = Q(() => {
|
|
6632
|
+
const R = m || tr, $ = new Set(R.map((X) => X.id));
|
|
6633
6633
|
return {
|
|
6634
|
-
defaultMarketEvents: yr.filter((
|
|
6635
|
-
customRanges: yr.filter((
|
|
6636
|
-
futureDefaultEvents: vr.filter((
|
|
6637
|
-
futureCustomRanges: vr.filter((
|
|
6634
|
+
defaultMarketEvents: yr.filter((X) => !X.isCustom && $.has(X.id)),
|
|
6635
|
+
customRanges: yr.filter((X) => X.isCustom || !$.has(X.id)),
|
|
6636
|
+
futureDefaultEvents: vr.filter((X) => !X.isCustom && $.has(X.id)),
|
|
6637
|
+
futureCustomRanges: vr.filter((X) => X.isCustom || !$.has(X.id))
|
|
6638
6638
|
};
|
|
6639
6639
|
}, [yr, vr, m]), ft = o || !!M;
|
|
6640
6640
|
se(() => {
|
|
@@ -6662,74 +6662,76 @@ const Id = {
|
|
|
6662
6662
|
}
|
|
6663
6663
|
const R = /* @__PURE__ */ new Date(), $ = new Date(tt.start);
|
|
6664
6664
|
$.setHours(0, 0, 0, 0);
|
|
6665
|
-
const
|
|
6666
|
-
|
|
6667
|
-
let
|
|
6665
|
+
const X = new Date(tt.end);
|
|
6666
|
+
X.setHours(0, 0, 0, 0);
|
|
6667
|
+
let le = null;
|
|
6668
6668
|
if (f.lastPreset) {
|
|
6669
|
-
const
|
|
6670
|
-
|
|
6671
|
-
const Re = new Date(
|
|
6672
|
-
Re.setHours(0, 0, 0, 0), $.getTime() ===
|
|
6669
|
+
const ne = Xe(f.lastPreset, R), de = new Date(ne.start);
|
|
6670
|
+
de.setHours(0, 0, 0, 0);
|
|
6671
|
+
const Re = new Date(ne.end);
|
|
6672
|
+
Re.setHours(0, 0, 0, 0), $.getTime() === de.getTime() && X.getTime() === Re.getTime() && (le = f.lastPreset);
|
|
6673
6673
|
}
|
|
6674
|
-
if (!
|
|
6675
|
-
const
|
|
6676
|
-
|
|
6674
|
+
if (!le) {
|
|
6675
|
+
const ne = rr(tt.start, tt.end, R, ge);
|
|
6676
|
+
le = ne ? ne.id : null;
|
|
6677
6677
|
}
|
|
6678
|
-
|
|
6678
|
+
le ? (G(le), Y(null), z(null)) : (G("custom"), Y(tt.start), z(tt.end)), W(null), K(null), q(null);
|
|
6679
6679
|
}, [tt.start?.getTime(), tt.end?.getTime(), ge, f.lastPreset, _r]);
|
|
6680
6680
|
const Pn = Q(() => {
|
|
6681
|
-
|
|
6681
|
+
const R = [...Sr, ...Cr].find((ne) => ne.id === D);
|
|
6682
|
+
if (R) return R.label;
|
|
6683
|
+
let $, X;
|
|
6682
6684
|
if (D === "custom" && j && V)
|
|
6683
|
-
|
|
6685
|
+
$ = j, X = V;
|
|
6684
6686
|
else {
|
|
6685
|
-
const
|
|
6686
|
-
if (
|
|
6687
|
-
|
|
6687
|
+
const ne = ge.find((de) => de.id === D);
|
|
6688
|
+
if (ne)
|
|
6689
|
+
$ = ne.startDate, X = ne.endDate;
|
|
6688
6690
|
else {
|
|
6689
|
-
const
|
|
6690
|
-
|
|
6691
|
+
const de = Xe(D);
|
|
6692
|
+
$ = de.start, X = de.end;
|
|
6691
6693
|
}
|
|
6692
6694
|
}
|
|
6693
|
-
return Ot(
|
|
6695
|
+
return Ot($, X, /* @__PURE__ */ new Date(), ge).display;
|
|
6694
6696
|
}, [D, j, V, ge]), Bn = Q(() => {
|
|
6695
6697
|
if (!ie || !te) return null;
|
|
6696
6698
|
let R, $;
|
|
6697
6699
|
if (te === "custom" && Ne && Ee)
|
|
6698
6700
|
R = Ne, $ = Ee;
|
|
6699
6701
|
else {
|
|
6700
|
-
const
|
|
6701
|
-
if (
|
|
6702
|
-
R =
|
|
6702
|
+
const le = ge.find((ne) => ne.id === te);
|
|
6703
|
+
if (le)
|
|
6704
|
+
R = le.startDate, $ = le.endDate;
|
|
6703
6705
|
else {
|
|
6704
|
-
const
|
|
6705
|
-
R =
|
|
6706
|
+
const ne = Xe(te);
|
|
6707
|
+
R = ne.start, $ = ne.end;
|
|
6706
6708
|
}
|
|
6707
6709
|
}
|
|
6708
6710
|
return Ot(R, $, /* @__PURE__ */ new Date(), ge).display;
|
|
6709
|
-
}, [ie, te, Ne, Ee, ge]),
|
|
6710
|
-
const R = ["7d", "30d", "60d", "90d", "mtd", "qtd", "ytd", "lytd"], $ = ge.find((
|
|
6711
|
+
}, [ie, te, Ne, Ee, ge]), sa = Q(() => {
|
|
6712
|
+
const R = ["7d", "30d", "60d", "90d", "mtd", "qtd", "ytd", "lytd"], $ = ge.find((X) => X.id === D);
|
|
6711
6713
|
if ($)
|
|
6712
6714
|
return yt($.startDate, $.endDate, /* @__PURE__ */ new Date());
|
|
6713
6715
|
if (R.includes(D)) {
|
|
6714
|
-
const { start:
|
|
6715
|
-
return yt(
|
|
6716
|
+
const { start: X, end: le } = Xe(D);
|
|
6717
|
+
return yt(X, le, /* @__PURE__ */ new Date());
|
|
6716
6718
|
}
|
|
6717
6719
|
return "";
|
|
6718
|
-
}, [D, ge]),
|
|
6720
|
+
}, [D, ge]), oa = Q(() => {
|
|
6719
6721
|
let R, $;
|
|
6720
6722
|
if (Be === "custom" && Pt && gt)
|
|
6721
6723
|
R = Pt, $ = gt;
|
|
6722
6724
|
else {
|
|
6723
|
-
const
|
|
6724
|
-
if (
|
|
6725
|
-
R =
|
|
6725
|
+
const ne = ge.find((de) => de.id === Be);
|
|
6726
|
+
if (ne)
|
|
6727
|
+
R = ne.startDate, $ = ne.endDate;
|
|
6726
6728
|
else {
|
|
6727
|
-
const
|
|
6728
|
-
R =
|
|
6729
|
+
const de = Xe(Be);
|
|
6730
|
+
R = de.start, $ = de.end;
|
|
6729
6731
|
}
|
|
6730
6732
|
}
|
|
6731
|
-
const
|
|
6732
|
-
return
|
|
6733
|
+
const X = Ot(R, $, /* @__PURE__ */ new Date(), ge), le = yt(R, $, /* @__PURE__ */ new Date());
|
|
6734
|
+
return X.preset ? `${X.preset.label} (${le})` : le;
|
|
6733
6735
|
}, [Be, Pt, gt, ge]);
|
|
6734
6736
|
Q(() => {
|
|
6735
6737
|
if (!ie || !lt) return null;
|
|
@@ -6737,46 +6739,46 @@ const Id = {
|
|
|
6737
6739
|
if (lt === "custom" && Bt && Mt)
|
|
6738
6740
|
R = Bt, $ = Mt;
|
|
6739
6741
|
else {
|
|
6740
|
-
const
|
|
6741
|
-
if (
|
|
6742
|
-
R =
|
|
6742
|
+
const ne = ge.find((de) => de.id === lt);
|
|
6743
|
+
if (ne)
|
|
6744
|
+
R = ne.startDate, $ = ne.endDate;
|
|
6743
6745
|
else {
|
|
6744
|
-
const
|
|
6745
|
-
R =
|
|
6746
|
+
const de = Xe(lt);
|
|
6747
|
+
R = de.start, $ = de.end;
|
|
6746
6748
|
}
|
|
6747
6749
|
}
|
|
6748
|
-
const
|
|
6749
|
-
return
|
|
6750
|
+
const X = Ot(R, $, /* @__PURE__ */ new Date(), ge), le = yt(R, $, /* @__PURE__ */ new Date());
|
|
6751
|
+
return X.preset ? `${X.preset.label} (${le})` : le;
|
|
6750
6752
|
}, [ie, lt, Bt, Mt, ge]), Q(() => {
|
|
6751
6753
|
if (!ie || we < 3 || !it) return null;
|
|
6752
6754
|
let R, $;
|
|
6753
6755
|
if (it === "custom" && At && Rt)
|
|
6754
6756
|
R = At, $ = Rt;
|
|
6755
6757
|
else {
|
|
6756
|
-
const
|
|
6757
|
-
if (
|
|
6758
|
-
R =
|
|
6758
|
+
const ne = ge.find((de) => de.id === it);
|
|
6759
|
+
if (ne)
|
|
6760
|
+
R = ne.startDate, $ = ne.endDate;
|
|
6759
6761
|
else {
|
|
6760
|
-
const
|
|
6761
|
-
R =
|
|
6762
|
+
const de = Xe(it);
|
|
6763
|
+
R = de.start, $ = de.end;
|
|
6762
6764
|
}
|
|
6763
6765
|
}
|
|
6764
|
-
const
|
|
6765
|
-
return
|
|
6766
|
+
const X = Ot(R, $, /* @__PURE__ */ new Date(), ge), le = yt(R, $, /* @__PURE__ */ new Date());
|
|
6767
|
+
return X.preset ? `${X.preset.label} (${le})` : le;
|
|
6766
6768
|
}, [ie, we, it, At, Rt, ge]);
|
|
6767
6769
|
const Mn = N((R) => {
|
|
6768
|
-
W(D), K(j), q(V), ie && (
|
|
6769
|
-
}, [D, j, V, ie, we, te, Ne, Ee, ve, ze, ut]),
|
|
6770
|
-
const
|
|
6771
|
-
|
|
6772
|
-
}, [t]), qt = N((R, $,
|
|
6773
|
-
if (R === "custom" && $ &&
|
|
6774
|
-
return [$,
|
|
6775
|
-
const
|
|
6776
|
-
if (
|
|
6777
|
-
return [
|
|
6778
|
-
const { start:
|
|
6779
|
-
return [
|
|
6770
|
+
W(D), K(j), q(V), ie && (ae(te), Pe(Ne), ee(Ee), we >= 3 && (Fe(ve), Qe(ze), Ke(ut))), g(R.currentTarget);
|
|
6771
|
+
}, [D, j, V, ie, we, te, Ne, Ee, ve, ze, ut]), la = N((R, $, X) => {
|
|
6772
|
+
const le = [R, $];
|
|
6773
|
+
X && (le.shortcutId = ar(X)), t(le);
|
|
6774
|
+
}, [t]), qt = N((R, $, X) => {
|
|
6775
|
+
if (R === "custom" && $ && X)
|
|
6776
|
+
return [$, X];
|
|
6777
|
+
const le = ge.find((Re) => Re.id === R);
|
|
6778
|
+
if (le)
|
|
6779
|
+
return [le.startDate, le.endDate];
|
|
6780
|
+
const { start: ne, end: de } = Xe(R);
|
|
6781
|
+
return [ne, de];
|
|
6780
6782
|
}, [ge]), rt = N((R) => {
|
|
6781
6783
|
h && h({ ...f, ...R });
|
|
6782
6784
|
}, [h, f]), Jt = N(() => {
|
|
@@ -6785,7 +6787,7 @@ const Id = {
|
|
|
6785
6787
|
const R = qt(L, F, U);
|
|
6786
6788
|
if (ie && we >= 2 && xe !== null) {
|
|
6787
6789
|
fe(xe), Ue(Se), Je(Oe);
|
|
6788
|
-
const $ = qt(xe, Se, Oe),
|
|
6790
|
+
const $ = qt(xe, Se, Oe), X = {
|
|
6789
6791
|
rangeA: R,
|
|
6790
6792
|
rangeB: $,
|
|
6791
6793
|
shortcutId: ar(L),
|
|
@@ -6793,8 +6795,8 @@ const Id = {
|
|
|
6793
6795
|
};
|
|
6794
6796
|
if (we >= 3 && Ae !== null) {
|
|
6795
6797
|
We(Ae), je(mt), Te(bt);
|
|
6796
|
-
const
|
|
6797
|
-
|
|
6798
|
+
const le = qt(Ae, mt, bt);
|
|
6799
|
+
X.rangeC = le, X.shortcutIdC = ar(Ae), rt({
|
|
6798
6800
|
lastPreset: L,
|
|
6799
6801
|
compareEnabled: !0,
|
|
6800
6802
|
rangeCount: we,
|
|
@@ -6809,7 +6811,7 @@ const Id = {
|
|
|
6809
6811
|
lastPresetB: xe,
|
|
6810
6812
|
lastPresetC: null
|
|
6811
6813
|
});
|
|
6812
|
-
t(
|
|
6814
|
+
t(X);
|
|
6813
6815
|
} else
|
|
6814
6816
|
rt({
|
|
6815
6817
|
lastPreset: L,
|
|
@@ -6817,70 +6819,70 @@ const Id = {
|
|
|
6817
6819
|
rangeCount: 1,
|
|
6818
6820
|
lastPresetB: null,
|
|
6819
6821
|
lastPresetC: null
|
|
6820
|
-
}),
|
|
6821
|
-
}, [L, F, U, ie, we, xe, Se, Oe, Ae, mt, bt, qt, t,
|
|
6822
|
-
o || (
|
|
6823
|
-
}, [o,
|
|
6824
|
-
o || (W(null), K(null), q(null),
|
|
6825
|
-
}, [o]),
|
|
6822
|
+
}), la(R[0], R[1], L);
|
|
6823
|
+
}, [L, F, U, ie, we, xe, Se, Oe, Ae, mt, bt, qt, t, la, rt]), An = N(() => {
|
|
6824
|
+
o || (ta && Jt(), W(null), K(null), q(null), ae(null), Pe(null), ee(null), Fe(null), Qe(null), Ke(null), A(null), g(null));
|
|
6825
|
+
}, [o, ta, Jt]), ia = N(() => {
|
|
6826
|
+
o || (W(null), K(null), q(null), ae(null), Pe(null), ee(null), Fe(null), Qe(null), Ke(null), A(null), g(null));
|
|
6827
|
+
}, [o]), ca = N(() => {
|
|
6826
6828
|
if (we >= 3) return;
|
|
6827
6829
|
const R = L !== null ? L : D;
|
|
6828
|
-
we === 1 ? (oe(!0), Le(2),
|
|
6829
|
-
}, [we, L, D, oe]),
|
|
6830
|
-
R === "C" ? (Le(2), Fe(null), Qe(null), Ke(null), We(null), je(null), Te(null), ce === "C" && re("B")) : R === "B" && we === 2 && (oe(!1), Le(1),
|
|
6830
|
+
we === 1 ? (oe(!0), Le(2), ae(R), re("B"), pt(!0)) : we === 2 && (Le(3), Fe(R), re("C"));
|
|
6831
|
+
}, [we, L, D, oe]), da = N((R) => {
|
|
6832
|
+
R === "C" ? (Le(2), Fe(null), Qe(null), Ke(null), We(null), je(null), Te(null), ce === "C" && re("B")) : R === "B" && we === 2 && (oe(!1), Le(1), ae(null), Pe(null), ee(null), fe(null), Ue(null), Je(null), re("A"), pt(!1), rt({
|
|
6831
6833
|
compareEnabled: !1,
|
|
6832
6834
|
rangeCount: 1,
|
|
6833
6835
|
lastPresetB: null,
|
|
6834
6836
|
lastPresetC: null
|
|
6835
6837
|
}));
|
|
6836
6838
|
}, [we, ce, oe, rt]), Rn = N(() => {
|
|
6837
|
-
oe(!1), Le(1), re("A"), pt(!1),
|
|
6839
|
+
oe(!1), Le(1), re("A"), pt(!1), ae(null), Pe(null), ee(null), fe(null), Ue(null), Je(null), Fe(null), Qe(null), Ke(null), We(null), je(null), Te(null), rt({
|
|
6838
6840
|
compareEnabled: !1,
|
|
6839
6841
|
rangeCount: 1,
|
|
6840
6842
|
lastPresetB: null,
|
|
6841
6843
|
lastPresetC: null
|
|
6842
6844
|
});
|
|
6843
6845
|
}, [oe, rt]), zn = N((R) => {
|
|
6844
|
-
P.current && (clearTimeout(P.current), P.current = null), A(null), ie && ce === "C" ? (Fe(R), Qe(null), Ke(null)) : ie && ce === "B" ? (
|
|
6846
|
+
P.current && (clearTimeout(P.current), P.current = null), A(null), ie && ce === "C" ? (Fe(R), Qe(null), Ke(null)) : ie && ce === "B" ? (ae(R), Pe(null), ee(null)) : (W(R), K(null), q(null));
|
|
6845
6847
|
}, [ie, ce]), $t = N((R) => {
|
|
6846
|
-
if (!ge.find((
|
|
6847
|
-
const
|
|
6848
|
-
ie && ce === "C" ? (Fe((Ae !== null ? Ae : ve) === R ?
|
|
6848
|
+
if (!ge.find((le) => le.id === R)) return;
|
|
6849
|
+
const X = f.pinnedPreset || "mtd";
|
|
6850
|
+
ie && ce === "C" ? (Fe((Ae !== null ? Ae : ve) === R ? X : R), Qe(null), Ke(null)) : ie && ce === "B" ? (ae((xe !== null ? xe : te) === R ? X : R), Pe(null), ee(null)) : (W((L !== null ? L : D) === R ? X : R), K(null), q(null));
|
|
6849
6851
|
}, [ge, ie, ce, f.pinnedPreset, L, D, xe, te, Ae, ve]), Fn = N((R, $) => {
|
|
6850
6852
|
if (ie && ce === "C")
|
|
6851
6853
|
if (Qe(R), $) {
|
|
6852
6854
|
Ke($);
|
|
6853
|
-
const
|
|
6854
|
-
|
|
6855
|
+
const X = rr(R, $, /* @__PURE__ */ new Date(), ge);
|
|
6856
|
+
X ? (Fe(X.id), Qe(null), Ke(null)) : Fe("custom");
|
|
6855
6857
|
} else
|
|
6856
6858
|
Fe("custom"), Ke(null);
|
|
6857
6859
|
else if (ie && ce === "B")
|
|
6858
6860
|
if (Pe(R), $) {
|
|
6859
6861
|
ee($);
|
|
6860
|
-
const
|
|
6861
|
-
|
|
6862
|
+
const X = rr(R, $, /* @__PURE__ */ new Date(), ge);
|
|
6863
|
+
X ? (ae(X.id), Pe(null), ee(null)) : ae("custom");
|
|
6862
6864
|
} else
|
|
6863
|
-
|
|
6865
|
+
ae("custom"), ee(null);
|
|
6864
6866
|
else if (K(R), $) {
|
|
6865
6867
|
q($);
|
|
6866
|
-
const
|
|
6867
|
-
|
|
6868
|
+
const X = rr(R, $, /* @__PURE__ */ new Date(), ge);
|
|
6869
|
+
X ? (W(X.id), K(null), q(null)) : W("custom");
|
|
6868
6870
|
} else
|
|
6869
6871
|
W("custom"), q(null);
|
|
6870
6872
|
}, [ge, ie, ce]), $n = N((R) => {
|
|
6871
|
-
T(R), rt({ pinnedPreset: R }), ie && ce === "C" ? (Fe(R), Qe(null), Ke(null)) : ie && ce === "B" ? (
|
|
6873
|
+
T(R), rt({ pinnedPreset: R }), ie && ce === "C" ? (Fe(R), Qe(null), Ke(null)) : ie && ce === "B" ? (ae(R), Pe(null), ee(null)) : (W(R), K(null), q(null));
|
|
6872
6874
|
}, [ie, ce, rt]), On = N((R, $) => {
|
|
6873
6875
|
P.current && (clearTimeout(P.current), P.current = null), $ ? A(R) : P.current = setTimeout(() => {
|
|
6874
6876
|
A(null);
|
|
6875
6877
|
}, 150);
|
|
6876
|
-
}, []),
|
|
6878
|
+
}, []), ua = N(() => {
|
|
6877
6879
|
Jt(), W(null), K(null), q(null), g(null);
|
|
6878
6880
|
}, [Jt]), Ln = N(() => {
|
|
6879
6881
|
let R;
|
|
6880
6882
|
if (Be === "custom" && gt)
|
|
6881
6883
|
R = gt;
|
|
6882
6884
|
else {
|
|
6883
|
-
const $ = ge.find((
|
|
6885
|
+
const $ = ge.find((X) => X.id === Be);
|
|
6884
6886
|
$ ? R = $.endDate : R = Xe(Be).end;
|
|
6885
6887
|
}
|
|
6886
6888
|
k("calendar"), Tn(new Date(R));
|
|
@@ -6916,7 +6918,7 @@ const Id = {
|
|
|
6916
6918
|
location: $e.location,
|
|
6917
6919
|
isCustom: !0
|
|
6918
6920
|
};
|
|
6919
|
-
b?.(R), br(($) => [...$.filter((
|
|
6921
|
+
b?.(R), br(($) => [...$.filter((ne) => ne.id !== R.id), { ...R, active: kt(R) }].sort((ne, de) => ne.startDate.getTime() - de.startDate.getTime())), x(null);
|
|
6920
6922
|
}, [C, $e, b]), Vn = N(() => {
|
|
6921
6923
|
if (!C || C.isNew) {
|
|
6922
6924
|
x(null);
|
|
@@ -6925,60 +6927,60 @@ const Id = {
|
|
|
6925
6927
|
C.isCustom && y?.(C.id);
|
|
6926
6928
|
const R = m || tr;
|
|
6927
6929
|
br(($) => {
|
|
6928
|
-
const
|
|
6929
|
-
return
|
|
6930
|
+
const X = $.filter((ne) => ne.id !== C.id), le = R.find((ne) => ne.id === C.id);
|
|
6931
|
+
return le && !C.isCustom ? [...X, { ...le, active: kt(le) }].sort((ne, de) => ne.startDate.getTime() - de.startDate.getTime()) : X;
|
|
6930
6932
|
}), x(null);
|
|
6931
6933
|
}, [C, y, m]), Qt = (R) => Be === R;
|
|
6932
|
-
|
|
6933
|
-
const
|
|
6934
|
+
Sr.some((R) => R.id === Be), Cr.some((R) => R.id === Be), ge.some((R) => R.id === Be);
|
|
6935
|
+
const ma = Q(() => {
|
|
6934
6936
|
const R = { small: 280, medium: 340, large: 400 };
|
|
6935
6937
|
return R[n] || R.medium;
|
|
6936
6938
|
}, [n]), Ct = N((R) => {
|
|
6937
6939
|
if (!R) return "Select...";
|
|
6938
6940
|
if (R === "custom") return "Custom";
|
|
6939
6941
|
if (R === "today") return "Today";
|
|
6940
|
-
const $ =
|
|
6942
|
+
const $ = Sr.find((ne) => ne.id === R);
|
|
6941
6943
|
if ($) return $.label;
|
|
6942
|
-
const
|
|
6943
|
-
if (
|
|
6944
|
-
const
|
|
6945
|
-
return
|
|
6946
|
-
}, [ge]), xr = N((R, $,
|
|
6947
|
-
let
|
|
6948
|
-
if (R === "custom" && $ &&
|
|
6949
|
-
|
|
6944
|
+
const X = Cr.find((ne) => ne.id === R);
|
|
6945
|
+
if (X) return X.label;
|
|
6946
|
+
const le = ge.find((ne) => ne.id === R);
|
|
6947
|
+
return le ? le.label : R;
|
|
6948
|
+
}, [ge]), xr = N((R, $, X) => {
|
|
6949
|
+
let le, ne;
|
|
6950
|
+
if (R === "custom" && $ && X)
|
|
6951
|
+
le = $, ne = X;
|
|
6950
6952
|
else {
|
|
6951
|
-
const
|
|
6952
|
-
if (
|
|
6953
|
-
|
|
6953
|
+
const de = ge.find((Re) => Re.id === R);
|
|
6954
|
+
if (de)
|
|
6955
|
+
le = de.startDate, ne = de.endDate;
|
|
6954
6956
|
else {
|
|
6955
6957
|
const Re = Xe(R || "mtd");
|
|
6956
|
-
|
|
6958
|
+
le = Re.start, ne = Re.end;
|
|
6957
6959
|
}
|
|
6958
6960
|
}
|
|
6959
|
-
return yt(
|
|
6961
|
+
return yt(le, ne, /* @__PURE__ */ new Date());
|
|
6960
6962
|
}, [ge]), Wn = N(() => {
|
|
6961
6963
|
pt((R) => !R);
|
|
6962
6964
|
}, []), jn = N(() => {
|
|
6963
6965
|
const R = L !== null ? L : D;
|
|
6964
|
-
oe(!0), Le(2),
|
|
6965
|
-
}, [L, D, oe]), Nr = N(({ label: R, isActive: $, presetName:
|
|
6966
|
-
const
|
|
6966
|
+
oe(!0), Le(2), ae(R), re("B"), pt(!0);
|
|
6967
|
+
}, [L, D, oe]), Nr = N(({ label: R, isActive: $, presetName: X, dateRange: le, color: ne, onSelect: de, onRemove: Re }) => {
|
|
6968
|
+
const ga = !X || X === "Select...";
|
|
6967
6969
|
return /* @__PURE__ */ c(
|
|
6968
|
-
|
|
6970
|
+
ue,
|
|
6969
6971
|
{
|
|
6970
|
-
className: `range-card range-card--${
|
|
6971
|
-
onClick:
|
|
6972
|
+
className: `range-card range-card--${ne} ${$ ? "range-card--active" : ""} ${ga ? "range-card--empty" : ""}`,
|
|
6973
|
+
onClick: de,
|
|
6972
6974
|
children: [
|
|
6973
|
-
/* @__PURE__ */ e(
|
|
6974
|
-
/* @__PURE__ */ c(
|
|
6975
|
-
/* @__PURE__ */ c(
|
|
6975
|
+
/* @__PURE__ */ e(ue, { className: "range-card__color-bar" }),
|
|
6976
|
+
/* @__PURE__ */ c(ue, { className: "range-card__content", children: [
|
|
6977
|
+
/* @__PURE__ */ c(ue, { className: "range-card__header", children: [
|
|
6976
6978
|
/* @__PURE__ */ e(De, { className: "range-card__label", children: R }),
|
|
6977
|
-
/* @__PURE__ */ e(
|
|
6979
|
+
/* @__PURE__ */ e(ue, { className: `range-card__indicator ${$ ? "range-card__indicator--active" : ""}` })
|
|
6978
6980
|
] }),
|
|
6979
|
-
|
|
6980
|
-
/* @__PURE__ */ e(De, { className: "range-card__preset", children:
|
|
6981
|
-
/* @__PURE__ */ e(De, { className: "range-card__dates", children:
|
|
6981
|
+
ga ? /* @__PURE__ */ e(De, { className: "range-card__preset", sx: { color: "#9ca3af", fontStyle: "italic" }, children: "Select a date range" }) : /* @__PURE__ */ c(Ge, { children: [
|
|
6982
|
+
/* @__PURE__ */ e(De, { className: "range-card__preset", children: X }),
|
|
6983
|
+
/* @__PURE__ */ e(De, { className: "range-card__dates", children: le })
|
|
6982
6984
|
] })
|
|
6983
6985
|
] }),
|
|
6984
6986
|
Re && /* @__PURE__ */ e(
|
|
@@ -6996,7 +6998,7 @@ const Id = {
|
|
|
6996
6998
|
]
|
|
6997
6999
|
}
|
|
6998
7000
|
);
|
|
6999
|
-
}, []),
|
|
7001
|
+
}, []), pa = /* @__PURE__ */ e(ue, { sx: { position: "relative", display: "inline-flex" }, children: /* @__PURE__ */ e(
|
|
7000
7002
|
at,
|
|
7001
7003
|
{
|
|
7002
7004
|
ref: I,
|
|
@@ -7005,7 +7007,7 @@ const Id = {
|
|
|
7005
7007
|
size: "small",
|
|
7006
7008
|
startIcon: /* @__PURE__ */ e(ba, { sx: { fontSize: 14, color: ft ? "white" : "rgba(79, 70, 229, 1)" } }),
|
|
7007
7009
|
endIcon: /* @__PURE__ */ e(
|
|
7008
|
-
|
|
7010
|
+
kr,
|
|
7009
7011
|
{
|
|
7010
7012
|
sx: {
|
|
7011
7013
|
fontSize: 16,
|
|
@@ -7035,30 +7037,30 @@ const Id = {
|
|
|
7035
7037
|
color: "secondary.main"
|
|
7036
7038
|
} : {}
|
|
7037
7039
|
},
|
|
7038
|
-
children: ie && Bn ? /* @__PURE__ */ c(
|
|
7040
|
+
children: ie && Bn ? /* @__PURE__ */ c(ue, { sx: { display: "flex", alignItems: "center", gap: 0.5 }, children: [
|
|
7039
7041
|
/* @__PURE__ */ e(Eo, { sx: { fontSize: 14, color: "secondary.main" } }),
|
|
7040
7042
|
/* @__PURE__ */ e("span", { children: "Compare" })
|
|
7041
7043
|
] }) : Pn
|
|
7042
7044
|
}
|
|
7043
7045
|
) });
|
|
7044
|
-
return /* @__PURE__ */ c(
|
|
7045
|
-
|
|
7046
|
+
return /* @__PURE__ */ c(ue, { className: "hybrid-date-picker", sx: d, children: [
|
|
7047
|
+
sa ? /* @__PURE__ */ e(
|
|
7046
7048
|
xt,
|
|
7047
7049
|
{
|
|
7048
|
-
title:
|
|
7050
|
+
title: sa,
|
|
7049
7051
|
placement: "top-start",
|
|
7050
7052
|
slotProps: {
|
|
7051
7053
|
popper: {
|
|
7052
7054
|
modifiers: [{ name: "offset", options: { offset: [0, -9] } }]
|
|
7053
7055
|
}
|
|
7054
7056
|
},
|
|
7055
|
-
children:
|
|
7057
|
+
children: pa
|
|
7056
7058
|
}
|
|
7057
|
-
) :
|
|
7059
|
+
) : pa,
|
|
7058
7060
|
(() => {
|
|
7059
7061
|
const R = /* @__PURE__ */ c(Ge, { children: [
|
|
7060
7062
|
s && /* @__PURE__ */ c(
|
|
7061
|
-
|
|
7063
|
+
ue,
|
|
7062
7064
|
{
|
|
7063
7065
|
sx: {
|
|
7064
7066
|
display: "flex",
|
|
@@ -7075,7 +7077,7 @@ const Id = {
|
|
|
7075
7077
|
et,
|
|
7076
7078
|
{
|
|
7077
7079
|
size: "small",
|
|
7078
|
-
onClick:
|
|
7080
|
+
onClick: ia,
|
|
7079
7081
|
sx: { p: 0.25 },
|
|
7080
7082
|
title: "Cancel",
|
|
7081
7083
|
children: /* @__PURE__ */ e(It, { sx: { fontSize: 18 } })
|
|
@@ -7084,8 +7086,8 @@ const Id = {
|
|
|
7084
7086
|
]
|
|
7085
7087
|
}
|
|
7086
7088
|
),
|
|
7087
|
-
He && /* @__PURE__ */ e(
|
|
7088
|
-
|
|
7089
|
+
He && /* @__PURE__ */ e(ue, { className: "hybrid-date-picker__active-banner", children: /* @__PURE__ */ c(
|
|
7090
|
+
ue,
|
|
7089
7091
|
{
|
|
7090
7092
|
className: `hybrid-date-picker__active-banner-content ${Qt(He.id) ? "hybrid-date-picker__active-banner-content--selected" : ""}`,
|
|
7091
7093
|
onClick: () => $t(He.id),
|
|
@@ -7095,13 +7097,13 @@ const Id = {
|
|
|
7095
7097
|
}
|
|
7096
7098
|
},
|
|
7097
7099
|
children: [
|
|
7098
|
-
/* @__PURE__ */ c(
|
|
7099
|
-
/* @__PURE__ */ e(
|
|
7100
|
-
/* @__PURE__ */ c(
|
|
7101
|
-
/* @__PURE__ */ c(
|
|
7100
|
+
/* @__PURE__ */ c(ue, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
|
|
7101
|
+
/* @__PURE__ */ e(Ar, { fontSize: "small", sx: { color: "success.main" } }),
|
|
7102
|
+
/* @__PURE__ */ c(ue, { children: [
|
|
7103
|
+
/* @__PURE__ */ c(ue, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
|
|
7102
7104
|
/* @__PURE__ */ e(De, { variant: "body2", fontWeight: 500, children: He.label }),
|
|
7103
7105
|
/* @__PURE__ */ e(
|
|
7104
|
-
|
|
7106
|
+
Wr,
|
|
7105
7107
|
{
|
|
7106
7108
|
label: "Live",
|
|
7107
7109
|
size: "small",
|
|
@@ -7122,7 +7124,7 @@ const Id = {
|
|
|
7122
7124
|
] })
|
|
7123
7125
|
] })
|
|
7124
7126
|
] }),
|
|
7125
|
-
/* @__PURE__ */ c(
|
|
7127
|
+
/* @__PURE__ */ c(ue, { sx: { display: "flex", alignItems: "center", gap: 0.5 }, children: [
|
|
7126
7128
|
Qt(He.id) && /* @__PURE__ */ e(Vt, { fontSize: "small", sx: { color: "success.main" } }),
|
|
7127
7129
|
/* @__PURE__ */ e(
|
|
7128
7130
|
et,
|
|
@@ -7138,7 +7140,7 @@ const Id = {
|
|
|
7138
7140
|
transition: "opacity 200ms",
|
|
7139
7141
|
flexShrink: 0
|
|
7140
7142
|
},
|
|
7141
|
-
children: /* @__PURE__ */ e(
|
|
7143
|
+
children: /* @__PURE__ */ e(jr, { fontSize: "small", sx: { fontSize: 16 } })
|
|
7142
7144
|
}
|
|
7143
7145
|
)
|
|
7144
7146
|
] })
|
|
@@ -7177,9 +7179,9 @@ const Id = {
|
|
|
7177
7179
|
position: "relative"
|
|
7178
7180
|
},
|
|
7179
7181
|
children: [
|
|
7180
|
-
/* @__PURE__ */ e(
|
|
7182
|
+
/* @__PURE__ */ e(Ar, { sx: { fontSize: 16 } }),
|
|
7181
7183
|
He && /* @__PURE__ */ e(
|
|
7182
|
-
|
|
7184
|
+
ue,
|
|
7183
7185
|
{
|
|
7184
7186
|
sx: {
|
|
7185
7187
|
position: "absolute",
|
|
@@ -7199,14 +7201,14 @@ const Id = {
|
|
|
7199
7201
|
] })
|
|
7200
7202
|
}
|
|
7201
7203
|
),
|
|
7202
|
-
/* @__PURE__ */ c(
|
|
7204
|
+
/* @__PURE__ */ c(ue, { className: "hybrid-date-picker__content", children: [
|
|
7203
7205
|
B === "calendar" && (() => {
|
|
7204
|
-
const $ = ie && ce === "C" ? it : ie && ce === "B" ? lt : Be,
|
|
7206
|
+
const $ = ie && ce === "C" ? it : ie && ce === "B" ? lt : Be, X = ie && ce === "C" ? At : ie && ce === "B" ? Bt : Pt, le = ie && ce === "C" ? Rt : ie && ce === "B" ? Mt : gt;
|
|
7205
7207
|
return /* @__PURE__ */ e(
|
|
7206
7208
|
hn,
|
|
7207
7209
|
{
|
|
7208
|
-
selectedStart: $ === "custom" &&
|
|
7209
|
-
selectedEnd: $ === "custom" ?
|
|
7210
|
+
selectedStart: $ === "custom" && X ? X : ge.find((ne) => ne.id === $)?.startDate ?? Xe($ || "mtd").start,
|
|
7211
|
+
selectedEnd: $ === "custom" ? le : ge.find((ne) => ne.id === $)?.endDate ?? Xe($ || "mtd").end,
|
|
7210
7212
|
onSelect: Fn,
|
|
7211
7213
|
marketDates: ge,
|
|
7212
7214
|
size: n,
|
|
@@ -7215,9 +7217,9 @@ const Id = {
|
|
|
7215
7217
|
}
|
|
7216
7218
|
);
|
|
7217
7219
|
})(),
|
|
7218
|
-
B === "markets" && /* @__PURE__ */ c(
|
|
7220
|
+
B === "markets" && /* @__PURE__ */ c(ue, { className: "hybrid-date-picker__markets-list", children: [
|
|
7219
7221
|
/* @__PURE__ */ e(De, { className: "hybrid-date-picker__events-section-header", children: "Market Events" }),
|
|
7220
|
-
|
|
7222
|
+
ra.filter(($) => !He || $.id !== He.id).map(($) => /* @__PURE__ */ e(
|
|
7221
7223
|
Ht,
|
|
7222
7224
|
{
|
|
7223
7225
|
preset: $,
|
|
@@ -7235,7 +7237,7 @@ const Id = {
|
|
|
7235
7237
|
size: "small",
|
|
7236
7238
|
onClick: () => En(!zt),
|
|
7237
7239
|
endIcon: /* @__PURE__ */ e(
|
|
7238
|
-
|
|
7240
|
+
kr,
|
|
7239
7241
|
{
|
|
7240
7242
|
sx: {
|
|
7241
7243
|
transform: zt ? "rotate(180deg)" : "none",
|
|
@@ -7249,7 +7251,7 @@ const Id = {
|
|
|
7249
7251
|
fontSize: 12,
|
|
7250
7252
|
textTransform: "none",
|
|
7251
7253
|
py: 1,
|
|
7252
|
-
mt:
|
|
7254
|
+
mt: ra.length > 0 ? 0.5 : 0,
|
|
7253
7255
|
"&:hover": {
|
|
7254
7256
|
bgcolor: "action.hover"
|
|
7255
7257
|
}
|
|
@@ -7270,7 +7272,7 @@ const Id = {
|
|
|
7270
7272
|
))
|
|
7271
7273
|
] }),
|
|
7272
7274
|
/* @__PURE__ */ e(De, { className: "hybrid-date-picker__events-section-header", children: "Custom Ranges" }),
|
|
7273
|
-
|
|
7275
|
+
aa.length > 0 ? aa.filter(($) => !He || $.id !== He.id).map(($) => /* @__PURE__ */ e(
|
|
7274
7276
|
Ht,
|
|
7275
7277
|
{
|
|
7276
7278
|
preset: $,
|
|
@@ -7288,7 +7290,7 @@ const Id = {
|
|
|
7288
7290
|
children: "No custom ranges saved"
|
|
7289
7291
|
}
|
|
7290
7292
|
),
|
|
7291
|
-
|
|
7293
|
+
na.length > 0 && zt && na.map(($) => /* @__PURE__ */ e(
|
|
7292
7294
|
Ht,
|
|
7293
7295
|
{
|
|
7294
7296
|
preset: $,
|
|
@@ -7299,7 +7301,7 @@ const Id = {
|
|
|
7299
7301
|
},
|
|
7300
7302
|
$.id
|
|
7301
7303
|
)),
|
|
7302
|
-
/* @__PURE__ */ e(
|
|
7304
|
+
/* @__PURE__ */ e(ue, { className: "hybrid-date-picker__markets-list-add", children: /* @__PURE__ */ e(
|
|
7303
7305
|
at,
|
|
7304
7306
|
{
|
|
7305
7307
|
fullWidth: !0,
|
|
@@ -7321,18 +7323,18 @@ const Id = {
|
|
|
7321
7323
|
) })
|
|
7322
7324
|
] })
|
|
7323
7325
|
] }),
|
|
7324
|
-
/* @__PURE__ */ e(
|
|
7326
|
+
/* @__PURE__ */ e(ue, { className: "hybrid-date-picker__footer", children: ie ? (
|
|
7325
7327
|
/* States 2, 3, 4: Comparing - show collapsible drawer */
|
|
7326
|
-
/* @__PURE__ */ c(
|
|
7328
|
+
/* @__PURE__ */ c(ue, { sx: { width: "100%" }, children: [
|
|
7327
7329
|
/* @__PURE__ */ c(
|
|
7328
|
-
|
|
7330
|
+
ue,
|
|
7329
7331
|
{
|
|
7330
7332
|
className: "hybrid-date-picker__footer-drawer-trigger",
|
|
7331
7333
|
onClick: Wn,
|
|
7332
7334
|
children: [
|
|
7333
|
-
/* @__PURE__ */ c(
|
|
7335
|
+
/* @__PURE__ */ c(ue, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: [
|
|
7334
7336
|
/* @__PURE__ */ e(
|
|
7335
|
-
|
|
7337
|
+
kr,
|
|
7336
7338
|
{
|
|
7337
7339
|
className: `hybrid-date-picker__footer-drawer-trigger-icon ${St ? "hybrid-date-picker__footer-drawer-trigger-icon--expanded" : ""}`,
|
|
7338
7340
|
sx: { fontSize: 18, color: "text.secondary" }
|
|
@@ -7341,7 +7343,7 @@ const Id = {
|
|
|
7341
7343
|
/* @__PURE__ */ c(De, { variant: "body2", fontWeight: 500, color: "text.primary", component: "span", sx: { display: "flex", alignItems: "center", gap: 0.25, flexWrap: "nowrap" }, children: [
|
|
7342
7344
|
"Comparing:",
|
|
7343
7345
|
/* @__PURE__ */ c(
|
|
7344
|
-
|
|
7346
|
+
ue,
|
|
7345
7347
|
{
|
|
7346
7348
|
component: "span",
|
|
7347
7349
|
className: "hybrid-date-picker__footer-drawer-range-label",
|
|
@@ -7350,14 +7352,14 @@ const Id = {
|
|
|
7350
7352
|
},
|
|
7351
7353
|
sx: { ml: 0.5 },
|
|
7352
7354
|
children: [
|
|
7353
|
-
/* @__PURE__ */ e(
|
|
7355
|
+
/* @__PURE__ */ e(ue, { component: "span", sx: { color: "#2563EB", fontSize: 10, mr: 0.25, lineHeight: 1 }, children: "●" }),
|
|
7354
7356
|
Ct(Be)
|
|
7355
7357
|
]
|
|
7356
7358
|
}
|
|
7357
7359
|
),
|
|
7358
7360
|
" vs ",
|
|
7359
7361
|
/* @__PURE__ */ c(
|
|
7360
|
-
|
|
7362
|
+
ue,
|
|
7361
7363
|
{
|
|
7362
7364
|
component: "span",
|
|
7363
7365
|
className: "hybrid-date-picker__footer-drawer-range-label",
|
|
@@ -7365,7 +7367,7 @@ const Id = {
|
|
|
7365
7367
|
$.stopPropagation(), pt(!0), re("B");
|
|
7366
7368
|
},
|
|
7367
7369
|
children: [
|
|
7368
|
-
/* @__PURE__ */ e(
|
|
7370
|
+
/* @__PURE__ */ e(ue, { component: "span", sx: { color: "#10B981", fontSize: 10, mr: 0.25, lineHeight: 1 }, children: "●" }),
|
|
7369
7371
|
Ct(lt)
|
|
7370
7372
|
]
|
|
7371
7373
|
}
|
|
@@ -7373,7 +7375,7 @@ const Id = {
|
|
|
7373
7375
|
we === 3 && /* @__PURE__ */ c(Ge, { children: [
|
|
7374
7376
|
" vs ",
|
|
7375
7377
|
/* @__PURE__ */ c(
|
|
7376
|
-
|
|
7378
|
+
ue,
|
|
7377
7379
|
{
|
|
7378
7380
|
component: "span",
|
|
7379
7381
|
className: "hybrid-date-picker__footer-drawer-range-label",
|
|
@@ -7381,7 +7383,7 @@ const Id = {
|
|
|
7381
7383
|
$.stopPropagation(), pt(!0), re("C");
|
|
7382
7384
|
},
|
|
7383
7385
|
children: [
|
|
7384
|
-
/* @__PURE__ */ e(
|
|
7386
|
+
/* @__PURE__ */ e(ue, { component: "span", sx: { color: "#F59E0B", fontSize: 10, mr: 0.25, lineHeight: 1 }, children: "●" }),
|
|
7385
7387
|
Ct(it)
|
|
7386
7388
|
]
|
|
7387
7389
|
}
|
|
@@ -7389,13 +7391,13 @@ const Id = {
|
|
|
7389
7391
|
] })
|
|
7390
7392
|
] })
|
|
7391
7393
|
] }),
|
|
7392
|
-
/* @__PURE__ */ c(
|
|
7394
|
+
/* @__PURE__ */ c(ue, { sx: { display: "flex", alignItems: "center", gap: 0.5 }, children: [
|
|
7393
7395
|
we < 3 && /* @__PURE__ */ e(
|
|
7394
7396
|
et,
|
|
7395
7397
|
{
|
|
7396
7398
|
size: "small",
|
|
7397
7399
|
onClick: ($) => {
|
|
7398
|
-
$.stopPropagation(),
|
|
7400
|
+
$.stopPropagation(), ca();
|
|
7399
7401
|
},
|
|
7400
7402
|
title: "Add range",
|
|
7401
7403
|
sx: { p: 0.5 },
|
|
@@ -7418,7 +7420,7 @@ const Id = {
|
|
|
7418
7420
|
]
|
|
7419
7421
|
}
|
|
7420
7422
|
),
|
|
7421
|
-
/* @__PURE__ */ e(no, { in: St, children: /* @__PURE__ */ c(
|
|
7423
|
+
/* @__PURE__ */ e(no, { in: St, children: /* @__PURE__ */ c(ue, { className: "hybrid-date-picker__footer-drawer-content", children: [
|
|
7422
7424
|
/* @__PURE__ */ e(
|
|
7423
7425
|
Nr,
|
|
7424
7426
|
{
|
|
@@ -7440,7 +7442,7 @@ const Id = {
|
|
|
7440
7442
|
dateRange: xr(lt, Bt, Mt),
|
|
7441
7443
|
color: "green",
|
|
7442
7444
|
onSelect: () => re("B"),
|
|
7443
|
-
onRemove: () =>
|
|
7445
|
+
onRemove: () => da("B")
|
|
7444
7446
|
}
|
|
7445
7447
|
),
|
|
7446
7448
|
we === 3 && /* @__PURE__ */ e(
|
|
@@ -7452,17 +7454,17 @@ const Id = {
|
|
|
7452
7454
|
dateRange: xr(it, At, Rt),
|
|
7453
7455
|
color: "amber",
|
|
7454
7456
|
onSelect: () => re("C"),
|
|
7455
|
-
onRemove: () =>
|
|
7457
|
+
onRemove: () => da("C")
|
|
7456
7458
|
}
|
|
7457
7459
|
),
|
|
7458
|
-
we < 3 && /* @__PURE__ */ e(
|
|
7460
|
+
we < 3 && /* @__PURE__ */ e(ue, { className: "range-card-add", onClick: ca, children: /* @__PURE__ */ e(Lt, { sx: { fontSize: 20, color: "grey.500" } }) })
|
|
7459
7461
|
] }) }),
|
|
7460
|
-
/* @__PURE__ */ e(
|
|
7462
|
+
/* @__PURE__ */ e(ue, { className: "hybrid-date-picker__footer-row", sx: { justifyContent: "flex-end" }, children: /* @__PURE__ */ e(
|
|
7461
7463
|
at,
|
|
7462
7464
|
{
|
|
7463
7465
|
variant: "contained",
|
|
7464
7466
|
size: "small",
|
|
7465
|
-
onClick:
|
|
7467
|
+
onClick: ua,
|
|
7466
7468
|
sx: {
|
|
7467
7469
|
textTransform: "none",
|
|
7468
7470
|
fontWeight: 500,
|
|
@@ -7476,8 +7478,8 @@ const Id = {
|
|
|
7476
7478
|
] })
|
|
7477
7479
|
) : (
|
|
7478
7480
|
/* State 1: No comparison - show Close link or + TimeFrame button */
|
|
7479
|
-
/* @__PURE__ */ c(
|
|
7480
|
-
/* @__PURE__ */ e(
|
|
7481
|
+
/* @__PURE__ */ c(ue, { className: "hybrid-date-picker__footer-row", children: [
|
|
7482
|
+
/* @__PURE__ */ e(ue, { sx: { display: "flex", alignItems: "center", gap: 1 }, children: a ? /* @__PURE__ */ e(xt, { title: "Add a second time frame to compare data across different periods", arrow: !0, children: /* @__PURE__ */ e(
|
|
7481
7483
|
at,
|
|
7482
7484
|
{
|
|
7483
7485
|
size: "small",
|
|
@@ -7499,7 +7501,7 @@ const Id = {
|
|
|
7499
7501
|
{
|
|
7500
7502
|
size: "small",
|
|
7501
7503
|
onClick: () => {
|
|
7502
|
-
i && i(),
|
|
7504
|
+
i && i(), ia();
|
|
7503
7505
|
},
|
|
7504
7506
|
sx: {
|
|
7505
7507
|
textTransform: "none",
|
|
@@ -7516,7 +7518,7 @@ const Id = {
|
|
|
7516
7518
|
children: "Close"
|
|
7517
7519
|
}
|
|
7518
7520
|
) }),
|
|
7519
|
-
/* @__PURE__ */ c(
|
|
7521
|
+
/* @__PURE__ */ c(ue, { sx: { display: "flex", alignItems: "center", gap: 1.5 }, children: [
|
|
7520
7522
|
/* @__PURE__ */ e(
|
|
7521
7523
|
De,
|
|
7522
7524
|
{
|
|
@@ -7539,12 +7541,12 @@ const Id = {
|
|
|
7539
7541
|
},
|
|
7540
7542
|
title: "Click to view in calendar",
|
|
7541
7543
|
children: (() => {
|
|
7542
|
-
const $ =
|
|
7544
|
+
const $ = oa.match(/^(.+?)(\s*\(.+\))$/);
|
|
7543
7545
|
return $ && $[1] && $[1].length > 14 ? /* @__PURE__ */ c(Ge, { children: [
|
|
7544
7546
|
$[1],
|
|
7545
7547
|
/* @__PURE__ */ e("br", {}),
|
|
7546
7548
|
$[2]
|
|
7547
|
-
] }) :
|
|
7549
|
+
] }) : oa;
|
|
7548
7550
|
})()
|
|
7549
7551
|
}
|
|
7550
7552
|
),
|
|
@@ -7553,7 +7555,7 @@ const Id = {
|
|
|
7553
7555
|
{
|
|
7554
7556
|
variant: "contained",
|
|
7555
7557
|
size: "small",
|
|
7556
|
-
onClick:
|
|
7558
|
+
onClick: ua,
|
|
7557
7559
|
sx: {
|
|
7558
7560
|
textTransform: "none",
|
|
7559
7561
|
fontWeight: 500,
|
|
@@ -7569,10 +7571,10 @@ const Id = {
|
|
|
7569
7571
|
) })
|
|
7570
7572
|
] });
|
|
7571
7573
|
return o ? /* @__PURE__ */ e(
|
|
7572
|
-
|
|
7574
|
+
ue,
|
|
7573
7575
|
{
|
|
7574
7576
|
sx: {
|
|
7575
|
-
width:
|
|
7577
|
+
width: ma,
|
|
7576
7578
|
borderRadius: 2,
|
|
7577
7579
|
overflow: "hidden",
|
|
7578
7580
|
mt: 1,
|
|
@@ -7601,7 +7603,7 @@ const Id = {
|
|
|
7601
7603
|
slotProps: {
|
|
7602
7604
|
paper: {
|
|
7603
7605
|
sx: {
|
|
7604
|
-
width:
|
|
7606
|
+
width: ma,
|
|
7605
7607
|
borderRadius: 2,
|
|
7606
7608
|
overflow: "hidden",
|
|
7607
7609
|
mt: 0.5,
|
|
@@ -7626,7 +7628,7 @@ const Id = {
|
|
|
7626
7628
|
/* @__PURE__ */ e(et, { size: "small", onClick: () => x(null), children: /* @__PURE__ */ e(It, { fontSize: "small" }) })
|
|
7627
7629
|
] }),
|
|
7628
7630
|
/* @__PURE__ */ c(io, { sx: { px: 2, py: 1.5 }, children: [
|
|
7629
|
-
/* @__PURE__ */ c(
|
|
7631
|
+
/* @__PURE__ */ c(ue, { className: "market-edit-modal__field", children: [
|
|
7630
7632
|
/* @__PURE__ */ e(De, { variant: "caption", fontWeight: 500, color: "text.secondary", component: "label", children: "Name" }),
|
|
7631
7633
|
/* @__PURE__ */ e(
|
|
7632
7634
|
nr,
|
|
@@ -7640,8 +7642,8 @@ const Id = {
|
|
|
7640
7642
|
}
|
|
7641
7643
|
)
|
|
7642
7644
|
] }),
|
|
7643
|
-
/* @__PURE__ */ c(
|
|
7644
|
-
/* @__PURE__ */ c(
|
|
7645
|
+
/* @__PURE__ */ c(ue, { className: "market-edit-modal__row", sx: { mt: 2 }, children: [
|
|
7646
|
+
/* @__PURE__ */ c(ue, { children: [
|
|
7645
7647
|
/* @__PURE__ */ e(De, { variant: "caption", fontWeight: 500, color: "text.secondary", component: "label", children: "Start Date" }),
|
|
7646
7648
|
/* @__PURE__ */ e(
|
|
7647
7649
|
nr,
|
|
@@ -7655,7 +7657,7 @@ const Id = {
|
|
|
7655
7657
|
}
|
|
7656
7658
|
)
|
|
7657
7659
|
] }),
|
|
7658
|
-
/* @__PURE__ */ c(
|
|
7660
|
+
/* @__PURE__ */ c(ue, { children: [
|
|
7659
7661
|
/* @__PURE__ */ e(De, { variant: "caption", fontWeight: 500, color: "text.secondary", component: "label", children: "End Date" }),
|
|
7660
7662
|
/* @__PURE__ */ e(
|
|
7661
7663
|
nr,
|
|
@@ -7670,7 +7672,7 @@ const Id = {
|
|
|
7670
7672
|
)
|
|
7671
7673
|
] })
|
|
7672
7674
|
] }),
|
|
7673
|
-
/* @__PURE__ */ c(
|
|
7675
|
+
/* @__PURE__ */ c(ue, { className: "market-edit-modal__field", sx: { mt: 2 }, children: [
|
|
7674
7676
|
/* @__PURE__ */ e(De, { variant: "caption", fontWeight: 500, color: "text.secondary", component: "label", children: "Location" }),
|
|
7675
7677
|
/* @__PURE__ */ e(
|
|
7676
7678
|
nr,
|
|
@@ -7686,7 +7688,7 @@ const Id = {
|
|
|
7686
7688
|
] })
|
|
7687
7689
|
] }),
|
|
7688
7690
|
/* @__PURE__ */ c(co, { sx: { px: 2, py: 1.5, justifyContent: "space-between", bgcolor: "grey.50" }, children: [
|
|
7689
|
-
C.isNew ? /* @__PURE__ */ e(
|
|
7691
|
+
C.isNew ? /* @__PURE__ */ e(ue, {}) : /* @__PURE__ */ e(
|
|
7690
7692
|
at,
|
|
7691
7693
|
{
|
|
7692
7694
|
size: "small",
|
|
@@ -7696,7 +7698,7 @@ const Id = {
|
|
|
7696
7698
|
children: "Delete"
|
|
7697
7699
|
}
|
|
7698
7700
|
),
|
|
7699
|
-
/* @__PURE__ */ c(
|
|
7701
|
+
/* @__PURE__ */ c(ue, { sx: { display: "flex", gap: 1 }, children: [
|
|
7700
7702
|
/* @__PURE__ */ e(
|
|
7701
7703
|
at,
|
|
7702
7704
|
{
|
|
@@ -7777,7 +7779,7 @@ const Ma = {
|
|
|
7777
7779
|
] });
|
|
7778
7780
|
};
|
|
7779
7781
|
bn.displayName = "SimpleSelector";
|
|
7780
|
-
const
|
|
7782
|
+
const Br = [
|
|
7781
7783
|
// Today - at the top
|
|
7782
7784
|
{ label: "Today", id: "TODAY", value: () => {
|
|
7783
7785
|
const r = ht("TODAY");
|
|
@@ -7916,7 +7918,7 @@ const Er = [
|
|
|
7916
7918
|
const v = o !== void 0, [_, f] = O(!1), [S, T] = O(!1), [w, I] = O(l ?? !1), M = a?.pinnedPreset || "MTD", [g, B] = O(() => a?.lastPreset?.toUpperCase() || "MTD"), [k, C] = O(null), x = Q(() => lr(r) ? r.rangeA : r, [r]), H = Q(() => lr(r) ? r.rangeB : null, [r]), A = N((W) => {
|
|
7917
7919
|
const F = W || "MTD";
|
|
7918
7920
|
n && a && n({ ...a, pinnedPreset: F.toLowerCase() });
|
|
7919
|
-
const K =
|
|
7921
|
+
const K = Br.find((U) => U.id === F && !U.disabled);
|
|
7920
7922
|
if (K) {
|
|
7921
7923
|
const U = K.value();
|
|
7922
7924
|
if (B(F), w)
|
|
@@ -7934,7 +7936,7 @@ const Er = [
|
|
|
7934
7936
|
}, [l]);
|
|
7935
7937
|
const P = N((W) => {
|
|
7936
7938
|
Promise.resolve().then(() => t(W));
|
|
7937
|
-
}, [t]), D =
|
|
7939
|
+
}, [t]), D = me(!1);
|
|
7938
7940
|
se(() => {
|
|
7939
7941
|
if (v) {
|
|
7940
7942
|
if (!D.current) {
|
|
@@ -7967,7 +7969,7 @@ const Er = [
|
|
|
7967
7969
|
C(F), j(W, F), T(!1);
|
|
7968
7970
|
}, [j]), z = Q(() => ({
|
|
7969
7971
|
shortcuts: {
|
|
7970
|
-
items:
|
|
7972
|
+
items: Br.map((W) => ({
|
|
7971
7973
|
label: W.label,
|
|
7972
7974
|
id: W.id,
|
|
7973
7975
|
getValue: W.value,
|
|
@@ -8007,7 +8009,7 @@ const Er = [
|
|
|
8007
8009
|
}
|
|
8008
8010
|
}), [x, G, Y, v, w, M, A, g, o]), L = Q(() => ({
|
|
8009
8011
|
shortcuts: {
|
|
8010
|
-
items:
|
|
8012
|
+
items: Br.map((W) => ({
|
|
8011
8013
|
label: W.label,
|
|
8012
8014
|
id: W.id,
|
|
8013
8015
|
getValue: W.value,
|
|
@@ -8724,7 +8726,7 @@ const Jd = function(t) {
|
|
|
8724
8726
|
);
|
|
8725
8727
|
};
|
|
8726
8728
|
Jd.displayName = "SimpleMetricCard";
|
|
8727
|
-
const
|
|
8729
|
+
const Mr = ({
|
|
8728
8730
|
type: r,
|
|
8729
8731
|
className: t = ""
|
|
8730
8732
|
}) => {
|
|
@@ -8749,7 +8751,7 @@ const Pr = ({
|
|
|
8749
8751
|
const u = r.map((m) => ({
|
|
8750
8752
|
value: m.id,
|
|
8751
8753
|
label: /* @__PURE__ */ c("div", { className: "payment-method-option", children: [
|
|
8752
|
-
/* @__PURE__ */ e(
|
|
8754
|
+
/* @__PURE__ */ e(Mr, { type: m.type }),
|
|
8753
8755
|
/* @__PURE__ */ c("div", { className: "payment-method-option__details", children: [
|
|
8754
8756
|
/* @__PURE__ */ c("span", { className: "payment-method-option__number", children: [
|
|
8755
8757
|
"**** ",
|
|
@@ -8763,13 +8765,13 @@ const Pr = ({
|
|
|
8763
8765
|
m.isDefault && /* @__PURE__ */ e("span", { className: "payment-method-option__badge", children: "Default" })
|
|
8764
8766
|
] }),
|
|
8765
8767
|
triggerLabel: /* @__PURE__ */ c("div", { className: "payment-method-trigger", children: [
|
|
8766
|
-
/* @__PURE__ */ e(
|
|
8768
|
+
/* @__PURE__ */ e(Mr, { type: m.type }),
|
|
8767
8769
|
/* @__PURE__ */ c("span", { children: [
|
|
8768
8770
|
"**** ",
|
|
8769
8771
|
m.last4
|
|
8770
8772
|
] })
|
|
8771
8773
|
] }),
|
|
8772
|
-
icon: /* @__PURE__ */ e(
|
|
8774
|
+
icon: /* @__PURE__ */ e(Mr, { type: m.type })
|
|
8773
8775
|
}));
|
|
8774
8776
|
s && u.push({
|
|
8775
8777
|
value: "__add_new__",
|
|
@@ -8899,7 +8901,7 @@ const vn = ({
|
|
|
8899
8901
|
className: B,
|
|
8900
8902
|
autoComplete: k
|
|
8901
8903
|
}) => {
|
|
8902
|
-
const C =
|
|
8904
|
+
const C = me(null), [x, H] = O(m ?? ""), [A, P] = O(!1), [D, G] = O(-1), j = me(null), Y = h !== void 0 ? h : x, V = String(Y).length > 0, z = A && o && s.length > 0, L = N(
|
|
8903
8905
|
(J) => {
|
|
8904
8906
|
const pe = J.target.value;
|
|
8905
8907
|
h === void 0 && H(pe), a > 0 ? (j.current && clearTimeout(j.current), j.current = setTimeout(() => {
|
|
@@ -9196,7 +9198,7 @@ const nu = ({
|
|
|
9196
9198
|
id: f,
|
|
9197
9199
|
name: S
|
|
9198
9200
|
}) => {
|
|
9199
|
-
const T = Ve(), w = f || T, I =
|
|
9201
|
+
const T = Ve(), w = f || T, I = me(null), [M, g] = O(a), [B, k] = O(""), [C, x] = O(null), [H, A] = O(!1), [P, D] = O(-1), G = t !== void 0, j = G ? t : M, Y = B ? u.filter(
|
|
9200
9202
|
(re) => re.toLowerCase().includes(B.toLowerCase()) && (i || !j.includes(re))
|
|
9201
9203
|
) : [], V = H && Y.length > 0, z = l === void 0 || j.length < l, L = N(
|
|
9202
9204
|
(re) => {
|
|
@@ -9535,7 +9537,7 @@ const _n = ({
|
|
|
9535
9537
|
d
|
|
9536
9538
|
].filter(Boolean).join(" ");
|
|
9537
9539
|
return /* @__PURE__ */ e("div", { ref: r, className: u, children: /* @__PURE__ */ e(
|
|
9538
|
-
|
|
9540
|
+
Kr,
|
|
9539
9541
|
{
|
|
9540
9542
|
variant: a ? "filled" : "outlined",
|
|
9541
9543
|
color: a ? "primary" : "default",
|
|
@@ -9549,7 +9551,7 @@ const _n = ({
|
|
|
9549
9551
|
) });
|
|
9550
9552
|
};
|
|
9551
9553
|
_n.displayName = "FilterChip";
|
|
9552
|
-
function
|
|
9554
|
+
function Yr({
|
|
9553
9555
|
open: r,
|
|
9554
9556
|
onDismiss: t,
|
|
9555
9557
|
anchorRef: a,
|
|
@@ -9561,7 +9563,7 @@ function jr({
|
|
|
9561
9563
|
bg: E.BgSurface,
|
|
9562
9564
|
shadow: Ze.Hover,
|
|
9563
9565
|
radius: Ce.Md,
|
|
9564
|
-
padding:
|
|
9566
|
+
padding: Z.Md,
|
|
9565
9567
|
zIndex: Va.Popover,
|
|
9566
9568
|
offset: 8,
|
|
9567
9569
|
portal: !0,
|
|
@@ -9582,7 +9584,7 @@ function jr({
|
|
|
9582
9584
|
}
|
|
9583
9585
|
);
|
|
9584
9586
|
}
|
|
9585
|
-
|
|
9587
|
+
Yr.displayName = "PresetPopover";
|
|
9586
9588
|
const iu = (r) => String(r), cu = /* @__PURE__ */ e("div", { className: "gloss-autocomplete__empty", children: "No matches found. Try a different search." });
|
|
9587
9589
|
function du() {
|
|
9588
9590
|
return /* @__PURE__ */ c("div", { className: "gloss-autocomplete__loading", children: [
|
|
@@ -9609,7 +9611,7 @@ function xn(r) {
|
|
|
9609
9611
|
disabled: v = !1,
|
|
9610
9612
|
size: _ = "md",
|
|
9611
9613
|
className: f
|
|
9612
|
-
} = r, [S, T] = O(""), [w, I] = O(!1), [M, g] = O(-1), B =
|
|
9614
|
+
} = r, [S, T] = O(""), [w, I] = O(!1), [M, g] = O(-1), B = me(null), k = me(null), C = me(null);
|
|
9613
9615
|
se(() => {
|
|
9614
9616
|
a != null && T(s(a));
|
|
9615
9617
|
}, [a, s]);
|
|
@@ -9691,7 +9693,7 @@ function xn(r) {
|
|
|
9691
9693
|
}
|
|
9692
9694
|
),
|
|
9693
9695
|
/* @__PURE__ */ e(
|
|
9694
|
-
|
|
9696
|
+
Yr,
|
|
9695
9697
|
{
|
|
9696
9698
|
open: j && !v,
|
|
9697
9699
|
onDismiss: G,
|
|
@@ -9748,7 +9750,7 @@ function Nn(r) {
|
|
|
9748
9750
|
maxSelected: y,
|
|
9749
9751
|
searchable: v = !1,
|
|
9750
9752
|
className: _
|
|
9751
|
-
} = r, [f, S] = O(!1), [T, w] = O(""), [I, M] = O(-1), g =
|
|
9753
|
+
} = r, [f, S] = O(!1), [T, w] = O(""), [I, M] = O(-1), g = me(null), B = me(null), k = me(null), C = Q(
|
|
9752
9754
|
() => t.filter((z) => a.includes(z.value)),
|
|
9753
9755
|
[t, a]
|
|
9754
9756
|
), x = Q(() => {
|
|
@@ -9833,7 +9835,7 @@ function Nn(r) {
|
|
|
9833
9835
|
"aria-disabled": p || void 0,
|
|
9834
9836
|
children: [
|
|
9835
9837
|
C.map((z) => /* @__PURE__ */ e("span", { className: "gloss-multi-select__tag", children: s ? s(z, () => P(z.value)) : /* @__PURE__ */ e(
|
|
9836
|
-
|
|
9838
|
+
Kr,
|
|
9837
9839
|
{
|
|
9838
9840
|
size: b === "lg" ? "md" : "sm",
|
|
9839
9841
|
variant: "outlined",
|
|
@@ -9877,7 +9879,7 @@ function Nn(r) {
|
|
|
9877
9879
|
}
|
|
9878
9880
|
),
|
|
9879
9881
|
/* @__PURE__ */ e(
|
|
9880
|
-
|
|
9882
|
+
Yr,
|
|
9881
9883
|
{
|
|
9882
9884
|
open: f && !p,
|
|
9883
9885
|
onDismiss: j,
|
|
@@ -9971,7 +9973,7 @@ function gu() {
|
|
|
9971
9973
|
}
|
|
9972
9974
|
);
|
|
9973
9975
|
}
|
|
9974
|
-
function
|
|
9976
|
+
function Ur(r) {
|
|
9975
9977
|
const {
|
|
9976
9978
|
size: t = "md",
|
|
9977
9979
|
shape: a = "circle",
|
|
@@ -10003,10 +10005,10 @@ function Kr(r) {
|
|
|
10003
10005
|
}
|
|
10004
10006
|
);
|
|
10005
10007
|
}
|
|
10006
|
-
|
|
10008
|
+
Ur.displayName = "PresetAvatar";
|
|
10007
10009
|
function fu(r, t) {
|
|
10008
10010
|
return /* @__PURE__ */ c("div", { className: `gloss-entity-picker__result ${t ? "gloss-entity-picker__result--highlighted" : ""}`, children: [
|
|
10009
|
-
r.avatarUrl ? /* @__PURE__ */ e("div", { className: "gloss-entity-picker__result-avatar", children: /* @__PURE__ */ e(
|
|
10011
|
+
r.avatarUrl ? /* @__PURE__ */ e("div", { className: "gloss-entity-picker__result-avatar", children: /* @__PURE__ */ e(Ur, { src: r.avatarUrl, alt: r.label, size: "sm" }) }) : r.icon ? /* @__PURE__ */ e("div", { className: "gloss-entity-picker__result-icon", children: /* @__PURE__ */ e(qe, { name: r.icon, definition: { size: "sm" } }) }) : null,
|
|
10010
10012
|
/* @__PURE__ */ c("div", { className: "gloss-entity-picker__result-info", children: [
|
|
10011
10013
|
/* @__PURE__ */ e("span", { className: "gloss-entity-picker__result-label", children: r.label }),
|
|
10012
10014
|
r.description && /* @__PURE__ */ e("span", { className: "gloss-entity-picker__result-description", children: r.description })
|
|
@@ -10048,7 +10050,7 @@ function bu({
|
|
|
10048
10050
|
) });
|
|
10049
10051
|
}
|
|
10050
10052
|
bu.displayName = "EntityPicker";
|
|
10051
|
-
function
|
|
10053
|
+
function Xr(r) {
|
|
10052
10054
|
const {
|
|
10053
10055
|
columns: t,
|
|
10054
10056
|
data: a,
|
|
@@ -10236,7 +10238,7 @@ function Yr(r) {
|
|
|
10236
10238
|
] })
|
|
10237
10239
|
] });
|
|
10238
10240
|
}
|
|
10239
|
-
|
|
10241
|
+
Xr.displayName = "DataTable";
|
|
10240
10242
|
const yu = [
|
|
10241
10243
|
{ value: "count", label: "Count" },
|
|
10242
10244
|
{ value: "total", label: "Total" },
|
|
@@ -10316,7 +10318,7 @@ const _u = {
|
|
|
10316
10318
|
padding: "0",
|
|
10317
10319
|
zIndex: Va.Modal
|
|
10318
10320
|
};
|
|
10319
|
-
function
|
|
10321
|
+
function Zr({ open: r, onDismiss: t, size: a = "md", children: n }) {
|
|
10320
10322
|
const s = _u[a];
|
|
10321
10323
|
return /* @__PURE__ */ c(Ge, { children: [
|
|
10322
10324
|
r && /* @__PURE__ */ e("div", { className: "gloss-container-dialog__backdrop", "data-density": "default" }),
|
|
@@ -10333,8 +10335,8 @@ function Ur({ open: r, onDismiss: t, size: a = "md", children: n }) {
|
|
|
10333
10335
|
)
|
|
10334
10336
|
] });
|
|
10335
10337
|
}
|
|
10336
|
-
|
|
10337
|
-
const
|
|
10338
|
+
Zr.displayName = "ContainerDialog";
|
|
10339
|
+
const qr = ({
|
|
10338
10340
|
ref: r,
|
|
10339
10341
|
children: t,
|
|
10340
10342
|
...a
|
|
@@ -10342,8 +10344,8 @@ const Xr = ({
|
|
|
10342
10344
|
const n = { ...a };
|
|
10343
10345
|
return delete n.className, delete n.style, /* @__PURE__ */ e("div", { ref: r, className: "gloss-container-dialog__header", ...n, children: /* @__PURE__ */ e(Nt, { region: "dialog-header", children: t }) });
|
|
10344
10346
|
};
|
|
10345
|
-
|
|
10346
|
-
const
|
|
10347
|
+
qr.displayName = "ContainerDialogHeader";
|
|
10348
|
+
const Jr = ({
|
|
10347
10349
|
ref: r,
|
|
10348
10350
|
children: t,
|
|
10349
10351
|
...a
|
|
@@ -10351,8 +10353,8 @@ const Zr = ({
|
|
|
10351
10353
|
const n = { ...a };
|
|
10352
10354
|
return delete n.className, delete n.style, /* @__PURE__ */ e("div", { ref: r, className: "gloss-container-dialog__body", ...n, children: /* @__PURE__ */ e(Nt, { region: "dialog-body", children: t }) });
|
|
10353
10355
|
};
|
|
10354
|
-
|
|
10355
|
-
const
|
|
10356
|
+
Jr.displayName = "ContainerDialogBody";
|
|
10357
|
+
const Qr = ({
|
|
10356
10358
|
ref: r,
|
|
10357
10359
|
children: t,
|
|
10358
10360
|
...a
|
|
@@ -10360,7 +10362,7 @@ const qr = ({
|
|
|
10360
10362
|
const n = { ...a };
|
|
10361
10363
|
return delete n.className, delete n.style, /* @__PURE__ */ e("div", { ref: r, className: "gloss-container-dialog__actions", ...n, children: /* @__PURE__ */ e(Nt, { region: "dialog-actions", children: t }) });
|
|
10362
10364
|
};
|
|
10363
|
-
|
|
10365
|
+
Qr.displayName = "ContainerDialogActions";
|
|
10364
10366
|
function Nu(r) {
|
|
10365
10367
|
const {
|
|
10366
10368
|
open: t,
|
|
@@ -10377,10 +10379,10 @@ function Nu(r) {
|
|
|
10377
10379
|
footerSlot: p,
|
|
10378
10380
|
className: b
|
|
10379
10381
|
} = r, y = s ?? a, v = ["gloss-form-dialog", b].filter(Boolean).join(" ");
|
|
10380
|
-
return /* @__PURE__ */ e(
|
|
10381
|
-
/* @__PURE__ */ e(
|
|
10382
|
-
/* @__PURE__ */ e(
|
|
10383
|
-
/* @__PURE__ */ e(
|
|
10382
|
+
return /* @__PURE__ */ e(Zr, { open: t, onDismiss: a, size: u, children: /* @__PURE__ */ c("div", { className: v, children: [
|
|
10383
|
+
/* @__PURE__ */ e(qr, { children: /* @__PURE__ */ e("h2", { style: { margin: 0 }, children: l }) }),
|
|
10384
|
+
/* @__PURE__ */ e(Jr, { children: m }),
|
|
10385
|
+
/* @__PURE__ */ e(Qr, { children: p || /* @__PURE__ */ c("div", { className: "gloss-form-dialog__actions", children: [
|
|
10384
10386
|
/* @__PURE__ */ e(
|
|
10385
10387
|
ke,
|
|
10386
10388
|
{
|
|
@@ -10899,7 +10901,7 @@ const wu = [
|
|
|
10899
10901
|
{ value: "WV", label: "West Virginia" },
|
|
10900
10902
|
{ value: "WI", label: "Wisconsin" },
|
|
10901
10903
|
{ value: "WY", label: "Wyoming" }
|
|
10902
|
-
],
|
|
10904
|
+
], Hr = he.object({
|
|
10903
10905
|
street: he.string().min(1, "Street address is required"),
|
|
10904
10906
|
street2: he.string().optional(),
|
|
10905
10907
|
city: he.string().min(1, "City is required"),
|
|
@@ -10978,7 +10980,7 @@ function Du({
|
|
|
10978
10980
|
);
|
|
10979
10981
|
Zn(m, () => ({
|
|
10980
10982
|
validate: () => {
|
|
10981
|
-
const g =
|
|
10983
|
+
const g = Hr.safeParse(p);
|
|
10982
10984
|
if (g.success)
|
|
10983
10985
|
return { success: !0, errors: {} };
|
|
10984
10986
|
const B = {};
|
|
@@ -10999,7 +11001,7 @@ function Du({
|
|
|
10999
11001
|
return;
|
|
11000
11002
|
}
|
|
11001
11003
|
try {
|
|
11002
|
-
|
|
11004
|
+
Hr.shape[g].parse(B), f((C) => ({ ...C, [g]: void 0 }));
|
|
11003
11005
|
} catch (k) {
|
|
11004
11006
|
k instanceof he.ZodError && f((C) => ({ ...C, [g]: k.issues[0]?.message }));
|
|
11005
11007
|
}
|
|
@@ -11868,7 +11870,7 @@ function lp({
|
|
|
11868
11870
|
const Tu = he.object({
|
|
11869
11871
|
paymentMethod: he.enum(["credit_card", "debit_card", "bank_transfer"]),
|
|
11870
11872
|
card: gr.optional(),
|
|
11871
|
-
billingAddress:
|
|
11873
|
+
billingAddress: Hr,
|
|
11872
11874
|
savePaymentMethod: he.boolean().optional()
|
|
11873
11875
|
}).refine(
|
|
11874
11876
|
(r) => r.paymentMethod === "credit_card" || r.paymentMethod === "debit_card" ? r.card !== void 0 : !0,
|
|
@@ -11937,7 +11939,7 @@ function cp({
|
|
|
11937
11939
|
cardholderName: s.card?.cardholderName ?? ""
|
|
11938
11940
|
}), [y, v] = O({}), [_, f] = O({}), [S, T] = O(
|
|
11939
11941
|
s.savePaymentMethod ?? !1
|
|
11940
|
-
), [w, I] = O(), M =
|
|
11942
|
+
), [w, I] = O(), M = me(null), g = h === "credit_card" || h === "debit_card", B = N((A, P) => {
|
|
11941
11943
|
try {
|
|
11942
11944
|
gr.shape[A].parse(P), v((G) => ({ ...G, [A]: void 0 }));
|
|
11943
11945
|
} catch (D) {
|
|
@@ -12216,8 +12218,8 @@ function up({
|
|
|
12216
12218
|
const v = N(async () => {
|
|
12217
12219
|
i && b !== d || await a();
|
|
12218
12220
|
}, [i, b, d, a]), _ = !i || b === d, f = m ? `${s} This will permanently delete "${m}".` : s;
|
|
12219
|
-
return /* @__PURE__ */ c(
|
|
12220
|
-
/* @__PURE__ */ e(
|
|
12221
|
+
return /* @__PURE__ */ c(Zr, { open: r, onDismiss: h ? void 0 : t, size: "sm", children: [
|
|
12222
|
+
/* @__PURE__ */ e(qr, { children: /* @__PURE__ */ c("div", { className: "gloss-pattern-destructive-modal__header-content", children: [
|
|
12221
12223
|
/* @__PURE__ */ e(
|
|
12222
12224
|
qe,
|
|
12223
12225
|
{
|
|
@@ -12228,7 +12230,7 @@ function up({
|
|
|
12228
12230
|
),
|
|
12229
12231
|
/* @__PURE__ */ e("h2", { className: "gloss-pattern-destructive-modal__title", children: n })
|
|
12230
12232
|
] }) }),
|
|
12231
|
-
/* @__PURE__ */ c(
|
|
12233
|
+
/* @__PURE__ */ c(Jr, { children: [
|
|
12232
12234
|
/* @__PURE__ */ e("p", { className: "gloss-pattern-destructive-modal__description", children: f }),
|
|
12233
12235
|
i && /* @__PURE__ */ c("div", { className: "gloss-pattern-destructive-modal__confirmation", children: [
|
|
12234
12236
|
/* @__PURE__ */ c("label", { className: "gloss-pattern-destructive-modal__label", children: [
|
|
@@ -12248,7 +12250,7 @@ function up({
|
|
|
12248
12250
|
)
|
|
12249
12251
|
] })
|
|
12250
12252
|
] }),
|
|
12251
|
-
/* @__PURE__ */ c(
|
|
12253
|
+
/* @__PURE__ */ c(Qr, { children: [
|
|
12252
12254
|
/* @__PURE__ */ e(ke, { variant: "ghost", onClick: t, disabled: h, children: o }),
|
|
12253
12255
|
/* @__PURE__ */ e(
|
|
12254
12256
|
ke,
|
|
@@ -12304,7 +12306,7 @@ function Eu(r) {
|
|
|
12304
12306
|
_.key
|
|
12305
12307
|
)) }),
|
|
12306
12308
|
/* @__PURE__ */ e(
|
|
12307
|
-
|
|
12309
|
+
Xr,
|
|
12308
12310
|
{
|
|
12309
12311
|
columns: o,
|
|
12310
12312
|
data: l,
|
|
@@ -12334,7 +12336,7 @@ function Pu(r) {
|
|
|
12334
12336
|
} = r, d = ["gloss-profile-card", i].filter(Boolean).join(" ");
|
|
12335
12337
|
return /* @__PURE__ */ e("div", { className: d, children: /* @__PURE__ */ e(sn, { variant: "outlined", children: /* @__PURE__ */ c("div", { className: "gloss-profile-card__content", children: [
|
|
12336
12338
|
/* @__PURE__ */ e(
|
|
12337
|
-
|
|
12339
|
+
Ur,
|
|
12338
12340
|
{
|
|
12339
12341
|
size: "xl",
|
|
12340
12342
|
src: n,
|
|
@@ -12458,7 +12460,7 @@ function kn(r) {
|
|
|
12458
12460
|
return o === "top" ? /* @__PURE__ */ c("div", { className: m, children: [
|
|
12459
12461
|
/* @__PURE__ */ e("div", { className: "gloss-preset-progress-bar__header", children: b }),
|
|
12460
12462
|
/* @__PURE__ */ e(
|
|
12461
|
-
|
|
12463
|
+
fa,
|
|
12462
12464
|
{
|
|
12463
12465
|
definition: u,
|
|
12464
12466
|
value: a,
|
|
@@ -12469,7 +12471,7 @@ function kn(r) {
|
|
|
12469
12471
|
)
|
|
12470
12472
|
] }) : /* @__PURE__ */ c("div", { className: m, children: [
|
|
12471
12473
|
/* @__PURE__ */ e(
|
|
12472
|
-
|
|
12474
|
+
fa,
|
|
12473
12475
|
{
|
|
12474
12476
|
definition: u,
|
|
12475
12477
|
value: a,
|
|
@@ -12534,7 +12536,7 @@ function Ru(r) {
|
|
|
12534
12536
|
) });
|
|
12535
12537
|
case 1:
|
|
12536
12538
|
return /* @__PURE__ */ e("div", { className: "gloss-import-wizard__preview", children: n.length > 0 && s ? /* @__PURE__ */ e(
|
|
12537
|
-
|
|
12539
|
+
Xr,
|
|
12538
12540
|
{
|
|
12539
12541
|
columns: n,
|
|
12540
12542
|
data: b,
|
|
@@ -12693,7 +12695,7 @@ const Ou = ({
|
|
|
12693
12695
|
disabled: l = !1,
|
|
12694
12696
|
children: o
|
|
12695
12697
|
}) => {
|
|
12696
|
-
const i = _e.Children.only(o), d =
|
|
12698
|
+
const i = _e.Children.only(o), d = me(null);
|
|
12697
12699
|
se(() => {
|
|
12698
12700
|
if (l || !a || !t) return;
|
|
12699
12701
|
const m = (p) => {
|
|
@@ -12746,10 +12748,10 @@ const Ou = ({
|
|
|
12746
12748
|
] }) : h;
|
|
12747
12749
|
};
|
|
12748
12750
|
Ou.displayName = "Dismissible";
|
|
12749
|
-
let
|
|
12751
|
+
let ea = null, wn = null;
|
|
12750
12752
|
try {
|
|
12751
12753
|
const r = require("@dnd-kit/sortable");
|
|
12752
|
-
|
|
12754
|
+
ea = r.useSortable || r.default && r.default.useSortable, wn = (r.CSS || r.default && r.default.CSS)?.Transform?.toString ?? null;
|
|
12753
12755
|
} catch {
|
|
12754
12756
|
}
|
|
12755
12757
|
const Lu = ({
|
|
@@ -12759,7 +12761,7 @@ const Lu = ({
|
|
|
12759
12761
|
children: n
|
|
12760
12762
|
}) => {
|
|
12761
12763
|
const s = _e.Children.only(n);
|
|
12762
|
-
return
|
|
12764
|
+
return ea ? /* @__PURE__ */ e(Dn, { id: t, disabled: a, outerRef: r ?? null, children: s }) : _e.cloneElement(s, {
|
|
12763
12765
|
ref: Xt(r, s.ref)
|
|
12764
12766
|
});
|
|
12765
12767
|
};
|
|
@@ -12772,7 +12774,7 @@ function Dn({ id: r, disabled: t, outerRef: a, children: n }) {
|
|
|
12772
12774
|
transform: i,
|
|
12773
12775
|
transition: d,
|
|
12774
12776
|
isDragging: u
|
|
12775
|
-
} =
|
|
12777
|
+
} = ea({ id: String(r) }), h = {
|
|
12776
12778
|
transform: wn?.(i) ?? void 0,
|
|
12777
12779
|
transition: d ?? void 0,
|
|
12778
12780
|
opacity: u ? 0.5 : void 0,
|
|
@@ -12790,10 +12792,10 @@ function Dn({ id: r, disabled: t, outerRef: a, children: n }) {
|
|
|
12790
12792
|
});
|
|
12791
12793
|
}
|
|
12792
12794
|
Dn.displayName = "SortableInner";
|
|
12793
|
-
let
|
|
12795
|
+
let Gr = null, Vr = null;
|
|
12794
12796
|
try {
|
|
12795
12797
|
const r = require("motion/react");
|
|
12796
|
-
|
|
12798
|
+
Gr = r.motion?.div ?? null, Vr = r.AnimatePresence ?? null;
|
|
12797
12799
|
} catch {
|
|
12798
12800
|
}
|
|
12799
12801
|
const Hu = ({
|
|
@@ -12809,7 +12811,7 @@ const Hu = ({
|
|
|
12809
12811
|
}, i = a ? _e.isValidElement(a) ? _e.cloneElement(a, {
|
|
12810
12812
|
onClick: o,
|
|
12811
12813
|
"aria-expanded": t
|
|
12812
|
-
}) : a : null, d =
|
|
12814
|
+
}) : a : null, d = Gr && Vr ? /* @__PURE__ */ e(Vr, { children: t && _e.createElement(Gr, {
|
|
12813
12815
|
key: "expandable-content",
|
|
12814
12816
|
initial: { height: 0, opacity: 0, overflow: "hidden" },
|
|
12815
12817
|
animate: { height: "auto", opacity: 1, overflow: "visible" },
|
|
@@ -12842,7 +12844,7 @@ export {
|
|
|
12842
12844
|
Wi as L,
|
|
12843
12845
|
Bi as M,
|
|
12844
12846
|
on as N,
|
|
12845
|
-
|
|
12847
|
+
Kr as O,
|
|
12846
12848
|
ke as P,
|
|
12847
12849
|
tc as Q,
|
|
12848
12850
|
Dl as R,
|
|
@@ -12869,7 +12871,7 @@ export {
|
|
|
12869
12871
|
Wd as a9,
|
|
12870
12872
|
Cn as aA,
|
|
12871
12873
|
tp as aB,
|
|
12872
|
-
|
|
12874
|
+
Hr as aC,
|
|
12873
12875
|
ap as aD,
|
|
12874
12876
|
rp as aE,
|
|
12875
12877
|
gr as aF,
|
|
@@ -12889,11 +12891,11 @@ export {
|
|
|
12889
12891
|
Bu as aT,
|
|
12890
12892
|
Ru as aU,
|
|
12891
12893
|
en as aV,
|
|
12892
|
-
|
|
12893
|
-
|
|
12894
|
-
|
|
12895
|
-
|
|
12896
|
-
|
|
12894
|
+
Tr as aW,
|
|
12895
|
+
Zr as aX,
|
|
12896
|
+
qr as aY,
|
|
12897
|
+
Jr as aZ,
|
|
12898
|
+
Qr as a_,
|
|
12897
12899
|
jd as aa,
|
|
12898
12900
|
Kd as ab,
|
|
12899
12901
|
Yd as ac,
|
|
@@ -12912,7 +12914,7 @@ export {
|
|
|
12912
12914
|
xn as ap,
|
|
12913
12915
|
Nn as aq,
|
|
12914
12916
|
bu as ar,
|
|
12915
|
-
|
|
12917
|
+
Xr as as,
|
|
12916
12918
|
Nu as at,
|
|
12917
12919
|
ku as au,
|
|
12918
12920
|
vu as av,
|
|
@@ -12937,9 +12939,9 @@ export {
|
|
|
12937
12939
|
Km as bD,
|
|
12938
12940
|
Wc as bE,
|
|
12939
12941
|
Gt as bF,
|
|
12940
|
-
|
|
12942
|
+
Ur as bG,
|
|
12941
12943
|
kn as bH,
|
|
12942
|
-
|
|
12944
|
+
Yr as bI,
|
|
12943
12945
|
_c as ba,
|
|
12944
12946
|
xc as bb,
|
|
12945
12947
|
mn as bc,
|
|
@@ -12953,8 +12955,8 @@ export {
|
|
|
12953
12955
|
yd as bk,
|
|
12954
12956
|
gn as bl,
|
|
12955
12957
|
fn as bm,
|
|
12956
|
-
|
|
12957
|
-
|
|
12958
|
+
Lr as bn,
|
|
12959
|
+
Or as bo,
|
|
12958
12960
|
bd as bp,
|
|
12959
12961
|
Cd as bq,
|
|
12960
12962
|
_d as br,
|