@pygmalionjs/pygmalion 0.5.23 → 0.5.25
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/dist-lib/pygmalion.js
CHANGED
|
@@ -1,9 +1,9 @@
|
|
|
1
1
|
var yh = Object.defineProperty;
|
|
2
2
|
var vh = (e, t, n) => t in e ? yh(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
3
|
var gn = (e, t, n) => vh(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
|
-
import { jsx as s, jsxs as g, Fragment as
|
|
5
|
-
import { R as si, u as wh, c as Ea, b as ud, g as lt, d as Sh, m as Dt, e as f, f as Tt, r as cn, h as Ps, i as Yn, j as ka, k as wn, l as fd, n as wr, p as Nh, o as pr, q as
|
|
6
|
-
import { aY as
|
|
4
|
+
import { jsx as s, jsxs as g, Fragment as Ye } from "react/jsx-runtime";
|
|
5
|
+
import { R as si, u as wh, c as Ea, b as ud, g as lt, d as Sh, m as Dt, e as f, f as Tt, r as cn, h as Ps, i as Yn, j as ka, k as wn, l as fd, n as wr, p as Nh, o as pr, q as Be, t as Ih, v as Ch, w as Ph, x as $h, y as Mh, z as Eh, A as kh, B as $s, C as Ah, D as Rh, E as Th, G as Fh, H as Lh, I as _h, S as Dh, J as zh, K as hd, L as Oh, M as Ms, O as Bh, P as jh, Q as Wh, T as Hh, U as pd, V as Uh, W as Oc, X as Vh, Y as md, Z as Kh, _ as qh, $ as Yh, a0 as Gh, a1 as Xh, a2 as Jh, a3 as gd, a4 as Qh, a5 as Zh, a6 as J, a7 as Bc, a8 as jc, a9 as ep, aa as os, ab as tp, ac as qo, ad as Es, ae as np, af as bd, ag as rp, ah as op, ai as ip, s as sp, aj as ir, ak as xd, al as yd, am as ks, an as vd, ao as ap, ap as cp, aq as Wc, ar as lp, as as dp, at as Hc, au as up, av as fp, aw as hp, ax as pp, ay as mp, az as gp, aA as bp, aB as xp, aC as yp, aD as vp, aE as wp, aF as Sp, a as Np, aG as Ip, aH as Cp, aI as Pp, aJ as $p, aK as Mp, aL as Ep, aM as kp, aN as Ap, aO as Rp, aP as Tp, aQ as Fp, aR as Lp, aS as Uc, aT as _p, aU as Dp, aV as zp, aW as Op, aX as Vc } from "./FrozenRoutePreview-Df_DH4UK.js";
|
|
6
|
+
import { aY as a1, aZ as c1, a_ as l1, a$ as d1, b0 as u1, b1 as f1, b2 as h1, b3 as p1, b4 as m1, b5 as g1, b6 as b1, b7 as x1, b8 as y1, b9 as v1, ba as w1, bb as S1 } from "./FrozenRoutePreview-Df_DH4UK.js";
|
|
7
7
|
import { useRef as Pe, useLayoutEffect as ai, useSyncExternalStore as Xe, useCallback as Pt, useReducer as wd, useEffect as ae, memo as Sd, createElement as ao, useState as Q, useMemo as _t } from "react";
|
|
8
8
|
import { createPortal as Bp } from "react-dom";
|
|
9
9
|
const Aa = {
|
|
@@ -572,7 +572,7 @@ function _i(e) {
|
|
|
572
572
|
c.has(l) || t.push(`Screenshot asset "${l}" is unreferenced.`);
|
|
573
573
|
return { valid: t.length === 0, errors: t, bytes: n };
|
|
574
574
|
}
|
|
575
|
-
function
|
|
575
|
+
function R0(e, t) {
|
|
576
576
|
var o;
|
|
577
577
|
const n = _i(e);
|
|
578
578
|
if (!n.valid)
|
|
@@ -585,7 +585,7 @@ function T0(e, t) {
|
|
|
585
585
|
t
|
|
586
586
|
) : null;
|
|
587
587
|
}
|
|
588
|
-
function
|
|
588
|
+
function T0(e, t) {
|
|
589
589
|
var a;
|
|
590
590
|
const n = _i(e);
|
|
591
591
|
if (!n.valid)
|
|
@@ -2097,7 +2097,7 @@ function ng(e, t) {
|
|
|
2097
2097
|
);
|
|
2098
2098
|
Xn.get(e) !== t && (Xn.set(e, t), tc());
|
|
2099
2099
|
}
|
|
2100
|
-
function
|
|
2100
|
+
function F0() {
|
|
2101
2101
|
Xn.size && (Xn.clear(), tc());
|
|
2102
2102
|
}
|
|
2103
2103
|
function rg() {
|
|
@@ -2660,14 +2660,14 @@ function ji(e = {}) {
|
|
|
2660
2660
|
}
|
|
2661
2661
|
async function k(R, T) {
|
|
2662
2662
|
if (e.prepare) return e.prepare(R, T);
|
|
2663
|
-
const { getDesignImportController: I } = await import("./FrozenRoutePreview-
|
|
2663
|
+
const { getDesignImportController: I } = await import("./FrozenRoutePreview-Df_DH4UK.js").then((F) => F.bd), N = I();
|
|
2664
2664
|
if (!N)
|
|
2665
2665
|
throw new Error("The design import controller is not available.");
|
|
2666
2666
|
return N.prepareScreenCapture(R, T);
|
|
2667
2667
|
}
|
|
2668
2668
|
async function L(R, T) {
|
|
2669
2669
|
if (e.settle) return e.settle(R, T);
|
|
2670
|
-
const { settleScreen: I } = await import("./FrozenRoutePreview-
|
|
2670
|
+
const { settleScreen: I } = await import("./FrozenRoutePreview-Df_DH4UK.js").then((N) => N.bc);
|
|
2671
2671
|
return I(R, T);
|
|
2672
2672
|
}
|
|
2673
2673
|
async function W(R, T) {
|
|
@@ -3274,7 +3274,7 @@ function qg(e) {
|
|
|
3274
3274
|
() => !1
|
|
3275
3275
|
);
|
|
3276
3276
|
}
|
|
3277
|
-
const Yg =
|
|
3277
|
+
const Yg = Be(function({
|
|
3278
3278
|
page: t,
|
|
3279
3279
|
active: n,
|
|
3280
3280
|
onLabelDown: r
|
|
@@ -3335,7 +3335,7 @@ const Yg = ze(function({
|
|
|
3335
3335
|
children: a.code ?? a.title
|
|
3336
3336
|
}
|
|
3337
3337
|
),
|
|
3338
|
-
!d && /* @__PURE__ */ g(
|
|
3338
|
+
!d && /* @__PURE__ */ g(Ye, { children: [
|
|
3339
3339
|
/* @__PURE__ */ g(
|
|
3340
3340
|
"span",
|
|
3341
3341
|
{
|
|
@@ -3726,7 +3726,7 @@ function wi(e, t, n) {
|
|
|
3726
3726
|
}
|
|
3727
3727
|
);
|
|
3728
3728
|
}
|
|
3729
|
-
function
|
|
3729
|
+
function L0({
|
|
3730
3730
|
sourceRevision: e,
|
|
3731
3731
|
recipes: t,
|
|
3732
3732
|
recipeVersion: n,
|
|
@@ -4058,7 +4058,7 @@ function Mb(e) {
|
|
|
4058
4058
|
t.has(r) && n.add(r), t.add(r);
|
|
4059
4059
|
return [...n];
|
|
4060
4060
|
}
|
|
4061
|
-
function
|
|
4061
|
+
function _0(e, t) {
|
|
4062
4062
|
var a;
|
|
4063
4063
|
const n = [], r = new Map(e.map((c) => [c.id, c])), o = /* @__PURE__ */ new Map();
|
|
4064
4064
|
for (const c of e)
|
|
@@ -4133,7 +4133,7 @@ function kb(e, t) {
|
|
|
4133
4133
|
const n = e.split("/"), r = t.split("/");
|
|
4134
4134
|
return n.length !== r.length ? !1 : n.every((o, i) => o.startsWith(":") || o === "*" ? r[i].length > 0 : o === r[i]);
|
|
4135
4135
|
}
|
|
4136
|
-
function
|
|
4136
|
+
function D0(e) {
|
|
4137
4137
|
const t = e.declaredScreens.map((o) => o.route).filter((o) => typeof o == "string").map(cl), n = /* @__PURE__ */ new Set(), r = [];
|
|
4138
4138
|
for (const o of e.routes) {
|
|
4139
4139
|
const i = o.path ?? o.id;
|
|
@@ -4492,7 +4492,7 @@ function Ur({ node: e }) {
|
|
|
4492
4492
|
};
|
|
4493
4493
|
window.addEventListener("mousemove", u), window.addEventListener("mouseup", p);
|
|
4494
4494
|
};
|
|
4495
|
-
return /* @__PURE__ */ g(
|
|
4495
|
+
return /* @__PURE__ */ g(Ye, { children: [
|
|
4496
4496
|
Xb.map((n) => /* @__PURE__ */ s(
|
|
4497
4497
|
"span",
|
|
4498
4498
|
{
|
|
@@ -4551,7 +4551,7 @@ function Vr({ node: e }) {
|
|
|
4551
4551
|
}
|
|
4552
4552
|
);
|
|
4553
4553
|
}
|
|
4554
|
-
const Kr =
|
|
4554
|
+
const Kr = Be(function({ count: t }) {
|
|
4555
4555
|
return f.showRenderCount ? /* @__PURE__ */ s(
|
|
4556
4556
|
"span",
|
|
4557
4557
|
{
|
|
@@ -4821,7 +4821,11 @@ function ei(e, t = !1) {
|
|
|
4821
4821
|
...e.domStyle.position === "fixed" ? { position: "absolute" } : {},
|
|
4822
4822
|
opacity: e.opacity,
|
|
4823
4823
|
...e.fill ? { background: e.fill, backgroundColor: e.fill } : {},
|
|
4824
|
-
|
|
4824
|
+
// `radius` is one number, so applying it over a captured style would round
|
|
4825
|
+
// corners the capture had deliberately flattened — a bar that shares its
|
|
4826
|
+
// bottom edge with the input below it came back with the seam visible.
|
|
4827
|
+
// The captured corners win when there are any.
|
|
4828
|
+
...e.radius && e.domStyle.borderTopLeftRadius == null ? { borderRadius: e.radius } : {},
|
|
4825
4829
|
...t ? { pointerEvents: "none" } : {}
|
|
4826
4830
|
}, i = Ku.has(e.domTag) ? void 0 : e.children.map((a) => ei(a));
|
|
4827
4831
|
return ao(
|
|
@@ -4852,7 +4856,7 @@ function ei(e, t = !1) {
|
|
|
4852
4856
|
e.id
|
|
4853
4857
|
);
|
|
4854
4858
|
}
|
|
4855
|
-
const hl =
|
|
4859
|
+
const hl = Be(function({
|
|
4856
4860
|
root: t
|
|
4857
4861
|
}) {
|
|
4858
4862
|
return ei(t, !0);
|
|
@@ -5004,7 +5008,7 @@ function sf() {
|
|
|
5004
5008
|
}
|
|
5005
5009
|
return e;
|
|
5006
5010
|
}
|
|
5007
|
-
const rx =
|
|
5011
|
+
const rx = Be(function({
|
|
5008
5012
|
def: t,
|
|
5009
5013
|
name: n
|
|
5010
5014
|
}) {
|
|
@@ -5128,7 +5132,7 @@ const rx = ze(function({
|
|
|
5128
5132
|
]
|
|
5129
5133
|
}
|
|
5130
5134
|
);
|
|
5131
|
-
}), ox =
|
|
5135
|
+
}), ox = Be(function({
|
|
5132
5136
|
section: t,
|
|
5133
5137
|
origin: n
|
|
5134
5138
|
}) {
|
|
@@ -5136,7 +5140,7 @@ const rx = ze(function({
|
|
|
5136
5140
|
const r = f.canvasPages.filter(
|
|
5137
5141
|
(a) => a.section === t && f.isScreenStateShown(a)
|
|
5138
5142
|
), o = hd(t, r), i = Ms;
|
|
5139
|
-
return /* @__PURE__ */ s(
|
|
5143
|
+
return /* @__PURE__ */ s(Ye, { children: o.map((a) => {
|
|
5140
5144
|
const c = Oh(t, a.laneId);
|
|
5141
5145
|
if (!c) return null;
|
|
5142
5146
|
const l = a.frames.filter(
|
|
@@ -5202,7 +5206,7 @@ const rx = ze(function({
|
|
|
5202
5206
|
a.laneId
|
|
5203
5207
|
);
|
|
5204
5208
|
}) });
|
|
5205
|
-
}), ix =
|
|
5209
|
+
}), ix = Be(function() {
|
|
5206
5210
|
const t = f.sectionRenameTarget, n = (i, a) => {
|
|
5207
5211
|
f.renameSection(f.activeCanvas, i, a), f.setSectionRenameTarget(null);
|
|
5208
5212
|
}, r = (i, a) => (c) => {
|
|
@@ -5247,7 +5251,7 @@ const rx = ze(function({
|
|
|
5247
5251
|
};
|
|
5248
5252
|
window.addEventListener("mousemove", x), window.addEventListener("mouseup", w);
|
|
5249
5253
|
};
|
|
5250
|
-
return /* @__PURE__ */ s(
|
|
5254
|
+
return /* @__PURE__ */ s(Ye, { children: [...sf().entries()].map(([i, a]) => {
|
|
5251
5255
|
var u;
|
|
5252
5256
|
const c = nx(a, of(i)), l = Bh(i), d = ((u = f.selectedCanvasObject) == null ? void 0 : u.kind) === "section" && f.selectedCanvasObject.name === i;
|
|
5253
5257
|
return /* @__PURE__ */ g(
|
|
@@ -5958,7 +5962,7 @@ async function vx(e, t) {
|
|
|
5958
5962
|
});
|
|
5959
5963
|
return Oo.set(r, i), i;
|
|
5960
5964
|
}
|
|
5961
|
-
const wx =
|
|
5965
|
+
const wx = Be(function({
|
|
5962
5966
|
page: t,
|
|
5963
5967
|
snapshot: n,
|
|
5964
5968
|
artifact: r,
|
|
@@ -6252,7 +6256,7 @@ function Ax(e, t) {
|
|
|
6252
6256
|
}
|
|
6253
6257
|
}, [t, e]);
|
|
6254
6258
|
}
|
|
6255
|
-
const Rx =
|
|
6259
|
+
const Rx = Be(function({
|
|
6256
6260
|
page: t,
|
|
6257
6261
|
active: n,
|
|
6258
6262
|
selected: r,
|
|
@@ -6344,7 +6348,7 @@ const Rx = ze(function({
|
|
|
6344
6348
|
}, [t.layersImported, t.id]);
|
|
6345
6349
|
const [Me, ue] = Q(!1), K = n || r || P || st || Me, Ie = Px(t.id, K), ve = $x(t.id);
|
|
6346
6350
|
Ax(t.id, Ie);
|
|
6347
|
-
const [V, Ne] = Q(null), [re, U] = Q(0), [oe, ne] = Q([]), We = Le ?? (A && !M ? nn(ee) : null),
|
|
6351
|
+
const [V, Ne] = Q(null), [re, U] = Q(0), [oe, ne] = Q([]), We = Le ?? (A && !M ? nn(ee) : null), ze = M != null || We != null || ($ == null ? void 0 : $.screenshot) != null, le = n, Ge = a && Jd({
|
|
6348
6352
|
detailActive: le,
|
|
6349
6353
|
previewIntended: P
|
|
6350
6354
|
}), He = _t(() => !r || t.route == null || !t.layersImported ? null : Ae === ee && We != null ? We : nn(Ae) ?? We, [
|
|
@@ -6355,7 +6359,7 @@ const Rx = ze(function({
|
|
|
6355
6359
|
t.route,
|
|
6356
6360
|
ee,
|
|
6357
6361
|
r
|
|
6358
|
-
]),
|
|
6362
|
+
]), Oe = gg(
|
|
6359
6363
|
He != null,
|
|
6360
6364
|
bg({
|
|
6361
6365
|
resizeDraftActive: S != null,
|
|
@@ -6453,7 +6457,7 @@ const Rx = ze(function({
|
|
|
6453
6457
|
);
|
|
6454
6458
|
}, [A, a, ee]), ae(() => {
|
|
6455
6459
|
var Ce, ke;
|
|
6456
|
-
if (!A || t.route == null || t.layersImported ||
|
|
6460
|
+
if (!A || t.route == null || t.layersImported || ze || V || !Ge)
|
|
6457
6461
|
return;
|
|
6458
6462
|
let Y = !0, ge = null;
|
|
6459
6463
|
const ye = (we) => {
|
|
@@ -6516,7 +6520,7 @@ const Rx = ze(function({
|
|
|
6516
6520
|
re,
|
|
6517
6521
|
ee,
|
|
6518
6522
|
$e,
|
|
6519
|
-
|
|
6523
|
+
ze,
|
|
6520
6524
|
Ge
|
|
6521
6525
|
]), ae(() => {
|
|
6522
6526
|
const Y = We != null && go(ee);
|
|
@@ -6574,7 +6578,7 @@ const Rx = ze(function({
|
|
|
6574
6578
|
// here regardless was the bypass that let a live boot — against a dead
|
|
6575
6579
|
// backend, a cold dev server — deliver the import a healthy capture
|
|
6576
6580
|
// already covered.
|
|
6577
|
-
Ke || t.route == null || t.layersImported || !
|
|
6581
|
+
Ke || t.route == null || t.layersImported || !ze || V)
|
|
6578
6582
|
return;
|
|
6579
6583
|
let Y = !0;
|
|
6580
6584
|
const ge = `detail:${$e}`;
|
|
@@ -6601,14 +6605,14 @@ const Rx = ze(function({
|
|
|
6601
6605
|
le,
|
|
6602
6606
|
A,
|
|
6603
6607
|
Ke,
|
|
6604
|
-
|
|
6608
|
+
ze,
|
|
6605
6609
|
t.importLayers,
|
|
6606
6610
|
t.layersImported,
|
|
6607
6611
|
t.route,
|
|
6608
6612
|
V,
|
|
6609
6613
|
$e
|
|
6610
6614
|
]), ae(() => {
|
|
6611
|
-
!G || !A || t.route == null || t.layersImported ||
|
|
6615
|
+
!G || !A || t.route == null || t.layersImported || ze || V || gi(
|
|
6612
6616
|
ee,
|
|
6613
6617
|
-1e3,
|
|
6614
6618
|
async () => null,
|
|
@@ -6623,7 +6627,7 @@ const Rx = ze(function({
|
|
|
6623
6627
|
V,
|
|
6624
6628
|
ee,
|
|
6625
6629
|
$e,
|
|
6626
|
-
|
|
6630
|
+
ze
|
|
6627
6631
|
]);
|
|
6628
6632
|
const sn = c.trim().length > 0, z = sn && ac(t, { detailActive: le }) ? sc({
|
|
6629
6633
|
origin: c,
|
|
@@ -6778,11 +6782,11 @@ const Rx = ze(function({
|
|
|
6778
6782
|
}), j(null);
|
|
6779
6783
|
};
|
|
6780
6784
|
window.addEventListener("mousemove", rt), window.addEventListener("mouseup", Zt);
|
|
6781
|
-
}, nt = t.frameSizeMode === "content" || le || G && Ie !== "detached",
|
|
6785
|
+
}, nt = t.frameSizeMode === "content" || le || G && Ie !== "detached", qe = Od({
|
|
6782
6786
|
hasRoute: t.route != null,
|
|
6783
6787
|
layersImported: !!t.layersImported,
|
|
6784
6788
|
cacheHydrated: A,
|
|
6785
|
-
hasSnapshot:
|
|
6789
|
+
hasSnapshot: ze,
|
|
6786
6790
|
// A grant only counts while there is somewhere to run. Without a live origin
|
|
6787
6791
|
// the frame stayed "live" — so it never fell back to the capture it already
|
|
6788
6792
|
// had, and showed "reproducing" forever in front of its own snapshot.
|
|
@@ -6791,7 +6795,7 @@ const Rx = ze(function({
|
|
|
6791
6795
|
t.id
|
|
6792
6796
|
), Nt = !t.layersImported || Rr != null, at = (
|
|
6793
6797
|
// No live origin means no prepared checkout — see liveOriginReady.
|
|
6794
|
-
sn && a && (zt ||
|
|
6798
|
+
sn && a && (zt || qe === "live" || Me || (le && !Ke || // Hover intent while the artifact cache is still hydrating — or a
|
|
6795
6799
|
// flow session owes this screen — must not warm-boot the app: the
|
|
6796
6800
|
// capture that makes the boot unnecessary may simply not have
|
|
6797
6801
|
// arrived yet. Intent prepares the frozen mount.
|
|
@@ -6805,7 +6809,7 @@ const Rx = ze(function({
|
|
|
6805
6809
|
// so its live producer boots offscreen.
|
|
6806
6810
|
active: (le || P) && Rr == null,
|
|
6807
6811
|
live: at
|
|
6808
|
-
}), fn = !o &&
|
|
6812
|
+
}), fn = !o && ze && // A live slot only outranks the capture while live can actually run. The
|
|
6809
6813
|
// frame the designer works in claims a slot as soon as it is active, so
|
|
6810
6814
|
// before a checkout exists that claim suppressed the static surface and the
|
|
6811
6815
|
// live route could not render either — the frame sat empty in front of the
|
|
@@ -6819,7 +6823,7 @@ const Rx = ze(function({
|
|
|
6819
6823
|
// that arrived without the hover mounts it here and promotes on mount.
|
|
6820
6824
|
preparedForPromotion: P || Ke,
|
|
6821
6825
|
preferDom: Kh() === "dom"
|
|
6822
|
-
}), wo = t.layersImported && f.pageRequiresLiveSharedPreview(t), qi =
|
|
6826
|
+
}), wo = t.layersImported && f.pageRequiresLiveSharedPreview(t), qi = ze && f.frozenPreviewMutations().some((Y) => !!Y.staleReason);
|
|
6823
6827
|
ae(() => {
|
|
6824
6828
|
if (t.frameSizeMode !== "content" || !nt)
|
|
6825
6829
|
return;
|
|
@@ -6916,7 +6920,7 @@ const Rx = ze(function({
|
|
|
6916
6920
|
},
|
|
6917
6921
|
`live:${t.id}`
|
|
6918
6922
|
) : null;
|
|
6919
|
-
return /* @__PURE__ */ g(
|
|
6923
|
+
return /* @__PURE__ */ g(Ye, { children: [
|
|
6920
6924
|
/* @__PURE__ */ g(
|
|
6921
6925
|
"div",
|
|
6922
6926
|
{
|
|
@@ -6925,10 +6929,10 @@ const Rx = ze(function({
|
|
|
6925
6929
|
"data-canonical-frame-id": t.importPageId ?? t.id,
|
|
6926
6930
|
"data-frame-active": n || void 0,
|
|
6927
6931
|
"data-frame-detail-active": le || void 0,
|
|
6928
|
-
"data-preview-state":
|
|
6932
|
+
"data-preview-state": qe,
|
|
6929
6933
|
"data-pyg-static-surface": Tr,
|
|
6930
6934
|
"data-pyg-static-route": String(fn),
|
|
6931
|
-
"data-pyg-has-snapshot": String(
|
|
6935
|
+
"data-pyg-has-snapshot": String(ze),
|
|
6932
6936
|
"data-pyg-artifact": String(M != null),
|
|
6933
6937
|
"data-pyg-live-slot": String(!!zt),
|
|
6934
6938
|
"data-pyg-background-only": String(o),
|
|
@@ -6937,12 +6941,12 @@ const Rx = ze(function({
|
|
|
6937
6941
|
"data-frame-lod": Ie,
|
|
6938
6942
|
"data-artifact-status": $ == null ? void 0 : $.status,
|
|
6939
6943
|
"data-artifact-resolution": Se.status,
|
|
6940
|
-
"data-preview-exact":
|
|
6944
|
+
"data-preview-exact": ze && ($ == null ? void 0 : $.stale) !== !0 ? "true" : "false",
|
|
6941
6945
|
"data-live-preview": at || void 0,
|
|
6942
6946
|
"data-preview-intent": P || void 0,
|
|
6943
6947
|
"data-preview-stale": oe.length > 0 || qi || ($ == null ? void 0 : $.stale) || void 0,
|
|
6944
6948
|
"data-responsive-resizing": S != null || void 0,
|
|
6945
|
-
"data-responsive-preview":
|
|
6949
|
+
"data-responsive-preview": Oe || void 0,
|
|
6946
6950
|
"data-viewport-width": Math.round(T),
|
|
6947
6951
|
"data-viewport-height": Math.round(I),
|
|
6948
6952
|
"data-background-preview": o || void 0,
|
|
@@ -7087,7 +7091,7 @@ const Rx = ze(function({
|
|
|
7087
7091
|
// page imported, and the frame then shows the authored placeholder —
|
|
7088
7092
|
// one empty div — while a 453KB snapshot of the real screen sits
|
|
7089
7093
|
// unused beside it. Measured: layerImportCount 1, snapshot present.
|
|
7090
|
-
(t.layerImportCount == null || t.layerImportCount > 1) && nt && (le || t.route == null || wo) ? le ?
|
|
7094
|
+
(t.layerImportCount == null || t.layerImportCount > 1) && nt && (le || t.route == null || wo) ? le ? Oe && He != null ? /* @__PURE__ */ s(
|
|
7091
7095
|
Vh,
|
|
7092
7096
|
{
|
|
7093
7097
|
page: t,
|
|
@@ -7403,10 +7407,10 @@ ${o.join(`
|
|
|
7403
7407
|
Sl = i;
|
|
7404
7408
|
}
|
|
7405
7409
|
}
|
|
7406
|
-
function
|
|
7410
|
+
function z0() {
|
|
7407
7411
|
return [...Er.values()].map(Vi);
|
|
7408
7412
|
}
|
|
7409
|
-
function
|
|
7413
|
+
function O0(e) {
|
|
7410
7414
|
const t = Er.get(e);
|
|
7411
7415
|
return t ? Vi(t) : void 0;
|
|
7412
7416
|
}
|
|
@@ -7466,7 +7470,7 @@ function ff() {
|
|
|
7466
7470
|
)
|
|
7467
7471
|
);
|
|
7468
7472
|
}
|
|
7469
|
-
function
|
|
7473
|
+
function B0(e, t = {}) {
|
|
7470
7474
|
const n = Er.get(e);
|
|
7471
7475
|
if (!n)
|
|
7472
7476
|
throw new Error(`Unknown component connection "${e}".`);
|
|
@@ -7783,12 +7787,12 @@ function Xx(e) {
|
|
|
7783
7787
|
function xf() {
|
|
7784
7788
|
return [...Mi.entries()].map(([e, t]) => ({ name: e, value: t }));
|
|
7785
7789
|
}
|
|
7786
|
-
function
|
|
7790
|
+
function j0(e, t) {
|
|
7787
7791
|
Mi.set(e, t), document.documentElement.style.setProperty(e, t);
|
|
7788
7792
|
const n = xf();
|
|
7789
7793
|
qn == null || qn(n), mf(n);
|
|
7790
7794
|
}
|
|
7791
|
-
function
|
|
7795
|
+
function W0() {
|
|
7792
7796
|
for (const e of Mi.keys()) document.documentElement.style.removeProperty(e);
|
|
7793
7797
|
Mi.clear(), qn == null || qn([]), mf([]);
|
|
7794
7798
|
}
|
|
@@ -8258,11 +8262,11 @@ function Tl({
|
|
|
8258
8262
|
const re = Pe(n);
|
|
8259
8263
|
re.current = n;
|
|
8260
8264
|
const U = J.buildApplyPayload(), oe = JSON.stringify(U), ne = oy(U), We = JSON.stringify(ne);
|
|
8261
|
-
function
|
|
8265
|
+
function ze() {
|
|
8262
8266
|
var h;
|
|
8263
8267
|
(h = ve.current) == null || h.cleanup(), ve.current = null;
|
|
8264
8268
|
}
|
|
8265
|
-
const le = !!e, Ge = le ? ((Fc = e.current) == null ? void 0 : Fc.contentDocument) ?? null : ((Lc = t == null ? void 0 : t.current) == null ? void 0 : Lc.ownerDocument) ?? null, He = (Ge == null ? void 0 : Ge.defaultView) ?? null,
|
|
8269
|
+
const le = !!e, Ge = le ? ((Fc = e.current) == null ? void 0 : Fc.contentDocument) ?? null : ((Lc = t == null ? void 0 : t.current) == null ? void 0 : Lc.ownerDocument) ?? null, He = (Ge == null ? void 0 : Ge.defaultView) ?? null, Oe = _t(() => Ea(lt()), []), Ue = _t(
|
|
8266
8270
|
() => Object.entries(lt()).filter(
|
|
8267
8271
|
([h, y]) => /^[A-Z][A-Za-z0-9_$]*$/.test(h) && !!y.importPath && Bc(h) != null
|
|
8268
8272
|
).sort(([h], [y]) => h.localeCompare(y)),
|
|
@@ -8317,18 +8321,18 @@ function Tl({
|
|
|
8317
8321
|
y = !0;
|
|
8318
8322
|
};
|
|
8319
8323
|
}, [We]), ae(() => K(), [a]), ae(() => {
|
|
8320
|
-
|
|
8324
|
+
ze(), E(null), L("original"), q("default"), j("item"), F(null), he(""), xe(""), Me(a ? jc(a) ?? 0 : 0);
|
|
8321
8325
|
}, [a]), ae(() => {
|
|
8322
|
-
|
|
8326
|
+
ze();
|
|
8323
8327
|
const h = a != null && a.isConnected ? a : null;
|
|
8324
8328
|
if (h) {
|
|
8325
8329
|
if (v == null && k === "original" && W === "default") {
|
|
8326
8330
|
window.requestAnimationFrame(() => K());
|
|
8327
8331
|
return;
|
|
8328
8332
|
}
|
|
8329
|
-
return ve.current = fy(h, { repeat: v, text: k, state: W }), K(), () =>
|
|
8333
|
+
return ve.current = fy(h, { repeat: v, text: k, state: W }), K(), () => ze();
|
|
8330
8334
|
}
|
|
8331
|
-
}, [a, v, k, W]), ae(() => () =>
|
|
8335
|
+
}, [a, v, k, W]), ae(() => () => ze(), []), ae(() => {
|
|
8332
8336
|
const h = [window];
|
|
8333
8337
|
le && He && He !== window && h.push(He), !le && (t != null && t.current) && h.push(t.current);
|
|
8334
8338
|
const y = () => K();
|
|
@@ -8395,7 +8399,7 @@ function Tl({
|
|
|
8395
8399
|
const y = (C = r.current) == null ? void 0 : C.getBoundingClientRect();
|
|
8396
8400
|
return { left: h.left - ((y == null ? void 0 : y.left) ?? 0), top: h.top - ((y == null ? void 0 : y.top) ?? 0), width: h.width, height: h.height };
|
|
8397
8401
|
}, dt = (h) => {
|
|
8398
|
-
const y =
|
|
8402
|
+
const y = Oe(h);
|
|
8399
8403
|
if (y) return y.name;
|
|
8400
8404
|
const C = vf(h), H = h.tagName.toLowerCase();
|
|
8401
8405
|
return C ? `${H}.${C}` : H;
|
|
@@ -8465,14 +8469,14 @@ function Tl({
|
|
|
8465
8469
|
} catch (D) {
|
|
8466
8470
|
J.toast(`Apply failed:${String(D).slice(0, 80)}`);
|
|
8467
8471
|
}
|
|
8468
|
-
}, z = a != null && a.isConnected ? a : null, Sn = o != null && o.isConnected ? o : null, pe = z != null && z.parentElement && z.parentElement !== Ve ? z.parentElement : null, St = S === "container" && pe ? pe : z, Z = z ? pt(z.getBoundingClientRect()) : null, X = pe ? pt(pe.getBoundingClientRect()) : null, Jn = S === "container" && St && St !== z ? pt(St.getBoundingClientRect()) : null, vo = Sn && Sn !== z ? pt(Sn.getBoundingClientRect()) : null, nt = z ? He.getComputedStyle(z) : null,
|
|
8472
|
+
}, z = a != null && a.isConnected ? a : null, Sn = o != null && o.isConnected ? o : null, pe = z != null && z.parentElement && z.parentElement !== Ve ? z.parentElement : null, St = S === "container" && pe ? pe : z, Z = z ? pt(z.getBoundingClientRect()) : null, X = pe ? pt(pe.getBoundingClientRect()) : null, Jn = S === "container" && St && St !== z ? pt(St.getBoundingClientRect()) : null, vo = Sn && Sn !== z ? pt(Sn.getBoundingClientRect()) : null, nt = z ? He.getComputedStyle(z) : null, qe = pe ? He.getComputedStyle(pe) : null, Rr = St ? He.getComputedStyle(St) : null, Nt = z ? dt(z) : "", at = z ? Oe(z) : null, Qt = z ? ep(z) : null, fn = z ? J.structuralEditKind(z) : null, Tr = z ? J.hasPendingValueEdit(z) : !1, wo = z ? J.structuralBlockReason(z, "insert") : "No elements are selected.", qi = z ? J.structuralBlockReason(z, "remove") : "No elements are selected.", Fr = z ? J.structuralBlockReason(z, "move") : "No elements are selected.", Qn = z && z.parentElement ? Array.from(z.parentElement.children).indexOf(z) : -1, Zn = ((_c = z == null ? void 0 : z.parentElement) == null ? void 0 : _c.children.length) ?? 0, Lr = at ? lt()[at.name] ?? null : null, Y = Qt && /^[A-Z]/.test(Qt.elementName) ? (at == null ? void 0 : at.name) ?? null : null, ge = z ? J.componentInsertBlockReason(z, Y) : "No elements are selected.", ye = _.trim().toLocaleLowerCase(), Re = Ue.filter(
|
|
8469
8473
|
([h, y]) => !ye || h.toLocaleLowerCase().includes(ye) || y.importPath.toLocaleLowerCase().includes(ye)
|
|
8470
8474
|
), Ce = Re.find(([h]) => h === te) ?? Re[0] ?? null, ke = (Ce == null ? void 0 : Ce[1]) ?? null, we = Ce ? Bc(Ce[0]) : null, rt = (z ? jc(z) : null) ?? 0, Zt = z ? dy(z, (at == null ? void 0 : at.props) ?? null, Lr) : !1, Mt = z ? uy(z, (at == null ? void 0 : at.props) ?? null, Lr) : [], er = z ? wf(z) : [], Ut = { count: er.length }, mt = Ae && z && Sn && Sn !== z ? [z, Sn] : null, En = J.entries, So = Object.entries((at == null ? void 0 : at.primitiveProps) ?? {}), hn = U, en = En.reduce((h, y) => {
|
|
8471
8475
|
const C = h.find((H) => H.el === y.el);
|
|
8472
8476
|
return C ? (C.label = y.label, C.items.push(y)) : h.push({ id: y.id, el: y.el, label: y.label, items: [y] }), h;
|
|
8473
8477
|
}, []), tr = hn.styles.length + hn.texts.length + hn.operations.length, No = qo() != null, Yi = No && A !== oe, Gf = en.filter(
|
|
8474
8478
|
(h) => h.items.some((y) => !os(y))
|
|
8475
|
-
).length, Gi = v != null || k !== "original" || W !== "default", _r = Gi && z ? gy(z, He) : null, Qe = py(
|
|
8479
|
+
).length, Gi = v != null || k !== "original" || W !== "default", _r = Gi && z ? gy(z, He) : null, Qe = py(qe), nr = Qe != null, Et = my(pe), pn = G === "custom" ? T.minWidth != null || T.maxWidth != null ? {
|
|
8476
8480
|
...T.minWidth != null ? { minWidth: Math.max(0, Math.round(T.minWidth)) } : {},
|
|
8477
8481
|
...T.maxWidth != null ? { maxWidth: Math.max(0, Math.round(T.maxWidth)) } : {}
|
|
8478
8482
|
} : null : ((Dc = El.find((h) => h.id === G)) == null ? void 0 : Dc.media) ?? null, Xi = er.filter((h) => h.isConnected && He.getComputedStyle(h).getPropertyValue("display") !== "none").map((h, y) => ({ el: h, index: y, rect: pt(h.getBoundingClientRect()) })).filter(({ rect: h }) => h.width > 0 && h.height > 0), Ji = Xi.slice().sort((h, y) => h.rect.top - y.rect.top || h.rect.left - y.rect.left).reduce((h, y) => {
|
|
@@ -8498,12 +8502,12 @@ function Tl({
|
|
|
8498
8502
|
width: Math.max(16, Math.min(h.right, C.right) - Math.max(h.left, C.left)),
|
|
8499
8503
|
height: Math.max(0, C.top - h.bottom)
|
|
8500
8504
|
};
|
|
8501
|
-
}), mn = Math.max(0, Ot(
|
|
8502
|
-
top: Math.max(0, Ot(
|
|
8503
|
-
right: Math.max(0, Ot(
|
|
8504
|
-
bottom: Math.max(0, Ot(
|
|
8505
|
-
left: Math.max(0, Ot(
|
|
8506
|
-
}, Qf = kt.left, Zf = kt.top, zr = (
|
|
8505
|
+
}), mn = Math.max(0, Ot(qe, "column-gap", Ot(qe, "gap"))), Dr = Math.max(0, Ot(qe, "row-gap", Ot(qe, "gap"))), kt = {
|
|
8506
|
+
top: Math.max(0, Ot(qe, "padding-top")),
|
|
8507
|
+
right: Math.max(0, Ot(qe, "padding-right")),
|
|
8508
|
+
bottom: Math.max(0, Ot(qe, "padding-bottom")),
|
|
8509
|
+
left: Math.max(0, Ot(qe, "padding-left"))
|
|
8510
|
+
}, Qf = kt.left, Zf = kt.top, zr = (qe == null ? void 0 : qe.getPropertyValue("justify-content")) || "normal", Nc = (qe == null ? void 0 : qe.getPropertyValue("align-items")) || "normal", Qi = (qe == null ? void 0 : qe.getPropertyValue("flex-direction")) || "row", eh = Rl(Qi.includes("column") ? Nc : zr), th = Rl(Qi.includes("column") ? zr : Nc), nh = jo(
|
|
8507
8511
|
(pe == null ? void 0 : pe.style.getPropertyValue("width")) || (X && X.width >= window.innerWidth * 0.8 ? "100%" : ""),
|
|
8508
8512
|
(X == null ? void 0 : X.width) ?? 0
|
|
8509
8513
|
), rh = jo(
|
|
@@ -8524,7 +8528,7 @@ function Tl({
|
|
|
8524
8528
|
), es = Math.max(
|
|
8525
8529
|
0,
|
|
8526
8530
|
(Io - mn * Math.max(0, It - 1)) / It
|
|
8527
|
-
), $c = Math.max(80, Math.floor(es)), lh = es < 160, Mc = Qe === "grid" && Et === It, dh = Qe === "scroll" ? `${It} items · horizontal scroll · ${Math.round(Pc)}px cards` : `${It} items · ${ch} rows × ${Co} columns · about ${Math.round(Pc)}px each`, uh = u === "cases" && !m && !!pe && !!X && !!Z, kn = !!pe && pe.scrollWidth > pe.clientWidth + 1 && !["auto", "scroll"].includes((
|
|
8531
|
+
), $c = Math.max(80, Math.floor(es)), lh = es < 160, Mc = Qe === "grid" && Et === It, dh = Qe === "scroll" ? `${It} items · horizontal scroll · ${Math.round(Pc)}px cards` : `${It} items · ${ch} rows × ${Co} columns · about ${Math.round(Pc)}px each`, uh = u === "cases" && !m && !!pe && !!X && !!Z, kn = !!pe && pe.scrollWidth > pe.clientWidth + 1 && !["auto", "scroll"].includes((qe == null ? void 0 : qe.getPropertyValue("overflow-x")) ?? ""), Ec = [
|
|
8528
8532
|
v != null ? `${v} items` : null,
|
|
8529
8533
|
k === "long" ? "long text" : k === "extreme" ? "extreme text" : null,
|
|
8530
8534
|
W === "selected" ? "selection status" : W === "disabled" ? "inactive" : W === "loading" ? "loading status" : null
|
|
@@ -8752,7 +8756,7 @@ function Tl({
|
|
|
8752
8756
|
}
|
|
8753
8757
|
),
|
|
8754
8758
|
vo && !l && /* @__PURE__ */ s("div", { style: Ao(vo, "#7cc4f8", !0) }),
|
|
8755
|
-
Jn && St && /* @__PURE__ */ g(
|
|
8759
|
+
Jn && St && /* @__PURE__ */ g(Ye, { children: [
|
|
8756
8760
|
/* @__PURE__ */ s("div", { style: Ao(Jn, "#9747ff", !0) }),
|
|
8757
8761
|
/* @__PURE__ */ g(
|
|
8758
8762
|
"div",
|
|
@@ -8766,7 +8770,7 @@ function Tl({
|
|
|
8766
8770
|
}
|
|
8767
8771
|
)
|
|
8768
8772
|
] }),
|
|
8769
|
-
Z && /* @__PURE__ */ g(
|
|
8773
|
+
Z && /* @__PURE__ */ g(Ye, { children: [
|
|
8770
8774
|
/* @__PURE__ */ s("div", { style: Ao(Z, "#0d99ff") }),
|
|
8771
8775
|
/* @__PURE__ */ s(
|
|
8772
8776
|
"div",
|
|
@@ -8806,7 +8810,7 @@ function Tl({
|
|
|
8806
8810
|
C
|
|
8807
8811
|
))
|
|
8808
8812
|
] }),
|
|
8809
|
-
uh && X && /* @__PURE__ */ g(
|
|
8813
|
+
uh && X && /* @__PURE__ */ g(Ye, { children: [
|
|
8810
8814
|
/* @__PURE__ */ s("div", { style: Ao(X, kn ? "#f24822" : "#9747ff", !0) }),
|
|
8811
8815
|
/* @__PURE__ */ g(
|
|
8812
8816
|
"div",
|
|
@@ -9015,7 +9019,7 @@ function Tl({
|
|
|
9015
9019
|
)
|
|
9016
9020
|
] }, y);
|
|
9017
9021
|
}),
|
|
9018
|
-
Z && /* @__PURE__ */ g(
|
|
9022
|
+
Z && /* @__PURE__ */ g(Ye, { children: [
|
|
9019
9023
|
/* @__PURE__ */ s(
|
|
9020
9024
|
"button",
|
|
9021
9025
|
{
|
|
@@ -9184,7 +9188,7 @@ function Tl({
|
|
|
9184
9188
|
] })
|
|
9185
9189
|
] })
|
|
9186
9190
|
] }),
|
|
9187
|
-
!m && /* @__PURE__ */ s(
|
|
9191
|
+
!m && /* @__PURE__ */ s(Ye, { children: (!z || !nt) && u !== "source" ? /* @__PURE__ */ g("div", { className: "flex min-h-0 flex-1 flex-col", children: [
|
|
9188
9192
|
/* @__PURE__ */ s("div", { className: "px-4 py-8 text-center text-[12px] leading-relaxed text-[#71717a]", children: "Select an element on the canvas." }),
|
|
9189
9193
|
en.length > 0 && /* @__PURE__ */ g(
|
|
9190
9194
|
"button",
|
|
@@ -9299,7 +9303,7 @@ function Tl({
|
|
|
9299
9303
|
className: `h-7 rounded-md text-[10px] font-semibold ${v === h ? "bg-[#0d99ff] text-white" : "bg-[#f4f4f5] text-[#52525b] hover:bg-[#e9e9ee]"}`,
|
|
9300
9304
|
onClick: () => {
|
|
9301
9305
|
if (h == null) {
|
|
9302
|
-
|
|
9306
|
+
ze(), E(null), K();
|
|
9303
9307
|
return;
|
|
9304
9308
|
}
|
|
9305
9309
|
Po(h);
|
|
@@ -9449,7 +9453,7 @@ function Tl({
|
|
|
9449
9453
|
children: nr ? "Applied" : "+ add"
|
|
9450
9454
|
}
|
|
9451
9455
|
) : null,
|
|
9452
|
-
children: pe && X ? /* @__PURE__ */ g(
|
|
9456
|
+
children: pe && X ? /* @__PURE__ */ g(Ye, { children: [
|
|
9453
9457
|
/* @__PURE__ */ g(
|
|
9454
9458
|
"button",
|
|
9455
9459
|
{
|
|
@@ -9727,7 +9731,7 @@ function Tl({
|
|
|
9727
9731
|
{
|
|
9728
9732
|
type: "checkbox",
|
|
9729
9733
|
"aria-label": "Hide excess content",
|
|
9730
|
-
checked: (
|
|
9734
|
+
checked: (qe == null ? void 0 : qe.getPropertyValue("overflow")) === "hidden",
|
|
9731
9735
|
className: "h-4 w-4 accent-[#0d99ff]",
|
|
9732
9736
|
onChange: (h) => Ze("overflow", h.currentTarget.checked ? "hidden" : "visible")
|
|
9733
9737
|
}
|
|
@@ -9737,7 +9741,7 @@ function Tl({
|
|
|
9737
9741
|
] }) : /* @__PURE__ */ s("div", { className: "text-[11px] text-[#a1a1aa]", children: "There is no parent frame." })
|
|
9738
9742
|
}
|
|
9739
9743
|
),
|
|
9740
|
-
pe && /* @__PURE__ */ s(
|
|
9744
|
+
pe && /* @__PURE__ */ s(Ye, { children: /* @__PURE__ */ g(et, { title: "Child · Resizing", children: [
|
|
9741
9745
|
/* @__PURE__ */ s("div", { className: "grid grid-cols-4 gap-1", children: [
|
|
9742
9746
|
["auto", "Auto"],
|
|
9743
9747
|
["flex-start", "start"],
|
|
@@ -9878,7 +9882,7 @@ function Tl({
|
|
|
9878
9882
|
type: "button",
|
|
9879
9883
|
className: "h-9 rounded-md bg-[#f4f4f5] text-[10px] font-semibold text-[#52525b] hover:bg-[#e9e9ee]",
|
|
9880
9884
|
onClick: () => {
|
|
9881
|
-
|
|
9885
|
+
ze(), E(null), L("original"), q("default"), K();
|
|
9882
9886
|
},
|
|
9883
9887
|
children: "Reset case preview"
|
|
9884
9888
|
}
|
|
@@ -9889,7 +9893,7 @@ function Tl({
|
|
|
9889
9893
|
type: "button",
|
|
9890
9894
|
className: "h-9 rounded-md bg-[#18181b] text-[10px] font-semibold text-white hover:bg-black",
|
|
9891
9895
|
onClick: () => {
|
|
9892
|
-
en.length > 0 && !window.confirm("Reset all unapplied editor changes? This also clears undo and redo history.") || (
|
|
9896
|
+
en.length > 0 && !window.confirm("Reset all unapplied editor changes? This also clears undo and redo history.") || (ze(), E(null), L("original"), q("default"), J.discardPending(), P(null), M(""), Ee(""), J.toast("Reset all unapplied changes"), K());
|
|
9893
9897
|
},
|
|
9894
9898
|
children: "Reset changes"
|
|
9895
9899
|
}
|
|
@@ -10294,7 +10298,7 @@ function Tl({
|
|
|
10294
10298
|
disabled: en.length === 0,
|
|
10295
10299
|
className: "mt-1.5 h-8 w-full rounded-md border border-[#fecaca] bg-[#fff7f7] text-[10px] font-semibold text-[#b91c1c] hover:bg-[#fef2f2] disabled:border-[#e4e4e7] disabled:bg-[#f4f4f5] disabled:text-[#a1a1aa]",
|
|
10296
10300
|
onClick: () => {
|
|
10297
|
-
window.confirm("Reset all unapplied editor changes? This also clears undo and redo history.") && (
|
|
10301
|
+
window.confirm("Reset all unapplied editor changes? This also clears undo and redo history.") && (ze(), E(null), L("original"), q("default"), J.discardPending(), P(null), M(""), Ee(""), J.toast("Reset all unapplied changes"));
|
|
10298
10302
|
},
|
|
10299
10303
|
children: "Reset changes"
|
|
10300
10304
|
}
|
|
@@ -10642,7 +10646,7 @@ function Fl() {
|
|
|
10642
10646
|
)
|
|
10643
10647
|
] });
|
|
10644
10648
|
}
|
|
10645
|
-
const by =
|
|
10649
|
+
const by = Be(function({ onClose: t }) {
|
|
10646
10650
|
const n = Xe(ka, wn, wn), r = f.activePage, o = Pe(null), i = Pe(null), [a, c] = Q(!1);
|
|
10647
10651
|
if (ae(() => J.reset(), []), r.route != null) {
|
|
10648
10652
|
const l = () => {
|
|
@@ -11049,7 +11053,7 @@ function zl({
|
|
|
11049
11053
|
}
|
|
11050
11054
|
);
|
|
11051
11055
|
}
|
|
11052
|
-
const Ay =
|
|
11056
|
+
const Ay = Be(function() {
|
|
11053
11057
|
const [t, n] = Q(null), [r, o] = Q(""), [i, a] = Q(null), [c, l] = Q(null);
|
|
11054
11058
|
if (!f.applyOpen) return null;
|
|
11055
11059
|
const d = f.getPendingSourceChanges(), u = JSON.stringify(d.payload), p = ky(d.payload), m = (i == null ? void 0 : i.fingerprint) === u && i.journalRevision === d.revision, b = xf(), x = op(), w = f.pages.filter(
|
|
@@ -11121,7 +11125,7 @@ const Ay = ze(function() {
|
|
|
11121
11125
|
}
|
|
11122
11126
|
}
|
|
11123
11127
|
};
|
|
11124
|
-
return /* @__PURE__ */ g(
|
|
11128
|
+
return /* @__PURE__ */ g(Ye, { children: [
|
|
11125
11129
|
/* @__PURE__ */ s("div", { className: "fixed inset-0 z-40 bg-black/30", onMouseDown: () => f.setApplyOpen(!1) }),
|
|
11126
11130
|
/* @__PURE__ */ g("div", { className: "fixed left-1/2 top-1/2 z-50 flex max-h-[80vh] w-[560px] -translate-x-1/2 -translate-y-1/2 flex-col overflow-hidden rounded-[13px] bg-white shadow-[0_8px_40px_rgba(0,0,0,.25)]", children: [
|
|
11127
11131
|
/* @__PURE__ */ g("div", { className: "flex items-center justify-between border-b border-[#e6e6e6] px-4 py-3", children: [
|
|
@@ -11222,7 +11226,7 @@ const Ay = ze(function() {
|
|
|
11222
11226
|
)),
|
|
11223
11227
|
!E || !k ? /* @__PURE__ */ s("div", { className: "text-[10px] text-amber-600", children: "Connect source preview and apply callbacks to review these changes." }) : null
|
|
11224
11228
|
] }),
|
|
11225
|
-
m && i ? /* @__PURE__ */ g(
|
|
11229
|
+
m && i ? /* @__PURE__ */ g(Ye, { children: [
|
|
11226
11230
|
/* @__PURE__ */ g("div", { className: "mb-3 rounded-md border border-[#d9ecfb] bg-[#f4faff] p-2", children: [
|
|
11227
11231
|
/* @__PURE__ */ g("div", { className: "mb-1 text-[10px] font-semibold text-[#1677b8]", children: [
|
|
11228
11232
|
"Reviewed code diff · revision ",
|
|
@@ -11659,7 +11663,7 @@ function Xy(e) {
|
|
|
11659
11663
|
);
|
|
11660
11664
|
return t;
|
|
11661
11665
|
}
|
|
11662
|
-
function
|
|
11666
|
+
function H0(e, t) {
|
|
11663
11667
|
return $f(e, t).document;
|
|
11664
11668
|
}
|
|
11665
11669
|
function $f(e, t) {
|
|
@@ -11805,7 +11809,7 @@ function ev(e) {
|
|
|
11805
11809
|
}
|
|
11806
11810
|
return [...t.values()];
|
|
11807
11811
|
}
|
|
11808
|
-
const tv =
|
|
11812
|
+
const tv = Be(function() {
|
|
11809
11813
|
var p;
|
|
11810
11814
|
const [t, n] = Q("jsx-tailwind"), [r, o] = Q(!1);
|
|
11811
11815
|
if (!f.codeOpen) return null;
|
|
@@ -11894,7 +11898,7 @@ const tv = ze(function() {
|
|
|
11894
11898
|
)
|
|
11895
11899
|
] }) : c.status === "blocked" ? /* @__PURE__ */ s("div", { className: "flex min-h-0 flex-1 items-center justify-center px-6 text-center text-[11px] text-red-300", children: "Resolve the compiler errors before generating code." }) : /* @__PURE__ */ s("pre", { className: "min-h-0 flex-1 overflow-auto px-3 pb-3 text-[11px] leading-relaxed text-emerald-300", children: c.code })
|
|
11896
11900
|
] });
|
|
11897
|
-
}), nv =
|
|
11901
|
+
}), nv = Be(function() {
|
|
11898
11902
|
var l;
|
|
11899
11903
|
const t = f.ctxMenu;
|
|
11900
11904
|
if (!t) return null;
|
|
@@ -11929,7 +11933,7 @@ const tv = ze(function() {
|
|
|
11929
11933
|
], c = f.editMode ? a : a.map(
|
|
11930
11934
|
(d) => d === "sep" || d.label === "Copy" ? d : { ...d, enabled: !1 }
|
|
11931
11935
|
);
|
|
11932
|
-
return /* @__PURE__ */ g(
|
|
11936
|
+
return /* @__PURE__ */ g(Ye, { children: [
|
|
11933
11937
|
/* @__PURE__ */ s(
|
|
11934
11938
|
"div",
|
|
11935
11939
|
{
|
|
@@ -12004,47 +12008,78 @@ function ov(e, t, n = () => !0) {
|
|
|
12004
12008
|
}
|
|
12005
12009
|
return { loose: a, groups: c };
|
|
12006
12010
|
}
|
|
12007
|
-
let
|
|
12008
|
-
const
|
|
12011
|
+
let ho = [], po = null;
|
|
12012
|
+
const Sa = /* @__PURE__ */ new Set();
|
|
12013
|
+
function iv(e) {
|
|
12014
|
+
ho = e.map((t) => {
|
|
12015
|
+
const n = String(t.label ?? "").trim();
|
|
12016
|
+
if (!n) throw new Error("Session preset is missing a label.");
|
|
12017
|
+
return {
|
|
12018
|
+
label: n,
|
|
12019
|
+
...t.environment ? { environment: t.environment } : {},
|
|
12020
|
+
...t.description ? { description: t.description } : {}
|
|
12021
|
+
};
|
|
12022
|
+
}), po != null && po >= ho.length && Mf(null);
|
|
12023
|
+
}
|
|
12024
|
+
function sv() {
|
|
12025
|
+
return ho;
|
|
12026
|
+
}
|
|
12027
|
+
function jl() {
|
|
12028
|
+
return po;
|
|
12029
|
+
}
|
|
12030
|
+
function Mf(e) {
|
|
12031
|
+
const t = e != null && e >= 0 && e < ho.length ? e : null;
|
|
12032
|
+
if (t !== po) {
|
|
12033
|
+
po = t, ir(
|
|
12034
|
+
t == null ? void 0 : ho[t].environment
|
|
12035
|
+
);
|
|
12036
|
+
for (const n of Sa) n();
|
|
12037
|
+
}
|
|
12038
|
+
}
|
|
12039
|
+
function av(e) {
|
|
12040
|
+
return Sa.add(e), () => Sa.delete(e);
|
|
12041
|
+
}
|
|
12042
|
+
let Na = null;
|
|
12043
|
+
const Ia = /* @__PURE__ */ new Set();
|
|
12009
12044
|
function $n(e) {
|
|
12010
|
-
if (!Object.is(
|
|
12011
|
-
|
|
12012
|
-
for (const t of
|
|
12045
|
+
if (!Object.is(Na, e)) {
|
|
12046
|
+
Na = e;
|
|
12047
|
+
for (const t of Ia) t();
|
|
12013
12048
|
}
|
|
12014
12049
|
}
|
|
12015
|
-
function
|
|
12016
|
-
return
|
|
12050
|
+
function mo() {
|
|
12051
|
+
return Na;
|
|
12017
12052
|
}
|
|
12018
|
-
function
|
|
12019
|
-
return
|
|
12053
|
+
function Ef(e) {
|
|
12054
|
+
return Ia.add(e), () => Ia.delete(e);
|
|
12020
12055
|
}
|
|
12021
|
-
const
|
|
12056
|
+
const cv = "data-pygmalion-source", lv = "/__pygmalion-storyboard/source-usage", dv = 4e3;
|
|
12022
12057
|
function wc(e) {
|
|
12023
12058
|
if (!e) return null;
|
|
12024
12059
|
const t = e.replaceAll("\\", "/").trim();
|
|
12025
12060
|
return !t || t.startsWith("/") || t.includes("\0") || t.split("/").includes("..") || t.length > 1200 ? null : t;
|
|
12026
12061
|
}
|
|
12027
|
-
function
|
|
12062
|
+
function uv(e) {
|
|
12028
12063
|
if (!e) return null;
|
|
12029
12064
|
const t = e.lastIndexOf("#");
|
|
12030
12065
|
return t <= 0 ? null : wc(e.slice(0, t));
|
|
12031
12066
|
}
|
|
12032
|
-
function
|
|
12067
|
+
function fv(e) {
|
|
12033
12068
|
if (!e) return null;
|
|
12034
12069
|
const t = e.indexOf("|");
|
|
12035
12070
|
return wc(t > 0 ? e.slice(0, t) : e);
|
|
12036
12071
|
}
|
|
12037
|
-
function
|
|
12072
|
+
function Ca(e) {
|
|
12038
12073
|
const t = /* @__PURE__ */ new Set(), n = /* @__PURE__ */ new Set();
|
|
12039
12074
|
let r = 0;
|
|
12040
12075
|
const o = (i) => {
|
|
12041
12076
|
var l;
|
|
12042
|
-
if (!i || r >=
|
|
12077
|
+
if (!i || r >= dv) return;
|
|
12043
12078
|
r += 1, i.componentName && n.add(i.componentName);
|
|
12044
|
-
const a =
|
|
12079
|
+
const a = uv(i.sourceStyle);
|
|
12045
12080
|
a && t.add(a);
|
|
12046
|
-
const c =
|
|
12047
|
-
(l = i.domAttributes) == null ? void 0 : l[
|
|
12081
|
+
const c = fv(
|
|
12082
|
+
(l = i.domAttributes) == null ? void 0 : l[cv]
|
|
12048
12083
|
);
|
|
12049
12084
|
c && t.add(c);
|
|
12050
12085
|
for (const d of i.children ?? []) o(d);
|
|
@@ -12054,23 +12089,23 @@ function Ia(e) {
|
|
|
12054
12089
|
componentNames: [...n].sort()
|
|
12055
12090
|
};
|
|
12056
12091
|
}
|
|
12057
|
-
function
|
|
12092
|
+
function hv(e) {
|
|
12058
12093
|
if (!e) return;
|
|
12059
12094
|
if (e.componentName) return e.componentName;
|
|
12060
|
-
const { componentNames: t } =
|
|
12095
|
+
const { componentNames: t } = Ca(e);
|
|
12061
12096
|
return t.length === 1 ? t[0] : void 0;
|
|
12062
12097
|
}
|
|
12063
|
-
function
|
|
12098
|
+
function pv(e) {
|
|
12064
12099
|
const t = e.slice(e.lastIndexOf("/") + 1), n = t.indexOf(".");
|
|
12065
12100
|
return n === -1 ? t : t.slice(0, n);
|
|
12066
12101
|
}
|
|
12067
|
-
function
|
|
12102
|
+
function kf(e) {
|
|
12068
12103
|
var r;
|
|
12069
12104
|
const t = (r = e.componentName) == null ? void 0 : r.trim(), n = (o) => {
|
|
12070
12105
|
const i = [...new Set(o.map(wc).filter(Boolean))].sort();
|
|
12071
12106
|
if (i.length !== 0) {
|
|
12072
12107
|
if (t) {
|
|
12073
|
-
const a = i.find((c) =>
|
|
12108
|
+
const a = i.find((c) => pv(c) === t);
|
|
12074
12109
|
if (a) return a;
|
|
12075
12110
|
}
|
|
12076
12111
|
return i[0];
|
|
@@ -12078,13 +12113,13 @@ function Ef(e) {
|
|
|
12078
12113
|
};
|
|
12079
12114
|
return n(e.declaredFiles ?? []) ?? n(e.sourceFiles);
|
|
12080
12115
|
}
|
|
12081
|
-
function
|
|
12116
|
+
function mv(e) {
|
|
12082
12117
|
var a;
|
|
12083
12118
|
const t = e.usageByFile ?? {}, n = e.usageRequested ?? !1, r = new Map(
|
|
12084
12119
|
e.consumers.map((c) => [c.frameId, c])
|
|
12085
12120
|
), o = [], i = [];
|
|
12086
12121
|
for (const c of e.catalog) {
|
|
12087
|
-
const l =
|
|
12122
|
+
const l = kf(c), d = ((a = c.componentName) == null ? void 0 : a.trim()) || void 0;
|
|
12088
12123
|
if (!l && !d) {
|
|
12089
12124
|
i.push(c.frameId);
|
|
12090
12125
|
continue;
|
|
@@ -12116,7 +12151,7 @@ function fv(e) {
|
|
|
12116
12151
|
unplacedFrameIds: i.sort()
|
|
12117
12152
|
};
|
|
12118
12153
|
}
|
|
12119
|
-
function
|
|
12154
|
+
function gv(e = []) {
|
|
12120
12155
|
return {
|
|
12121
12156
|
frames: [],
|
|
12122
12157
|
canonicalGroups: [],
|
|
@@ -12145,7 +12180,7 @@ function hv(e = []) {
|
|
|
12145
12180
|
})).sort((t, n) => t.frameId.localeCompare(n.frameId))
|
|
12146
12181
|
};
|
|
12147
12182
|
}
|
|
12148
|
-
function
|
|
12183
|
+
function bv(e) {
|
|
12149
12184
|
const t = /* @__PURE__ */ new Set([
|
|
12150
12185
|
...e.startFrameIds,
|
|
12151
12186
|
...e.branchFrameIds
|
|
@@ -12165,7 +12200,7 @@ function Fn(e) {
|
|
|
12165
12200
|
(t, n) => t.localeCompare(n)
|
|
12166
12201
|
);
|
|
12167
12202
|
}
|
|
12168
|
-
function
|
|
12203
|
+
function Af(e, t) {
|
|
12169
12204
|
const n = [...t].filter((N) => N.frameId.trim()).map((N) => ({
|
|
12170
12205
|
...N,
|
|
12171
12206
|
frameId: N.frameId.trim(),
|
|
@@ -12338,7 +12373,7 @@ function kf(e, t) {
|
|
|
12338
12373
|
return (F = l.get(N.nodeId)) == null ? void 0 : F.frameId;
|
|
12339
12374
|
}
|
|
12340
12375
|
)
|
|
12341
|
-
), T =
|
|
12376
|
+
), T = bv({
|
|
12342
12377
|
frames: W,
|
|
12343
12378
|
canonicalGroups: q,
|
|
12344
12379
|
sharedSources: S,
|
|
@@ -12367,13 +12402,13 @@ function kf(e, t) {
|
|
|
12367
12402
|
unplacedFrames: I
|
|
12368
12403
|
};
|
|
12369
12404
|
}
|
|
12370
|
-
const
|
|
12405
|
+
const Wl = {
|
|
12371
12406
|
spine: [],
|
|
12372
12407
|
detours: /* @__PURE__ */ new Map(),
|
|
12373
12408
|
detourParent: /* @__PURE__ */ new Map(),
|
|
12374
12409
|
offJourney: []
|
|
12375
12410
|
};
|
|
12376
|
-
function
|
|
12411
|
+
function Rf(e) {
|
|
12377
12412
|
const t = e.frames.some(
|
|
12378
12413
|
(r) => r.outgoingTransitions.some((o) => o.origin === "explicit")
|
|
12379
12414
|
), n = /* @__PURE__ */ new Map();
|
|
@@ -12383,7 +12418,7 @@ function Af(e) {
|
|
|
12383
12418
|
}
|
|
12384
12419
|
return n;
|
|
12385
12420
|
}
|
|
12386
|
-
function
|
|
12421
|
+
function xv(e) {
|
|
12387
12422
|
const t = /* @__PURE__ */ new Map(), n = /* @__PURE__ */ new Set(), r = (o) => {
|
|
12388
12423
|
const i = t.get(o);
|
|
12389
12424
|
if (i) return { path: i, cyclic: !1 };
|
|
@@ -12400,15 +12435,15 @@ function mv(e) {
|
|
|
12400
12435
|
};
|
|
12401
12436
|
return (o) => r(o).path;
|
|
12402
12437
|
}
|
|
12403
|
-
function
|
|
12404
|
-
if (e.frames.length === 0) return
|
|
12405
|
-
const t =
|
|
12438
|
+
function yv(e) {
|
|
12439
|
+
if (e.frames.length === 0) return Wl;
|
|
12440
|
+
const t = Rf(e), n = xv(t), r = e.startFrameIds.length ? e.startFrameIds : e.frames.filter((d) => d.incomingTransitions.length === 0).map((d) => d.frameId);
|
|
12406
12441
|
let o = [];
|
|
12407
12442
|
for (const d of r) {
|
|
12408
12443
|
const u = n(d);
|
|
12409
12444
|
u.length > o.length && (o = u);
|
|
12410
12445
|
}
|
|
12411
|
-
if (o.length < 2) return
|
|
12446
|
+
if (o.length < 2) return Wl;
|
|
12412
12447
|
const i = new Set(o), a = /* @__PURE__ */ new Map(), c = /* @__PURE__ */ new Map();
|
|
12413
12448
|
for (const d of o) {
|
|
12414
12449
|
const u = (t.get(d) ?? []).filter((p) => !i.has(p));
|
|
@@ -12421,14 +12456,14 @@ function gv(e) {
|
|
|
12421
12456
|
const l = e.frames.map((d) => d.frameId).filter((d) => !i.has(d) && !c.has(d));
|
|
12422
12457
|
return { spine: o, detours: a, detourParent: c, offJourney: l };
|
|
12423
12458
|
}
|
|
12424
|
-
function
|
|
12459
|
+
function vv(e, t) {
|
|
12425
12460
|
return t ? e.spine.includes(t) ? t : e.detourParent.get(t) ?? null : null;
|
|
12426
12461
|
}
|
|
12427
|
-
function
|
|
12428
|
-
const t =
|
|
12462
|
+
function wv(e) {
|
|
12463
|
+
const t = Rf(e);
|
|
12429
12464
|
return e.frames.filter((n) => (t.get(n.frameId) ?? []).length === 0);
|
|
12430
12465
|
}
|
|
12431
|
-
function
|
|
12466
|
+
function Tf({
|
|
12432
12467
|
frame: e,
|
|
12433
12468
|
label: t,
|
|
12434
12469
|
onSelectFrame: n
|
|
@@ -12463,7 +12498,7 @@ function hr({
|
|
|
12463
12498
|
}
|
|
12464
12499
|
);
|
|
12465
12500
|
}
|
|
12466
|
-
const
|
|
12501
|
+
const Sv = {
|
|
12467
12502
|
observed: "Frames observed rendering this piece",
|
|
12468
12503
|
direct: "Files that name this piece; barrels are followed through",
|
|
12469
12504
|
transitive: "Nothing names it directly. This is the dependency closure, which a barrel inflates — not a usage count.",
|
|
@@ -12471,10 +12506,10 @@ const yv = {
|
|
|
12471
12506
|
unused: "The source scan found nothing that uses it",
|
|
12472
12507
|
"not-traced": "No source file to trace, or no scan available"
|
|
12473
12508
|
};
|
|
12474
|
-
function
|
|
12509
|
+
function Nv(e) {
|
|
12475
12510
|
return e.evidence === "observed" ? `${e.usedByFrames.length} frames` : e.evidence === "direct" ? `${e.usedByFiles.length} files` : e.evidence === "transitive" ? `${e.transitiveCount ?? 0} indirect` : e.evidence === "pending" ? "checking…" : e.evidence === "unused" ? "unused" : "not traced";
|
|
12476
12511
|
}
|
|
12477
|
-
function
|
|
12512
|
+
function Iv({
|
|
12478
12513
|
children: e,
|
|
12479
12514
|
count: t
|
|
12480
12515
|
}) {
|
|
@@ -12506,19 +12541,19 @@ function Hn({
|
|
|
12506
12541
|
children: "›"
|
|
12507
12542
|
}
|
|
12508
12543
|
),
|
|
12509
|
-
/* @__PURE__ */ s("span", { className: "min-w-0 flex-1", children: /* @__PURE__ */ s(
|
|
12544
|
+
/* @__PURE__ */ s("span", { className: "min-w-0 flex-1", children: /* @__PURE__ */ s(Iv, { count: t, children: e }) })
|
|
12510
12545
|
]
|
|
12511
12546
|
}
|
|
12512
12547
|
),
|
|
12513
12548
|
o ? /* @__PURE__ */ s("div", { className: "mt-0.5 flex flex-col gap-0.5", children: r }) : null
|
|
12514
12549
|
] });
|
|
12515
12550
|
}
|
|
12516
|
-
function
|
|
12551
|
+
function Cv({
|
|
12517
12552
|
model: e,
|
|
12518
12553
|
frameById: t,
|
|
12519
12554
|
onSelectFrame: n
|
|
12520
12555
|
}) {
|
|
12521
|
-
const r =
|
|
12556
|
+
const r = wv(e), o = f.canvasPages.filter((l) => l.route != null), i = o.filter((l) => {
|
|
12522
12557
|
var d;
|
|
12523
12558
|
return !((d = l.scenarioIds) != null && d.length);
|
|
12524
12559
|
}), a = o.flatMap((l) => {
|
|
@@ -12533,7 +12568,7 @@ function Sv({
|
|
|
12533
12568
|
r.length > 0 && /* @__PURE__ */ g(Hn, { label: "Nothing follows", count: r.length, children: [
|
|
12534
12569
|
/* @__PURE__ */ s("p", { className: "px-1.5 text-[9px] leading-relaxed text-[#999]", children: "An end state is fine here. A step that should continue is not." }),
|
|
12535
12570
|
r.map((l) => /* @__PURE__ */ s(
|
|
12536
|
-
|
|
12571
|
+
Tf,
|
|
12537
12572
|
{
|
|
12538
12573
|
frame: l,
|
|
12539
12574
|
onSelectFrame: n
|
|
@@ -12576,14 +12611,14 @@ function Sv({
|
|
|
12576
12611
|
)
|
|
12577
12612
|
] });
|
|
12578
12613
|
}
|
|
12579
|
-
function
|
|
12614
|
+
function Pv({
|
|
12580
12615
|
model: e,
|
|
12581
12616
|
onSelectFrame: t,
|
|
12582
12617
|
activeFrameId: n,
|
|
12583
12618
|
composition: r = null,
|
|
12584
12619
|
frameNameById: o
|
|
12585
12620
|
}) {
|
|
12586
|
-
const i = new Map(e.frames.map((x) => [x.frameId, x])), a = _t(() =>
|
|
12621
|
+
const i = new Map(e.frames.map((x) => [x.frameId, x])), a = _t(() => yv(e), [e]), c = vv(a, n), [l, d] = Q({}), u = e.frames.filter((x) => x.warnings.length), p = (r == null ? void 0 : r.entries) ?? [], m = (r == null ? void 0 : r.unplacedFrameIds) ?? [];
|
|
12587
12622
|
return e.startFrameIds.length > 0 || e.branchFrameIds.length > 0 || e.canonicalGroups.length > 0 || e.sharedSources.length > 0 || e.warnings.length > 0 || e.unplacedFrames.length > 0 || p.length > 0 || m.length > 0 ? (
|
|
12588
12623
|
// The height belongs to the panel that stacks the regions, so this one
|
|
12589
12624
|
// fills what it is given rather than capping itself.
|
|
@@ -12691,7 +12726,7 @@ function Nv({
|
|
|
12691
12726
|
) : null,
|
|
12692
12727
|
/* @__PURE__ */ g("div", { className: "mt-2 flex flex-col gap-2", children: [
|
|
12693
12728
|
/* @__PURE__ */ s(
|
|
12694
|
-
|
|
12729
|
+
Cv,
|
|
12695
12730
|
{
|
|
12696
12731
|
model: e,
|
|
12697
12732
|
frameById: i,
|
|
@@ -12724,8 +12759,8 @@ function Nv({
|
|
|
12724
12759
|
"span",
|
|
12725
12760
|
{
|
|
12726
12761
|
className: "shrink-0 text-[9px] text-[#999]",
|
|
12727
|
-
title:
|
|
12728
|
-
children:
|
|
12762
|
+
title: Sv[x.evidence],
|
|
12763
|
+
children: Nv(x)
|
|
12729
12764
|
}
|
|
12730
12765
|
)
|
|
12731
12766
|
] }),
|
|
@@ -12789,7 +12824,7 @@ function Nv({
|
|
|
12789
12824
|
),
|
|
12790
12825
|
e.warnings.length > 0 && /* @__PURE__ */ g(Hn, { label: "Warnings", count: e.warnings.length, children: [
|
|
12791
12826
|
u.map((x) => /* @__PURE__ */ s(
|
|
12792
|
-
|
|
12827
|
+
Tf,
|
|
12793
12828
|
{
|
|
12794
12829
|
frame: x,
|
|
12795
12830
|
label: `${x.name} · ${x.warnings.length}`,
|
|
@@ -12813,16 +12848,16 @@ function Nv({
|
|
|
12813
12848
|
)
|
|
12814
12849
|
) : null;
|
|
12815
12850
|
}
|
|
12816
|
-
function
|
|
12851
|
+
function $v({ type: e }) {
|
|
12817
12852
|
return /* @__PURE__ */ s("span", { className: `shrink-0 ${e === "component" ? "text-[#9747ff]" : "text-[#999]"}`, children: e === "text" ? /* @__PURE__ */ s(Gu, { size: 10 }) : e === "columns" ? /* @__PURE__ */ s(hc, { size: 10 }) : e === "component" ? /* @__PURE__ */ s(Ci, { size: 10 }) : /* @__PURE__ */ s(Ni, { size: 10 }) });
|
|
12818
12853
|
}
|
|
12819
|
-
const
|
|
12854
|
+
const Mv = Sd(function e({ node: t, depth: n }) {
|
|
12820
12855
|
return Vu(() => {
|
|
12821
12856
|
const r = f.isSelected(t.id), o = f.collapsed.has(t.id), i = t.children.length > 0, a = f.renamingId === t.id, c = t.type === "text" ? t.text : t.name, l = (d) => {
|
|
12822
12857
|
const u = d.trim();
|
|
12823
12858
|
u && u !== c && f.patch(t, t.type === "text" ? { text: u } : { name: u }), f.setRenaming(null);
|
|
12824
12859
|
};
|
|
12825
|
-
return /* @__PURE__ */ g(
|
|
12860
|
+
return /* @__PURE__ */ g(Ye, { children: [
|
|
12826
12861
|
/* @__PURE__ */ g(
|
|
12827
12862
|
"div",
|
|
12828
12863
|
{
|
|
@@ -12853,7 +12888,7 @@ const Cv = Sd(function e({ node: t, depth: n }) {
|
|
|
12853
12888
|
children: /* @__PURE__ */ s(ni, { open: !o })
|
|
12854
12889
|
}
|
|
12855
12890
|
),
|
|
12856
|
-
/* @__PURE__ */ s(
|
|
12891
|
+
/* @__PURE__ */ s($v, { type: t.type }),
|
|
12857
12892
|
a ? /* @__PURE__ */ s(
|
|
12858
12893
|
"input",
|
|
12859
12894
|
{
|
|
@@ -12913,7 +12948,7 @@ const Cv = Sd(function e({ node: t, depth: n }) {
|
|
|
12913
12948
|
] });
|
|
12914
12949
|
});
|
|
12915
12950
|
});
|
|
12916
|
-
function
|
|
12951
|
+
function Ev({
|
|
12917
12952
|
id: e,
|
|
12918
12953
|
name: t,
|
|
12919
12954
|
active: n,
|
|
@@ -12950,32 +12985,32 @@ function Pv({
|
|
|
12950
12985
|
}
|
|
12951
12986
|
);
|
|
12952
12987
|
}
|
|
12953
|
-
const
|
|
12954
|
-
function
|
|
12988
|
+
const Ff = "pygmalion.leftPanel.heights";
|
|
12989
|
+
function Hl() {
|
|
12955
12990
|
try {
|
|
12956
|
-
const e = window.localStorage.getItem(
|
|
12991
|
+
const e = window.localStorage.getItem(Ff), t = e ? JSON.parse(e) : null;
|
|
12957
12992
|
return t && typeof t == "object" && !Array.isArray(t) ? t : {};
|
|
12958
12993
|
} catch {
|
|
12959
12994
|
return {};
|
|
12960
12995
|
}
|
|
12961
12996
|
}
|
|
12962
|
-
function
|
|
12997
|
+
function kv(e, t) {
|
|
12963
12998
|
const [n, r] = Q(() => {
|
|
12964
|
-
const i =
|
|
12999
|
+
const i = Hl()[e];
|
|
12965
13000
|
return typeof i == "number" && Number.isFinite(i) ? i : t;
|
|
12966
13001
|
});
|
|
12967
13002
|
return [n, (i) => {
|
|
12968
13003
|
r(i);
|
|
12969
13004
|
try {
|
|
12970
13005
|
window.localStorage.setItem(
|
|
12971
|
-
|
|
12972
|
-
JSON.stringify({ ...
|
|
13006
|
+
Ff,
|
|
13007
|
+
JSON.stringify({ ...Hl(), [e]: i })
|
|
12973
13008
|
);
|
|
12974
13009
|
} catch {
|
|
12975
13010
|
}
|
|
12976
13011
|
}];
|
|
12977
13012
|
}
|
|
12978
|
-
function
|
|
13013
|
+
function Av({
|
|
12979
13014
|
label: e,
|
|
12980
13015
|
height: t,
|
|
12981
13016
|
onResize: n,
|
|
@@ -13000,7 +13035,7 @@ function Mv({
|
|
|
13000
13035
|
}
|
|
13001
13036
|
);
|
|
13002
13037
|
}
|
|
13003
|
-
function
|
|
13038
|
+
function Lf({ shown: e, declared: t }) {
|
|
13004
13039
|
return t === 0 ? null : /* @__PURE__ */ s(
|
|
13005
13040
|
"span",
|
|
13006
13041
|
{
|
|
@@ -13010,7 +13045,7 @@ function Ff({ shown: e, declared: t }) {
|
|
|
13010
13045
|
}
|
|
13011
13046
|
);
|
|
13012
13047
|
}
|
|
13013
|
-
const vs =
|
|
13048
|
+
const vs = Be(function({
|
|
13014
13049
|
leaf: t,
|
|
13015
13050
|
label: n,
|
|
13016
13051
|
active: r,
|
|
@@ -13026,23 +13061,50 @@ const vs = ze(function({
|
|
|
13026
13061
|
onClick: () => f.switchCanvas(t.canvas),
|
|
13027
13062
|
children: [
|
|
13028
13063
|
/* @__PURE__ */ s("span", { className: "min-w-0 flex-1 truncate", children: n ?? t.label }),
|
|
13029
|
-
/* @__PURE__ */ s(
|
|
13064
|
+
/* @__PURE__ */ s(Lf, { shown: t.frames, declared: t.declared })
|
|
13030
13065
|
]
|
|
13031
13066
|
}
|
|
13032
13067
|
);
|
|
13033
|
-
}),
|
|
13068
|
+
}), Rv = Be(function() {
|
|
13069
|
+
const t = Xe(
|
|
13070
|
+
av,
|
|
13071
|
+
jl,
|
|
13072
|
+
// The selection is a module value, so it reads the same on both sides —
|
|
13073
|
+
// and the panel renders server-side in tests, which requires this.
|
|
13074
|
+
jl
|
|
13075
|
+
), n = sv();
|
|
13076
|
+
return n.length === 0 ? null : /* @__PURE__ */ g("div", { className: "shrink-0 border-b border-[#e6e6e6] px-3 py-2.5", children: [
|
|
13077
|
+
/* @__PURE__ */ s("div", { className: "text-[11px] font-semibold text-[#333]", children: "Runtime" }),
|
|
13078
|
+
/* @__PURE__ */ s("div", { role: "group", "aria-label": "Runtime", className: "mt-1.5 flex gap-1", children: n.map((r, o) => {
|
|
13079
|
+
const i = t === o;
|
|
13080
|
+
return /* @__PURE__ */ s(
|
|
13081
|
+
"button",
|
|
13082
|
+
{
|
|
13083
|
+
type: "button",
|
|
13084
|
+
"data-session-preset": r.label,
|
|
13085
|
+
"aria-pressed": i,
|
|
13086
|
+
title: r.description,
|
|
13087
|
+
className: `h-7 flex-1 rounded-md px-2 text-[11px] font-medium ${i ? "bg-[#e5f4ff] text-[#0d99ff]" : "bg-[#f5f5f5] text-[#555] hover:bg-[#ececec] hover:text-[#333]"}`,
|
|
13088
|
+
onClick: () => Mf(i ? null : o),
|
|
13089
|
+
children: r.label
|
|
13090
|
+
},
|
|
13091
|
+
r.label
|
|
13092
|
+
);
|
|
13093
|
+
}) })
|
|
13094
|
+
] });
|
|
13095
|
+
}), Tv = Be(function({
|
|
13034
13096
|
view: t = "story",
|
|
13035
13097
|
onFrameFocus: n = (o) => f.selectFrame(o),
|
|
13036
13098
|
storyboardReady: r = !0
|
|
13037
13099
|
}) {
|
|
13038
|
-
const [o, i] =
|
|
13100
|
+
const [o, i] = kv("frames", 176), [a, c] = Q({}), l = ov(
|
|
13039
13101
|
f.pages,
|
|
13040
13102
|
f.canvasNames,
|
|
13041
13103
|
(I) => f.isScreenStateShown(I)
|
|
13042
13104
|
), d = (I) => I.canvases.some((N) => N.canvas === f.activeCanvas), u = Xe(
|
|
13043
|
-
|
|
13044
|
-
|
|
13045
|
-
|
|
13105
|
+
Ef,
|
|
13106
|
+
mo,
|
|
13107
|
+
mo
|
|
13046
13108
|
), p = f.canvasPages, m = p.length > 0 && p.every((I) => I.route == null), b = (I) => ({
|
|
13047
13109
|
frameId: I.id,
|
|
13048
13110
|
screenId: I.importPageId ?? I.id,
|
|
@@ -13052,20 +13114,20 @@ const vs = ze(function({
|
|
|
13052
13114
|
), w = new Set(x.map((I) => I.id)), v = [
|
|
13053
13115
|
...x.map(b),
|
|
13054
13116
|
...m ? [] : p.filter((I) => !w.has(I.id)).map(b)
|
|
13055
|
-
], E = r ? u ?
|
|
13117
|
+
], E = r ? u ? Af(u, v) : gv(v) : null, k = p.map((I) => ({
|
|
13056
13118
|
frameId: I.id,
|
|
13057
13119
|
name: I.name,
|
|
13058
|
-
componentName:
|
|
13120
|
+
componentName: hv(I.root),
|
|
13059
13121
|
declaredFiles: I.sourcePaths ?? [],
|
|
13060
|
-
...
|
|
13061
|
-
})), [L, W] = Q({}), [q, S] = Q(!1), G = (m ? [...new Set(k.map(
|
|
13122
|
+
...Ca(I.root)
|
|
13123
|
+
})), [L, W] = Q({}), [q, S] = Q(!1), G = (m ? [...new Set(k.map(kf).filter(Boolean))].sort() : []).join(",");
|
|
13062
13124
|
ae(() => {
|
|
13063
13125
|
if (!G) return;
|
|
13064
13126
|
let I = !1;
|
|
13065
13127
|
return S(!0), (async () => {
|
|
13066
13128
|
try {
|
|
13067
13129
|
const N = await fetch(
|
|
13068
|
-
`${
|
|
13130
|
+
`${lv}?files=${encodeURIComponent(G)}`
|
|
13069
13131
|
);
|
|
13070
13132
|
if (I || !N.ok) return;
|
|
13071
13133
|
const F = await N.json();
|
|
@@ -13078,20 +13140,21 @@ const vs = ze(function({
|
|
|
13078
13140
|
I = !0;
|
|
13079
13141
|
};
|
|
13080
13142
|
}, [G]);
|
|
13081
|
-
const R = m ?
|
|
13143
|
+
const R = m ? mv({
|
|
13082
13144
|
usageByFile: L,
|
|
13083
13145
|
usageRequested: q,
|
|
13084
13146
|
catalog: k,
|
|
13085
13147
|
consumers: f.pages.filter((I) => I.layersImported === !0).map((I) => ({
|
|
13086
13148
|
frameId: I.id,
|
|
13087
13149
|
name: I.name,
|
|
13088
|
-
...
|
|
13150
|
+
...Ca(I.root)
|
|
13089
13151
|
}))
|
|
13090
13152
|
}) : null, T = new Map(
|
|
13091
13153
|
f.pages.map((I) => [I.id, I.name])
|
|
13092
13154
|
);
|
|
13093
13155
|
return /* @__PURE__ */ g("div", { className: "flex min-h-0 flex-1 flex-col", children: [
|
|
13094
|
-
|
|
13156
|
+
/* @__PURE__ */ s(Rv, {}),
|
|
13157
|
+
t === "story" && /* @__PURE__ */ g(Ye, { children: [
|
|
13095
13158
|
/* @__PURE__ */ g("div", { className: "shrink-0 border-b border-[#e6e6e6] px-3 py-2.5", children: [
|
|
13096
13159
|
/* @__PURE__ */ s("div", { className: "text-[11px] font-semibold text-[#333]", children: "Pages" }),
|
|
13097
13160
|
/* @__PURE__ */ g("div", { className: "mt-1.5 flex flex-col gap-0.5", children: [
|
|
@@ -13126,7 +13189,7 @@ const vs = ze(function({
|
|
|
13126
13189
|
children: [
|
|
13127
13190
|
/* @__PURE__ */ s("span", { className: "w-3 shrink-0 text-[9px] text-[#999]", children: a[I.section] ?? d(I) ? "▾" : "▸" }),
|
|
13128
13191
|
/* @__PURE__ */ s("span", { className: "min-w-0 flex-1 truncate", children: I.section }),
|
|
13129
|
-
/* @__PURE__ */ s(
|
|
13192
|
+
/* @__PURE__ */ s(Lf, { shown: I.frames, declared: I.declared })
|
|
13130
13193
|
]
|
|
13131
13194
|
}
|
|
13132
13195
|
),
|
|
@@ -13165,7 +13228,7 @@ const vs = ze(function({
|
|
|
13165
13228
|
}) })
|
|
13166
13229
|
] }),
|
|
13167
13230
|
E && /* @__PURE__ */ s("div", { className: "min-h-0 flex-1", children: /* @__PURE__ */ s(
|
|
13168
|
-
|
|
13231
|
+
Pv,
|
|
13169
13232
|
{
|
|
13170
13233
|
model: E,
|
|
13171
13234
|
onSelectFrame: n,
|
|
@@ -13175,7 +13238,7 @@ const vs = ze(function({
|
|
|
13175
13238
|
}
|
|
13176
13239
|
) })
|
|
13177
13240
|
] }),
|
|
13178
|
-
t === "frames" && /* @__PURE__ */ g(
|
|
13241
|
+
t === "frames" && /* @__PURE__ */ g(Ye, { children: [
|
|
13179
13242
|
/* @__PURE__ */ g("div", { className: "shrink-0 px-3 pb-2 pt-2.5", style: { height: o }, children: [
|
|
13180
13243
|
/* @__PURE__ */ s("div", { className: "text-[11px] font-semibold text-[#333]", children: "Frames" }),
|
|
13181
13244
|
/* @__PURE__ */ s("div", { className: "mt-1.5 flex h-[calc(100%-1.25rem)] flex-col gap-0.5 overflow-auto", children: f.canvasPages.map((I, N) => {
|
|
@@ -13187,7 +13250,7 @@ const vs = ze(function({
|
|
|
13187
13250
|
/* @__PURE__ */ s("span", { className: "h-px flex-1 bg-[#e6e6e6]" })
|
|
13188
13251
|
] }),
|
|
13189
13252
|
/* @__PURE__ */ s(
|
|
13190
|
-
|
|
13253
|
+
Ev,
|
|
13191
13254
|
{
|
|
13192
13255
|
id: I.id,
|
|
13193
13256
|
name: I.name,
|
|
@@ -13200,7 +13263,7 @@ const vs = ze(function({
|
|
|
13200
13263
|
}) })
|
|
13201
13264
|
] }),
|
|
13202
13265
|
/* @__PURE__ */ s(
|
|
13203
|
-
|
|
13266
|
+
Av,
|
|
13204
13267
|
{
|
|
13205
13268
|
label: "Frames height",
|
|
13206
13269
|
height: o,
|
|
@@ -13208,74 +13271,43 @@ const vs = ze(function({
|
|
|
13208
13271
|
}
|
|
13209
13272
|
),
|
|
13210
13273
|
/* @__PURE__ */ s("div", { className: "px-3 pb-1 pt-1 text-[11px] font-semibold text-[#333]", children: "Layers" }),
|
|
13211
|
-
/* @__PURE__ */ s("div", { className: "min-h-0 flex-1 overflow-auto pb-2", children: /* @__PURE__ */ s(
|
|
13274
|
+
/* @__PURE__ */ s("div", { className: "min-h-0 flex-1 overflow-auto pb-2", children: /* @__PURE__ */ s(Mv, { node: f.root, depth: 0 }) })
|
|
13212
13275
|
] })
|
|
13213
13276
|
] });
|
|
13214
13277
|
});
|
|
13215
|
-
let
|
|
13216
|
-
function
|
|
13278
|
+
let _f = [];
|
|
13279
|
+
function Ul(e, t, n) {
|
|
13217
13280
|
if (!Number.isFinite(e) || e < 1)
|
|
13218
13281
|
throw new Error(
|
|
13219
13282
|
`Viewport preset "${n}" has an invalid ${t}: ${String(e)}.`
|
|
13220
13283
|
);
|
|
13221
13284
|
return Math.round(e);
|
|
13222
13285
|
}
|
|
13223
|
-
function
|
|
13224
|
-
|
|
13286
|
+
function Fv(e) {
|
|
13287
|
+
_f = e.map((t) => {
|
|
13225
13288
|
const n = String(t.label ?? "").trim();
|
|
13226
13289
|
if (!n) throw new Error("Viewport preset is missing a label.");
|
|
13227
13290
|
return {
|
|
13228
13291
|
label: n,
|
|
13229
|
-
width:
|
|
13230
|
-
...t.height == null ? {} : { height:
|
|
13292
|
+
width: Ul(t.width, "width", n),
|
|
13293
|
+
...t.height == null ? {} : { height: Ul(t.height, "height", n) },
|
|
13231
13294
|
...t.description ? { description: t.description } : {}
|
|
13232
13295
|
};
|
|
13233
13296
|
});
|
|
13234
13297
|
}
|
|
13235
|
-
function
|
|
13236
|
-
return
|
|
13298
|
+
function Df() {
|
|
13299
|
+
return _f;
|
|
13237
13300
|
}
|
|
13238
|
-
function
|
|
13301
|
+
function Lv(e, t) {
|
|
13239
13302
|
return Math.round(t.width) !== e.width ? !1 : e.height == null || Math.round(t.height) === e.height;
|
|
13240
13303
|
}
|
|
13241
|
-
|
|
13242
|
-
const Ca = /* @__PURE__ */ new Set();
|
|
13243
|
-
function Rv(e) {
|
|
13244
|
-
po = e.map((t) => {
|
|
13245
|
-
const n = String(t.label ?? "").trim();
|
|
13246
|
-
if (!n) throw new Error("Session preset is missing a label.");
|
|
13247
|
-
return {
|
|
13248
|
-
label: n,
|
|
13249
|
-
...t.environment ? { environment: t.environment } : {},
|
|
13250
|
-
...t.description ? { description: t.description } : {}
|
|
13251
|
-
};
|
|
13252
|
-
}), mo != null && mo >= po.length && Df(null);
|
|
13253
|
-
}
|
|
13254
|
-
function Tv() {
|
|
13255
|
-
return po;
|
|
13256
|
-
}
|
|
13257
|
-
function Ul() {
|
|
13258
|
-
return mo;
|
|
13259
|
-
}
|
|
13260
|
-
function Df(e) {
|
|
13261
|
-
const t = e != null && e >= 0 && e < po.length ? e : null;
|
|
13262
|
-
if (t !== mo) {
|
|
13263
|
-
mo = t, ir(
|
|
13264
|
-
t == null ? void 0 : po[t].environment
|
|
13265
|
-
);
|
|
13266
|
-
for (const n of Ca) n();
|
|
13267
|
-
}
|
|
13268
|
-
}
|
|
13269
|
-
function Fv(e) {
|
|
13270
|
-
return Ca.add(e), () => Ca.delete(e);
|
|
13271
|
-
}
|
|
13272
|
-
function Lv(e, t) {
|
|
13304
|
+
function _v(e, t) {
|
|
13273
13305
|
return Object.entries((t == null ? void 0 : t.props) ?? {}).filter(
|
|
13274
13306
|
([n, r]) => Object.hasOwn(e.sourceProps, n) && r.some((o) => typeof o == typeof e.sourceProps[n])
|
|
13275
13307
|
).map(([n]) => n);
|
|
13276
13308
|
}
|
|
13277
|
-
const
|
|
13278
|
-
function
|
|
13309
|
+
const Dv = 10;
|
|
13310
|
+
function U0(e, t) {
|
|
13279
13311
|
var c, l;
|
|
13280
13312
|
const n = [], r = new Set(t.scenarios.map((d) => d.id)), o = new Map(t.screens.map((d) => [d.id, d])), i = /* @__PURE__ */ new Map();
|
|
13281
13313
|
for (const d of t.screens)
|
|
@@ -13291,7 +13323,7 @@ function V0(e, t) {
|
|
|
13291
13323
|
continue;
|
|
13292
13324
|
}
|
|
13293
13325
|
if (d.kind === "behavior" || d.kind === "todo") {
|
|
13294
|
-
d.reason.trim().length <
|
|
13326
|
+
d.reason.trim().length < Dv && n.push({
|
|
13295
13327
|
severity: "error",
|
|
13296
13328
|
scenarioId: d.scenarioId,
|
|
13297
13329
|
message: `${d.kind} claim needs a substantive reason`
|
|
@@ -13411,7 +13443,7 @@ function V0(e, t) {
|
|
|
13411
13443
|
});
|
|
13412
13444
|
return n;
|
|
13413
13445
|
}
|
|
13414
|
-
function
|
|
13446
|
+
function zv(e) {
|
|
13415
13447
|
return f.pages.find(
|
|
13416
13448
|
(t) => (t.importPageId ?? t.id) === e
|
|
13417
13449
|
) ?? null;
|
|
@@ -13424,13 +13456,13 @@ function zf(e, t) {
|
|
|
13424
13456
|
}
|
|
13425
13457
|
return null;
|
|
13426
13458
|
}
|
|
13427
|
-
function
|
|
13459
|
+
function Ov(e) {
|
|
13428
13460
|
if (e.kind === "behavior" || e.kind === "todo")
|
|
13429
13461
|
return {
|
|
13430
13462
|
status: "failed",
|
|
13431
13463
|
message: "behavior/todo claims have no editor state to reproduce"
|
|
13432
13464
|
};
|
|
13433
|
-
const t =
|
|
13465
|
+
const t = zv(e.screenId);
|
|
13434
13466
|
if (!t)
|
|
13435
13467
|
return { status: "failed", message: `screen "${e.screenId}" is not loaded` };
|
|
13436
13468
|
if (f.selectFrame(t.id), e.kind === "frame" || e.kind === "screen-state" || e.kind === "catalog")
|
|
@@ -13448,7 +13480,7 @@ function zv(e) {
|
|
|
13448
13480
|
};
|
|
13449
13481
|
}
|
|
13450
13482
|
if (e.kind === "viewport") {
|
|
13451
|
-
const r =
|
|
13483
|
+
const r = Df().find(
|
|
13452
13484
|
(o) => o.label === e.preset
|
|
13453
13485
|
);
|
|
13454
13486
|
return r ? (f.resizeFrame(
|
|
@@ -13497,7 +13529,7 @@ function zv(e) {
|
|
|
13497
13529
|
};
|
|
13498
13530
|
}
|
|
13499
13531
|
const so = /* @__PURE__ */ new Map();
|
|
13500
|
-
function
|
|
13532
|
+
function Bv(e) {
|
|
13501
13533
|
so.clear();
|
|
13502
13534
|
for (const t of e) {
|
|
13503
13535
|
if (t.kind === "behavior" || t.kind === "todo") continue;
|
|
@@ -13505,10 +13537,10 @@ function Ov(e) {
|
|
|
13505
13537
|
n.push(t), so.set(t.screenId, n);
|
|
13506
13538
|
}
|
|
13507
13539
|
}
|
|
13508
|
-
function
|
|
13540
|
+
function jv(e) {
|
|
13509
13541
|
return so.get(e) ?? [];
|
|
13510
13542
|
}
|
|
13511
|
-
function
|
|
13543
|
+
function Wv(e, t, n) {
|
|
13512
13544
|
const r = [];
|
|
13513
13545
|
for (const o of so.get(e) ?? [])
|
|
13514
13546
|
o.kind === "component-state" && o.componentName === t && o.prop === n && r.push(o.scenarioId);
|
|
@@ -13527,22 +13559,22 @@ function Fe({
|
|
|
13527
13559
|
/* @__PURE__ */ s("div", { className: "mt-1 flex flex-col gap-1.5", children: n })
|
|
13528
13560
|
] });
|
|
13529
13561
|
}
|
|
13530
|
-
function
|
|
13562
|
+
function Hv(e, t, n, r) {
|
|
13531
13563
|
return Object.hasOwn(e.componentProps, t) ? e.componentProps[t] : r ?? n[0];
|
|
13532
13564
|
}
|
|
13533
13565
|
function Vl(e) {
|
|
13534
13566
|
return typeof e == "boolean" ? e ? "On" : "Off" : String(e);
|
|
13535
13567
|
}
|
|
13536
|
-
function
|
|
13568
|
+
function Uv({
|
|
13537
13569
|
node: e,
|
|
13538
13570
|
entry: t,
|
|
13539
13571
|
sourceWritableProps: n = null,
|
|
13540
13572
|
propBadges: r,
|
|
13541
13573
|
onPatch: o
|
|
13542
13574
|
}) {
|
|
13543
|
-
return /* @__PURE__ */ s(
|
|
13575
|
+
return /* @__PURE__ */ s(Ye, { children: Object.entries(t.props ?? {}).map(([i, a]) => {
|
|
13544
13576
|
var p, m;
|
|
13545
|
-
const c = ((p = t.propLabels) == null ? void 0 : p[i]) ?? i, l =
|
|
13577
|
+
const c = ((p = t.propLabels) == null ? void 0 : p[i]) ?? i, l = Hv(
|
|
13546
13578
|
e,
|
|
13547
13579
|
i,
|
|
13548
13580
|
a,
|
|
@@ -13628,7 +13660,7 @@ function Kl({ kind: e }) {
|
|
|
13628
13660
|
}
|
|
13629
13661
|
) : null;
|
|
13630
13662
|
}
|
|
13631
|
-
const
|
|
13663
|
+
const Vv = Be(function({
|
|
13632
13664
|
page: t
|
|
13633
13665
|
}) {
|
|
13634
13666
|
if (!t.scenario || t.route == null) return null;
|
|
@@ -13711,7 +13743,7 @@ const Uv = ze(function({
|
|
|
13711
13743
|
})
|
|
13712
13744
|
}
|
|
13713
13745
|
) });
|
|
13714
|
-
}),
|
|
13746
|
+
}), Kv = {
|
|
13715
13747
|
frame: "FRAME",
|
|
13716
13748
|
"screen-state": "STATE",
|
|
13717
13749
|
"component-state": "TOGGLE",
|
|
@@ -13720,7 +13752,7 @@ const Uv = ze(function({
|
|
|
13720
13752
|
"interactive-state": "AXIS",
|
|
13721
13753
|
"card-slot": "SLOT",
|
|
13722
13754
|
"list-length": "LIST"
|
|
13723
|
-
},
|
|
13755
|
+
}, qv = /* @__PURE__ */ new Set([
|
|
13724
13756
|
"component-state",
|
|
13725
13757
|
"card-slot",
|
|
13726
13758
|
"list-length"
|
|
@@ -13745,12 +13777,12 @@ function ql(e) {
|
|
|
13745
13777
|
return "this frame";
|
|
13746
13778
|
}
|
|
13747
13779
|
}
|
|
13748
|
-
const
|
|
13780
|
+
const Yv = Be(function({
|
|
13749
13781
|
page: t
|
|
13750
13782
|
}) {
|
|
13751
|
-
const n =
|
|
13783
|
+
const n = jv(t.importPageId ?? t.id);
|
|
13752
13784
|
return n.length === 0 ? null : /* @__PURE__ */ s(Fe, { title: "Scenario coverage", children: n.map((r) => {
|
|
13753
|
-
const o = !f.editMode &&
|
|
13785
|
+
const o = !f.editMode && qv.has(r.kind);
|
|
13754
13786
|
return /* @__PURE__ */ g(
|
|
13755
13787
|
"button",
|
|
13756
13788
|
{
|
|
@@ -13761,33 +13793,33 @@ const qv = ze(function({
|
|
|
13761
13793
|
title: o ? zn : r.reason ?? ql(r),
|
|
13762
13794
|
className: "flex h-7 items-center justify-between gap-2 rounded-md bg-[#fafafa] px-2 text-left ring-1 ring-inset ring-[#ececec] hover:bg-[#f0f7ff] disabled:cursor-not-allowed disabled:opacity-45 disabled:hover:bg-[#fafafa]",
|
|
13763
13795
|
onClick: () => {
|
|
13764
|
-
|
|
13796
|
+
Ov(r);
|
|
13765
13797
|
},
|
|
13766
13798
|
children: [
|
|
13767
13799
|
/* @__PURE__ */ s("span", { className: "truncate text-[11px] font-semibold text-[#333]", children: r.scenarioId }),
|
|
13768
13800
|
/* @__PURE__ */ g("span", { className: "flex shrink-0 items-center gap-1", children: [
|
|
13769
13801
|
/* @__PURE__ */ s("span", { className: "max-w-40 truncate text-[9px] text-[#999]", children: ql(r) }),
|
|
13770
|
-
/* @__PURE__ */ s("span", { className: "rounded bg-[#f0f0f0] px-1 py-0.5 text-[8px] font-semibold tracking-wide text-[#666]", children:
|
|
13802
|
+
/* @__PURE__ */ s("span", { className: "rounded bg-[#f0f0f0] px-1 py-0.5 text-[8px] font-semibold tracking-wide text-[#666]", children: Kv[r.kind] ?? r.kind })
|
|
13771
13803
|
] })
|
|
13772
13804
|
]
|
|
13773
13805
|
},
|
|
13774
13806
|
r.scenarioId
|
|
13775
13807
|
);
|
|
13776
13808
|
}) });
|
|
13777
|
-
}),
|
|
13778
|
-
function
|
|
13809
|
+
}), Gv = "/__pygmalion-storyboard/component-branches", Yl = /* @__PURE__ */ new Map();
|
|
13810
|
+
function Xv(e) {
|
|
13779
13811
|
const t = Yl.get(e);
|
|
13780
13812
|
if (t) return t;
|
|
13781
13813
|
const n = fetch(
|
|
13782
|
-
`${
|
|
13814
|
+
`${Gv}?source=${encodeURIComponent(e)}`
|
|
13783
13815
|
).then((r) => r.ok ? r.json() : { branches: [] }).then((r) => r.branches ?? []).catch(() => []);
|
|
13784
13816
|
return Yl.set(e, n), n;
|
|
13785
13817
|
}
|
|
13786
|
-
function
|
|
13818
|
+
function Jv(e) {
|
|
13787
13819
|
var t, n;
|
|
13788
13820
|
return e.prop ? (((n = (t = lt()[e.component]) == null ? void 0 : t.props) == null ? void 0 : n[e.prop]) ?? []).filter((o) => typeof o == "string") : (e.options ?? []).map((r) => r.label);
|
|
13789
13821
|
}
|
|
13790
|
-
function
|
|
13822
|
+
function Qv({
|
|
13791
13823
|
label: e,
|
|
13792
13824
|
title: t,
|
|
13793
13825
|
ariaLabel: n,
|
|
@@ -13812,7 +13844,7 @@ function Jv({
|
|
|
13812
13844
|
)
|
|
13813
13845
|
] });
|
|
13814
13846
|
}
|
|
13815
|
-
const
|
|
13847
|
+
const Zv = Be(function({
|
|
13816
13848
|
page: t
|
|
13817
13849
|
}) {
|
|
13818
13850
|
const n = dp(), [r, o] = Q({}), i = n.filter(
|
|
@@ -13821,7 +13853,7 @@ const Qv = ze(function({
|
|
|
13821
13853
|
return ae(() => {
|
|
13822
13854
|
let c = !0;
|
|
13823
13855
|
for (const l of a)
|
|
13824
|
-
|
|
13856
|
+
Xv(l).then((d) => {
|
|
13825
13857
|
c && o(
|
|
13826
13858
|
(u) => u[l] ? u : { ...u, [l]: d }
|
|
13827
13859
|
);
|
|
@@ -13832,7 +13864,7 @@ const Qv = ze(function({
|
|
|
13832
13864
|
}, [a.join("|")]), i.length === 0 ? null : /* @__PURE__ */ s(Fe, { title: "Screen dimensions", children: i.map((c) => {
|
|
13833
13865
|
const l = [Wc(t, c)].filter(
|
|
13834
13866
|
Boolean
|
|
13835
|
-
), d =
|
|
13867
|
+
), d = Jv(c), u = new Set(d), m = (c.sourcePath ? r[c.sourcePath] ?? [] : []).filter((b) => {
|
|
13836
13868
|
const x = [b.renders, ...b.values ?? []].filter(
|
|
13837
13869
|
(w) => !!w
|
|
13838
13870
|
);
|
|
@@ -13845,7 +13877,7 @@ const Qv = ze(function({
|
|
|
13845
13877
|
className: "flex flex-col gap-1",
|
|
13846
13878
|
children: [
|
|
13847
13879
|
l.map((b) => /* @__PURE__ */ s(
|
|
13848
|
-
|
|
13880
|
+
Qv,
|
|
13849
13881
|
{
|
|
13850
13882
|
label: c.label,
|
|
13851
13883
|
title: c.component,
|
|
@@ -13885,7 +13917,7 @@ const Qv = ze(function({
|
|
|
13885
13917
|
c.id
|
|
13886
13918
|
);
|
|
13887
13919
|
}) });
|
|
13888
|
-
}),
|
|
13920
|
+
}), ew = Be(function({
|
|
13889
13921
|
page: t
|
|
13890
13922
|
}) {
|
|
13891
13923
|
const n = vd().filter(
|
|
@@ -13937,7 +13969,7 @@ const Qv = ze(function({
|
|
|
13937
13969
|
r.id
|
|
13938
13970
|
);
|
|
13939
13971
|
}) });
|
|
13940
|
-
}),
|
|
13972
|
+
}), tw = Be(function({
|
|
13941
13973
|
page: t
|
|
13942
13974
|
}) {
|
|
13943
13975
|
const n = yd().filter(
|
|
@@ -13982,7 +14014,7 @@ const Qv = ze(function({
|
|
|
13982
14014
|
);
|
|
13983
14015
|
})
|
|
13984
14016
|
] }, o.id)) }, r.id)) });
|
|
13985
|
-
}),
|
|
14017
|
+
}), nw = Be(function({
|
|
13986
14018
|
page: t
|
|
13987
14019
|
}) {
|
|
13988
14020
|
const n = pp(t, xd());
|
|
@@ -14015,7 +14047,7 @@ const Qv = ze(function({
|
|
|
14015
14047
|
r.id
|
|
14016
14048
|
);
|
|
14017
14049
|
}) });
|
|
14018
|
-
}),
|
|
14050
|
+
}), rw = Be(function({
|
|
14019
14051
|
page: t
|
|
14020
14052
|
}) {
|
|
14021
14053
|
const { unclassified: n } = Wu(
|
|
@@ -14044,7 +14076,7 @@ const Qv = ze(function({
|
|
|
14044
14076
|
r.id
|
|
14045
14077
|
))
|
|
14046
14078
|
] });
|
|
14047
|
-
}),
|
|
14079
|
+
}), ow = [
|
|
14048
14080
|
{ v: "fill", label: "Fill" },
|
|
14049
14081
|
{ v: "fit", label: "Hug" },
|
|
14050
14082
|
{ v: "fixed", label: "Fixed" }
|
|
@@ -14058,7 +14090,7 @@ function Ct({ label: e, value: t }) {
|
|
|
14058
14090
|
function Gl(e, t) {
|
|
14059
14091
|
return e === "fixed" ? `${Math.round(t ?? 0)}px` : e;
|
|
14060
14092
|
}
|
|
14061
|
-
const
|
|
14093
|
+
const iw = Be(function({
|
|
14062
14094
|
node: t
|
|
14063
14095
|
}) {
|
|
14064
14096
|
const n = t.type === "component" ? lt()[t.componentName] : void 0, r = Object.entries(t.componentProps ?? {});
|
|
@@ -14076,7 +14108,7 @@ const ow = ze(function({
|
|
|
14076
14108
|
] }),
|
|
14077
14109
|
t.sourceComponent && /* @__PURE__ */ s(Fe, { title: "Source", children: /* @__PURE__ */ s(Ct, { label: "Component", value: t.sourceComponent }) })
|
|
14078
14110
|
] });
|
|
14079
|
-
}),
|
|
14111
|
+
}), sw = Be(function({
|
|
14080
14112
|
section: t,
|
|
14081
14113
|
members: n
|
|
14082
14114
|
}) {
|
|
@@ -14092,7 +14124,7 @@ const ow = ze(function({
|
|
|
14092
14124
|
/* @__PURE__ */ s(Ct, { label: "Frames", value: String(n) })
|
|
14093
14125
|
] }) });
|
|
14094
14126
|
});
|
|
14095
|
-
function
|
|
14127
|
+
function aw({ node: e }) {
|
|
14096
14128
|
const t = f.sharedSourceImpactFor(e);
|
|
14097
14129
|
if (t.frames.length < 2) return null;
|
|
14098
14130
|
const n = f.sharedSourceEditScopeFor(e), r = t.frames.slice(0, 3).map((a) => a.name), o = t.frames.length - r.length, i = `${r.join(" · ")}${o > 0 ? ` · ${o} more` : ""}`;
|
|
@@ -14127,7 +14159,7 @@ function sw({ node: e }) {
|
|
|
14127
14159
|
/* @__PURE__ */ s("div", { className: "text-[10px] leading-relaxed text-[#999]", children: "Unsupported source operations remain limited to the selected frame." })
|
|
14128
14160
|
] });
|
|
14129
14161
|
}
|
|
14130
|
-
function
|
|
14162
|
+
function cw({ node: e }) {
|
|
14131
14163
|
var i;
|
|
14132
14164
|
const t = e.type === "component" ? (i = lt()[e.componentName]) == null ? void 0 : i.props : void 0, n = Object.entries(e.sourceProps).filter(
|
|
14133
14165
|
([a]) => !t || !Object.hasOwn(t, a)
|
|
@@ -14223,7 +14255,7 @@ function Xl({ value: e, onChange: t }) {
|
|
|
14223
14255
|
className: "h-7 min-w-0 flex-1 rounded-md bg-[#f5f5f5] px-1.5 text-[11px] text-[#333] outline-none hover:ring-1 hover:ring-inset hover:ring-[#e6e6e6]",
|
|
14224
14256
|
value: e,
|
|
14225
14257
|
onChange: (n) => t(n.target.value),
|
|
14226
|
-
children:
|
|
14258
|
+
children: ow.map((n) => /* @__PURE__ */ s("option", { value: n.v, children: n.label }, n.v))
|
|
14227
14259
|
}
|
|
14228
14260
|
);
|
|
14229
14261
|
}
|
|
@@ -14235,7 +14267,7 @@ function ii({
|
|
|
14235
14267
|
const [r, o] = Q(!1), [i, a] = Q(""), c = bf(), l = e.startsWith("var("), d = l ? e.slice(4, -1) : "", u = c.find((m) => m.name === d), p = i.trim() ? c.filter((m) => m.name.toLowerCase().includes(i.trim().toLowerCase())) : c;
|
|
14236
14268
|
return /* @__PURE__ */ g("div", { className: "relative", children: [
|
|
14237
14269
|
/* @__PURE__ */ g("div", { className: "flex h-7 items-center gap-1.5 rounded-md bg-[#f5f5f5] px-1.5", children: [
|
|
14238
|
-
l ? /* @__PURE__ */ g(
|
|
14270
|
+
l ? /* @__PURE__ */ g(Ye, { children: [
|
|
14239
14271
|
/* @__PURE__ */ s(
|
|
14240
14272
|
"button",
|
|
14241
14273
|
{
|
|
@@ -14247,7 +14279,7 @@ function ii({
|
|
|
14247
14279
|
}
|
|
14248
14280
|
),
|
|
14249
14281
|
/* @__PURE__ */ s("span", { className: "w-full truncate text-[11px] text-[#333]", children: d })
|
|
14250
|
-
] }) : /* @__PURE__ */ g(
|
|
14282
|
+
] }) : /* @__PURE__ */ g(Ye, { children: [
|
|
14251
14283
|
/* @__PURE__ */ s(
|
|
14252
14284
|
"input",
|
|
14253
14285
|
{
|
|
@@ -14337,7 +14369,7 @@ function Jl({
|
|
|
14337
14369
|
)) });
|
|
14338
14370
|
}
|
|
14339
14371
|
const Ql = ["start", "center", "end"];
|
|
14340
|
-
function
|
|
14372
|
+
function lw({ node: e }) {
|
|
14341
14373
|
const t = e.type === "rows", n = (o, i) => f.patch(
|
|
14342
14374
|
e,
|
|
14343
14375
|
t ? { justify: o, alignItems: i } : { justify: i, alignItems: o }
|
|
@@ -14373,14 +14405,14 @@ function cw({ node: e }) {
|
|
|
14373
14405
|
)
|
|
14374
14406
|
] });
|
|
14375
14407
|
}
|
|
14376
|
-
function
|
|
14408
|
+
function dw(e) {
|
|
14377
14409
|
const t = e.root.domStyle.display;
|
|
14378
14410
|
if (t === "grid" || t === "inline-grid") return "grid";
|
|
14379
14411
|
if (t === "block" || t === "contents") return "free";
|
|
14380
14412
|
const n = e.root.domStyle.flexDirection;
|
|
14381
14413
|
return n != null && n.startsWith("row") ? "horizontal" : n != null && n.startsWith("column") ? "vertical" : e.root.type === "columns" ? "horizontal" : "vertical";
|
|
14382
14414
|
}
|
|
14383
|
-
function
|
|
14415
|
+
function uw({ mode: e }) {
|
|
14384
14416
|
return e === "grid" ? /* @__PURE__ */ s("span", { "aria-hidden": "true", className: "grid h-4 w-4 grid-cols-2 gap-[3px]", children: [0, 1, 2, 3].map((t) => /* @__PURE__ */ s("i", { className: "rounded-[2px] border border-current" }, t)) }) : e === "vertical" || e === "horizontal" ? /* @__PURE__ */ g("span", { "aria-hidden": "true", className: `flex items-center gap-[3px] ${e === "vertical" ? "flex-col" : ""}`, children: [
|
|
14385
14417
|
/* @__PURE__ */ s("i", { className: "h-[5px] w-[5px] rounded-[2px] border border-current" }),
|
|
14386
14418
|
/* @__PURE__ */ s("i", { className: "h-[5px] w-[5px] rounded-[2px] border border-current" }),
|
|
@@ -14391,13 +14423,13 @@ function dw({ mode: e }) {
|
|
|
14391
14423
|
/* @__PURE__ */ s("i", { className: "absolute bottom-0 left-[4px] h-[5px] w-[5px] rounded-[2px] border border-current" })
|
|
14392
14424
|
] });
|
|
14393
14425
|
}
|
|
14394
|
-
const
|
|
14426
|
+
const fw = Be(function({ page: t }) {
|
|
14395
14427
|
Xe(
|
|
14396
14428
|
nc,
|
|
14397
14429
|
$r,
|
|
14398
14430
|
$r
|
|
14399
14431
|
);
|
|
14400
|
-
const n = t.route == null, r = (b) => f.patchPage(t.id, b), o =
|
|
14432
|
+
const n = t.route == null, r = (b) => f.patchPage(t.id, b), o = dw(t), i = (b) => {
|
|
14401
14433
|
const x = { ...t.root.domStyle };
|
|
14402
14434
|
b === "free" ? (x.display = "block", x.position = "relative", delete x.flexDirection, delete x.gridTemplateColumns) : b === "grid" ? (x.display = "grid", x.gridTemplateColumns || (x.gridTemplateColumns = "repeat(2, minmax(0, 1fr))"), x.gap || (x.gap = `${t.root.gap}px`), delete x.flexDirection) : (x.display = "flex", x.flexDirection = b === "horizontal" ? "row" : "column", delete x.gridTemplateColumns), f.patch(t.root, {
|
|
14403
14435
|
type: b === "horizontal" ? "columns" : "rows",
|
|
@@ -14426,7 +14458,7 @@ const uw = ze(function({ page: t }) {
|
|
|
14426
14458
|
resizeHeight: b.height != null
|
|
14427
14459
|
}
|
|
14428
14460
|
);
|
|
14429
|
-
}, d =
|
|
14461
|
+
}, d = Df(), u = eg(), p = t.authoredFrameSize, m = f.frameSizeDiffersFromAuthored(t.id);
|
|
14430
14462
|
return /* @__PURE__ */ g("div", { "data-object-props": "frame", className: "min-h-0 flex-1 overflow-auto", children: [
|
|
14431
14463
|
f.editMode ? /* @__PURE__ */ s(Fe, { title: "Frame", children: /* @__PURE__ */ s(
|
|
14432
14464
|
"input",
|
|
@@ -14474,7 +14506,7 @@ const uw = ze(function({ page: t }) {
|
|
|
14474
14506
|
"aria-label": "Preview viewport",
|
|
14475
14507
|
className: "flex flex-wrap gap-1",
|
|
14476
14508
|
children: d.map((b) => {
|
|
14477
|
-
const x =
|
|
14509
|
+
const x = Lv(b, {
|
|
14478
14510
|
width: t.width ?? 390,
|
|
14479
14511
|
height: t.height ?? 600
|
|
14480
14512
|
});
|
|
@@ -14557,16 +14589,16 @@ const uw = ze(function({ page: t }) {
|
|
|
14557
14589
|
b.id
|
|
14558
14590
|
))
|
|
14559
14591
|
] }),
|
|
14560
|
-
/* @__PURE__ */ s(
|
|
14561
|
-
/* @__PURE__ */ s(tw, { page: t }),
|
|
14592
|
+
/* @__PURE__ */ s(Vv, { page: t }),
|
|
14562
14593
|
/* @__PURE__ */ s(nw, { page: t }),
|
|
14563
|
-
|
|
14564
|
-
|
|
14565
|
-
/* @__PURE__ */ s(
|
|
14566
|
-
/* @__PURE__ */ s(
|
|
14594
|
+
/* @__PURE__ */ s(rw, { page: t }),
|
|
14595
|
+
f.editMode && /* @__PURE__ */ g(Ye, { children: [
|
|
14596
|
+
/* @__PURE__ */ s(Zv, { page: t }),
|
|
14597
|
+
/* @__PURE__ */ s(tw, { page: t }),
|
|
14598
|
+
/* @__PURE__ */ s(ew, { page: t })
|
|
14567
14599
|
] }),
|
|
14568
|
-
/* @__PURE__ */ s(
|
|
14569
|
-
f.editMode && /* @__PURE__ */ g(
|
|
14600
|
+
/* @__PURE__ */ s(Yv, { page: t }),
|
|
14601
|
+
f.editMode && /* @__PURE__ */ g(Ye, { children: [
|
|
14570
14602
|
/* @__PURE__ */ g(Fe, { title: "Position", children: [
|
|
14571
14603
|
/* @__PURE__ */ s("div", { className: "grid grid-cols-6 gap-1", children: [
|
|
14572
14604
|
["left alignment", "x", "start", /* @__PURE__ */ s(Qu, { size: 13 }, "left")],
|
|
@@ -14629,7 +14661,7 @@ const uw = ze(function({ page: t }) {
|
|
|
14629
14661
|
"aria-pressed": o === b,
|
|
14630
14662
|
className: `flex h-8 items-center justify-center rounded-md ${o === b ? "bg-white text-[#18181b] shadow-sm ring-1 ring-inset ring-[#dedee3]" : "text-[#777] hover:text-[#333]"}`,
|
|
14631
14663
|
onClick: () => i(b),
|
|
14632
|
-
children: /* @__PURE__ */ s(
|
|
14664
|
+
children: /* @__PURE__ */ s(uw, { mode: b })
|
|
14633
14665
|
},
|
|
14634
14666
|
b
|
|
14635
14667
|
)) }),
|
|
@@ -14662,7 +14694,7 @@ const uw = ze(function({ page: t }) {
|
|
|
14662
14694
|
] }),
|
|
14663
14695
|
/* @__PURE__ */ s(ii, { value: t.fill ?? "#ffffff", onChange: (b) => r({ fill: b }) })
|
|
14664
14696
|
] }),
|
|
14665
|
-
/* @__PURE__ */ s(Fe, { title: "Screen", children: n ? /* @__PURE__ */ g(
|
|
14697
|
+
/* @__PURE__ */ s(Fe, { title: "Screen", children: n ? /* @__PURE__ */ g(Ye, { children: [
|
|
14666
14698
|
/* @__PURE__ */ s(
|
|
14667
14699
|
"input",
|
|
14668
14700
|
{
|
|
@@ -14710,7 +14742,7 @@ const uw = ze(function({ page: t }) {
|
|
|
14710
14742
|
] })
|
|
14711
14743
|
] })
|
|
14712
14744
|
] });
|
|
14713
|
-
}),
|
|
14745
|
+
}), hw = Be(function({ section: t }) {
|
|
14714
14746
|
const n = f.canvasPages.filter((r) => r.section === t.name).length;
|
|
14715
14747
|
return f.editMode ? /* @__PURE__ */ g("div", { "data-object-props": "section", className: "min-h-0 flex-1 overflow-auto", children: [
|
|
14716
14748
|
/* @__PURE__ */ g(Fe, { title: "Section", children: [
|
|
@@ -14786,48 +14818,16 @@ const uw = ze(function({ page: t }) {
|
|
|
14786
14818
|
]
|
|
14787
14819
|
}
|
|
14788
14820
|
) })
|
|
14789
|
-
] }) : /* @__PURE__ */ s(
|
|
14790
|
-
}),
|
|
14791
|
-
const t = Xe(
|
|
14792
|
-
Fv,
|
|
14793
|
-
Ul,
|
|
14794
|
-
// The selection is a module value, so it reads the same on both sides —
|
|
14795
|
-
// and the panel renders server-side in tests, which requires this.
|
|
14796
|
-
Ul
|
|
14797
|
-
), n = Tv();
|
|
14798
|
-
return n.length === 0 ? null : /* @__PURE__ */ g("div", { className: "border-b border-[#e5e5e5] px-3 py-2", children: [
|
|
14799
|
-
/* @__PURE__ */ s("div", { className: "mb-1.5 text-[10px] font-semibold uppercase tracking-wide text-[#999]", children: "Runtime" }),
|
|
14800
|
-
/* @__PURE__ */ s("div", { role: "group", "aria-label": "Runtime", className: "flex flex-wrap gap-1", children: n.map((r, o) => {
|
|
14801
|
-
const i = t === o;
|
|
14802
|
-
return /* @__PURE__ */ s(
|
|
14803
|
-
"button",
|
|
14804
|
-
{
|
|
14805
|
-
type: "button",
|
|
14806
|
-
"data-session-preset": r.label,
|
|
14807
|
-
"aria-pressed": i,
|
|
14808
|
-
title: r.description,
|
|
14809
|
-
className: `h-8 min-w-[56px] flex-1 rounded-md px-2 text-[11px] font-semibold ${i ? "bg-[#e5f4ff] text-[#0d99ff]" : "bg-[#f5f5f5] text-[#555] hover:bg-[#ececec] hover:text-[#333]"}`,
|
|
14810
|
-
onClick: () => Df(i ? null : o),
|
|
14811
|
-
children: r.label
|
|
14812
|
-
},
|
|
14813
|
-
r.label
|
|
14814
|
-
);
|
|
14815
|
-
}) })
|
|
14816
|
-
] });
|
|
14817
|
-
}), pw = ze(function() {
|
|
14818
|
-
return /* @__PURE__ */ g(qe, { children: [
|
|
14819
|
-
/* @__PURE__ */ s(hw, {}),
|
|
14820
|
-
/* @__PURE__ */ s(mw, {})
|
|
14821
|
-
] });
|
|
14822
|
-
}), mw = ze(function() {
|
|
14821
|
+
] }) : /* @__PURE__ */ s(sw, { section: t, members: n });
|
|
14822
|
+
}), pw = Be(function() {
|
|
14823
14823
|
var l, d;
|
|
14824
14824
|
if (((l = f.selectedCanvasObject) == null ? void 0 : l.kind) === "frame") {
|
|
14825
14825
|
const u = f.selectedFrame;
|
|
14826
|
-
return u ? /* @__PURE__ */ s(
|
|
14826
|
+
return u ? /* @__PURE__ */ s(fw, { page: u }) : null;
|
|
14827
14827
|
}
|
|
14828
14828
|
if (((d = f.selectedCanvasObject) == null ? void 0 : d.kind) === "section") {
|
|
14829
14829
|
const u = f.selectedSection;
|
|
14830
|
-
return u ? /* @__PURE__ */ s(
|
|
14830
|
+
return u ? /* @__PURE__ */ s(hw, { section: u }) : null;
|
|
14831
14831
|
}
|
|
14832
14832
|
const t = f.selected;
|
|
14833
14833
|
if (!t)
|
|
@@ -14842,8 +14842,8 @@ const uw = ze(function({ page: t }) {
|
|
|
14842
14842
|
f.selectedIds.length,
|
|
14843
14843
|
" selected · Property edits use the primary selection"
|
|
14844
14844
|
] }),
|
|
14845
|
-
/* @__PURE__ */ s(sw, { node: t }),
|
|
14846
14845
|
/* @__PURE__ */ s(aw, { node: t }),
|
|
14846
|
+
/* @__PURE__ */ s(cw, { node: t }),
|
|
14847
14847
|
/* @__PURE__ */ s(Fe, { title: t.name, children: /* @__PURE__ */ s(
|
|
14848
14848
|
"input",
|
|
14849
14849
|
{
|
|
@@ -14871,15 +14871,15 @@ const uw = ze(function({ page: t }) {
|
|
|
14871
14871
|
t.componentName
|
|
14872
14872
|
] }),
|
|
14873
14873
|
a && /* @__PURE__ */ s(
|
|
14874
|
-
|
|
14874
|
+
Uv,
|
|
14875
14875
|
{
|
|
14876
14876
|
node: t,
|
|
14877
14877
|
entry: a,
|
|
14878
|
-
sourceWritableProps: t.sourceComponent ?
|
|
14878
|
+
sourceWritableProps: t.sourceComponent ? _v(t, a) : null,
|
|
14879
14879
|
propBadges: Object.fromEntries(
|
|
14880
14880
|
Object.keys(a.props ?? {}).map((u) => [
|
|
14881
14881
|
u,
|
|
14882
|
-
|
|
14882
|
+
Wv(
|
|
14883
14883
|
f.activePage.importPageId ?? f.activePage.id,
|
|
14884
14884
|
t.componentName,
|
|
14885
14885
|
u
|
|
@@ -14912,7 +14912,7 @@ const uw = ze(function({ page: t }) {
|
|
|
14912
14912
|
onChange: (u) => n({ type: u })
|
|
14913
14913
|
}
|
|
14914
14914
|
),
|
|
14915
|
-
/* @__PURE__ */ s(
|
|
14915
|
+
/* @__PURE__ */ s(lw, { node: t }),
|
|
14916
14916
|
/* @__PURE__ */ g("div", { className: "flex gap-1.5", children: [
|
|
14917
14917
|
/* @__PURE__ */ s(ct, { label: "Gap", value: t.gap, onChange: (u) => n({ gap: u }) }),
|
|
14918
14918
|
/* @__PURE__ */ s(ct, { label: "Padding", value: t.padding, onChange: (u) => n({ padding: u }) })
|
|
@@ -14961,7 +14961,7 @@ const uw = ze(function({ page: t }) {
|
|
|
14961
14961
|
children: /* @__PURE__ */ s(Ii, { size: 12 })
|
|
14962
14962
|
}
|
|
14963
14963
|
),
|
|
14964
|
-
children: t.borderWidth > 0 ? /* @__PURE__ */ g(
|
|
14964
|
+
children: t.borderWidth > 0 ? /* @__PURE__ */ g(Ye, { children: [
|
|
14965
14965
|
/* @__PURE__ */ s(
|
|
14966
14966
|
ii,
|
|
14967
14967
|
{
|
|
@@ -15027,9 +15027,9 @@ const uw = ze(function({ page: t }) {
|
|
|
15027
15027
|
),
|
|
15028
15028
|
/* @__PURE__ */ s(ii, { value: t.color, onChange: (u) => n({ color: u }) })
|
|
15029
15029
|
] })
|
|
15030
|
-
] }) : /* @__PURE__ */ s(
|
|
15031
|
-
}),
|
|
15032
|
-
return /* @__PURE__ */ g(
|
|
15030
|
+
] }) : /* @__PURE__ */ s(iw, { node: t });
|
|
15031
|
+
}), mw = Be(function() {
|
|
15032
|
+
return /* @__PURE__ */ g(Ye, { children: [
|
|
15033
15033
|
/* @__PURE__ */ s(
|
|
15034
15034
|
"button",
|
|
15035
15035
|
{
|
|
@@ -15056,8 +15056,8 @@ const uw = ze(function({ page: t }) {
|
|
|
15056
15056
|
)
|
|
15057
15057
|
] });
|
|
15058
15058
|
});
|
|
15059
|
-
|
|
15060
|
-
return /* @__PURE__ */ g(
|
|
15059
|
+
Be(function() {
|
|
15060
|
+
return /* @__PURE__ */ g(Ye, { children: [
|
|
15061
15061
|
/* @__PURE__ */ s(
|
|
15062
15062
|
"button",
|
|
15063
15063
|
{
|
|
@@ -15082,7 +15082,7 @@ ze(function() {
|
|
|
15082
15082
|
)
|
|
15083
15083
|
] });
|
|
15084
15084
|
});
|
|
15085
|
-
function
|
|
15085
|
+
function gw(e) {
|
|
15086
15086
|
return [...new Set(e)].sort().join(`
|
|
15087
15087
|
`);
|
|
15088
15088
|
}
|
|
@@ -15093,10 +15093,10 @@ function Zl(e, t) {
|
|
|
15093
15093
|
r - t.viewportHeight / 2
|
|
15094
15094
|
);
|
|
15095
15095
|
}
|
|
15096
|
-
function
|
|
15096
|
+
function bw(e, t) {
|
|
15097
15097
|
return e === t ? 0 : e < t ? -1 : 1;
|
|
15098
15098
|
}
|
|
15099
|
-
function
|
|
15099
|
+
function xw(e, t = {}) {
|
|
15100
15100
|
const n = t.hasSnapshot ?? (() => !1), r = [], o = [], i = /* @__PURE__ */ new Set();
|
|
15101
15101
|
for (const p of e)
|
|
15102
15102
|
if (!n(p.key)) {
|
|
@@ -15107,7 +15107,7 @@ function yw(e, t = {}) {
|
|
|
15107
15107
|
i.has(p.key) || (i.add(p.key), o.push(p));
|
|
15108
15108
|
}
|
|
15109
15109
|
const a = o.map((p, m) => ({ candidate: p, order: m })).sort(
|
|
15110
|
-
(p, m) =>
|
|
15110
|
+
(p, m) => bw(p.candidate.distance, m.candidate.distance) || p.order - m.order
|
|
15111
15111
|
).map((p) => p.candidate), c = /* @__PURE__ */ new Map();
|
|
15112
15112
|
for (const p of a) {
|
|
15113
15113
|
if (p.groupKey == null) continue;
|
|
@@ -15136,33 +15136,33 @@ function yw(e, t = {}) {
|
|
|
15136
15136
|
}
|
|
15137
15137
|
return { units: l, interactionFrames: r };
|
|
15138
15138
|
}
|
|
15139
|
-
const
|
|
15139
|
+
const yw = 250, vw = 8, ww = 32, Sw = /* @__PURE__ */ new Set();
|
|
15140
15140
|
let ed = {
|
|
15141
15141
|
phase: "idle",
|
|
15142
15142
|
total: 0,
|
|
15143
15143
|
completed: 0,
|
|
15144
15144
|
failed: 0
|
|
15145
15145
|
};
|
|
15146
|
-
function
|
|
15146
|
+
function Nw(e) {
|
|
15147
15147
|
const t = ed;
|
|
15148
15148
|
if (!(t.phase === e.phase && t.total === e.total && t.completed === e.completed && t.failed === e.failed)) {
|
|
15149
15149
|
ed = e;
|
|
15150
|
-
for (const n of
|
|
15150
|
+
for (const n of Sw) n();
|
|
15151
15151
|
}
|
|
15152
15152
|
}
|
|
15153
|
-
function
|
|
15153
|
+
function Iw(e, t = {}) {
|
|
15154
15154
|
const n = Math.max(
|
|
15155
15155
|
1,
|
|
15156
|
-
t.pauseBackoffMs ??
|
|
15156
|
+
t.pauseBackoffMs ?? yw
|
|
15157
15157
|
), r = Math.max(
|
|
15158
15158
|
1,
|
|
15159
|
-
t.interactionChunkSize ??
|
|
15159
|
+
t.interactionChunkSize ?? vw
|
|
15160
15160
|
), o = Math.max(
|
|
15161
15161
|
0,
|
|
15162
|
-
t.interactionRequestCap ??
|
|
15162
|
+
t.interactionRequestCap ?? ww
|
|
15163
15163
|
);
|
|
15164
15164
|
let i = 0, a = !1, c = null, l = 0, d = 0, u = 0;
|
|
15165
|
-
const p = (E) => new Promise((k) => setTimeout(k, E)), m = (E) =>
|
|
15165
|
+
const p = (E) => new Promise((k) => setTimeout(k, E)), m = (E) => Nw({ phase: E, total: l, completed: d, failed: u }), b = (E, k) => {
|
|
15166
15166
|
if (E)
|
|
15167
15167
|
try {
|
|
15168
15168
|
k ? E.discard() : E.release();
|
|
@@ -15229,7 +15229,7 @@ function Cw(e, t = {}) {
|
|
|
15229
15229
|
}
|
|
15230
15230
|
return { run: w, cancel: v };
|
|
15231
15231
|
}
|
|
15232
|
-
const td = "absolute z-20 flex flex-col overflow-hidden rounded-[13px] border border-[#e6e6e6] bg-white shadow-[0_2px_14px_rgba(0,0,0,.08)]",
|
|
15232
|
+
const td = "absolute z-20 flex flex-col overflow-hidden rounded-[13px] border border-[#e6e6e6] bg-white shadow-[0_2px_14px_rgba(0,0,0,.08)]", Cw = 600, bn = 200, an = 280, Pw = 480, ws = "absolute bottom-11 left-1/2 z-40 w-44 -translate-x-1/2 rounded-xl bg-[#1e1e1e] p-1.5 text-[12px] shadow-[0_4px_20px_rgba(0,0,0,.25)]", Xr = (e) => `flex h-9 w-9 items-center justify-center rounded-lg ${e ? "bg-[#0d99ff] text-white" : "text-[#333] hover:bg-[#f5f5f5]"}`;
|
|
15233
15233
|
function Ln({
|
|
15234
15234
|
icon: e,
|
|
15235
15235
|
label: t,
|
|
@@ -15257,7 +15257,7 @@ function Ln({
|
|
|
15257
15257
|
)
|
|
15258
15258
|
);
|
|
15259
15259
|
}
|
|
15260
|
-
const
|
|
15260
|
+
const $w = Be(function({
|
|
15261
15261
|
previewIdentityReady: t = !0
|
|
15262
15262
|
} = {}) {
|
|
15263
15263
|
var wt;
|
|
@@ -15280,10 +15280,10 @@ const Mw = ze(function({
|
|
|
15280
15280
|
$r
|
|
15281
15281
|
);
|
|
15282
15282
|
const l = Xe(
|
|
15283
|
-
|
|
15284
|
-
|
|
15285
|
-
|
|
15286
|
-
), d = t ? l : null, p = (d ?
|
|
15283
|
+
Ef,
|
|
15284
|
+
mo,
|
|
15285
|
+
mo
|
|
15286
|
+
), d = t ? l : null, p = (d ? Af(
|
|
15287
15287
|
d,
|
|
15288
15288
|
f.canvasPages.map((_) => ({
|
|
15289
15289
|
frameId: _.id,
|
|
@@ -15317,7 +15317,7 @@ const Mw = ze(function({
|
|
|
15317
15317
|
)
|
|
15318
15318
|
])
|
|
15319
15319
|
)
|
|
15320
|
-
], w =
|
|
15320
|
+
], w = gw(x), [v, E] = Q("");
|
|
15321
15321
|
ae(() => {
|
|
15322
15322
|
let _ = !0;
|
|
15323
15323
|
return E(""), t ? (Qa(x).then(() => {
|
|
@@ -15381,9 +15381,9 @@ const Mw = ze(function({
|
|
|
15381
15381
|
...oe && We ? { frame: { id: ne, fingerprint: We } } : {}
|
|
15382
15382
|
});
|
|
15383
15383
|
}
|
|
15384
|
-
const ue =
|
|
15384
|
+
const ue = xw(Me, {
|
|
15385
15385
|
hasSnapshot: Gn
|
|
15386
|
-
}), K = cc(), Ie =
|
|
15386
|
+
}), K = cc(), Ie = Iw({
|
|
15387
15387
|
leaseInstance: async (V) => {
|
|
15388
15388
|
const Ne = B.get(V.pageId);
|
|
15389
15389
|
if (!Ne || Ne.route == null) return null;
|
|
@@ -15417,22 +15417,22 @@ const Mw = ze(function({
|
|
|
15417
15417
|
try {
|
|
15418
15418
|
await new Promise((le, Ge) => {
|
|
15419
15419
|
const He = () => {
|
|
15420
|
-
ne.removeEventListener("load",
|
|
15421
|
-
},
|
|
15420
|
+
ne.removeEventListener("load", Oe), ne.removeEventListener("error", Ue);
|
|
15421
|
+
}, Oe = () => {
|
|
15422
15422
|
He(), le();
|
|
15423
15423
|
}, Ue = () => {
|
|
15424
15424
|
He(), Ge(new Error(`The sweep preview failed to load ${oe}.`));
|
|
15425
15425
|
};
|
|
15426
|
-
ne.addEventListener("load",
|
|
15426
|
+
ne.addEventListener("load", Oe), ne.addEventListener("error", Ue), ne.src = oe;
|
|
15427
15427
|
});
|
|
15428
15428
|
} catch (le) {
|
|
15429
15429
|
throw ne.remove(), le;
|
|
15430
15430
|
}
|
|
15431
15431
|
let We = !1;
|
|
15432
|
-
const
|
|
15432
|
+
const ze = () => {
|
|
15433
15433
|
We || (We = !0, ne.remove());
|
|
15434
15434
|
};
|
|
15435
|
-
return { reused: !1, iframe: ne, release:
|
|
15435
|
+
return { reused: !1, iframe: ne, release: ze, discard: ze };
|
|
15436
15436
|
},
|
|
15437
15437
|
produce: (V, Ne, re) => {
|
|
15438
15438
|
const U = B.get(V.pageId), oe = Ne == null ? void 0 : Ne.iframe;
|
|
@@ -15557,28 +15557,28 @@ const Mw = ze(function({
|
|
|
15557
15557
|
preset: oe.preset,
|
|
15558
15558
|
interactions: oe.interactions,
|
|
15559
15559
|
assertions: oe.assertions
|
|
15560
|
-
},
|
|
15560
|
+
}, ze = wi(
|
|
15561
15561
|
We,
|
|
15562
15562
|
a,
|
|
15563
15563
|
_
|
|
15564
15564
|
);
|
|
15565
|
-
if (!
|
|
15565
|
+
if (!ze || go(jt(oe, a)))
|
|
15566
15566
|
continue;
|
|
15567
|
-
const le = Jt(ne,
|
|
15567
|
+
const le = Jt(ne, ze), Ge = (oe.canvas ?? "default") === q;
|
|
15568
15568
|
le.status === "error" && le.reason !== "not-prepared" && Ge && V.add(ne);
|
|
15569
15569
|
const He = le.status === "error" && le.reason === "not-prepared";
|
|
15570
15570
|
if (Ge && (le.status === "outdated" || le.status === "generating" || le.status === "checking" || He) && (Ne += 1), le.status !== "outdated" && !(He && ue))
|
|
15571
15571
|
continue;
|
|
15572
|
-
const
|
|
15572
|
+
const Oe = oe.width ?? 390, Ue = cn(oe), Te = oe.canvas ?? "default";
|
|
15573
15573
|
ve.push({
|
|
15574
15574
|
pageId: oe.id,
|
|
15575
15575
|
canonicalId: ne,
|
|
15576
15576
|
canvas: Te,
|
|
15577
15577
|
distance: Ie && Te === q ? Zl(
|
|
15578
|
-
{ x: oe.x ?? 0, y: oe.y ?? 0, width:
|
|
15578
|
+
{ x: oe.x ?? 0, y: oe.y ?? 0, width: Oe, height: Ue },
|
|
15579
15579
|
Ie
|
|
15580
15580
|
) : Number.POSITIVE_INFINITY,
|
|
15581
|
-
fingerprint:
|
|
15581
|
+
fingerprint: ze,
|
|
15582
15582
|
...(() => {
|
|
15583
15583
|
const Ve = lc(We, _);
|
|
15584
15584
|
return Ve ? { recipe: Ve } : {};
|
|
@@ -15624,7 +15624,7 @@ const Mw = ze(function({
|
|
|
15624
15624
|
(te) => te.id === G
|
|
15625
15625
|
);
|
|
15626
15626
|
he && Cu(he, a);
|
|
15627
|
-
},
|
|
15627
|
+
}, Cw);
|
|
15628
15628
|
return () => clearTimeout(_);
|
|
15629
15629
|
}, [
|
|
15630
15630
|
R,
|
|
@@ -15880,7 +15880,7 @@ const Mw = ze(function({
|
|
|
15880
15880
|
const te = he.clientX, xe = _ === "left" ? se : Se, B = (ue) => {
|
|
15881
15881
|
const K = _ === "left" ? ue.clientX - te : te - ue.clientX, Ie = Math.max(
|
|
15882
15882
|
bn,
|
|
15883
|
-
Math.min(
|
|
15883
|
+
Math.min(Pw, xe + K)
|
|
15884
15884
|
);
|
|
15885
15885
|
_ === "left" ? Ee(Ie) : be(Ie);
|
|
15886
15886
|
}, Me = () => {
|
|
@@ -16138,7 +16138,7 @@ const Mw = ze(function({
|
|
|
16138
16138
|
)) })
|
|
16139
16139
|
] }),
|
|
16140
16140
|
/* @__PURE__ */ s(
|
|
16141
|
-
|
|
16141
|
+
Tv,
|
|
16142
16142
|
{
|
|
16143
16143
|
view: O,
|
|
16144
16144
|
onFrameFocus: _e,
|
|
@@ -16314,7 +16314,7 @@ const Mw = ze(function({
|
|
|
16314
16314
|
children: "↔"
|
|
16315
16315
|
}
|
|
16316
16316
|
),
|
|
16317
|
-
/* @__PURE__ */ s(
|
|
16317
|
+
/* @__PURE__ */ s(mw, {})
|
|
16318
16318
|
] })
|
|
16319
16319
|
] }),
|
|
16320
16320
|
/* @__PURE__ */ s(pw, {}),
|
|
@@ -16567,12 +16567,12 @@ const Mw = ze(function({
|
|
|
16567
16567
|
]
|
|
16568
16568
|
}
|
|
16569
16569
|
);
|
|
16570
|
-
}),
|
|
16571
|
-
function
|
|
16570
|
+
}), Mw = 1, Ew = 4;
|
|
16571
|
+
function kw() {
|
|
16572
16572
|
if (!(typeof navigator > "u"))
|
|
16573
16573
|
return navigator.deviceMemory;
|
|
16574
16574
|
}
|
|
16575
|
-
function
|
|
16575
|
+
function Aw(e, t, n, r = Mw) {
|
|
16576
16576
|
const o = /* @__PURE__ */ new Map();
|
|
16577
16577
|
return e.forEach((i, a) => {
|
|
16578
16578
|
if (!ac(i)) return;
|
|
@@ -16603,7 +16603,7 @@ function Rw(e, t, n, r = Ew) {
|
|
|
16603
16603
|
});
|
|
16604
16604
|
}), [...o.values()].sort((i, a) => a.members - i.members || i.order - a.order).slice(0, Math.max(0, r)).map((i) => i.target);
|
|
16605
16605
|
}
|
|
16606
|
-
function
|
|
16606
|
+
function Rw(e, t, n) {
|
|
16607
16607
|
if (!e) return [];
|
|
16608
16608
|
const r = (p) => p.importPageId ?? p.id, o = t.find((p) => p.id === n);
|
|
16609
16609
|
if (!o) return [];
|
|
@@ -16636,13 +16636,13 @@ function Tw(e, t, n) {
|
|
|
16636
16636
|
}
|
|
16637
16637
|
return d;
|
|
16638
16638
|
}
|
|
16639
|
-
function
|
|
16640
|
-
const t = e.deviceMemoryGb ??
|
|
16641
|
-
if (t != null && t <
|
|
16639
|
+
function Tw(e) {
|
|
16640
|
+
const t = e.deviceMemoryGb ?? kw();
|
|
16641
|
+
if (t != null && t < Ew)
|
|
16642
16642
|
return () => {
|
|
16643
16643
|
};
|
|
16644
|
-
const n = e.instances ?? cc(), r = e.getGraph ??
|
|
16645
|
-
for (const o of
|
|
16644
|
+
const n = e.instances ?? cc(), r = e.getGraph ?? mo;
|
|
16645
|
+
for (const o of Aw(
|
|
16646
16646
|
e.getPages(),
|
|
16647
16647
|
e.appOrigin,
|
|
16648
16648
|
e.baselineEnvironment
|
|
@@ -16653,7 +16653,7 @@ function Fw(e) {
|
|
|
16653
16653
|
() => e.editor.activePageId,
|
|
16654
16654
|
(o) => {
|
|
16655
16655
|
if (!o) return;
|
|
16656
|
-
const i =
|
|
16656
|
+
const i = Rw(
|
|
16657
16657
|
r(),
|
|
16658
16658
|
e.getPages(),
|
|
16659
16659
|
o
|
|
@@ -16665,7 +16665,7 @@ function Fw(e) {
|
|
|
16665
16665
|
}
|
|
16666
16666
|
);
|
|
16667
16667
|
}
|
|
16668
|
-
function
|
|
16668
|
+
function Fw(e) {
|
|
16669
16669
|
return e.flatMap((t, n) => {
|
|
16670
16670
|
const r = t.id.trim() || `path:${n + 1}`, o = t.screenIds.map((i) => i.trim()).filter(Boolean);
|
|
16671
16671
|
return o.slice(1).map((i, a) => {
|
|
@@ -16696,7 +16696,7 @@ function Pa(e, t = /* @__PURE__ */ new Set()) {
|
|
|
16696
16696
|
}
|
|
16697
16697
|
return t.delete(e), n;
|
|
16698
16698
|
}
|
|
16699
|
-
function
|
|
16699
|
+
function Lw(e) {
|
|
16700
16700
|
return JSON.stringify(
|
|
16701
16701
|
Pa({
|
|
16702
16702
|
version: 1,
|
|
@@ -16720,11 +16720,11 @@ function _w(e) {
|
|
|
16720
16720
|
function ut(e) {
|
|
16721
16721
|
return [...new Set([...e].map((t) => t == null ? void 0 : t.trim()).filter(Boolean))].sort((t, n) => t.localeCompare(n));
|
|
16722
16722
|
}
|
|
16723
|
-
function
|
|
16723
|
+
function _w(e, t) {
|
|
16724
16724
|
var r;
|
|
16725
16725
|
return ((r = e.id) == null ? void 0 : r.trim()) || `edge:${t + 1}`;
|
|
16726
16726
|
}
|
|
16727
|
-
function
|
|
16727
|
+
function Dw(e) {
|
|
16728
16728
|
const t = [...e.screens].sort((r, o) => r.id.localeCompare(o.id)), n = t[0].id;
|
|
16729
16729
|
return {
|
|
16730
16730
|
id: `story:${n}`,
|
|
@@ -16753,7 +16753,7 @@ function nd(e) {
|
|
|
16753
16753
|
e.scenarioId
|
|
16754
16754
|
].join(":");
|
|
16755
16755
|
}
|
|
16756
|
-
function
|
|
16756
|
+
function zw(e) {
|
|
16757
16757
|
var ce, ie;
|
|
16758
16758
|
const t = [], n = [], r = /* @__PURE__ */ new Map();
|
|
16759
16759
|
for (const P of e.screens) {
|
|
@@ -16774,7 +16774,7 @@ function Ow(e) {
|
|
|
16774
16774
|
for (const P of n) {
|
|
16775
16775
|
let A;
|
|
16776
16776
|
try {
|
|
16777
|
-
if (A = (e.recipeKey ??
|
|
16777
|
+
if (A = (e.recipeKey ?? Lw)(P), !A.trim()) throw new Error("Recipe keys cannot be empty.");
|
|
16778
16778
|
} catch ($) {
|
|
16779
16779
|
i.add(P.id), t.push({
|
|
16780
16780
|
code: "invalid-recipe",
|
|
@@ -16786,7 +16786,7 @@ function Ow(e) {
|
|
|
16786
16786
|
const M = o.get(A);
|
|
16787
16787
|
M ? M.screens.push(P) : o.set(A, { recipeKey: A, screens: [P] });
|
|
16788
16788
|
}
|
|
16789
|
-
const a = [...o.values()].map(
|
|
16789
|
+
const a = [...o.values()].map(Dw).sort((P, A) => P.id.localeCompare(A.id)), c = {};
|
|
16790
16790
|
for (const P of a)
|
|
16791
16791
|
for (const A of P.screenIds) c[A] = P.id;
|
|
16792
16792
|
const l = new Map(a.map((P) => [P.id, P])), d = (P, A) => ut([
|
|
@@ -16845,7 +16845,7 @@ function Ow(e) {
|
|
|
16845
16845
|
let E = 0;
|
|
16846
16846
|
for (const [P, A] of v)
|
|
16847
16847
|
for (const M of A) {
|
|
16848
|
-
const $ =
|
|
16848
|
+
const $ = _w(M, E);
|
|
16849
16849
|
E += 1;
|
|
16850
16850
|
const de = b(M.from, $, "source"), se = b(M.to, $, "target");
|
|
16851
16851
|
if (!de || !se || de === se) continue;
|
|
@@ -17015,7 +17015,7 @@ function Ow(e) {
|
|
|
17015
17015
|
coverage: je
|
|
17016
17016
|
};
|
|
17017
17017
|
}
|
|
17018
|
-
function
|
|
17018
|
+
function Ow(e) {
|
|
17019
17019
|
return e ? JSON.parse(JSON.stringify(e)) : void 0;
|
|
17020
17020
|
}
|
|
17021
17021
|
function ki(e) {
|
|
@@ -17029,7 +17029,7 @@ function ki(e) {
|
|
|
17029
17029
|
function rd(e) {
|
|
17030
17030
|
return JSON.stringify(ki(e ?? null));
|
|
17031
17031
|
}
|
|
17032
|
-
function
|
|
17032
|
+
function Bw(e) {
|
|
17033
17033
|
return !!(e && typeof e == "object" && !Array.isArray(e));
|
|
17034
17034
|
}
|
|
17035
17035
|
function Ht(e) {
|
|
@@ -17077,7 +17077,7 @@ function od(e, t, n) {
|
|
|
17077
17077
|
screenIds: n.get(i) ?? [a]
|
|
17078
17078
|
})).sort((i, a) => i.representativeId.localeCompare(a.representativeId));
|
|
17079
17079
|
}
|
|
17080
|
-
function
|
|
17080
|
+
function jw(e) {
|
|
17081
17081
|
var n;
|
|
17082
17082
|
const t = /* @__PURE__ */ new Map();
|
|
17083
17083
|
for (const r of e ?? []) {
|
|
@@ -17091,7 +17091,7 @@ function Ww(e) {
|
|
|
17091
17091
|
}
|
|
17092
17092
|
return [...t.values()].sort((r, o) => r.id.localeCompare(o.id));
|
|
17093
17093
|
}
|
|
17094
|
-
function
|
|
17094
|
+
function Ww(e, t, n, r) {
|
|
17095
17095
|
return (e ?? []).flatMap((o, i) => {
|
|
17096
17096
|
var p, m, b;
|
|
17097
17097
|
const a = (p = o.from) == null ? void 0 : p.trim(), c = (m = o.to) == null ? void 0 : m.trim();
|
|
@@ -17115,7 +17115,7 @@ function Hw(e, t, n, r) {
|
|
|
17115
17115
|
);
|
|
17116
17116
|
});
|
|
17117
17117
|
}
|
|
17118
|
-
function
|
|
17118
|
+
function Hw(e, t, n) {
|
|
17119
17119
|
const r = Ht(e.route);
|
|
17120
17120
|
if (!r) return [];
|
|
17121
17121
|
const o = t.filter(
|
|
@@ -17139,7 +17139,7 @@ function Uw(e, t, n) {
|
|
|
17139
17139
|
)
|
|
17140
17140
|
].sort((c, l) => c.localeCompare(l));
|
|
17141
17141
|
}
|
|
17142
|
-
function
|
|
17142
|
+
function Uw(e, t) {
|
|
17143
17143
|
const n = e.some((i) => i.importKind != null), r = t.candidates ?? [], o = jf(t);
|
|
17144
17144
|
return e.filter(
|
|
17145
17145
|
(i) => n ? i.importKind === "screens" : !!i.route
|
|
@@ -17161,7 +17161,7 @@ function Vw(e, t) {
|
|
|
17161
17161
|
scenario: i.scenario,
|
|
17162
17162
|
state: i.state,
|
|
17163
17163
|
scenarioId: i.scenarioId,
|
|
17164
|
-
scenarioIds:
|
|
17164
|
+
scenarioIds: Hw(i, r, o),
|
|
17165
17165
|
interactions: i.interactions,
|
|
17166
17166
|
environment: i.environment,
|
|
17167
17167
|
preset: i.preset,
|
|
@@ -17178,7 +17178,7 @@ function Ki(e, t) {
|
|
|
17178
17178
|
const i = !e.environment && !e.preset ? 0 : 1, a = !t.environment && !t.preset ? 0 : 1;
|
|
17179
17179
|
return i !== a ? i - a : e.id.localeCompare(t.id);
|
|
17180
17180
|
}
|
|
17181
|
-
function
|
|
17181
|
+
function Vw(e) {
|
|
17182
17182
|
const t = /* @__PURE__ */ new Map();
|
|
17183
17183
|
for (const n of e) {
|
|
17184
17184
|
const r = Ht(n.route);
|
|
@@ -17193,7 +17193,7 @@ function Kw(e) {
|
|
|
17193
17193
|
})
|
|
17194
17194
|
);
|
|
17195
17195
|
}
|
|
17196
|
-
function
|
|
17196
|
+
function Kw(e) {
|
|
17197
17197
|
const t = /* @__PURE__ */ new Map();
|
|
17198
17198
|
for (const n of e) {
|
|
17199
17199
|
const r = Ht(n.route);
|
|
@@ -17208,7 +17208,7 @@ function qw(e) {
|
|
|
17208
17208
|
])
|
|
17209
17209
|
);
|
|
17210
17210
|
}
|
|
17211
|
-
function
|
|
17211
|
+
function qw(e) {
|
|
17212
17212
|
return e.action === "wait" ? null : JSON.stringify(
|
|
17213
17213
|
ki({
|
|
17214
17214
|
action: e.action,
|
|
@@ -17225,12 +17225,12 @@ function Yw(e) {
|
|
|
17225
17225
|
);
|
|
17226
17226
|
}
|
|
17227
17227
|
function Bf(e) {
|
|
17228
|
-
return (e.interactions ?? []).map(
|
|
17228
|
+
return (e.interactions ?? []).map(qw).filter((t) => t != null);
|
|
17229
17229
|
}
|
|
17230
|
-
function
|
|
17230
|
+
function Yw(e, t) {
|
|
17231
17231
|
return e.length < t.length && e.every((n, r) => n === t[r]);
|
|
17232
17232
|
}
|
|
17233
|
-
function
|
|
17233
|
+
function Gw(e, t) {
|
|
17234
17234
|
const n = /* @__PURE__ */ new Map();
|
|
17235
17235
|
for (const r of e) {
|
|
17236
17236
|
const o = Ht(r.route);
|
|
@@ -17249,7 +17249,7 @@ function Xw(e, t) {
|
|
|
17249
17249
|
}));
|
|
17250
17250
|
});
|
|
17251
17251
|
}
|
|
17252
|
-
function
|
|
17252
|
+
function Xw(e, t) {
|
|
17253
17253
|
const n = /* @__PURE__ */ new Map();
|
|
17254
17254
|
for (const r of e) {
|
|
17255
17255
|
const o = Ht(r.route);
|
|
@@ -17267,7 +17267,7 @@ function Jw(e, t) {
|
|
|
17267
17267
|
const d = i.get(l.id);
|
|
17268
17268
|
if (!d.length) return [];
|
|
17269
17269
|
const p = o.filter(
|
|
17270
|
-
(m) =>
|
|
17270
|
+
(m) => Yw(
|
|
17271
17271
|
i.get(m.id),
|
|
17272
17272
|
d
|
|
17273
17273
|
)
|
|
@@ -17299,7 +17299,7 @@ function Jw(e, t) {
|
|
|
17299
17299
|
});
|
|
17300
17300
|
});
|
|
17301
17301
|
}
|
|
17302
|
-
function
|
|
17302
|
+
function Jw(e) {
|
|
17303
17303
|
var n;
|
|
17304
17304
|
const t = /* @__PURE__ */ new Map();
|
|
17305
17305
|
for (const r of e) {
|
|
@@ -17331,7 +17331,7 @@ function Qw(e) {
|
|
|
17331
17331
|
});
|
|
17332
17332
|
});
|
|
17333
17333
|
}
|
|
17334
|
-
function
|
|
17334
|
+
function Qw(e, t, n) {
|
|
17335
17335
|
const r = new Set(
|
|
17336
17336
|
(t.routes ?? []).map((o) => Ht(o.path)).filter((o) => !!o)
|
|
17337
17337
|
);
|
|
@@ -17353,7 +17353,7 @@ function Zw(e, t, n) {
|
|
|
17353
17353
|
} : o;
|
|
17354
17354
|
});
|
|
17355
17355
|
}
|
|
17356
|
-
function
|
|
17356
|
+
function Zw(e, t) {
|
|
17357
17357
|
var d, u, p, m, b;
|
|
17358
17358
|
const n = new Set(e.map((x) => x.id)), r = new Map(
|
|
17359
17359
|
e.map((x, w) => [x.id, w])
|
|
@@ -17418,42 +17418,42 @@ function e0(e, t) {
|
|
|
17418
17418
|
}
|
|
17419
17419
|
function jf(e) {
|
|
17420
17420
|
var t, n;
|
|
17421
|
-
return
|
|
17421
|
+
return Ow(
|
|
17422
17422
|
(n = (t = e.scenarios) == null ? void 0 : t.find(
|
|
17423
17423
|
(r) => r.id === "environment:baseline"
|
|
17424
17424
|
)) == null ? void 0 : n.environment
|
|
17425
17425
|
);
|
|
17426
17426
|
}
|
|
17427
|
-
function
|
|
17427
|
+
function e0(e) {
|
|
17428
17428
|
var l, d, u, p, m;
|
|
17429
|
-
const t =
|
|
17429
|
+
const t = Uw(
|
|
17430
17430
|
e.pages,
|
|
17431
17431
|
e.manifest
|
|
17432
|
-
), n =
|
|
17432
|
+
), n = Vw(t), r = Kw(t), o = Qw(
|
|
17433
17433
|
t,
|
|
17434
17434
|
e.manifest,
|
|
17435
17435
|
n
|
|
17436
17436
|
), a = [
|
|
17437
|
-
...
|
|
17437
|
+
...Ww(
|
|
17438
17438
|
e.manifest.edges,
|
|
17439
17439
|
n,
|
|
17440
17440
|
r,
|
|
17441
17441
|
new Set(o.map((b) => b.id))
|
|
17442
17442
|
),
|
|
17443
|
+
...Gw(o, n),
|
|
17443
17444
|
...Xw(o, n),
|
|
17444
|
-
...Jw(o
|
|
17445
|
-
...Qw(o)
|
|
17445
|
+
...Jw(o)
|
|
17446
17446
|
], c = [
|
|
17447
17447
|
...((l = e.storyboard) == null ? void 0 : l.edges) ?? [],
|
|
17448
|
-
...
|
|
17448
|
+
...Fw(((d = e.storyboard) == null ? void 0 : d.paths) ?? [])
|
|
17449
17449
|
];
|
|
17450
|
-
return
|
|
17450
|
+
return zw({
|
|
17451
17451
|
screens: o,
|
|
17452
17452
|
assets: e.assets,
|
|
17453
|
-
scenarios:
|
|
17453
|
+
scenarios: jw(e.manifest.routes),
|
|
17454
17454
|
explicitEdges: c,
|
|
17455
17455
|
inferredEdges: a,
|
|
17456
|
-
startScreenIds: (p = (u = e.storyboard) == null ? void 0 : u.startScreenIds) != null && p.length ? e.storyboard.startScreenIds :
|
|
17456
|
+
startScreenIds: (p = (u = e.storyboard) == null ? void 0 : u.startScreenIds) != null && p.length ? e.storyboard.startScreenIds : Zw(o, [...c, ...a]),
|
|
17457
17457
|
nonVisualScenarioIds: (m = e.storyboard) == null ? void 0 : m.nonVisualScenarioIds
|
|
17458
17458
|
});
|
|
17459
17459
|
}
|
|
@@ -17466,12 +17466,12 @@ async function Wf(e) {
|
|
|
17466
17466
|
if (!n.ok)
|
|
17467
17467
|
throw new Error(`Storyboard discovery failed (${n.status})`);
|
|
17468
17468
|
const r = await n.json();
|
|
17469
|
-
if (!
|
|
17469
|
+
if (!Bw(r))
|
|
17470
17470
|
throw new Error("Storyboard discovery returned an invalid manifest.");
|
|
17471
17471
|
return {
|
|
17472
17472
|
manifest: r,
|
|
17473
17473
|
baselineEnvironment: jf(r),
|
|
17474
|
-
graph:
|
|
17474
|
+
graph: e0({
|
|
17475
17475
|
manifest: r,
|
|
17476
17476
|
pages: e.pages,
|
|
17477
17477
|
assets: e.assets,
|
|
@@ -17479,7 +17479,7 @@ async function Wf(e) {
|
|
|
17479
17479
|
})
|
|
17480
17480
|
};
|
|
17481
17481
|
}
|
|
17482
|
-
async function
|
|
17482
|
+
async function V0(e) {
|
|
17483
17483
|
$n(null);
|
|
17484
17484
|
try {
|
|
17485
17485
|
const t = await Wf(e);
|
|
@@ -17488,15 +17488,15 @@ async function K0(e) {
|
|
|
17488
17488
|
throw $n(null), t;
|
|
17489
17489
|
}
|
|
17490
17490
|
}
|
|
17491
|
-
const Ai = "var(--pygmalion-catalog-surface, #ffffff)", Ri = "var(--pygmalion-catalog-canvas, #f5f5f5)", $a = "var(--pygmalion-catalog-border, #e5e7eb)", Ti = "var(--pygmalion-catalog-text, #202124)", Wt = "var(--pygmalion-catalog-muted, #6b7280)",
|
|
17492
|
-
function
|
|
17491
|
+
const Ai = "var(--pygmalion-catalog-surface, #ffffff)", Ri = "var(--pygmalion-catalog-canvas, #f5f5f5)", $a = "var(--pygmalion-catalog-border, #e5e7eb)", Ti = "var(--pygmalion-catalog-text, #202124)", Wt = "var(--pygmalion-catalog-muted, #6b7280)", t0 = "var(--pygmalion-catalog-header, #11182f)", n0 = "var(--pygmalion-catalog-accent, #7c6cf2)";
|
|
17492
|
+
function K0({
|
|
17493
17493
|
title: e,
|
|
17494
17494
|
eyebrow: t,
|
|
17495
17495
|
description: n,
|
|
17496
17496
|
version: r,
|
|
17497
17497
|
meta: o,
|
|
17498
17498
|
children: i,
|
|
17499
|
-
headerBackground: a =
|
|
17499
|
+
headerBackground: a = t0,
|
|
17500
17500
|
headerColor: c = "#ffffff",
|
|
17501
17501
|
bodyBackground: l = Ai,
|
|
17502
17502
|
bodyGap: d = 40
|
|
@@ -17613,7 +17613,7 @@ function q0({
|
|
|
17613
17613
|
}
|
|
17614
17614
|
);
|
|
17615
17615
|
}
|
|
17616
|
-
function
|
|
17616
|
+
function q0({
|
|
17617
17617
|
title: e,
|
|
17618
17618
|
itemId: t,
|
|
17619
17619
|
count: n,
|
|
@@ -17658,7 +17658,7 @@ function Y0({
|
|
|
17658
17658
|
}
|
|
17659
17659
|
);
|
|
17660
17660
|
}
|
|
17661
|
-
function
|
|
17661
|
+
function Y0({
|
|
17662
17662
|
rows: e,
|
|
17663
17663
|
columns: t,
|
|
17664
17664
|
cornerLabel: n,
|
|
@@ -17677,7 +17677,7 @@ function G0({
|
|
|
17677
17677
|
display: "inline-block",
|
|
17678
17678
|
width: "max-content",
|
|
17679
17679
|
padding: a ? 16 : 0,
|
|
17680
|
-
border: a ? `1px dashed ${
|
|
17680
|
+
border: a ? `1px dashed ${n0}` : void 0,
|
|
17681
17681
|
borderRadius: a ? 4 : void 0
|
|
17682
17682
|
},
|
|
17683
17683
|
children: /* @__PURE__ */ g(
|
|
@@ -17755,11 +17755,11 @@ function G0({
|
|
|
17755
17755
|
}
|
|
17756
17756
|
);
|
|
17757
17757
|
}
|
|
17758
|
-
function
|
|
17758
|
+
function r0(e) {
|
|
17759
17759
|
return e.normalize("NFKD").replace(/[\u0300-\u036f]/g, "").replace(/[^\p{L}\p{N}]+/gu, "-").replace(/^-+|-+$/g, "").toLowerCase() || "page";
|
|
17760
17760
|
}
|
|
17761
17761
|
function Hf(e, t, n = "PygmalionCatalog") {
|
|
17762
|
-
const r = (o) =>
|
|
17762
|
+
const r = (o) => r0(o).replace(/-/g, "_");
|
|
17763
17763
|
return `${n}_${r(e)}_${r(t)}`;
|
|
17764
17764
|
}
|
|
17765
17765
|
function Uf(e, t) {
|
|
@@ -17781,10 +17781,10 @@ function Vf(e) {
|
|
|
17781
17781
|
t.add(n.id);
|
|
17782
17782
|
}
|
|
17783
17783
|
}
|
|
17784
|
-
function
|
|
17784
|
+
function o0(e, t, n) {
|
|
17785
17785
|
return typeof e == "function" ? e(t, n) : e;
|
|
17786
17786
|
}
|
|
17787
|
-
function
|
|
17787
|
+
function i0({
|
|
17788
17788
|
page: e,
|
|
17789
17789
|
items: t,
|
|
17790
17790
|
renderPreview: n,
|
|
@@ -17888,7 +17888,7 @@ function s0({
|
|
|
17888
17888
|
}
|
|
17889
17889
|
);
|
|
17890
17890
|
}
|
|
17891
|
-
function
|
|
17891
|
+
function G0(e) {
|
|
17892
17892
|
Vf(e.items);
|
|
17893
17893
|
const t = /* @__PURE__ */ new Map();
|
|
17894
17894
|
for (const o of e.items) {
|
|
@@ -17912,7 +17912,7 @@ function X0(e) {
|
|
|
17912
17912
|
const n = {}, r = [];
|
|
17913
17913
|
for (const o of t.values()) {
|
|
17914
17914
|
const i = () => /* @__PURE__ */ s(
|
|
17915
|
-
|
|
17915
|
+
i0,
|
|
17916
17916
|
{
|
|
17917
17917
|
page: o.page,
|
|
17918
17918
|
items: o.items,
|
|
@@ -17925,7 +17925,7 @@ function X0(e) {
|
|
|
17925
17925
|
component: i,
|
|
17926
17926
|
children: "none"
|
|
17927
17927
|
};
|
|
17928
|
-
const a =
|
|
17928
|
+
const a = o0(e.frame, o.page, o.items);
|
|
17929
17929
|
r.push({
|
|
17930
17930
|
...o.page,
|
|
17931
17931
|
componentName: o.registryName,
|
|
@@ -17943,7 +17943,7 @@ function X0(e) {
|
|
|
17943
17943
|
}
|
|
17944
17944
|
};
|
|
17945
17945
|
}
|
|
17946
|
-
function
|
|
17946
|
+
function s0(e, t = 60) {
|
|
17947
17947
|
const n = Object.entries((e == null ? void 0 : e.props) ?? {}).filter(([, c]) => c.length > 0).sort(([c, l], [d, u]) => u.length - l.length || c.localeCompare(d)), r = n[0], o = n[1], i = Math.max(1, (r == null ? void 0 : r[1].length) ?? 1), a = o == null ? void 0 : o[1].slice(0, Math.max(1, Math.floor(t / i)));
|
|
17948
17948
|
return {
|
|
17949
17949
|
row: r,
|
|
@@ -17952,7 +17952,7 @@ function a0(e, t = 60) {
|
|
|
17952
17952
|
additional: n.slice(2)
|
|
17953
17953
|
};
|
|
17954
17954
|
}
|
|
17955
|
-
function
|
|
17955
|
+
function a0(e, t, n, r) {
|
|
17956
17956
|
return {
|
|
17957
17957
|
...e.defaultProps,
|
|
17958
17958
|
...Object.fromEntries(t.fixed),
|
|
@@ -17960,7 +17960,7 @@ function c0(e, t, n, r) {
|
|
|
17960
17960
|
...t.column && r !== void 0 ? { [t.column[0]]: r } : {}
|
|
17961
17961
|
};
|
|
17962
17962
|
}
|
|
17963
|
-
function
|
|
17963
|
+
function c0({
|
|
17964
17964
|
item: e,
|
|
17965
17965
|
entry: t,
|
|
17966
17966
|
maxVariantCells: n
|
|
@@ -17986,7 +17986,7 @@ function l0({
|
|
|
17986
17986
|
]
|
|
17987
17987
|
}
|
|
17988
17988
|
);
|
|
17989
|
-
const r =
|
|
17989
|
+
const r = s0(t, n), o = ((c = r.row) == null ? void 0 : c[1]) ?? [void 0], i = ((l = r.column) == null ? void 0 : l[1]) ?? [void 0], a = t.component;
|
|
17990
17990
|
return /* @__PURE__ */ g(
|
|
17991
17991
|
"section",
|
|
17992
17992
|
{
|
|
@@ -18017,7 +18017,7 @@ function l0({
|
|
|
18017
18017
|
children: o.flatMap(
|
|
18018
18018
|
(d) => i.map((u) => {
|
|
18019
18019
|
var b, x;
|
|
18020
|
-
const p =
|
|
18020
|
+
const p = a0(t, r, d, u), m = [
|
|
18021
18021
|
r.row && d !== void 0 ? `${((b = t.propLabels) == null ? void 0 : b[r.row[0]]) ?? r.row[0]}=${String(d)}` : "",
|
|
18022
18022
|
r.column && u !== void 0 ? `${((x = t.propLabels) == null ? void 0 : x[r.column[0]]) ?? r.column[0]}=${String(u)}` : ""
|
|
18023
18023
|
].filter(Boolean).join(" · ");
|
|
@@ -18076,7 +18076,7 @@ function l0({
|
|
|
18076
18076
|
}
|
|
18077
18077
|
);
|
|
18078
18078
|
}
|
|
18079
|
-
function
|
|
18079
|
+
function X0(e) {
|
|
18080
18080
|
Vf(e.items);
|
|
18081
18081
|
const t = {}, n = [], r = [], o = e.maxVariantCells ?? 60;
|
|
18082
18082
|
for (const i of e.items) {
|
|
@@ -18085,7 +18085,7 @@ function J0(e) {
|
|
|
18085
18085
|
i.id,
|
|
18086
18086
|
e.registryPrefix
|
|
18087
18087
|
), c = e.registry[i.name], l = () => /* @__PURE__ */ s(
|
|
18088
|
-
|
|
18088
|
+
c0,
|
|
18089
18089
|
{
|
|
18090
18090
|
item: i,
|
|
18091
18091
|
entry: c,
|
|
@@ -18113,7 +18113,7 @@ function J0(e) {
|
|
|
18113
18113
|
}
|
|
18114
18114
|
};
|
|
18115
18115
|
}
|
|
18116
|
-
const Ss = (e) => e.map((t) => `"${t.name}"`).join(", "), id = (e) => `${e.width ?? "?"}x${e.height ?? "?"}`,
|
|
18116
|
+
const Ss = (e) => e.map((t) => `"${t.name}"`).join(", "), id = (e) => `${e.width ?? "?"}x${e.height ?? "?"}`, l0 = (e) => e.state ?? "default", d0 = (e) => e === void 0 ? "(no canvas)" : `"${e}"`, Vo = (e, t) => {
|
|
18117
18117
|
const n = /* @__PURE__ */ new Map();
|
|
18118
18118
|
for (const r of e) {
|
|
18119
18119
|
const o = n.get(t(r));
|
|
@@ -18121,7 +18121,7 @@ const Ss = (e) => e.map((t) => `"${t.name}"`).join(", "), id = (e) => `${e.width
|
|
|
18121
18121
|
}
|
|
18122
18122
|
return n;
|
|
18123
18123
|
};
|
|
18124
|
-
function
|
|
18124
|
+
function J0(e) {
|
|
18125
18125
|
const t = Vo(
|
|
18126
18126
|
e.filter((r) => !!r.scenario && r.route != null),
|
|
18127
18127
|
(r) => r.scenario
|
|
@@ -18138,7 +18138,7 @@ function Q0(e) {
|
|
|
18138
18138
|
}
|
|
18139
18139
|
const i = Vo(o, (a) => a.canvas);
|
|
18140
18140
|
if (i.size > 1) {
|
|
18141
|
-
const a = [...i.entries()].map(([c, l]) => `${
|
|
18141
|
+
const a = [...i.entries()].map(([c, l]) => `${d0(c)}: ${Ss(l)}`).join("; ");
|
|
18142
18142
|
n.push({
|
|
18143
18143
|
severity: "warning",
|
|
18144
18144
|
code: "cross-canvas",
|
|
@@ -18156,7 +18156,7 @@ function Q0(e) {
|
|
|
18156
18156
|
message: `Scenario "${r}" mixes viewports: ${d}; sibling states should share one viewport so flipping between them compares like with like.`
|
|
18157
18157
|
});
|
|
18158
18158
|
}
|
|
18159
|
-
const l = Vo(a,
|
|
18159
|
+
const l = Vo(a, l0);
|
|
18160
18160
|
for (const [d, u] of l)
|
|
18161
18161
|
u.length < 2 || n.push({
|
|
18162
18162
|
severity: "warning",
|
|
@@ -18168,23 +18168,23 @@ function Q0(e) {
|
|
|
18168
18168
|
}
|
|
18169
18169
|
return n.sort((r, o) => r.severity !== o.severity ? r.severity === "warning" ? -1 : 1 : r.scenario < o.scenario ? -1 : r.scenario > o.scenario ? 1 : 0);
|
|
18170
18170
|
}
|
|
18171
|
-
const Kf = 42e4,
|
|
18172
|
-
function
|
|
18173
|
-
const t =
|
|
18174
|
-
return Math.min(t,
|
|
18171
|
+
const Kf = 42e4, u0 = 2e3, f0 = 500, h0 = 5e3, p0 = 3e4;
|
|
18172
|
+
function m0(e) {
|
|
18173
|
+
const t = h0 * 2 ** Math.max(0, e);
|
|
18174
|
+
return Math.min(t, p0);
|
|
18175
18175
|
}
|
|
18176
|
-
function
|
|
18176
|
+
function g0(e) {
|
|
18177
18177
|
return new Promise((t) => setTimeout(t, e));
|
|
18178
18178
|
}
|
|
18179
|
-
async function
|
|
18179
|
+
async function b0(e) {
|
|
18180
18180
|
const {
|
|
18181
18181
|
initial: t,
|
|
18182
18182
|
fetchStatus: n,
|
|
18183
18183
|
requestResync: r,
|
|
18184
18184
|
timeoutMs: o = Kf,
|
|
18185
|
-
intervalMs: i =
|
|
18185
|
+
intervalMs: i = f0,
|
|
18186
18186
|
now: a = Date.now,
|
|
18187
|
-
sleep: c =
|
|
18187
|
+
sleep: c = g0
|
|
18188
18188
|
} = e;
|
|
18189
18189
|
let l = t, d = !1;
|
|
18190
18190
|
const u = a();
|
|
@@ -18201,9 +18201,9 @@ async function x0(e) {
|
|
|
18201
18201
|
}
|
|
18202
18202
|
return l;
|
|
18203
18203
|
}
|
|
18204
|
-
const sd = /^[a-f0-9]{64}$/,
|
|
18204
|
+
const sd = /^[a-f0-9]{64}$/, x0 = /^\/__pygmalion-qa\/artifacts\/[A-Za-z0-9_-]{8,120}\.png$/, y0 = /^p\d+$/;
|
|
18205
18205
|
function Ma(e) {
|
|
18206
|
-
return typeof e == "string" &&
|
|
18206
|
+
return typeof e == "string" && x0.test(e) ? e : void 0;
|
|
18207
18207
|
}
|
|
18208
18208
|
function ad(e, t) {
|
|
18209
18209
|
const n = new URL(e, t);
|
|
@@ -18223,7 +18223,7 @@ function cd(e) {
|
|
|
18223
18223
|
const t = e;
|
|
18224
18224
|
return !Number.isSafeInteger(t.width) || !Number.isSafeInteger(t.height) || Number(t.width) < 1 || Number(t.height) < 1 || Number(t.width) > 65536 || Number(t.height) > 65536 ? null : { width: Number(t.width), height: Number(t.height) };
|
|
18225
18225
|
}
|
|
18226
|
-
function
|
|
18226
|
+
function v0(e) {
|
|
18227
18227
|
if (!e || typeof e != "object" || Array.isArray(e)) return null;
|
|
18228
18228
|
const t = e, n = cd(t.before), r = cd(t.after);
|
|
18229
18229
|
if (!n || !r || !Number.isSafeInteger(t.changedPixels) || !Number.isSafeInteger(t.totalPixels) || Number(t.changedPixels) < 0 || Number(t.totalPixels) < 1 || Number(t.changedPixels) > Number(t.totalPixels) || typeof t.threshold != "number" || !Number.isFinite(t.threshold) || t.threshold < 0 || t.threshold > 1)
|
|
@@ -18240,7 +18240,7 @@ function w0(e) {
|
|
|
18240
18240
|
heatmapUrl: o
|
|
18241
18241
|
};
|
|
18242
18242
|
}
|
|
18243
|
-
function
|
|
18243
|
+
function w0(e, t) {
|
|
18244
18244
|
if (!e || typeof e != "object" || Array.isArray(e)) return null;
|
|
18245
18245
|
const n = e;
|
|
18246
18246
|
if (typeof n.id != "string" || !n.id) return null;
|
|
@@ -18248,7 +18248,7 @@ function S0(e, t) {
|
|
|
18248
18248
|
if (!o) return null;
|
|
18249
18249
|
const i = Ns(n.after);
|
|
18250
18250
|
if (t === "changed" && !i) return null;
|
|
18251
|
-
const a = i ?
|
|
18251
|
+
const a = i ? v0(n.pixelDiff) : null;
|
|
18252
18252
|
return {
|
|
18253
18253
|
id: n.id,
|
|
18254
18254
|
before: o,
|
|
@@ -18260,7 +18260,7 @@ function S0(e, t) {
|
|
|
18260
18260
|
...a ? { pixelDiff: a } : {}
|
|
18261
18261
|
};
|
|
18262
18262
|
}
|
|
18263
|
-
function
|
|
18263
|
+
function S0(e, t = []) {
|
|
18264
18264
|
const n = new Set(t), r = n.size > 0, o = /* @__PURE__ */ new Set(), i = [
|
|
18265
18265
|
...e.styles.map((a) => a.affectedFrames ?? []),
|
|
18266
18266
|
...e.texts.map((a) => a.affectedFrames ?? []),
|
|
@@ -18268,7 +18268,7 @@ function N0(e, t = []) {
|
|
|
18268
18268
|
];
|
|
18269
18269
|
for (const a of i)
|
|
18270
18270
|
for (const c of a) {
|
|
18271
|
-
if (r &&
|
|
18271
|
+
if (r && y0.test(c.id) && !n.has(c.id))
|
|
18272
18272
|
throw new Error(
|
|
18273
18273
|
`"Impact Screen"${c.name}"This internal editor ID (${c.id}) is used. A canonical screen ID is required.`
|
|
18274
18274
|
);
|
|
@@ -18288,7 +18288,7 @@ async function ld(e, t, n) {
|
|
|
18288
18288
|
);
|
|
18289
18289
|
if (typeof o.baselineId != "string" || !o.baselineId)
|
|
18290
18290
|
throw new Error("Pygmalion visual QA response has no baselineId");
|
|
18291
|
-
const i = Array.isArray(o.frames) ? o.frames.map((u) =>
|
|
18291
|
+
const i = Array.isArray(o.frames) ? o.frames.map((u) => w0(u, n.phase)).filter((u) => u != null) : [], a = Array.isArray(o.failures) ? o.failures.map((u) => {
|
|
18292
18292
|
if (!u || typeof u != "object" || Array.isArray(u)) return null;
|
|
18293
18293
|
const p = u;
|
|
18294
18294
|
return typeof p.id == "string" && typeof p.error == "string" ? { id: p.id, error: p.error } : null;
|
|
@@ -18305,12 +18305,12 @@ const Is = {
|
|
|
18305
18305
|
mirror: "/__pygmalion-dev-control",
|
|
18306
18306
|
sessions: "/__pygmalion-design-session",
|
|
18307
18307
|
inspect: "/__pygmalion-inspect"
|
|
18308
|
-
},
|
|
18308
|
+
}, N0 = "pygmalion.designSessionId", I0 = "/__pygmalion-qa", Ko = /* @__PURE__ */ new Map();
|
|
18309
18309
|
function dd() {
|
|
18310
18310
|
var e;
|
|
18311
18311
|
return typeof window < "u" && ((e = window.crypto) != null && e.randomUUID) ? window.crypto.randomUUID() : `pygmalion-${Date.now()}-${Math.random().toString(36).slice(2)}`;
|
|
18312
18312
|
}
|
|
18313
|
-
function
|
|
18313
|
+
function C0(e, t) {
|
|
18314
18314
|
if (e) return e;
|
|
18315
18315
|
const n = Ko.get(t);
|
|
18316
18316
|
if (n) return n;
|
|
@@ -18330,23 +18330,23 @@ async function tn(e) {
|
|
|
18330
18330
|
if (!e.ok) throw new Error(t.error ?? `Pygmalion request failed (${e.status})`);
|
|
18331
18331
|
return t;
|
|
18332
18332
|
}
|
|
18333
|
-
const
|
|
18334
|
-
function Cs(e =
|
|
18333
|
+
const P0 = 3e4;
|
|
18334
|
+
function Cs(e = P0) {
|
|
18335
18335
|
return typeof AbortSignal > "u" || typeof AbortSignal.timeout != "function" ? {} : { signal: AbortSignal.timeout(e) };
|
|
18336
18336
|
}
|
|
18337
|
-
function
|
|
18337
|
+
function Q0(e = {}) {
|
|
18338
18338
|
var je, ce, ie, P, A;
|
|
18339
18339
|
const {
|
|
18340
18340
|
sessionId: t,
|
|
18341
|
-
sessionStorageKey: n =
|
|
18341
|
+
sessionStorageKey: n = N0,
|
|
18342
18342
|
autoStart: r = !0,
|
|
18343
18343
|
fetcher: o = fetch,
|
|
18344
18344
|
formatApplyMessage: i
|
|
18345
|
-
} = e, a = ((je = e.endpoints) == null ? void 0 : je.mirror) ?? Is.mirror, c = ((ce = e.endpoints) == null ? void 0 : ce.sessions) ?? Is.sessions, l = ((ie = e.endpoints) == null ? void 0 : ie.inspect) ?? Is.inspect, d = e.visualQa != null, u = ((P = e.visualQa) == null ? void 0 : P.endpoint) ??
|
|
18345
|
+
} = e, a = ((je = e.endpoints) == null ? void 0 : je.mirror) ?? Is.mirror, c = ((ce = e.endpoints) == null ? void 0 : ce.sessions) ?? Is.sessions, l = ((ie = e.endpoints) == null ? void 0 : ie.inspect) ?? Is.inspect, d = e.visualQa != null, u = ((P = e.visualQa) == null ? void 0 : P.endpoint) ?? I0, p = JSON.stringify(((A = e.visualQa) == null ? void 0 : A.eligibleFrameIds) ?? []), m = _t(
|
|
18346
18346
|
() => JSON.parse(p),
|
|
18347
18347
|
[p]
|
|
18348
18348
|
), b = _t(
|
|
18349
|
-
() =>
|
|
18349
|
+
() => C0(t, n),
|
|
18350
18350
|
[t, n]
|
|
18351
18351
|
), [x, w] = Q({
|
|
18352
18352
|
state: "idle",
|
|
@@ -18378,7 +18378,7 @@ function Z0(e = {}) {
|
|
|
18378
18378
|
...M || se ? {} : Cs()
|
|
18379
18379
|
});
|
|
18380
18380
|
let Se = await tn(Ee);
|
|
18381
|
-
if (M || (Se = await
|
|
18381
|
+
if (M || (Se = await b0({
|
|
18382
18382
|
initial: Se,
|
|
18383
18383
|
fetchStatus: async () => tn(
|
|
18384
18384
|
await o(`${a}/status`, Cs())
|
|
@@ -18527,7 +18527,7 @@ function Z0(e = {}) {
|
|
|
18527
18527
|
);
|
|
18528
18528
|
if (!$.ok || !Number.isSafeInteger($.revision))
|
|
18529
18529
|
throw new Error($.error ?? "Pygmalion could not preview the visual changes");
|
|
18530
|
-
const de = d ?
|
|
18530
|
+
const de = d ? S0(M, m) : [];
|
|
18531
18531
|
let se;
|
|
18532
18532
|
const Ee = v.appOrigin ?? x.appOrigin;
|
|
18533
18533
|
if (de.length > 0) {
|
|
@@ -18615,7 +18615,7 @@ function Z0(e = {}) {
|
|
|
18615
18615
|
if (x.state !== "error") return;
|
|
18616
18616
|
const M = window.setTimeout(() => {
|
|
18617
18617
|
G(!1);
|
|
18618
|
-
},
|
|
18618
|
+
}, m0(ee.current++));
|
|
18619
18619
|
return () => window.clearTimeout(M);
|
|
18620
18620
|
}, [r, k, x.state, G]), ae(() => {
|
|
18621
18621
|
if (!r || x.state !== "idle") return;
|
|
@@ -18631,7 +18631,7 @@ function Z0(e = {}) {
|
|
|
18631
18631
|
} catch {
|
|
18632
18632
|
}
|
|
18633
18633
|
})();
|
|
18634
|
-
},
|
|
18634
|
+
}, u0);
|
|
18635
18635
|
return () => {
|
|
18636
18636
|
M = !0, window.clearInterval($);
|
|
18637
18637
|
};
|
|
@@ -18656,7 +18656,7 @@ function Z0(e = {}) {
|
|
|
18656
18656
|
revertLastVisual: O
|
|
18657
18657
|
};
|
|
18658
18658
|
}
|
|
18659
|
-
function
|
|
18659
|
+
function Z0({
|
|
18660
18660
|
value: e,
|
|
18661
18661
|
currentCommit: t = null,
|
|
18662
18662
|
refs: n,
|
|
@@ -18751,7 +18751,7 @@ function e1({
|
|
|
18751
18751
|
);
|
|
18752
18752
|
}
|
|
18753
18753
|
let qf = !1, Yf = "";
|
|
18754
|
-
const
|
|
18754
|
+
const e1 = {
|
|
18755
18755
|
editor: f,
|
|
18756
18756
|
getObserverTree: vp,
|
|
18757
18757
|
isObservableProp: yp,
|
|
@@ -18761,8 +18761,8 @@ const t1 = {
|
|
|
18761
18761
|
Promise.resolve().then(() => ea),
|
|
18762
18762
|
Promise.resolve().then(() => og),
|
|
18763
18763
|
Promise.resolve().then(() => nm),
|
|
18764
|
-
import("./FrozenRoutePreview-
|
|
18765
|
-
import("./FrozenRoutePreview-
|
|
18764
|
+
import("./FrozenRoutePreview-Df_DH4UK.js").then((u) => u.bf),
|
|
18765
|
+
import("./FrozenRoutePreview-Df_DH4UK.js").then((u) => u.be)
|
|
18766
18766
|
]), a = i.getMountedShadowPreviewHandle(e), c = f.pages.find(
|
|
18767
18767
|
(u) => u.id === e
|
|
18768
18768
|
);
|
|
@@ -18862,17 +18862,17 @@ const t1 = {
|
|
|
18862
18862
|
};
|
|
18863
18863
|
}
|
|
18864
18864
|
};
|
|
18865
|
-
function
|
|
18865
|
+
function t1(e) {
|
|
18866
18866
|
f.navigateToPageByName(e);
|
|
18867
18867
|
}
|
|
18868
|
-
function
|
|
18868
|
+
function n1() {
|
|
18869
18869
|
f.openPreview();
|
|
18870
18870
|
}
|
|
18871
|
-
function
|
|
18871
|
+
function r1() {
|
|
18872
18872
|
const e = J.entries.length > 0;
|
|
18873
18873
|
return e && J.discardPending(), f.resetCurrentEdits() || e;
|
|
18874
18874
|
}
|
|
18875
|
-
function
|
|
18875
|
+
function o1({
|
|
18876
18876
|
registry: e,
|
|
18877
18877
|
tokens: t,
|
|
18878
18878
|
initialPages: n,
|
|
@@ -18932,7 +18932,7 @@ function i1({
|
|
|
18932
18932
|
const [st, wt] = Q();
|
|
18933
18933
|
d && (d.assertComplete(), Sp(d));
|
|
18934
18934
|
const _ = e ?? (d == null ? void 0 : d.getRegistry()), he = t ?? (d == null ? void 0 : d.getTokens()), te = n ?? (d == null ? void 0 : d.getInitialPages());
|
|
18935
|
-
_ && Np(_), Fx(i ?? []), he && Gx(he),
|
|
18935
|
+
_ && Np(_), Fx(i ?? []), he && Gx(he), Fv(a ?? []), iv(c ?? []), Xx(u ?? null), eu(b), Xd(
|
|
18936
18936
|
!!(w != null && w.trim())
|
|
18937
18937
|
);
|
|
18938
18938
|
const xe = st ?? x, B = _t(
|
|
@@ -18988,7 +18988,7 @@ function i1({
|
|
|
18988
18988
|
interactions: U.interactions,
|
|
18989
18989
|
assertions: U.assertions
|
|
18990
18990
|
})
|
|
18991
|
-
), v != null && ou(v), _p(k ?? null), L != null && Ip(L), W != null && Cp(W), Ry(q), f.initEditMode(o !== "view-only"), Nu(S ?? []), vu(j ?? 1),
|
|
18991
|
+
), v != null && ou(v), _p(k ?? null), L != null && Ip(L), W != null && Cp(W), Ry(q), f.initEditMode(o !== "view-only"), Nu(S ?? []), vu(j ?? 1), Bv(G ?? []), Pp(R ?? []), $p(T ?? []), Mp(I ?? [], N), Ep(F ?? []), kp(O ?? [], ee), Ap(Ae ?? []), jg($e ?? 0), Rp(je ?? []), Ob(ce ?? []), Dp(ie ?? null), zp(A ?? null), Tp(M ?? null), Op($ ?? null), te && f.initPagesFromComponents(te, { initialCanvas: r }), ai(() => {
|
|
18992
18992
|
p != null && Fp(p), m != null && Lp(m), Zm(l ?? []);
|
|
18993
18993
|
}, [p, l, m]), ai(() => {
|
|
18994
18994
|
!xe || !te || !_e || Qs(xe, {
|
|
@@ -19030,8 +19030,8 @@ function i1({
|
|
|
19030
19030
|
const U = new AbortController(), oe = yb({
|
|
19031
19031
|
endpoint: w,
|
|
19032
19032
|
captureBaseUrl: p
|
|
19033
|
-
}), ne = Ya(m), We = (
|
|
19034
|
-
Qs(
|
|
19033
|
+
}), ne = Ya(m), We = (Oe) => {
|
|
19034
|
+
Qs(Oe, {
|
|
19035
19035
|
namespace: b,
|
|
19036
19036
|
previewRevision: m,
|
|
19037
19037
|
appOrigin: Uc(),
|
|
@@ -19045,23 +19045,23 @@ function i1({
|
|
|
19045
19045
|
fingerprint: (Ve = Ne[Te]) == null ? void 0 : Ve.fingerprint
|
|
19046
19046
|
};
|
|
19047
19047
|
})
|
|
19048
|
-
}), wt(
|
|
19049
|
-
},
|
|
19048
|
+
}), wt(Oe);
|
|
19049
|
+
}, ze = (Oe, Ue, Te, Ve) => $b({
|
|
19050
19050
|
namespace: b,
|
|
19051
19051
|
sourceRevision: ne,
|
|
19052
19052
|
transport: oe,
|
|
19053
19053
|
signal: Te,
|
|
19054
|
-
...
|
|
19054
|
+
...Oe.length ? { frames: Oe } : {},
|
|
19055
19055
|
...Ue ? {} : { generate: !1 },
|
|
19056
19056
|
...Ve === void 0 ? {} : { priority: Ve }
|
|
19057
|
-
}), le = (
|
|
19057
|
+
}), le = (Oe, Ue) => {
|
|
19058
19058
|
const Te = new Set(Ue);
|
|
19059
|
-
return
|
|
19060
|
-
}, Ge = (
|
|
19061
|
-
if (Ys(async (
|
|
19059
|
+
return Oe.filter((Ve) => Te.has(Ve.id));
|
|
19060
|
+
}, Ge = (Oe, Ue) => Oe instanceof Error && Oe.message ? Oe.message : Ue, He = new AbortController();
|
|
19061
|
+
if (Ys(async (Oe, Ue) => {
|
|
19062
19062
|
var Ve, $t, pt, dt;
|
|
19063
|
-
const Te = await
|
|
19064
|
-
|
|
19063
|
+
const Te = await ze(
|
|
19064
|
+
Oe,
|
|
19065
19065
|
!0,
|
|
19066
19066
|
He.signal,
|
|
19067
19067
|
Ue == null ? void 0 : Ue.priority
|
|
@@ -19069,7 +19069,7 @@ function i1({
|
|
|
19069
19069
|
if (Te.status === "accepted") {
|
|
19070
19070
|
We(Te.artifact);
|
|
19071
19071
|
const un = new Set(((Ve = Te.frameResolution) == null ? void 0 : Ve.exact) ?? []);
|
|
19072
|
-
if (
|
|
19072
|
+
if (Oe.every((Je) => un.has(Je.id)))
|
|
19073
19073
|
return { status: "accepted" };
|
|
19074
19074
|
const zt = [
|
|
19075
19075
|
...(($t = Te.frameResolution) == null ? void 0 : $t.missing) ?? [],
|
|
@@ -19098,14 +19098,14 @@ function i1({
|
|
|
19098
19098
|
...(dt = Te.error) != null && dt.pygmalionNotPrepared ? { notPrepared: !0 } : {}
|
|
19099
19099
|
};
|
|
19100
19100
|
}), ve.current.length) {
|
|
19101
|
-
const
|
|
19101
|
+
const Oe = ve.current.filter((Te) => {
|
|
19102
19102
|
const Ve = Jt(
|
|
19103
19103
|
Te.id,
|
|
19104
19104
|
Te.fingerprint
|
|
19105
19105
|
).status;
|
|
19106
19106
|
return Ve !== "exact" && Ve !== "generating";
|
|
19107
19107
|
});
|
|
19108
|
-
ft(
|
|
19108
|
+
ft(Oe, { status: "checking" });
|
|
19109
19109
|
const Ue = (Te) => Te.filter((Ve) => {
|
|
19110
19110
|
const $t = Jt(
|
|
19111
19111
|
Ve.id,
|
|
@@ -19127,12 +19127,12 @@ function i1({
|
|
|
19127
19127
|
);
|
|
19128
19128
|
ft(
|
|
19129
19129
|
Ue(
|
|
19130
|
-
|
|
19130
|
+
Oe.filter((Je) => Ve.has(Je.id))
|
|
19131
19131
|
),
|
|
19132
19132
|
{ status: "exact" }
|
|
19133
19133
|
);
|
|
19134
19134
|
const $t = Ue(
|
|
19135
|
-
|
|
19135
|
+
Oe.filter((Je) => !Ve.has(Je.id))
|
|
19136
19136
|
), pt = [];
|
|
19137
19137
|
for (const Je of sl(
|
|
19138
19138
|
$t
|
|
@@ -19172,7 +19172,7 @@ function i1({
|
|
|
19172
19172
|
for (const Je of sl(
|
|
19173
19173
|
Ue(pt)
|
|
19174
19174
|
)) {
|
|
19175
|
-
const Ke = await
|
|
19175
|
+
const Ke = await ze(
|
|
19176
19176
|
Je,
|
|
19177
19177
|
!1,
|
|
19178
19178
|
U.signal
|
|
@@ -19205,7 +19205,7 @@ function i1({
|
|
|
19205
19205
|
}
|
|
19206
19206
|
})().catch((Te) => {
|
|
19207
19207
|
if (U.signal.aborted) return;
|
|
19208
|
-
const Ve = Ue(
|
|
19208
|
+
const Ve = Ue(Oe);
|
|
19209
19209
|
ft(Ve, {
|
|
19210
19210
|
status: "error",
|
|
19211
19211
|
reason: "unavailable",
|
|
@@ -19266,125 +19266,125 @@ function i1({
|
|
|
19266
19266
|
const U = p ?? wn();
|
|
19267
19267
|
if (!U) return;
|
|
19268
19268
|
const oe = `${U}|${m ?? Yn()}`;
|
|
19269
|
-
return re.current != null && re.current !== oe && Qg(), re.current = oe,
|
|
19269
|
+
return re.current != null && re.current !== oe && Qg(), re.current = oe, Tw({
|
|
19270
19270
|
editor: f,
|
|
19271
19271
|
getPages: () => f.pages,
|
|
19272
19272
|
appOrigin: U,
|
|
19273
19273
|
baselineEnvironment: Tt()
|
|
19274
19274
|
});
|
|
19275
|
-
}, [p, _e, m]), /* @__PURE__ */ s(
|
|
19275
|
+
}, [p, _e, m]), /* @__PURE__ */ s($w, { previewIdentityReady: _e });
|
|
19276
19276
|
}
|
|
19277
19277
|
export {
|
|
19278
19278
|
Vy as DEFAULT_DESIGN_COMPILE_LIMITS,
|
|
19279
|
-
|
|
19279
|
+
a1 as DESIGN_IMPORT_KINDS,
|
|
19280
19280
|
Hy as DESIGN_IR_SCHEMA,
|
|
19281
19281
|
Uy as DESIGN_IR_VERSION,
|
|
19282
19282
|
al as MIN_SURFACE_REASON_LENGTH,
|
|
19283
|
-
|
|
19284
|
-
|
|
19285
|
-
|
|
19286
|
-
|
|
19283
|
+
K0 as PygmalionCatalogDocument,
|
|
19284
|
+
Y0 as PygmalionCatalogMatrix,
|
|
19285
|
+
q0 as PygmalionCatalogSection,
|
|
19286
|
+
o1 as PygmalionEditor,
|
|
19287
19287
|
wp as STORYBOARD_ENVIRONMENT_CONTROL,
|
|
19288
|
-
|
|
19289
|
-
|
|
19290
|
-
|
|
19291
|
-
|
|
19292
|
-
|
|
19288
|
+
c1 as STORYBOARD_ENVIRONMENT_QUERY,
|
|
19289
|
+
Z0 as SourceRefControl,
|
|
19290
|
+
e1 as __debug,
|
|
19291
|
+
Ov as applyScenarioCoverageClaim,
|
|
19292
|
+
j0 as applyTokenOverride,
|
|
19293
19293
|
$b as bootstrapPreviewArtifact,
|
|
19294
|
-
|
|
19294
|
+
F0 as clearPreviewEnvironmentControlValues,
|
|
19295
19295
|
Hm as clearPygmalionPreviewCache,
|
|
19296
19296
|
Zy as compileDesignDocument,
|
|
19297
|
-
|
|
19298
|
-
|
|
19299
|
-
|
|
19300
|
-
|
|
19301
|
-
|
|
19302
|
-
|
|
19297
|
+
X0 as createDesignComponentCatalog,
|
|
19298
|
+
s0 as createDesignComponentVariantMatrix,
|
|
19299
|
+
G0 as createDesignGalleryCatalog,
|
|
19300
|
+
l1 as createDesignImportController,
|
|
19301
|
+
H0 as createDesignIntermediateDocument,
|
|
19302
|
+
d1 as createDesignScreenCollection,
|
|
19303
19303
|
yb as createPreviewArtifactHttpTransport,
|
|
19304
|
-
|
|
19304
|
+
L0 as createPreviewCacheNamespace,
|
|
19305
19305
|
pb as createPreviewFrameFingerprint,
|
|
19306
19306
|
Lu as createPreviewRecipeFingerprint,
|
|
19307
19307
|
xb as createStoryboardCaptureRecipeIdentity,
|
|
19308
|
-
|
|
19309
|
-
|
|
19310
|
-
|
|
19311
|
-
|
|
19308
|
+
zw as createStoryboardGraph,
|
|
19309
|
+
e0 as createStoryboardGraphFromDiscovery,
|
|
19310
|
+
Af as createStoryboardGraphViewModel,
|
|
19311
|
+
Fw as createStoryboardPathEdges,
|
|
19312
19312
|
Of as createStoryboardRouteScenarioId,
|
|
19313
19313
|
wr as createStoryboardRouteUrl,
|
|
19314
|
-
|
|
19314
|
+
r0 as designCatalogKey,
|
|
19315
19315
|
Hf as designCatalogRegistryName,
|
|
19316
19316
|
_b as enumerateControlCandidates,
|
|
19317
|
-
|
|
19317
|
+
B0 as enumerateDesignComponentConnectionCases,
|
|
19318
19318
|
zb as enumerateRequestCandidates,
|
|
19319
|
-
|
|
19320
|
-
|
|
19321
|
-
|
|
19319
|
+
D0 as enumerateRouteCandidates,
|
|
19320
|
+
u1 as expandDesignScreenCasesViewports,
|
|
19321
|
+
f1 as expandDesignScreenCollectionViewports,
|
|
19322
19322
|
Wu as frameSurfaceDemands,
|
|
19323
|
-
|
|
19323
|
+
h1 as framesMissingScenario,
|
|
19324
19324
|
Qy as getDesignCodegenAdapters,
|
|
19325
|
-
|
|
19325
|
+
O0 as getDesignComponentConnection,
|
|
19326
19326
|
ma as getDesignComponentConnectionForComponent,
|
|
19327
|
-
|
|
19327
|
+
z0 as getDesignComponentConnections,
|
|
19328
19328
|
Wb as getObservedRequests,
|
|
19329
19329
|
tg as getPreviewEnvironmentControlValue,
|
|
19330
19330
|
eg as getPreviewEnvironmentControls,
|
|
19331
19331
|
rg as getPreviewEnvironmentOverride,
|
|
19332
19332
|
Fa as getRecommendedPygmalionPreviewConcurrency,
|
|
19333
|
-
|
|
19334
|
-
|
|
19333
|
+
jl as getSelectedSessionPreset,
|
|
19334
|
+
sv as getSessionPresets,
|
|
19335
19335
|
Tt as getStoryboardBaselineEnvironment,
|
|
19336
19336
|
jf as getStoryboardDiscoveryBaselineEnvironment,
|
|
19337
|
-
|
|
19337
|
+
mo as getStoryboardGraph,
|
|
19338
19338
|
Bb as getSurfaceClassifications,
|
|
19339
|
-
|
|
19339
|
+
Df as getViewportPresets,
|
|
19340
19340
|
Wf as loadStoryboardDiscovery,
|
|
19341
|
-
|
|
19341
|
+
p1 as mergeScreenPresets,
|
|
19342
19342
|
Dt as mergeStoryboardEnvironment,
|
|
19343
|
-
|
|
19344
|
-
|
|
19345
|
-
|
|
19346
|
-
|
|
19347
|
-
|
|
19348
|
-
|
|
19343
|
+
V0 as publishStoryboardDiscovery,
|
|
19344
|
+
t1 as pygmalionNavigate,
|
|
19345
|
+
n1 as pygmalionOpenPreview,
|
|
19346
|
+
r1 as pygmalionResetCurrentEdits,
|
|
19347
|
+
T0 as reconstructRoutePreviewArtifactScreenshotV3,
|
|
19348
|
+
R0 as reconstructRoutePreviewArtifactSnapshotV3,
|
|
19349
19349
|
Jy as registerDesignCodegenAdapter,
|
|
19350
19350
|
Db as requestEndpointShape,
|
|
19351
|
-
|
|
19351
|
+
W0 as resetTokenOverrides,
|
|
19352
19352
|
Pb as resolvePreviewArtifactFrames,
|
|
19353
|
-
|
|
19354
|
-
|
|
19353
|
+
Uw as resolveStoryboardScreenCases,
|
|
19354
|
+
Mf as selectSessionPreset,
|
|
19355
19355
|
Np as setComponentRegistry,
|
|
19356
19356
|
Fx as setDesignComponentConnections,
|
|
19357
19357
|
jb as setObservedRequests,
|
|
19358
19358
|
ng as setPreviewEnvironmentControlValue,
|
|
19359
19359
|
Zm as setPreviewEnvironmentControls,
|
|
19360
19360
|
Fp as setPygmalionAppOrigin,
|
|
19361
|
-
|
|
19361
|
+
m1 as setPygmalionArtifactOrigin,
|
|
19362
19362
|
ou as setPygmalionPreviewConcurrency,
|
|
19363
19363
|
Lp as setPygmalionPreviewRevision,
|
|
19364
|
-
|
|
19364
|
+
iv as setSessionPresets,
|
|
19365
19365
|
ir as setStoryboardBaselineEnvironment,
|
|
19366
19366
|
$n as setStoryboardGraph,
|
|
19367
19367
|
Ob as setSurfaceClassifications,
|
|
19368
19368
|
Gx as setTokens,
|
|
19369
|
-
|
|
19370
|
-
|
|
19369
|
+
Fv as setViewportPresets,
|
|
19370
|
+
Lw as storyboardScreenRecipeKey,
|
|
19371
19371
|
nc as subscribePreviewEnvironmentControls,
|
|
19372
|
-
|
|
19373
|
-
|
|
19372
|
+
av as subscribeSessionPresets,
|
|
19373
|
+
Ef as subscribeStoryboardGraph,
|
|
19374
19374
|
Eb as unclassifiedSurfaces,
|
|
19375
|
-
|
|
19375
|
+
Q0 as usePygmalionProject,
|
|
19376
19376
|
ff as validateDesignComponentConnections,
|
|
19377
|
-
|
|
19378
|
-
|
|
19377
|
+
g1 as validateFrameBranchKinds,
|
|
19378
|
+
b1 as validateInteractiveStates,
|
|
19379
19379
|
Cb as validatePreviewArtifactBundle,
|
|
19380
19380
|
_i as validateRoutePreviewArtifactV3Browser,
|
|
19381
|
-
|
|
19382
|
-
|
|
19383
|
-
|
|
19381
|
+
U0 as validateScenarioCoverage,
|
|
19382
|
+
x1 as validateScreenCards,
|
|
19383
|
+
y1 as validateScreenDimensions,
|
|
19384
19384
|
Lg as validateScreenFlows,
|
|
19385
|
-
|
|
19386
|
-
|
|
19387
|
-
|
|
19388
|
-
|
|
19389
|
-
|
|
19385
|
+
v1 as validateScreenLanes,
|
|
19386
|
+
w1 as validateScreenLists,
|
|
19387
|
+
J0 as validateScreenStateGroups,
|
|
19388
|
+
S1 as validateSectionHeaders,
|
|
19389
|
+
_0 as validateSurfaceDemands
|
|
19390
19390
|
};
|