@mt-gloss/ui 0.1.119 → 0.1.121
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/{COMMITS-BkM1Urzh.js → COMMITS-8eHelQHO.js} +114 -101
- package/composites-panels.js +294 -332
- package/index.js +3 -3
- package/package.json +1 -1
- package/ui.css +1 -1
package/composites-panels.js
CHANGED
|
@@ -1,22 +1,22 @@
|
|
|
1
|
-
import { u as
|
|
2
|
-
import { C as
|
|
3
|
-
import { jsx as n, jsxs as f, Fragment as
|
|
4
|
-
import
|
|
1
|
+
import { u as O, h as fe, j as V, g as we, S as Ee, b as Pe, k as xe } from "./COMMITS-8eHelQHO.js";
|
|
2
|
+
import { C as Ut, N as zt, o as Ht, d as Vt, p as Bt, l as Kt, c as Yt, n as Wt, P as Gt, m as Qt, f as qt, i as jt, r as Zt, e as Xt } from "./COMMITS-8eHelQHO.js";
|
|
3
|
+
import { jsx as n, jsxs as f, Fragment as B } from "react/jsx-runtime";
|
|
4
|
+
import U, { useState as x, useRef as K, createContext as ge, useContext as be, useMemo as ie, useEffect as R, useCallback as L, useLayoutEffect as Ae } from "react";
|
|
5
5
|
import { useSensors as ke, useSensor as ce, PointerSensor as De, KeyboardSensor as Le, DndContext as Oe, closestCenter as Me } from "@dnd-kit/core";
|
|
6
6
|
import { sortableKeyboardCoordinates as Ie, SortableContext as $e, horizontalListSortingStrategy as Re, arrayMove as Fe, useSortable as Ue } from "@dnd-kit/sortable";
|
|
7
7
|
import { CSS as ze } from "@dnd-kit/utilities";
|
|
8
8
|
import { M as de } from "./MetricCard-Cyoxhb_S.js";
|
|
9
|
-
function
|
|
10
|
-
const e =
|
|
9
|
+
function wt() {
|
|
10
|
+
const e = O();
|
|
11
11
|
if (e?.state.activePanelId !== "settings") return null;
|
|
12
12
|
const t = e.state.activeTrigger;
|
|
13
13
|
return t?.kind === "card-overflow" ? t.cardId : null;
|
|
14
14
|
}
|
|
15
15
|
function He({ span: e, rotating: t = !0, children: r }) {
|
|
16
|
-
const
|
|
17
|
-
return /* @__PURE__ */ n("div", { className:
|
|
16
|
+
const l = ["clone-card", `span-${e}`, t ? "rotating" : ""].filter(Boolean).join(" "), a = r != null ? "full" : "fallback";
|
|
17
|
+
return /* @__PURE__ */ n("div", { className: l, "data-clone-fidelity": a, children: r });
|
|
18
18
|
}
|
|
19
|
-
function
|
|
19
|
+
function Et({ primary: e, secondary: t }) {
|
|
20
20
|
return /* @__PURE__ */ f("div", { className: "gloss-panel-chrome-v2__footer-msg", children: [
|
|
21
21
|
/* @__PURE__ */ n("span", { className: "gloss-panel-chrome-v2__footer-msg-primary", children: e }),
|
|
22
22
|
t != null && /* @__PURE__ */ n("span", { className: "gloss-panel-chrome-v2__footer-msg-secondary", children: t })
|
|
@@ -26,7 +26,7 @@ function Ve({
|
|
|
26
26
|
value: e,
|
|
27
27
|
onChange: t,
|
|
28
28
|
enabled: r = !1,
|
|
29
|
-
onToggleEnabled:
|
|
29
|
+
onToggleEnabled: l
|
|
30
30
|
}) {
|
|
31
31
|
const a = "settings-threshold-enabled";
|
|
32
32
|
return /* @__PURE__ */ f("div", { className: "settings-shell__field settings-shell__field--threshold", children: [
|
|
@@ -41,12 +41,12 @@ function Ve({
|
|
|
41
41
|
"aria-label": "Enable threshold indicator",
|
|
42
42
|
"aria-checked": r,
|
|
43
43
|
checked: r,
|
|
44
|
-
onChange: (i) =>
|
|
44
|
+
onChange: (i) => l?.(i.target.checked),
|
|
45
45
|
className: "settings-shell__toggle"
|
|
46
46
|
}
|
|
47
47
|
)
|
|
48
48
|
] }),
|
|
49
|
-
r ? /* @__PURE__ */ f(
|
|
49
|
+
r ? /* @__PURE__ */ f(B, { children: [
|
|
50
50
|
/* @__PURE__ */ n("span", { className: "settings-shell__label", "aria-hidden": "true", children: "Alert level (%)" }),
|
|
51
51
|
/* @__PURE__ */ f("div", { className: "settings-shell__slider-row", children: [
|
|
52
52
|
/* @__PURE__ */ n(
|
|
@@ -101,17 +101,17 @@ function Be({ value: e, onChange: t }) {
|
|
|
101
101
|
] });
|
|
102
102
|
}
|
|
103
103
|
function Ke({ id: e, onRemove: t }) {
|
|
104
|
-
const { attributes: r, listeners:
|
|
104
|
+
const { attributes: r, listeners: l, setNodeRef: a, transform: i, transition: u, isDragging: o } = Ue({ id: e }), s = {
|
|
105
105
|
transform: ze.Transform.toString(i),
|
|
106
106
|
transition: u,
|
|
107
|
-
opacity:
|
|
107
|
+
opacity: o ? 0.6 : 1
|
|
108
108
|
};
|
|
109
109
|
return /* @__PURE__ */ f(
|
|
110
110
|
"li",
|
|
111
111
|
{
|
|
112
112
|
ref: a,
|
|
113
113
|
style: s,
|
|
114
|
-
className: `settings-shell__slot-pill${
|
|
114
|
+
className: `settings-shell__slot-pill${o ? " settings-shell__slot-pill--dragging" : ""}`,
|
|
115
115
|
children: [
|
|
116
116
|
/* @__PURE__ */ n(
|
|
117
117
|
"button",
|
|
@@ -120,7 +120,7 @@ function Ke({ id: e, onRemove: t }) {
|
|
|
120
120
|
className: "settings-shell__slot-pill__handle",
|
|
121
121
|
"aria-label": `Reorder ${e}`,
|
|
122
122
|
...r,
|
|
123
|
-
...
|
|
123
|
+
...l,
|
|
124
124
|
children: /* @__PURE__ */ n("span", { "aria-hidden": "true", className: "settings-shell__slot-pill__grip", children: "⋮⋮" })
|
|
125
125
|
}
|
|
126
126
|
),
|
|
@@ -143,17 +143,16 @@ function Ye({ value: e, onChange: t }) {
|
|
|
143
143
|
const r = ke(
|
|
144
144
|
ce(De, { activationConstraint: { distance: 4 } }),
|
|
145
145
|
ce(Le, { coordinateGetter: Ie })
|
|
146
|
-
),
|
|
146
|
+
), l = U.useRef(!1), [a, i] = U.useState(!1), u = (s) => {
|
|
147
147
|
const { active: c, over: d } = s;
|
|
148
148
|
if (!d || c.id === d.id) return;
|
|
149
149
|
const m = e.findIndex((b) => b === c.id), h = e.findIndex((b) => b === d.id);
|
|
150
150
|
m === -1 || h === -1 || t(Fe([...e], m, h));
|
|
151
|
-
},
|
|
152
|
-
|
|
151
|
+
}, o = (s) => {
|
|
152
|
+
l.current || (l.current = !0, i(!0)), t(e.filter((c) => c !== s));
|
|
153
153
|
};
|
|
154
154
|
return /* @__PURE__ */ f("div", { className: "settings-shell__field settings-shell__field--slots", "aria-label": "Stack slots", children: [
|
|
155
|
-
/* @__PURE__ */ n("
|
|
156
|
-
/* @__PURE__ */ n(Oe, { sensors: r, collisionDetection: Me, onDragEnd: u, children: /* @__PURE__ */ n($e, { items: [...e], strategy: Re, children: /* @__PURE__ */ n("ul", { className: "settings-shell__slots-list", role: "list", children: e.map((s) => /* @__PURE__ */ n(Ke, { id: s, onRemove: () => l(s) }, s)) }) }) }),
|
|
155
|
+
/* @__PURE__ */ n(Oe, { sensors: r, collisionDetection: Me, onDragEnd: u, children: /* @__PURE__ */ n($e, { items: [...e], strategy: Re, children: /* @__PURE__ */ n("ul", { className: "settings-shell__slots-list", role: "list", children: e.map((s) => /* @__PURE__ */ n(Ke, { id: s, onRemove: () => o(s) }, s)) }) }) }),
|
|
157
156
|
e.length === 0 && a && /* @__PURE__ */ n("p", { className: "settings-shell__help", children: "All slots removed. Apply to commit, or Reset to restore." }),
|
|
158
157
|
/* @__PURE__ */ n("p", { className: "settings-shell__help settings-shell__help--small", children: "Drag to reorder · click × to remove" })
|
|
159
158
|
] });
|
|
@@ -163,7 +162,7 @@ function Ge({
|
|
|
163
162
|
value: e,
|
|
164
163
|
onSelect: t,
|
|
165
164
|
enabled: r = !1,
|
|
166
|
-
onToggleEnabled:
|
|
165
|
+
onToggleEnabled: l
|
|
167
166
|
}) {
|
|
168
167
|
const a = "settings-accent-enabled";
|
|
169
168
|
return /* @__PURE__ */ f("div", { className: "settings-shell__field settings-shell__field--color", role: "group", "aria-label": "Accent color", children: [
|
|
@@ -178,12 +177,12 @@ function Ge({
|
|
|
178
177
|
"aria-label": "Enable accent override",
|
|
179
178
|
"aria-checked": r,
|
|
180
179
|
checked: r,
|
|
181
|
-
onChange: (i) =>
|
|
180
|
+
onChange: (i) => l?.(i.target.checked),
|
|
182
181
|
className: "settings-shell__toggle"
|
|
183
182
|
}
|
|
184
183
|
)
|
|
185
184
|
] }),
|
|
186
|
-
r ? /* @__PURE__ */ f(
|
|
185
|
+
r ? /* @__PURE__ */ f(B, { children: [
|
|
187
186
|
/* @__PURE__ */ n("span", { className: "settings-shell__label", children: "Accent color" }),
|
|
188
187
|
/* @__PURE__ */ n("div", { className: "settings-shell__swatch-row", children: We.map((i) => {
|
|
189
188
|
const u = e === i;
|
|
@@ -204,25 +203,25 @@ function Ge({
|
|
|
204
203
|
] });
|
|
205
204
|
}
|
|
206
205
|
const Qe = ["Orders", "Quota", "Unassigned"], qe = ["threshold", "timeframe", "color"];
|
|
207
|
-
function
|
|
206
|
+
function Pt({
|
|
208
207
|
isOpen: e,
|
|
209
208
|
cardSpan: t,
|
|
210
209
|
cardLabel: r = "Metric",
|
|
211
|
-
cardValue:
|
|
210
|
+
cardValue: l = "—",
|
|
212
211
|
previewSlot: a,
|
|
213
212
|
dimensions: i = qe,
|
|
214
213
|
initialTab: u,
|
|
215
|
-
initialValues:
|
|
214
|
+
initialValues: o
|
|
216
215
|
}) {
|
|
217
|
-
const s =
|
|
218
|
-
|
|
219
|
-
i.includes(
|
|
220
|
-
}, [i,
|
|
221
|
-
const
|
|
216
|
+
const s = O(), c = s?.state.activeTrigger, d = c?.kind === "card-overflow" ? c.cardId : null, m = fe(), h = c?.span, b = t ?? h ?? 1, p = i[0] ?? "threshold", [y, E] = U.useState(u ?? p);
|
|
217
|
+
U.useEffect(() => {
|
|
218
|
+
i.includes(y) || E(p);
|
|
219
|
+
}, [i, y, p]);
|
|
220
|
+
const v = d != null ? s?.state?.bufferByCard?.[d]?.changes ?? {} : {}, N = typeof v.threshold == "number" ? v.threshold : typeof o?.threshold == "number" ? o.threshold : 80, I = typeof v.timeframe == "number" ? v.timeframe : typeof o?.timeframe == "number" ? o.timeframe : 30, $ = typeof v.accent == "string" ? v.accent : typeof o?.accent == "string" ? o.accent : null, w = Array.isArray(v.slots) ? v.slots : Array.isArray(o?.slots) ? o.slots : Qe, A = typeof v.thresholdEnabled == "boolean" ? v.thresholdEnabled : typeof o?.thresholdEnabled == "boolean" ? o.thresholdEnabled : !1, Y = typeof v.accentEnabled == "boolean" ? v.accentEnabled : typeof o?.accentEnabled == "boolean" ? o.accentEnabled : !1, W = (P) => {
|
|
222
221
|
d == null || s == null || s.dispatch({ type: "SET_BUFFER_VALUE", cardId: d, key: "threshold", value: Number(P.target.value) });
|
|
223
222
|
}, G = (P) => {
|
|
224
223
|
d == null || s == null || s.dispatch({ type: "SET_BUFFER_VALUE", cardId: d, key: "timeframe", value: Number(P.target.value) });
|
|
225
|
-
},
|
|
224
|
+
}, le = (P) => {
|
|
226
225
|
d == null || s == null || s.dispatch({ type: "SET_BUFFER_VALUE", cardId: d, key: "accent", value: P });
|
|
227
226
|
}, Q = (P) => {
|
|
228
227
|
d == null || s == null || s.dispatch({ type: "SET_BUFFER_VALUE", cardId: d, key: "slots", value: P });
|
|
@@ -230,22 +229,21 @@ function xt({
|
|
|
230
229
|
d == null || s == null || s.dispatch({ type: "SET_BUFFER_VALUE", cardId: d, key: "thresholdEnabled", value: P });
|
|
231
230
|
}, g = (P) => {
|
|
232
231
|
d == null || s == null || s.dispatch({ type: "SET_BUFFER_VALUE", cardId: d, key: "accentEnabled", value: P });
|
|
233
|
-
}, C = s?.state.isDirty ?? !1,
|
|
232
|
+
}, C = s?.state.isDirty ?? !1, S = d;
|
|
234
233
|
return /* @__PURE__ */ n(
|
|
235
|
-
|
|
234
|
+
V,
|
|
236
235
|
{
|
|
237
236
|
variant: "with-stage",
|
|
238
|
-
title: "Configure metric",
|
|
239
237
|
onClose: () => s?.dispatch({ type: "CLOSE_PANEL", reason: "header-x" }),
|
|
240
|
-
stage: /* @__PURE__ */ n(He, { span: b, rotating: !m, children: a ?? /* @__PURE__ */ f(
|
|
238
|
+
stage: /* @__PURE__ */ n(He, { span: b, rotating: !m, children: a ?? /* @__PURE__ */ f(B, { children: [
|
|
241
239
|
/* @__PURE__ */ n("div", { style: { fontSize: 9, textTransform: "uppercase", letterSpacing: "0.06em", color: "#9ca3af", marginBottom: 6 }, children: r }),
|
|
242
|
-
/* @__PURE__ */ n("div", { style: { fontSize: 22, fontWeight: 700, color: "#111827", lineHeight: 1 }, children:
|
|
240
|
+
/* @__PURE__ */ n("div", { style: { fontSize: 22, fontWeight: 700, color: "#111827", lineHeight: 1 }, children: l })
|
|
243
241
|
] }) }),
|
|
244
242
|
navigation: /* @__PURE__ */ n(
|
|
245
243
|
we,
|
|
246
244
|
{
|
|
247
245
|
dimensions: i,
|
|
248
|
-
activeTab:
|
|
246
|
+
activeTab: y,
|
|
249
247
|
onSelect: E,
|
|
250
248
|
reduced: m
|
|
251
249
|
}
|
|
@@ -259,61 +257,49 @@ function xt({
|
|
|
259
257
|
className: "gloss-panel-chrome-v2__footer-btn",
|
|
260
258
|
disabled: !C,
|
|
261
259
|
onClick: () => {
|
|
262
|
-
|
|
260
|
+
S != null && s?.dispatch({ type: "CLEAR_BUFFER", cardId: S });
|
|
263
261
|
},
|
|
264
262
|
children: "Reset"
|
|
265
263
|
}
|
|
266
264
|
),
|
|
267
|
-
right: /* @__PURE__ */
|
|
268
|
-
|
|
269
|
-
|
|
270
|
-
|
|
271
|
-
|
|
272
|
-
|
|
273
|
-
|
|
274
|
-
|
|
275
|
-
|
|
276
|
-
|
|
277
|
-
|
|
278
|
-
/* @__PURE__ */ n(
|
|
279
|
-
"button",
|
|
280
|
-
{
|
|
281
|
-
id: "settings-apply",
|
|
282
|
-
type: "button",
|
|
283
|
-
className: "gloss-panel-chrome-v2__footer-btn gloss-panel-chrome-v2__footer-btn--primary",
|
|
284
|
-
disabled: !C,
|
|
285
|
-
onClick: () => s?.dispatch({ type: "CLOSE_PANEL", reason: "apply-button" }),
|
|
286
|
-
children: "Apply"
|
|
287
|
-
}
|
|
288
|
-
)
|
|
289
|
-
] })
|
|
265
|
+
right: /* @__PURE__ */ n(
|
|
266
|
+
"button",
|
|
267
|
+
{
|
|
268
|
+
id: "settings-apply",
|
|
269
|
+
type: "button",
|
|
270
|
+
className: "gloss-panel-chrome-v2__footer-btn gloss-panel-chrome-v2__footer-btn--primary",
|
|
271
|
+
disabled: !C,
|
|
272
|
+
onClick: () => s?.dispatch({ type: "CLOSE_PANEL", reason: "apply-button" }),
|
|
273
|
+
children: "Apply"
|
|
274
|
+
}
|
|
275
|
+
)
|
|
290
276
|
},
|
|
291
277
|
children: /* @__PURE__ */ n("div", { className: "settings-shell", "data-shell": "settings", "aria-hidden": !e, children: /* @__PURE__ */ f(
|
|
292
278
|
"div",
|
|
293
279
|
{
|
|
294
280
|
role: "tabpanel",
|
|
295
|
-
id: `settings-tabpanel-${
|
|
281
|
+
id: `settings-tabpanel-${y}`,
|
|
296
282
|
"aria-label": "Settings dimension controls",
|
|
297
283
|
tabIndex: 0,
|
|
298
284
|
className: "settings-shell__tabpanel",
|
|
299
285
|
children: [
|
|
300
|
-
|
|
286
|
+
y === "threshold" && /* @__PURE__ */ n(
|
|
301
287
|
Ve,
|
|
302
288
|
{
|
|
303
289
|
value: N,
|
|
304
290
|
onChange: W,
|
|
305
|
-
enabled:
|
|
291
|
+
enabled: A,
|
|
306
292
|
onToggleEnabled: q
|
|
307
293
|
}
|
|
308
294
|
),
|
|
309
|
-
|
|
310
|
-
|
|
311
|
-
|
|
295
|
+
y === "timeframe" && /* @__PURE__ */ n(Be, { value: I, onChange: G }),
|
|
296
|
+
y === "slots" && /* @__PURE__ */ n(Ye, { value: w, onChange: Q }),
|
|
297
|
+
y === "color" && /* @__PURE__ */ n(
|
|
312
298
|
Ge,
|
|
313
299
|
{
|
|
314
|
-
value:
|
|
315
|
-
onSelect:
|
|
316
|
-
enabled:
|
|
300
|
+
value: $,
|
|
301
|
+
onSelect: le,
|
|
302
|
+
enabled: Y,
|
|
317
303
|
onToggleEnabled: g
|
|
318
304
|
}
|
|
319
305
|
)
|
|
@@ -831,11 +817,11 @@ function Ce({
|
|
|
831
817
|
lenses: e,
|
|
832
818
|
activeLens: t,
|
|
833
819
|
onLensChange: r,
|
|
834
|
-
variant:
|
|
820
|
+
variant: l = "pills",
|
|
835
821
|
lensMeta: a = ae
|
|
836
822
|
}) {
|
|
837
|
-
return
|
|
838
|
-
const u = i === t,
|
|
823
|
+
return l === "pills" ? /* @__PURE__ */ n("div", { className: "cat-pills-wrap", children: /* @__PURE__ */ n("div", { className: "cat-pills", role: "tablist", "aria-label": "Metric lenses", children: e.map((i) => {
|
|
824
|
+
const u = i === t, o = a[i], s = ["cat-pill"];
|
|
839
825
|
return u && s.push("active"), /* @__PURE__ */ f(
|
|
840
826
|
"button",
|
|
841
827
|
{
|
|
@@ -849,7 +835,7 @@ function Ce({
|
|
|
849
835
|
},
|
|
850
836
|
children: [
|
|
851
837
|
i,
|
|
852
|
-
|
|
838
|
+
o?.beta && /* @__PURE__ */ n("span", { className: "cat-pill-beta", "aria-label": "Beta", children: "BETA" })
|
|
853
839
|
]
|
|
854
840
|
},
|
|
855
841
|
i
|
|
@@ -861,9 +847,9 @@ function je({
|
|
|
861
847
|
activeLens: t,
|
|
862
848
|
onLensChange: r
|
|
863
849
|
}) {
|
|
864
|
-
const [
|
|
850
|
+
const [l, a] = x(!1), i = K(null), u = () => {
|
|
865
851
|
i.current != null && (window.clearTimeout(i.current), i.current = null);
|
|
866
|
-
},
|
|
852
|
+
}, o = () => {
|
|
867
853
|
u(), i.current = window.setTimeout(() => a(!1), 100);
|
|
868
854
|
}, s = e.filter((c) => c !== t);
|
|
869
855
|
return /* @__PURE__ */ n("div", { className: "cat-segmented-wrap", children: /* @__PURE__ */ f("div", { className: "cat-segmented", children: [
|
|
@@ -884,16 +870,16 @@ function je({
|
|
|
884
870
|
onMouseEnter: () => {
|
|
885
871
|
u(), a(!0);
|
|
886
872
|
},
|
|
887
|
-
onMouseLeave:
|
|
873
|
+
onMouseLeave: o,
|
|
888
874
|
children: [
|
|
889
|
-
/* @__PURE__ */ n("button", { type: "button", className: "cat-seg cat-seg-more-btn", "aria-haspopup": "menu", "aria-expanded":
|
|
890
|
-
|
|
875
|
+
/* @__PURE__ */ n("button", { type: "button", className: "cat-seg cat-seg-more-btn", "aria-haspopup": "menu", "aria-expanded": l, children: "More ▾" }),
|
|
876
|
+
l && /* @__PURE__ */ n(
|
|
891
877
|
"div",
|
|
892
878
|
{
|
|
893
879
|
className: "cat-seg-overflow",
|
|
894
880
|
role: "menu",
|
|
895
881
|
onMouseEnter: u,
|
|
896
|
-
onMouseLeave:
|
|
882
|
+
onMouseLeave: o,
|
|
897
883
|
children: s.map((c) => /* @__PURE__ */ n(
|
|
898
884
|
"button",
|
|
899
885
|
{
|
|
@@ -914,13 +900,13 @@ function je({
|
|
|
914
900
|
)
|
|
915
901
|
] }) });
|
|
916
902
|
}
|
|
917
|
-
function te({ tiles: e, selectedTileId: t, onSelectTile: r, renderTile:
|
|
903
|
+
function te({ tiles: e, selectedTileId: t, onSelectTile: r, renderTile: l }) {
|
|
918
904
|
return /* @__PURE__ */ n("div", { className: "cat-tiles", children: e.map((a) => {
|
|
919
905
|
const i = a.id === t, u = a.subStats != null && a.subStats.length > 0;
|
|
920
|
-
let
|
|
921
|
-
u ? a.subStats.length === 5 ?
|
|
906
|
+
let o = null;
|
|
907
|
+
u ? a.subStats.length === 5 ? o = "span-5" : a.subStats.length === 3 ? o = "span-3" : o = "span-2" : a.stack === !0 && (o = "span-2");
|
|
922
908
|
const s = ["cat-tile"];
|
|
923
|
-
|
|
909
|
+
o && s.push(o), i && s.push("selected"), a.isNew && s.push("is-new"), a.startHere && s.push("start-here"), a.donut && s.push("has-donut");
|
|
924
910
|
const c = 1;
|
|
925
911
|
let d = 0.7;
|
|
926
912
|
if (a.donut) {
|
|
@@ -945,7 +931,7 @@ function te({ tiles: e, selectedTileId: t, onSelectTile: r, renderTile: o }) {
|
|
|
945
931
|
style: a.accent ? { "--cat-tile-accent": a.accent } : void 0,
|
|
946
932
|
children: [
|
|
947
933
|
a.startHere && /* @__PURE__ */ n("span", { className: "cat-tile-start-here", "aria-hidden": "true", children: "START HERE" }),
|
|
948
|
-
|
|
934
|
+
l ? l(a) : /* @__PURE__ */ n(
|
|
949
935
|
"div",
|
|
950
936
|
{
|
|
951
937
|
className: "cat-tile-primitive-wrapper gloss-metric-card",
|
|
@@ -986,10 +972,10 @@ const se = ge(null);
|
|
|
986
972
|
function re() {
|
|
987
973
|
return be(se);
|
|
988
974
|
}
|
|
989
|
-
function
|
|
975
|
+
function xt({ mode: e, dispatch: t }) {
|
|
990
976
|
const r = re();
|
|
991
977
|
if (r == null && e == null) return null;
|
|
992
|
-
const
|
|
978
|
+
const l = r?.mode ?? e ?? "add", a = r?.selectedTileId ?? null, i = r?.description ?? null, u = a == null;
|
|
993
979
|
return /* @__PURE__ */ f("div", { className: "panel-footer catalog", children: [
|
|
994
980
|
/* @__PURE__ */ n("div", { className: "cat-description", id: "cat-desc", children: i ?? /* @__PURE__ */ n("em", { children: "Tap a metric to see its description" }) }),
|
|
995
981
|
/* @__PURE__ */ f("div", { style: { display: "flex", padding: "10px 14px", gap: 8 }, children: [
|
|
@@ -1004,7 +990,7 @@ function At({ mode: e, dispatch: t }) {
|
|
|
1004
990
|
children: "Cancel"
|
|
1005
991
|
}
|
|
1006
992
|
),
|
|
1007
|
-
|
|
993
|
+
l === "add" && /* @__PURE__ */ n(
|
|
1008
994
|
"button",
|
|
1009
995
|
{
|
|
1010
996
|
id: "btn-cat-add",
|
|
@@ -1015,7 +1001,7 @@ function At({ mode: e, dispatch: t }) {
|
|
|
1015
1001
|
children: "Add metric"
|
|
1016
1002
|
}
|
|
1017
1003
|
),
|
|
1018
|
-
|
|
1004
|
+
l === "replace" && /* @__PURE__ */ n(
|
|
1019
1005
|
"button",
|
|
1020
1006
|
{
|
|
1021
1007
|
id: "btn-cat-replace",
|
|
@@ -1034,65 +1020,53 @@ function ue(e, t) {
|
|
|
1034
1020
|
const r = t.toLowerCase();
|
|
1035
1021
|
if (e.label.toLowerCase().includes(r) || e.value.toLowerCase().includes(r)) return !0;
|
|
1036
1022
|
if (e.subStats) {
|
|
1037
|
-
for (const
|
|
1038
|
-
if (
|
|
1023
|
+
for (const l of e.subStats)
|
|
1024
|
+
if (l.label.toLowerCase().includes(r) || l.value.toLowerCase().includes(r)) return !0;
|
|
1039
1025
|
}
|
|
1040
1026
|
return !1;
|
|
1041
1027
|
}
|
|
1042
1028
|
function Ze() {
|
|
1043
1029
|
const t = re()?.description ?? null;
|
|
1044
|
-
return t == null ? /* @__PURE__ */ n("
|
|
1030
|
+
return t == null ? /* @__PURE__ */ n("span", { style: { fontStyle: "italic" }, children: "Tap a metric to see its description" }) : /* @__PURE__ */ n("span", { children: t });
|
|
1045
1031
|
}
|
|
1046
|
-
function
|
|
1032
|
+
function At({
|
|
1047
1033
|
isOpen: e,
|
|
1048
1034
|
lenses: t = ve,
|
|
1049
1035
|
defaultLens: r = ye,
|
|
1050
|
-
tilesByLens:
|
|
1036
|
+
tilesByLens: l = _e,
|
|
1051
1037
|
lensMeta: a = ae,
|
|
1052
1038
|
renderTile: i
|
|
1053
1039
|
}) {
|
|
1054
|
-
const u =
|
|
1055
|
-
() =>
|
|
1056
|
-
[
|
|
1057
|
-
),
|
|
1058
|
-
() => (
|
|
1059
|
-
[
|
|
1060
|
-
), N = () => u?.dispatch({ type: "CLOSE_PANEL", reason: "
|
|
1040
|
+
const u = O(), [o, s] = x(r), [c, d] = x(null), [m, h] = x(null), [b, p] = x(""), y = l[o] ?? { primary: [] }, E = a[o], T = ie(
|
|
1041
|
+
() => y.primary.filter((w) => ue(w, b)),
|
|
1042
|
+
[y.primary, b]
|
|
1043
|
+
), v = ie(
|
|
1044
|
+
() => (y.secondary ?? []).filter((w) => ue(w, b)),
|
|
1045
|
+
[y.secondary, b]
|
|
1046
|
+
), N = () => u?.dispatch({ type: "CLOSE_PANEL", reason: "apply-button" }), I = () => u?.dispatch({ type: "CLOSE_PANEL", reason: "header-x" }), $ = c == null;
|
|
1061
1047
|
return /* @__PURE__ */ n(
|
|
1062
1048
|
se.Provider,
|
|
1063
1049
|
{
|
|
1064
1050
|
value: { mode: "add", selectedTileId: c, description: m },
|
|
1065
1051
|
children: /* @__PURE__ */ n(
|
|
1066
|
-
|
|
1052
|
+
V,
|
|
1067
1053
|
{
|
|
1068
1054
|
variant: "no-stage",
|
|
1069
1055
|
title: "Add a metric",
|
|
1070
|
-
onClose:
|
|
1056
|
+
onClose: I,
|
|
1071
1057
|
footer: {
|
|
1072
1058
|
left: /* @__PURE__ */ n(Ze, {}),
|
|
1073
|
-
right: /* @__PURE__ */
|
|
1074
|
-
|
|
1075
|
-
|
|
1076
|
-
|
|
1077
|
-
|
|
1078
|
-
|
|
1079
|
-
|
|
1080
|
-
|
|
1081
|
-
|
|
1082
|
-
|
|
1083
|
-
|
|
1084
|
-
/* @__PURE__ */ n(
|
|
1085
|
-
"button",
|
|
1086
|
-
{
|
|
1087
|
-
id: "btn-cat-add",
|
|
1088
|
-
type: "button",
|
|
1089
|
-
className: "gloss-panel-chrome-v2__footer-btn gloss-panel-chrome-v2__footer-btn--primary",
|
|
1090
|
-
disabled: F,
|
|
1091
|
-
onClick: O,
|
|
1092
|
-
children: "Add metric"
|
|
1093
|
-
}
|
|
1094
|
-
)
|
|
1095
|
-
] })
|
|
1059
|
+
right: /* @__PURE__ */ n(
|
|
1060
|
+
"button",
|
|
1061
|
+
{
|
|
1062
|
+
id: "btn-cat-add",
|
|
1063
|
+
type: "button",
|
|
1064
|
+
className: "gloss-panel-chrome-v2__footer-btn gloss-panel-chrome-v2__footer-btn--primary",
|
|
1065
|
+
disabled: $,
|
|
1066
|
+
onClick: N,
|
|
1067
|
+
children: "Add metric"
|
|
1068
|
+
}
|
|
1069
|
+
)
|
|
1096
1070
|
},
|
|
1097
1071
|
children: /* @__PURE__ */ f("div", { "data-shell": "catalog-add", "aria-hidden": !e, children: [
|
|
1098
1072
|
/* @__PURE__ */ n("div", { className: "cat-search", children: /* @__PURE__ */ n(
|
|
@@ -1103,18 +1077,18 @@ function kt({
|
|
|
1103
1077
|
placeholder: "Search metrics",
|
|
1104
1078
|
"aria-label": "Search metrics",
|
|
1105
1079
|
value: b,
|
|
1106
|
-
onChange: (
|
|
1080
|
+
onChange: (w) => p(w.target.value)
|
|
1107
1081
|
}
|
|
1108
1082
|
) }),
|
|
1109
1083
|
/* @__PURE__ */ n(
|
|
1110
1084
|
Ce,
|
|
1111
1085
|
{
|
|
1112
1086
|
lenses: t,
|
|
1113
|
-
activeLens:
|
|
1087
|
+
activeLens: o,
|
|
1114
1088
|
lensMeta: a,
|
|
1115
1089
|
variant: "pills",
|
|
1116
|
-
onLensChange: (
|
|
1117
|
-
s(
|
|
1090
|
+
onLensChange: (w) => {
|
|
1091
|
+
s(w), d(null), h(null), p("");
|
|
1118
1092
|
}
|
|
1119
1093
|
}
|
|
1120
1094
|
),
|
|
@@ -1125,29 +1099,29 @@ function kt({
|
|
|
1125
1099
|
/* @__PURE__ */ n(
|
|
1126
1100
|
te,
|
|
1127
1101
|
{
|
|
1128
|
-
tiles:
|
|
1102
|
+
tiles: T,
|
|
1129
1103
|
selectedTileId: c,
|
|
1130
|
-
onSelectTile: (
|
|
1131
|
-
d(
|
|
1104
|
+
onSelectTile: (w, A) => {
|
|
1105
|
+
d(w), h(A);
|
|
1132
1106
|
},
|
|
1133
1107
|
renderTile: i
|
|
1134
1108
|
}
|
|
1135
1109
|
),
|
|
1136
|
-
|
|
1110
|
+
v.length > 0 && /* @__PURE__ */ f("div", { className: "cat-more-in-lens", children: [
|
|
1137
1111
|
/* @__PURE__ */ n("div", { className: "cat-more-in-lens__heading", children: "MORE IN THIS LENS" }),
|
|
1138
1112
|
/* @__PURE__ */ n(
|
|
1139
1113
|
te,
|
|
1140
1114
|
{
|
|
1141
|
-
tiles:
|
|
1115
|
+
tiles: v,
|
|
1142
1116
|
selectedTileId: c,
|
|
1143
|
-
onSelectTile: (
|
|
1144
|
-
d(
|
|
1117
|
+
onSelectTile: (w, A) => {
|
|
1118
|
+
d(w), h(A);
|
|
1145
1119
|
},
|
|
1146
1120
|
renderTile: i
|
|
1147
1121
|
}
|
|
1148
1122
|
)
|
|
1149
1123
|
] }),
|
|
1150
|
-
|
|
1124
|
+
T.length === 0 && v.length === 0 && b.length > 0 && /* @__PURE__ */ f("div", { className: "cat-empty", children: [
|
|
1151
1125
|
'No metrics match "',
|
|
1152
1126
|
b,
|
|
1153
1127
|
'".'
|
|
@@ -1160,52 +1134,40 @@ function kt({
|
|
|
1160
1134
|
}
|
|
1161
1135
|
function Xe() {
|
|
1162
1136
|
const t = re()?.description ?? null;
|
|
1163
|
-
return t == null ? /* @__PURE__ */ n("em", { children: "Tap a metric to see its description" }) : /* @__PURE__ */ n(
|
|
1137
|
+
return t == null ? /* @__PURE__ */ n("em", { children: "Tap a metric to see its description" }) : /* @__PURE__ */ n(B, { children: t });
|
|
1164
1138
|
}
|
|
1165
|
-
function
|
|
1139
|
+
function kt({
|
|
1166
1140
|
isOpen: e,
|
|
1167
1141
|
replacingLabel: t,
|
|
1168
1142
|
lenses: r = ve,
|
|
1169
|
-
defaultLens:
|
|
1143
|
+
defaultLens: l = ye,
|
|
1170
1144
|
tilesByLens: a = _e,
|
|
1171
1145
|
renderTile: i
|
|
1172
1146
|
}) {
|
|
1173
|
-
const u =
|
|
1147
|
+
const u = O(), [o, s] = x(l), [c, d] = x(null), [m, h] = x(null), b = a[o] ?? { primary: [] }, p = [...b.primary, ...b.secondary ?? []], y = () => u?.dispatch({ type: "CLOSE_PANEL", reason: "apply-button" }), E = () => u?.dispatch({ type: "CLOSE_PANEL", reason: "header-x" }), T = c == null;
|
|
1174
1148
|
return /* @__PURE__ */ n(
|
|
1175
1149
|
se.Provider,
|
|
1176
1150
|
{
|
|
1177
1151
|
value: { mode: "replace", selectedTileId: c, description: m },
|
|
1178
1152
|
children: /* @__PURE__ */ n(
|
|
1179
|
-
|
|
1153
|
+
V,
|
|
1180
1154
|
{
|
|
1181
1155
|
variant: "no-stage",
|
|
1182
1156
|
title: "Replace metric",
|
|
1183
|
-
onClose:
|
|
1157
|
+
onClose: E,
|
|
1184
1158
|
footer: {
|
|
1185
1159
|
left: /* @__PURE__ */ n(Xe, {}),
|
|
1186
|
-
right: /* @__PURE__ */
|
|
1187
|
-
|
|
1188
|
-
|
|
1189
|
-
|
|
1190
|
-
|
|
1191
|
-
|
|
1192
|
-
|
|
1193
|
-
|
|
1194
|
-
|
|
1195
|
-
|
|
1196
|
-
|
|
1197
|
-
/* @__PURE__ */ n(
|
|
1198
|
-
"button",
|
|
1199
|
-
{
|
|
1200
|
-
id: "btn-cat-replace",
|
|
1201
|
-
type: "button",
|
|
1202
|
-
className: "gloss-panel-chrome-v2__footer-btn gloss-panel-chrome-v2__footer-btn--primary",
|
|
1203
|
-
disabled: y,
|
|
1204
|
-
onClick: E,
|
|
1205
|
-
children: "Replace metric"
|
|
1206
|
-
}
|
|
1207
|
-
)
|
|
1208
|
-
] })
|
|
1160
|
+
right: /* @__PURE__ */ n(
|
|
1161
|
+
"button",
|
|
1162
|
+
{
|
|
1163
|
+
id: "btn-cat-replace",
|
|
1164
|
+
type: "button",
|
|
1165
|
+
className: "gloss-panel-chrome-v2__footer-btn gloss-panel-chrome-v2__footer-btn--primary",
|
|
1166
|
+
disabled: T,
|
|
1167
|
+
onClick: y,
|
|
1168
|
+
children: "Replace metric"
|
|
1169
|
+
}
|
|
1170
|
+
)
|
|
1209
1171
|
},
|
|
1210
1172
|
children: /* @__PURE__ */ f("div", { "data-shell": "catalog-replace", "aria-hidden": !e, children: [
|
|
1211
1173
|
t && /* @__PURE__ */ f("p", { className: "cat-subtitle", children: [
|
|
@@ -1216,9 +1178,9 @@ function Dt({
|
|
|
1216
1178
|
Ce,
|
|
1217
1179
|
{
|
|
1218
1180
|
lenses: r,
|
|
1219
|
-
activeLens:
|
|
1220
|
-
onLensChange: (
|
|
1221
|
-
s(
|
|
1181
|
+
activeLens: o,
|
|
1182
|
+
onLensChange: (v) => {
|
|
1183
|
+
s(v), d(null), h(null);
|
|
1222
1184
|
}
|
|
1223
1185
|
}
|
|
1224
1186
|
),
|
|
@@ -1227,8 +1189,8 @@ function Dt({
|
|
|
1227
1189
|
{
|
|
1228
1190
|
tiles: p,
|
|
1229
1191
|
selectedTileId: c,
|
|
1230
|
-
onSelectTile: (
|
|
1231
|
-
d(
|
|
1192
|
+
onSelectTile: (v, N) => {
|
|
1193
|
+
d(v), h(N);
|
|
1232
1194
|
},
|
|
1233
1195
|
renderTile: i
|
|
1234
1196
|
}
|
|
@@ -1244,7 +1206,7 @@ function Te() {
|
|
|
1244
1206
|
return be(Ne);
|
|
1245
1207
|
}
|
|
1246
1208
|
function Je(e = {}) {
|
|
1247
|
-
const t = Te(), r = t?.createPage,
|
|
1209
|
+
const t = Te(), r = t?.createPage, l = t?.setPages;
|
|
1248
1210
|
return /* @__PURE__ */ f(
|
|
1249
1211
|
"div",
|
|
1250
1212
|
{
|
|
@@ -1263,7 +1225,7 @@ function Je(e = {}) {
|
|
|
1263
1225
|
r();
|
|
1264
1226
|
return;
|
|
1265
1227
|
}
|
|
1266
|
-
|
|
1228
|
+
l && l((a) => [
|
|
1267
1229
|
...a,
|
|
1268
1230
|
{ id: `new-${Date.now()}`, name: "Untitled", active: !1 }
|
|
1269
1231
|
]);
|
|
@@ -1275,24 +1237,24 @@ function Je(e = {}) {
|
|
|
1275
1237
|
}
|
|
1276
1238
|
);
|
|
1277
1239
|
}
|
|
1278
|
-
function pe({ page: e, onRename: t, onKebab: r, onDragStart:
|
|
1279
|
-
const i = Te(), [u,
|
|
1280
|
-
|
|
1240
|
+
function pe({ page: e, onRename: t, onKebab: r, onDragStart: l, onSwitchPage: a }) {
|
|
1241
|
+
const i = Te(), [u, o] = x(!1), s = K(null);
|
|
1242
|
+
R(() => {
|
|
1281
1243
|
if (!u) return;
|
|
1282
|
-
const p = (
|
|
1283
|
-
s.current && (s.current.contains(
|
|
1244
|
+
const p = (y) => {
|
|
1245
|
+
s.current && (s.current.contains(y.target) || o(!1));
|
|
1284
1246
|
};
|
|
1285
1247
|
return document.addEventListener("mousedown", p, !0), () => document.removeEventListener("mousedown", p, !0);
|
|
1286
1248
|
}, [u]);
|
|
1287
1249
|
const c = () => {
|
|
1288
|
-
if (
|
|
1250
|
+
if (o(!1), t) return t(e.id);
|
|
1289
1251
|
if (!i?.renamePage) return;
|
|
1290
1252
|
const p = window.prompt("Rename page", e.name);
|
|
1291
1253
|
p != null && p.trim().length > 0 && i.renamePage(e.id, p.trim());
|
|
1292
1254
|
}, d = () => {
|
|
1293
|
-
|
|
1255
|
+
o(!1), i?.duplicatePage?.(e.id);
|
|
1294
1256
|
}, m = () => {
|
|
1295
|
-
|
|
1257
|
+
o(!1), i?.deletePage?.(e.id);
|
|
1296
1258
|
}, h = (p) => {
|
|
1297
1259
|
p.stopPropagation(), a && !e.active && a(e.id);
|
|
1298
1260
|
}, b = ["pm-row"];
|
|
@@ -1302,7 +1264,7 @@ function pe({ page: e, onRename: t, onKebab: r, onDragStart: o, onSwitchPage: a
|
|
|
1302
1264
|
{
|
|
1303
1265
|
className: "pm-handle",
|
|
1304
1266
|
"aria-hidden": "true",
|
|
1305
|
-
onMouseDown: () =>
|
|
1267
|
+
onMouseDown: () => l?.(e.id),
|
|
1306
1268
|
children: "⋮⋮"
|
|
1307
1269
|
}
|
|
1308
1270
|
),
|
|
@@ -1332,7 +1294,7 @@ function pe({ page: e, onRename: t, onKebab: r, onDragStart: o, onSwitchPage: a
|
|
|
1332
1294
|
onMouseDown: (p) => p.stopPropagation(),
|
|
1333
1295
|
onClick: (p) => {
|
|
1334
1296
|
if (p.stopPropagation(), r) return r(e.id);
|
|
1335
|
-
|
|
1297
|
+
o((y) => !y);
|
|
1336
1298
|
},
|
|
1337
1299
|
children: "⋯"
|
|
1338
1300
|
}
|
|
@@ -1369,50 +1331,50 @@ const et = [
|
|
|
1369
1331
|
{ id: "p-morning", name: "My Morning", active: !1 },
|
|
1370
1332
|
{ id: "p-accounts", name: "My Accounts", active: !1 }
|
|
1371
1333
|
];
|
|
1372
|
-
function
|
|
1334
|
+
function Dt({
|
|
1373
1335
|
isOpen: e,
|
|
1374
1336
|
pages: t = et,
|
|
1375
1337
|
externalPages: r,
|
|
1376
|
-
activePageId:
|
|
1338
|
+
activePageId: l,
|
|
1377
1339
|
onRename: a,
|
|
1378
1340
|
onDuplicate: i,
|
|
1379
1341
|
onDelete: u,
|
|
1380
|
-
onReorder:
|
|
1342
|
+
onReorder: o,
|
|
1381
1343
|
onCreatePage: s,
|
|
1382
1344
|
onSwitchPage: c
|
|
1383
1345
|
}) {
|
|
1384
|
-
const d =
|
|
1385
|
-
h((
|
|
1386
|
-
}, []), p =
|
|
1346
|
+
const d = O(), [m, h] = x(() => [...t]), b = L((g, C) => {
|
|
1347
|
+
h((S) => S.map((k) => k.id === g ? { ...k, name: C } : k));
|
|
1348
|
+
}, []), p = L((g) => {
|
|
1387
1349
|
h((C) => {
|
|
1388
|
-
const
|
|
1389
|
-
if (!
|
|
1390
|
-
const
|
|
1391
|
-
id: `${
|
|
1392
|
-
name: `${
|
|
1350
|
+
const S = C.find((F) => F.id === g);
|
|
1351
|
+
if (!S) return C;
|
|
1352
|
+
const k = {
|
|
1353
|
+
id: `${S.id}-copy-${Date.now()}`,
|
|
1354
|
+
name: `${S.name} copy`,
|
|
1393
1355
|
active: !1
|
|
1394
|
-
},
|
|
1395
|
-
return [...C.slice(0,
|
|
1356
|
+
}, D = C.findIndex((F) => F.id === g);
|
|
1357
|
+
return [...C.slice(0, D + 1), k, ...C.slice(D + 1)];
|
|
1396
1358
|
});
|
|
1397
|
-
}, []),
|
|
1398
|
-
h((C) => C.filter((
|
|
1399
|
-
}, []), E =
|
|
1359
|
+
}, []), y = L((g) => {
|
|
1360
|
+
h((C) => C.filter((S) => S.id !== g));
|
|
1361
|
+
}, []), E = L((g) => {
|
|
1400
1362
|
h((C) => {
|
|
1401
|
-
const
|
|
1402
|
-
return
|
|
1363
|
+
const S = new Map(C.map((D) => [D.id, D])), k = g.map((D) => S.get(D)).filter(Boolean);
|
|
1364
|
+
return k.length === C.length ? k : C;
|
|
1403
1365
|
});
|
|
1404
|
-
}, []),
|
|
1366
|
+
}, []), T = r != null, v = T ? r : m, N = l != null ? v.map((g) => ({ ...g, active: g.id === l })) : [...v], I = a ?? (T ? void 0 : b), $ = i ?? (T ? void 0 : p), w = u ?? (T ? void 0 : y), A = o ?? (T ? void 0 : E), Y = L(
|
|
1405
1367
|
(g) => {
|
|
1406
|
-
|
|
1368
|
+
T || h(g);
|
|
1407
1369
|
},
|
|
1408
|
-
[
|
|
1409
|
-
), W =
|
|
1370
|
+
[T]
|
|
1371
|
+
), W = L(
|
|
1410
1372
|
(g) => {
|
|
1411
|
-
const C = g[0]?.items.map((
|
|
1412
|
-
C.length > 0 &&
|
|
1373
|
+
const C = g[0]?.items.map((S) => S.id) ?? [];
|
|
1374
|
+
C.length > 0 && A && A(C);
|
|
1413
1375
|
},
|
|
1414
|
-
[
|
|
1415
|
-
), G = N.map((g) => `${g.id}:${g.name}`).join("|"), Q =
|
|
1376
|
+
[A]
|
|
1377
|
+
), G = N.map((g) => `${g.id}:${g.name}`).join("|"), Q = A != null && N.length > 1 ? /* @__PURE__ */ n(
|
|
1416
1378
|
Ee,
|
|
1417
1379
|
{
|
|
1418
1380
|
zones: [
|
|
@@ -1422,7 +1384,7 @@ function Lt({
|
|
|
1422
1384
|
}
|
|
1423
1385
|
],
|
|
1424
1386
|
onZoneChange: W,
|
|
1425
|
-
renderZone: (g, C,
|
|
1387
|
+
renderZone: (g, C, S) => /* @__PURE__ */ n("div", { className: "pm-list", role: "list", children: S }),
|
|
1426
1388
|
renderItem: (g) => /* @__PURE__ */ n(
|
|
1427
1389
|
pe,
|
|
1428
1390
|
{
|
|
@@ -1446,15 +1408,15 @@ function Lt({
|
|
|
1446
1408
|
{
|
|
1447
1409
|
value: {
|
|
1448
1410
|
pages: N,
|
|
1449
|
-
setPages:
|
|
1450
|
-
renamePage:
|
|
1451
|
-
duplicatePage:
|
|
1452
|
-
deletePage:
|
|
1411
|
+
setPages: Y,
|
|
1412
|
+
renamePage: I,
|
|
1413
|
+
duplicatePage: $,
|
|
1414
|
+
deletePage: w,
|
|
1453
1415
|
// Sprint 2026-05-20 — propagate live create binding for footer.
|
|
1454
1416
|
createPage: s
|
|
1455
1417
|
},
|
|
1456
1418
|
children: /* @__PURE__ */ n(
|
|
1457
|
-
|
|
1419
|
+
V,
|
|
1458
1420
|
{
|
|
1459
1421
|
variant: "no-stage",
|
|
1460
1422
|
title: "Manage pages",
|
|
@@ -1466,7 +1428,7 @@ function Lt({
|
|
|
1466
1428
|
}
|
|
1467
1429
|
);
|
|
1468
1430
|
}
|
|
1469
|
-
const
|
|
1431
|
+
const Lt = {
|
|
1470
1432
|
SETTINGS: "settings",
|
|
1471
1433
|
CATALOG_ADD: "catalog-add",
|
|
1472
1434
|
CATALOG_REPLACE: "catalog-replace",
|
|
@@ -1486,30 +1448,30 @@ const Ot = {
|
|
|
1486
1448
|
pointerEvents: "none",
|
|
1487
1449
|
background: "rgba(0, 0, 0, 0.04)"
|
|
1488
1450
|
};
|
|
1489
|
-
function
|
|
1451
|
+
function Ot() {
|
|
1490
1452
|
const { state: e, dispatch: t, getCloseLog: r } = Pe();
|
|
1491
|
-
|
|
1453
|
+
R(() => {
|
|
1492
1454
|
if (e.activePanelId == null) return;
|
|
1493
1455
|
function i(u) {
|
|
1494
1456
|
u.key === "Escape" && t({ type: "CLOSE_PANEL", reason: "escape-key" });
|
|
1495
1457
|
}
|
|
1496
1458
|
return document.addEventListener("keydown", i), () => document.removeEventListener("keydown", i);
|
|
1497
1459
|
}, [e.activePanelId, t]);
|
|
1498
|
-
const
|
|
1460
|
+
const l = K(e);
|
|
1499
1461
|
Ae(() => {
|
|
1500
|
-
|
|
1501
|
-
}),
|
|
1462
|
+
l.current = e;
|
|
1463
|
+
}), R(() => {
|
|
1502
1464
|
if (process.env.NODE_ENV === "production") return;
|
|
1503
1465
|
const i = window;
|
|
1504
1466
|
return i.__panelsHostHandle && console.warn("[panels] multiple PanelHost/PanelHostShell instances mounted; dev handle is unreliable"), i.__panelsHostHandle = {
|
|
1505
1467
|
dispatch: t,
|
|
1506
|
-
getState: () =>
|
|
1468
|
+
getState: () => l.current,
|
|
1507
1469
|
getCloseLog: r
|
|
1508
1470
|
}, () => {
|
|
1509
1471
|
i.__panelsHostHandle?.dispatch === t && delete window.__panelsHostHandle;
|
|
1510
1472
|
};
|
|
1511
1473
|
}, [t, r]);
|
|
1512
|
-
const a =
|
|
1474
|
+
const a = L(() => {
|
|
1513
1475
|
t({ type: "CLOSE_PANEL", reason: "nav-escape-hatch" });
|
|
1514
1476
|
}, [t]);
|
|
1515
1477
|
return /* @__PURE__ */ n("div", { "data-panel-host": "true", style: tt, children: e.activePanelId != null && /* @__PURE__ */ n(
|
|
@@ -1523,25 +1485,25 @@ function Mt() {
|
|
|
1523
1485
|
}
|
|
1524
1486
|
const at = 700;
|
|
1525
1487
|
function st(e) {
|
|
1526
|
-
const [t, r] = x(null),
|
|
1527
|
-
return
|
|
1488
|
+
const [t, r] = x(null), l = K(null);
|
|
1489
|
+
return R(() => {
|
|
1528
1490
|
if (e != null) {
|
|
1529
|
-
|
|
1491
|
+
l.current != null && (clearTimeout(l.current), l.current = null), r(null);
|
|
1530
1492
|
return;
|
|
1531
1493
|
}
|
|
1532
|
-
return r((a) => a),
|
|
1533
|
-
r(null),
|
|
1494
|
+
return r((a) => a), l.current = setTimeout(() => {
|
|
1495
|
+
r(null), l.current = null;
|
|
1534
1496
|
}, at), () => {
|
|
1535
|
-
|
|
1497
|
+
l.current != null && (clearTimeout(l.current), l.current = null);
|
|
1536
1498
|
};
|
|
1537
|
-
}, [e]),
|
|
1499
|
+
}, [e]), R(() => {
|
|
1538
1500
|
e != null && r(e);
|
|
1539
1501
|
}, [e]), e != null ? { panelId: e, isOpen: !0 } : t != null ? { panelId: t, isOpen: !1 } : { panelId: null, isOpen: !1 };
|
|
1540
1502
|
}
|
|
1541
|
-
function
|
|
1542
|
-
const r =
|
|
1543
|
-
if (r == null ||
|
|
1544
|
-
const a =
|
|
1503
|
+
function Mt({ panelComponents: e, children: t }) {
|
|
1504
|
+
const r = O(), l = st(r?.state.activePanelId ?? null);
|
|
1505
|
+
if (r == null || l.panelId == null) return null;
|
|
1506
|
+
const a = l.panelId, i = l.isOpen, u = e?.[a];
|
|
1545
1507
|
return u == null && t == null ? (process.env.NODE_ENV !== "production" && console.error(
|
|
1546
1508
|
"[panels] No panel component registered for activePanelId:",
|
|
1547
1509
|
a
|
|
@@ -1550,39 +1512,39 @@ function It({ panelComponents: e, children: t }) {
|
|
|
1550
1512
|
function me(e) {
|
|
1551
1513
|
return e === null ? null : e.kind === "manage-pages-action" ? `global-${e.align ?? "left"}` : e.kind === "card-overflow" || e.kind === "empty-cell" ? `section-${e.sectionIndex}` : null;
|
|
1552
1514
|
}
|
|
1553
|
-
const rt = 685, he = 627,
|
|
1515
|
+
const rt = 685, he = 627, ot = "cubic-bezier(0.22, 1, 0.36, 1)", lt = 200;
|
|
1554
1516
|
function Se(e, t) {
|
|
1555
1517
|
if (typeof window > "u") return t;
|
|
1556
1518
|
const r = window.getComputedStyle(document.documentElement).getPropertyValue(e).trim();
|
|
1557
1519
|
if (!r) return t;
|
|
1558
|
-
const
|
|
1559
|
-
return Number.isNaN(
|
|
1520
|
+
const l = parseFloat(r);
|
|
1521
|
+
return Number.isNaN(l) ? t : r.endsWith("s") && !r.endsWith("ms") ? l * 1e3 : l;
|
|
1560
1522
|
}
|
|
1561
1523
|
function it(e, t) {
|
|
1562
1524
|
return typeof window > "u" ? t : window.getComputedStyle(document.documentElement).getPropertyValue(e).trim() || t;
|
|
1563
1525
|
}
|
|
1564
|
-
function
|
|
1526
|
+
function z(e) {
|
|
1565
1527
|
e.dispatch({ type: "OPEN_PANEL", panelId: e.panelId, trigger: e.trigger });
|
|
1566
1528
|
}
|
|
1567
1529
|
function ct(e) {
|
|
1568
|
-
const { mountEl: t, chromeEl: r, reducedMotion:
|
|
1530
|
+
const { mountEl: t, chromeEl: r, reducedMotion: l, onAssert: a } = e;
|
|
1569
1531
|
if (t == null || r == null) {
|
|
1570
|
-
|
|
1532
|
+
z(e), a?.({ branch: "slide-fallback-no-dom", timestamp: Date.now() });
|
|
1571
1533
|
return;
|
|
1572
1534
|
}
|
|
1573
|
-
if (
|
|
1535
|
+
if (l) {
|
|
1574
1536
|
e.dispatch({ type: "OPEN_PANEL", panelId: e.panelId, trigger: e.trigger }), a?.({ branch: "slide-reduced-motion", timestamp: Date.now() });
|
|
1575
1537
|
return;
|
|
1576
1538
|
}
|
|
1577
1539
|
if (typeof r.animate != "function") {
|
|
1578
|
-
|
|
1540
|
+
z(e), a?.({ branch: "slide-no-waapi", timestamp: Date.now() });
|
|
1579
1541
|
return;
|
|
1580
1542
|
}
|
|
1581
1543
|
const i = r.cloneNode(!0);
|
|
1582
1544
|
i.id = "panel-chrome-frozen", i.style.cssText = "position:absolute;left:8px;right:8px;top:8px;z-index:1;pointer-events:none;", t.appendChild(i), r.style.zIndex = "2", e.dispatch({ type: "OPEN_PANEL", panelId: e.panelId, trigger: e.trigger });
|
|
1583
|
-
const u = Se("--panel-open-dur", rt),
|
|
1545
|
+
const u = Se("--panel-open-dur", rt), o = it("--panel-easing", ot), s = r.animate(
|
|
1584
1546
|
[{ transform: "translateY(100%)" }, { transform: "translateY(0)" }],
|
|
1585
|
-
{ duration: u, easing:
|
|
1547
|
+
{ duration: u, easing: o, fill: "forwards" }
|
|
1586
1548
|
);
|
|
1587
1549
|
s.addEventListener(
|
|
1588
1550
|
"finish",
|
|
@@ -1595,17 +1557,17 @@ function ct(e) {
|
|
|
1595
1557
|
function dt(e) {
|
|
1596
1558
|
const { mountEl: t, onAssert: r } = e;
|
|
1597
1559
|
if (t == null) {
|
|
1598
|
-
e.dispatch({ type: "CLOSE_PANEL", reason: "mutex-handoff" }), setTimeout(() =>
|
|
1560
|
+
e.dispatch({ type: "CLOSE_PANEL", reason: "mutex-handoff" }), setTimeout(() => z(e), he), r?.({ branch: "handoff-fallback-no-mount", timestamp: Date.now() });
|
|
1599
1561
|
return;
|
|
1600
1562
|
}
|
|
1601
|
-
const
|
|
1563
|
+
const l = Se("--panel-close-dur", he);
|
|
1602
1564
|
let a = !1, i = null;
|
|
1603
1565
|
const u = (s) => {
|
|
1604
1566
|
s.target !== t || s.propertyName !== "max-height" || a || (a = !0, i != null && clearTimeout(i), t.removeEventListener("transitionend", u), e.dispatch({ type: "OPEN_PANEL", panelId: e.panelId, trigger: e.trigger }), r?.({ branch: "handoff-complete", timestamp: Date.now() }));
|
|
1605
|
-
},
|
|
1567
|
+
}, o = () => {
|
|
1606
1568
|
a || (a = !0, t.removeEventListener("transitionend", u), e.dispatch({ type: "OPEN_PANEL", panelId: e.panelId, trigger: e.trigger }), r?.({ branch: "handoff-forced", timestamp: Date.now() }));
|
|
1607
1569
|
};
|
|
1608
|
-
t.addEventListener("transitionend", u), e.dispatch({ type: "CLOSE_PANEL", reason: "mutex-handoff" }), i = setTimeout(
|
|
1570
|
+
t.addEventListener("transitionend", u), e.dispatch({ type: "CLOSE_PANEL", reason: "mutex-handoff" }), i = setTimeout(o, l + lt);
|
|
1609
1571
|
}
|
|
1610
1572
|
function ut(e) {
|
|
1611
1573
|
const { state: t, onAssert: r } = e;
|
|
@@ -1613,8 +1575,8 @@ function ut(e) {
|
|
|
1613
1575
|
e.dispatch({ type: "OPEN_PANEL", panelId: e.panelId, trigger: e.trigger }), r?.({ branch: "blocked-dirty", timestamp: Date.now() });
|
|
1614
1576
|
return;
|
|
1615
1577
|
}
|
|
1616
|
-
const
|
|
1617
|
-
if (!!t.activePanelId &&
|
|
1578
|
+
const l = me(t.activeTrigger), a = me(e.trigger);
|
|
1579
|
+
if (!!t.activePanelId && l != null && l === a) {
|
|
1618
1580
|
ct(e);
|
|
1619
1581
|
return;
|
|
1620
1582
|
}
|
|
@@ -1622,28 +1584,28 @@ function ut(e) {
|
|
|
1622
1584
|
dt(e);
|
|
1623
1585
|
return;
|
|
1624
1586
|
}
|
|
1625
|
-
|
|
1587
|
+
z(e), r?.({ branch: "fresh-open", timestamp: Date.now() });
|
|
1626
1588
|
}
|
|
1627
1589
|
function pt() {
|
|
1628
1590
|
if (!(typeof window > "u"))
|
|
1629
1591
|
return window.__panelsAsserter;
|
|
1630
1592
|
}
|
|
1631
|
-
function
|
|
1632
|
-
const e =
|
|
1633
|
-
return
|
|
1634
|
-
(r,
|
|
1593
|
+
function It() {
|
|
1594
|
+
const e = O(), t = fe();
|
|
1595
|
+
return L(
|
|
1596
|
+
(r, l) => {
|
|
1635
1597
|
if (!e)
|
|
1636
1598
|
return;
|
|
1637
1599
|
const a = typeof document < "u" ? document.querySelector('[data-mount="panel"]') : null, i = typeof document < "u" ? document.querySelector('[data-chrome="panel"]') : null, u = {
|
|
1638
1600
|
panelId: r,
|
|
1639
|
-
trigger:
|
|
1601
|
+
trigger: l,
|
|
1640
1602
|
state: e.state,
|
|
1641
1603
|
dispatch: e.dispatch,
|
|
1642
1604
|
mountEl: a,
|
|
1643
1605
|
chromeEl: i,
|
|
1644
1606
|
reducedMotion: t,
|
|
1645
|
-
onAssert: (
|
|
1646
|
-
pt()?.recordTransition?.(
|
|
1607
|
+
onAssert: (o) => {
|
|
1608
|
+
pt()?.recordTransition?.(o);
|
|
1647
1609
|
}
|
|
1648
1610
|
};
|
|
1649
1611
|
ut(u);
|
|
@@ -1651,27 +1613,27 @@ function $t() {
|
|
|
1651
1613
|
[e, t]
|
|
1652
1614
|
);
|
|
1653
1615
|
}
|
|
1654
|
-
function
|
|
1616
|
+
function $t({ children: e }) {
|
|
1655
1617
|
return /* @__PURE__ */ n("div", { className: "clone-stage", children: e });
|
|
1656
1618
|
}
|
|
1657
|
-
let
|
|
1619
|
+
let H = !1, j = null;
|
|
1658
1620
|
function ne() {
|
|
1659
1621
|
const e = [];
|
|
1660
1622
|
let t = "cleaned";
|
|
1661
1623
|
document.querySelectorAll("#panel-chrome-frozen").length > 0 && (e.push("#panel-chrome-frozen"), t = "lingering");
|
|
1662
|
-
const
|
|
1663
|
-
|
|
1664
|
-
const a =
|
|
1624
|
+
const l = document.querySelectorAll(".gloss-panel-mount");
|
|
1625
|
+
l.length > 1 && e.push(`mount-count=${l.length}`);
|
|
1626
|
+
const a = l[0] ?? null, i = a ? a.querySelectorAll(".gloss-panel-chrome") : [];
|
|
1665
1627
|
i.length > 1 && e.push(`chrome-count=${i.length}`);
|
|
1666
1628
|
const u = i[0] ?? null;
|
|
1667
1629
|
if (u) {
|
|
1668
1630
|
const d = u.style.zIndex;
|
|
1669
1631
|
d !== "" && d !== "2" && e.push(`chrome-zindex=${d}`);
|
|
1670
1632
|
}
|
|
1671
|
-
const
|
|
1633
|
+
const o = a ? "present" : "absent", s = u ? "present" : "absent";
|
|
1672
1634
|
return {
|
|
1673
1635
|
valid: e.length === 0,
|
|
1674
|
-
mount:
|
|
1636
|
+
mount: o,
|
|
1675
1637
|
chrome: s,
|
|
1676
1638
|
frozen: t,
|
|
1677
1639
|
orphans: e,
|
|
@@ -1679,19 +1641,19 @@ function ne() {
|
|
|
1679
1641
|
};
|
|
1680
1642
|
}
|
|
1681
1643
|
const Z = "8px 8px 0px", X = "64px", J = "inset(0px 0px 60px 0px)", ee = "inset(0px -40px -40px -40px)";
|
|
1682
|
-
function _(e, t, r,
|
|
1683
|
-
return { id: e, constraint: t, expected: r, actual:
|
|
1644
|
+
function _(e, t, r, l, a) {
|
|
1645
|
+
return { id: e, constraint: t, expected: r, actual: l, pass: a };
|
|
1684
1646
|
}
|
|
1685
|
-
function
|
|
1647
|
+
function M(e) {
|
|
1686
1648
|
const t = parseInt(e, 10);
|
|
1687
1649
|
return Number.isFinite(t) ? t : NaN;
|
|
1688
1650
|
}
|
|
1689
|
-
function
|
|
1690
|
-
const e = [], t = document.querySelector(".gloss-panel-mount"), r = t?.querySelector(".gloss-panel-chrome") ?? null,
|
|
1651
|
+
function oe() {
|
|
1652
|
+
const e = [], t = document.querySelector(".gloss-panel-mount"), r = t?.querySelector(".gloss-panel-chrome") ?? null, l = document.querySelector(".gloss-panel-coordinator") ?? document.querySelector("[data-panel-coordinator]"), a = document.querySelector(".bell-cutout"), i = document.querySelector(".bell-popover"), u = document.querySelector(".gloss-bottom-toolbar");
|
|
1691
1653
|
if (!t)
|
|
1692
1654
|
e.push(_("C1", "mount --reveal-y matches clip-path inset-bottom Npx", "mount present", "absent", !1));
|
|
1693
1655
|
else {
|
|
1694
|
-
const
|
|
1656
|
+
const o = getComputedStyle(t), s = o.getPropertyValue("--reveal-y").trim() || t.style.getPropertyValue("--reveal-y").trim(), c = o.clipPath || t.style.clipPath || "", d = c.match(/inset\(\s*0(?:px)?\s+0(?:px)?\s+(\d+)px\s+0(?:px)?\s*\)/), m = d ? parseInt(d[1], 10) : NaN, h = M(s), b = Number.isFinite(m) && Number.isFinite(h) && m === h;
|
|
1695
1657
|
e.push(
|
|
1696
1658
|
_(
|
|
1697
1659
|
"C1",
|
|
@@ -1705,7 +1667,7 @@ function le() {
|
|
|
1705
1667
|
if (!t)
|
|
1706
1668
|
e.push(_("C2", "mount padding constant", Z, "absent", !1));
|
|
1707
1669
|
else {
|
|
1708
|
-
const
|
|
1670
|
+
const o = t.style.padding, s = getComputedStyle(t), c = o || s.padding || "", d = c === Z || c === "8px 8px 0px 8px";
|
|
1709
1671
|
e.push(_("C2", "mount padding constant", Z, c || "n/a", d));
|
|
1710
1672
|
}
|
|
1711
1673
|
if (!t)
|
|
@@ -1717,11 +1679,11 @@ function le() {
|
|
|
1717
1679
|
if (!r)
|
|
1718
1680
|
e.push(_("C4", "panel-chrome height formula = (row-h*3)+(row-gap*3)-8px", "formula match", "absent", !1));
|
|
1719
1681
|
else {
|
|
1720
|
-
const
|
|
1721
|
-
|
|
1722
|
-
), c =
|
|
1723
|
-
|
|
1724
|
-
), d = s * 3 + c * 3 - 8, m =
|
|
1682
|
+
const o = getComputedStyle(r), s = M(
|
|
1683
|
+
o.getPropertyValue("--row-h").trim() || r.style.getPropertyValue("--row-h").trim() || "0"
|
|
1684
|
+
), c = M(
|
|
1685
|
+
o.getPropertyValue("--row-gap").trim() || r.style.getPropertyValue("--row-gap").trim() || "0"
|
|
1686
|
+
), d = s * 3 + c * 3 - 8, m = M(o.height || r.style.height || ""), h = Number.isFinite(s) && Number.isFinite(c) && Number.isFinite(m) && Number.isFinite(d) && m === d;
|
|
1725
1687
|
e.push(
|
|
1726
1688
|
_(
|
|
1727
1689
|
"C4",
|
|
@@ -1732,30 +1694,30 @@ function le() {
|
|
|
1732
1694
|
)
|
|
1733
1695
|
);
|
|
1734
1696
|
}
|
|
1735
|
-
if (!
|
|
1697
|
+
if (!l || !r)
|
|
1736
1698
|
e.push(
|
|
1737
1699
|
_(
|
|
1738
1700
|
"C5",
|
|
1739
1701
|
'coordinator perspective + origin "center bottom"; chrome perspective-style flat',
|
|
1740
1702
|
"present",
|
|
1741
|
-
`coordinator=${
|
|
1703
|
+
`coordinator=${l ? "present" : "absent"} chrome=${r ? "present" : "absent"}`,
|
|
1742
1704
|
!1
|
|
1743
1705
|
)
|
|
1744
1706
|
);
|
|
1745
1707
|
else {
|
|
1746
|
-
const
|
|
1708
|
+
const o = getComputedStyle(l), s = getComputedStyle(r), c = o.perspective || l.style.perspective || "", d = (o.perspectiveOrigin || l.style.perspectiveOrigin || "").trim(), m = s.perspectiveStyle || r.style.perspectiveStyle || "", y = c !== "" && c !== "none" && (d === "center bottom" || d === "50% 100%") && m === "flat";
|
|
1747
1709
|
e.push(
|
|
1748
1710
|
_(
|
|
1749
1711
|
"C5",
|
|
1750
1712
|
'coordinator perspective + origin "center bottom"; chrome perspective-style flat',
|
|
1751
1713
|
"perspective:not-none, origin:center bottom, chrome-style:flat",
|
|
1752
1714
|
`perspective=${c} origin=${d} chrome-style=${m}`,
|
|
1753
|
-
|
|
1715
|
+
y
|
|
1754
1716
|
)
|
|
1755
1717
|
);
|
|
1756
1718
|
}
|
|
1757
1719
|
{
|
|
1758
|
-
let
|
|
1720
|
+
let o = !1, s = "absent";
|
|
1759
1721
|
try {
|
|
1760
1722
|
for (const c of Array.from(document.styleSheets)) {
|
|
1761
1723
|
let d = [];
|
|
@@ -1766,8 +1728,8 @@ function le() {
|
|
|
1766
1728
|
}
|
|
1767
1729
|
for (const m of d)
|
|
1768
1730
|
if (m.name === "stage-spin") {
|
|
1769
|
-
const b = Array.from(m.cssRules), p = b.find((N) => N.keyText === "0%" || N.keyText === "from"),
|
|
1770
|
-
|
|
1731
|
+
const b = Array.from(m.cssRules), p = b.find((N) => N.keyText === "0%" || N.keyText === "from"), y = b.find((N) => N.keyText === "100%" || N.keyText === "to"), E = p?.style.transform ?? "", T = y?.style.transform ?? "", v = /rotateY\(\s*0(?:deg)?\s*\)/;
|
|
1732
|
+
o = v.test(E) && v.test(T), s = `0%=${E || "n/a"} 100%=${T || "n/a"}`;
|
|
1771
1733
|
break;
|
|
1772
1734
|
}
|
|
1773
1735
|
if (s !== "absent") break;
|
|
@@ -1781,12 +1743,12 @@ function le() {
|
|
|
1781
1743
|
"@keyframes stage-spin 0% AND 100% anchor at rotateY(0)",
|
|
1782
1744
|
"both frames rotateY(0)",
|
|
1783
1745
|
s,
|
|
1784
|
-
|
|
1746
|
+
o
|
|
1785
1747
|
)
|
|
1786
1748
|
);
|
|
1787
1749
|
}
|
|
1788
1750
|
{
|
|
1789
|
-
const
|
|
1751
|
+
const o = document.documentElement, s = getComputedStyle(o), c = s.getPropertyValue("--panel-open-dur").trim() || o.style.getPropertyValue("--panel-open-dur").trim(), d = s.getPropertyValue("--panel-close-dur").trim() || o.style.getPropertyValue("--panel-close-dur").trim(), m = M(c) || parseFloat(c) * (c.endsWith("s") && !c.endsWith("ms") ? 1e3 : 1), h = M(d) || parseFloat(d) * (d.endsWith("s") && !d.endsWith("ms") ? 1e3 : 1), b = Number.isFinite(m) && Number.isFinite(h) && m > h;
|
|
1790
1752
|
e.push(
|
|
1791
1753
|
_("C7", "--panel-open-dur > --panel-close-dur", "open > close", `open=${c || "n/a"} close=${d || "n/a"}`, b)
|
|
1792
1754
|
);
|
|
@@ -1794,7 +1756,7 @@ function le() {
|
|
|
1794
1756
|
if (!a)
|
|
1795
1757
|
e.push(_("C8", "BellCutout zero computed animation/transition", "no inline timing", "absent", !1));
|
|
1796
1758
|
else {
|
|
1797
|
-
const
|
|
1759
|
+
const o = getComputedStyle(a), s = o.animationName || "", c = o.transitionProperty || "", d = (s === "" || s === "none") && (c === "" || c === "none" || c === "all");
|
|
1798
1760
|
e.push(
|
|
1799
1761
|
_(
|
|
1800
1762
|
"C8",
|
|
@@ -1808,33 +1770,33 @@ function le() {
|
|
|
1808
1770
|
if (!t)
|
|
1809
1771
|
e.push(_("C9", "mount closed-state clipPath", J, "absent", !1));
|
|
1810
1772
|
else {
|
|
1811
|
-
const
|
|
1773
|
+
const o = t.style.clipPath, s = getComputedStyle(t), c = o || s.clipPath || "", d = c === J;
|
|
1812
1774
|
e.push(_("C9", "mount closed-state clipPath", J, c || "n/a", d));
|
|
1813
1775
|
}
|
|
1814
1776
|
if (!i)
|
|
1815
1777
|
e.push(_("C10", "bell-popover parentElement === document.body (open)", "body", "absent", !1));
|
|
1816
1778
|
else {
|
|
1817
|
-
const
|
|
1779
|
+
const o = i.parentElement, s = o === document.body;
|
|
1818
1780
|
e.push(
|
|
1819
1781
|
_(
|
|
1820
1782
|
"C10",
|
|
1821
1783
|
"bell-popover parentElement === document.body (open)",
|
|
1822
1784
|
"body",
|
|
1823
|
-
|
|
1785
|
+
o === document.body ? "body" : o?.tagName ?? "n/a",
|
|
1824
1786
|
s
|
|
1825
1787
|
)
|
|
1826
1788
|
);
|
|
1827
1789
|
}
|
|
1828
|
-
if (!
|
|
1790
|
+
if (!l)
|
|
1829
1791
|
e.push(_("C11", "coordinator overflow === visible", "visible", "absent", !1));
|
|
1830
1792
|
else {
|
|
1831
|
-
const s = getComputedStyle(
|
|
1793
|
+
const s = getComputedStyle(l).overflow || l.style.overflow || "", c = s === "visible";
|
|
1832
1794
|
e.push(_("C11", "coordinator overflow === visible", "visible", s || "n/a", c));
|
|
1833
1795
|
}
|
|
1834
1796
|
if (!u)
|
|
1835
1797
|
e.push(_("C12", "toolbar clipPath = inset(0 -40 -40 -40)", ee, "absent", !1));
|
|
1836
1798
|
else {
|
|
1837
|
-
const
|
|
1799
|
+
const o = u.style.clipPath, s = getComputedStyle(u), c = o || s.clipPath || "", d = c === ee;
|
|
1838
1800
|
e.push(_("C12", "toolbar clipPath = inset(0 -40 -40 -40)", ee, c || "n/a", d));
|
|
1839
1801
|
}
|
|
1840
1802
|
return e.push(
|
|
@@ -1856,7 +1818,7 @@ function le() {
|
|
|
1856
1818
|
), e;
|
|
1857
1819
|
}
|
|
1858
1820
|
function mt(e) {
|
|
1859
|
-
return
|
|
1821
|
+
return oe().find((t) => t.id === e);
|
|
1860
1822
|
}
|
|
1861
1823
|
function ht() {
|
|
1862
1824
|
const e = ne();
|
|
@@ -1868,84 +1830,84 @@ function ht() {
|
|
|
1868
1830
|
actual: `valid=${e.valid} mount=${e.mount} chrome=${e.chrome} frozen=${e.frozen} orphans=[${e.orphans.join(",")}]`,
|
|
1869
1831
|
pass: e.valid
|
|
1870
1832
|
}
|
|
1871
|
-
], cc:
|
|
1833
|
+
], cc: oe() };
|
|
1872
1834
|
}
|
|
1873
1835
|
function ft() {
|
|
1874
1836
|
return {
|
|
1875
1837
|
enable: gt,
|
|
1876
1838
|
disable: bt,
|
|
1877
|
-
isEnabled: () =>
|
|
1839
|
+
isEnabled: () => H,
|
|
1878
1840
|
getLastReport: () => j,
|
|
1879
1841
|
recordTransition: (e) => {
|
|
1880
|
-
|
|
1842
|
+
H && (j = { ...e, ...ne() });
|
|
1881
1843
|
},
|
|
1882
1844
|
assertOnce: () => {
|
|
1883
1845
|
const e = ne();
|
|
1884
1846
|
return j = e, e;
|
|
1885
1847
|
},
|
|
1886
|
-
assertCcOnly:
|
|
1848
|
+
assertCcOnly: oe,
|
|
1887
1849
|
getCcRowById: mt,
|
|
1888
1850
|
assertPanelTruths: ht
|
|
1889
1851
|
};
|
|
1890
1852
|
}
|
|
1891
1853
|
function gt() {
|
|
1892
|
-
if (
|
|
1854
|
+
if (H = !0, typeof window > "u") return;
|
|
1893
1855
|
window.__panelsAsserter || (window.__panelsAsserter = ft(), console.info(
|
|
1894
1856
|
"[panels] asserter enabled (P3b Q12-12 + P6 W5 cc:C1..C14). Inspect via window.__panelsAsserter."
|
|
1895
1857
|
));
|
|
1896
1858
|
}
|
|
1897
1859
|
function bt() {
|
|
1898
|
-
|
|
1860
|
+
H = !1;
|
|
1899
1861
|
}
|
|
1900
1862
|
export {
|
|
1901
|
-
|
|
1902
|
-
|
|
1903
|
-
|
|
1904
|
-
|
|
1863
|
+
Ut as COMMITS,
|
|
1864
|
+
At as CatalogAddShell,
|
|
1865
|
+
xt as CatalogFooter,
|
|
1866
|
+
kt as CatalogReplaceShell,
|
|
1905
1867
|
se as CatalogStateContext,
|
|
1906
1868
|
He as CloneCard,
|
|
1907
|
-
|
|
1869
|
+
$t as CloneStage,
|
|
1908
1870
|
ye as MOCK_DEFAULT_LENS,
|
|
1909
1871
|
ve as MOCK_LENSES,
|
|
1910
1872
|
ae as MOCK_LENS_META,
|
|
1911
1873
|
et as MOCK_PAGES,
|
|
1912
1874
|
_e as MOCK_TILES_BY_LENS,
|
|
1913
|
-
|
|
1914
|
-
|
|
1875
|
+
zt as NotificationCenterShell,
|
|
1876
|
+
Lt as PANEL_IDS,
|
|
1915
1877
|
Je as PageMgmtFooter,
|
|
1916
|
-
|
|
1878
|
+
Dt as PageMgmtShell,
|
|
1917
1879
|
Ne as PageMgmtStateContext,
|
|
1918
|
-
|
|
1919
|
-
|
|
1920
|
-
|
|
1921
|
-
|
|
1922
|
-
|
|
1923
|
-
|
|
1924
|
-
|
|
1925
|
-
|
|
1880
|
+
Ht as PanelBody,
|
|
1881
|
+
Vt as PanelChrome,
|
|
1882
|
+
V as PanelChromeV2,
|
|
1883
|
+
Bt as PanelFooter,
|
|
1884
|
+
Et as PanelFooterMessage,
|
|
1885
|
+
Kt as PanelHeader,
|
|
1886
|
+
Yt as PanelHost,
|
|
1887
|
+
Ot as PanelHostShell,
|
|
1926
1888
|
xe as PanelMount,
|
|
1927
|
-
|
|
1928
|
-
|
|
1929
|
-
|
|
1930
|
-
|
|
1931
|
-
|
|
1932
|
-
|
|
1889
|
+
Wt as PanelNavigation,
|
|
1890
|
+
Gt as PanelProvider,
|
|
1891
|
+
Mt as PanelSlot,
|
|
1892
|
+
Qt as PanelStage,
|
|
1893
|
+
Pt as SettingsShell,
|
|
1894
|
+
oe as assertCcOnly,
|
|
1933
1895
|
ne as assertPanelDomShape,
|
|
1934
1896
|
ht as assertPanelTruths,
|
|
1935
|
-
|
|
1897
|
+
qt as deriveSurfaceState,
|
|
1936
1898
|
bt as disablePanelAsserter,
|
|
1937
1899
|
gt as enablePanelAsserter,
|
|
1938
1900
|
mt as getCcRowById,
|
|
1939
|
-
|
|
1901
|
+
jt as initialState,
|
|
1940
1902
|
me as positionKey,
|
|
1941
|
-
|
|
1903
|
+
Zt as reducer,
|
|
1942
1904
|
ut as transitionToPanel,
|
|
1943
1905
|
re as useCatalogState,
|
|
1944
|
-
|
|
1906
|
+
wt as useEditingCardId,
|
|
1945
1907
|
Te as usePageMgmtState,
|
|
1946
1908
|
Pe as usePanelContext,
|
|
1947
|
-
|
|
1948
|
-
|
|
1909
|
+
O as usePanelContextOptional,
|
|
1910
|
+
Xt as usePanelCoordinator,
|
|
1949
1911
|
fe as useReducedMotionPanel,
|
|
1950
|
-
|
|
1912
|
+
It as useTransitionToPanel
|
|
1951
1913
|
};
|