@pygmalionjs/pygmalion 0.5.11 → 0.5.12
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist-lib/pygmalion.js +469 -462
- package/package.json +1 -1
package/dist-lib/pygmalion.js
CHANGED
|
@@ -2,7 +2,7 @@ var Bf = Object.defineProperty;
|
|
|
2
2
|
var jf = (e, t, n) => t in e ? Bf(e, t, { enumerable: !0, configurable: !0, writable: !0, value: n }) : e[t] = n;
|
|
3
3
|
var an = (e, t, n) => jf(e, typeof t != "symbol" ? t + "" : t, n);
|
|
4
4
|
import { jsx as s, jsxs as g, Fragment as Ke } from "react/jsx-runtime";
|
|
5
|
-
import { R as Zo, u as Wf, c as fa, b as Vl, g as Qe, d as Hf, m as
|
|
5
|
+
import { R as Zo, u as Wf, c as fa, b as Vl, g as Qe, d as Hf, m as Tt, e as f, f as Kt, r as dn, h as ys, i as qn, j as ha, k as Qt, l as Kl, n as pr, p as Vf, o as Wn, q as He, t as Kf, v as Uf, w as qf, x as Yf, y as Gf, z as Xf, A as Jf, B as vs, C as Qf, D as Zf, E as eh, G as th, H as nh, I as rh, S as oh, J as ih, K as sh, L as ah, M as ch, O as lh, P as dh, Q as uh, T as fh, U as Ul, V as hh, W as wc, X as ph, Y as ql, Z as mh, _ as gh, $ as bh, a0 as xh, a1 as yh, a2 as vh, a3 as Yl, a4 as wh, a5 as Sh, a6 as G, a7 as Sc, a8 as Nc, a9 as Nh, aa as Qi, ab as Ih, ac as Wo, ad as ws, ae as Ch, af as Gl, ag as $h, ah as Ph, ai as Mh, aj as Eh, s as kh, ak as Xl, al as Jl, am as Ss, an as Ql, ao as Ah, ap as Rh, aq as Ic, ar as Th, as as Fh, at as Cc, au as Lh, av as Dh, aw as zh, ax as _h, ay as Oh, az as Bh, aA as jh, aB as Wh, aC as Hh, aD as Vh, aE as Kh, aF as Uh, a as qh, aG as Yh, aH as Gh, aI as Xh, aJ as Jh, aK as Qh, aL as Zh, aM as ep, aN as tp, aO as np, aP as rp, aQ as op, aR as ip, aS as Lr, aT as sp, aU as ap, aV as cp, aW as lp, aX as $c } from "./FrozenRoutePreview-BR5CBAD3.js";
|
|
6
6
|
import { aY as u0, aZ as f0, a_ as h0, a$ as p0, b0 as m0, b1 as g0, b2 as b0, b3 as x0, b4 as y0, b5 as v0, b6 as w0, b7 as S0, b8 as N0, b9 as I0 } from "./FrozenRoutePreview-BR5CBAD3.js";
|
|
7
7
|
import { useRef as Ce, useLayoutEffect as ei, useSyncExternalStore as Je, useCallback as St, useReducer as Zl, useEffect as ce, memo as ed, createElement as to, useState as q, useMemo as Rt } from "react";
|
|
8
8
|
import { createPortal as dp } from "react-dom";
|
|
@@ -103,9 +103,9 @@ function yp({
|
|
|
103
103
|
}
|
|
104
104
|
return c;
|
|
105
105
|
}
|
|
106
|
-
const sr = /* @__PURE__ */ new Map(), ar = /* @__PURE__ */ new Map(),
|
|
106
|
+
const sr = /* @__PURE__ */ new Map(), ar = /* @__PURE__ */ new Map(), Jr = /* @__PURE__ */ new Map(), mr = "full";
|
|
107
107
|
function rd(e) {
|
|
108
|
-
return sr.get(e) ??
|
|
108
|
+
return sr.get(e) ?? mr;
|
|
109
109
|
}
|
|
110
110
|
function od(e) {
|
|
111
111
|
return ar.get(e) ?? !1;
|
|
@@ -135,22 +135,22 @@ function vp() {
|
|
|
135
135
|
}
|
|
136
136
|
const Ho = {};
|
|
137
137
|
function ma(e, t) {
|
|
138
|
-
let n =
|
|
139
|
-
return n || (n = /* @__PURE__ */ new Set(),
|
|
140
|
-
n.delete(t), n.size === 0 &&
|
|
138
|
+
let n = Jr.get(e);
|
|
139
|
+
return n || (n = /* @__PURE__ */ new Set(), Jr.set(e, n)), n.add(t), () => {
|
|
140
|
+
n.delete(t), n.size === 0 && Jr.delete(e);
|
|
141
141
|
};
|
|
142
142
|
}
|
|
143
143
|
function wp() {
|
|
144
144
|
let e = 0;
|
|
145
|
-
for (const t of
|
|
145
|
+
for (const t of Jr.values()) e += t.size;
|
|
146
146
|
return e;
|
|
147
147
|
}
|
|
148
148
|
function Ec(e, t = /* @__PURE__ */ new Map()) {
|
|
149
149
|
const n = /* @__PURE__ */ new Set();
|
|
150
150
|
for (const [r, o] of sr)
|
|
151
|
-
(e.get(r) ??
|
|
151
|
+
(e.get(r) ?? mr) !== o && n.add(r);
|
|
152
152
|
for (const [r, o] of e)
|
|
153
|
-
!sr.has(r) && o !==
|
|
153
|
+
!sr.has(r) && o !== mr && n.add(r);
|
|
154
154
|
for (const [r, o] of ar)
|
|
155
155
|
(t.get(r) ?? !1) !== o && n.add(r);
|
|
156
156
|
for (const [r, o] of t)
|
|
@@ -161,7 +161,7 @@ function Ec(e, t = /* @__PURE__ */ new Map()) {
|
|
|
161
161
|
for (const [r, o] of t)
|
|
162
162
|
o && ar.set(r, o);
|
|
163
163
|
for (const r of n) {
|
|
164
|
-
const o =
|
|
164
|
+
const o = Jr.get(r);
|
|
165
165
|
if (o)
|
|
166
166
|
for (const i of [...o]) i();
|
|
167
167
|
}
|
|
@@ -220,7 +220,7 @@ function ad(e) {
|
|
|
220
220
|
H.set(
|
|
221
221
|
A.id,
|
|
222
222
|
fp(
|
|
223
|
-
v.get(A.id) ??
|
|
223
|
+
v.get(A.id) ?? mr,
|
|
224
224
|
$,
|
|
225
225
|
A.screenshotDensity,
|
|
226
226
|
R
|
|
@@ -229,7 +229,7 @@ function ad(e) {
|
|
|
229
229
|
Ho.displayDensity = $, Ho.overview = R, Ho.frames = x.map((A) => ({
|
|
230
230
|
id: A.id,
|
|
231
231
|
screenshotDensity: A.screenshotDensity,
|
|
232
|
-
tier: v.get(A.id) ??
|
|
232
|
+
tier: v.get(A.id) ?? mr
|
|
233
233
|
})), Mc(
|
|
234
234
|
hp(ti, $)
|
|
235
235
|
), Ec(v, H);
|
|
@@ -254,7 +254,7 @@ function ad(e) {
|
|
|
254
254
|
}
|
|
255
255
|
const $p = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
256
256
|
__proto__: null,
|
|
257
|
-
DEFAULT_FRAME_LOD_TIER:
|
|
257
|
+
DEFAULT_FRAME_LOD_TIER: mr,
|
|
258
258
|
__debugFrameLodState: vp,
|
|
259
259
|
countFrameLodListeners: wp,
|
|
260
260
|
createFrameLodController: ad,
|
|
@@ -621,12 +621,12 @@ function ba(e = {}) {
|
|
|
621
621
|
Math.max(Rc, Math.min(o, i))
|
|
622
622
|
);
|
|
623
623
|
}
|
|
624
|
-
let yd = ba(),
|
|
625
|
-
const
|
|
624
|
+
let yd = ba(), Kr = 0, Tc = 0, Vo = 0, ns = !1;
|
|
625
|
+
const zt = [], ht = /* @__PURE__ */ new Map(), Ht = /* @__PURE__ */ new Map(), gr = /* @__PURE__ */ new Set(), jt = /* @__PURE__ */ new Map(), br = /* @__PURE__ */ new Map(), mt = /* @__PURE__ */ new Map(), vd = /* @__PURE__ */ new Map(), xa = /* @__PURE__ */ new Map(), Fc = /* @__PURE__ */ new WeakMap(), Dn = /* @__PURE__ */ new Map(), Mo = /* @__PURE__ */ new Map();
|
|
626
626
|
let Eo = 0, Jp = 0, rs = !1;
|
|
627
627
|
const Ko = [], ni = /* @__PURE__ */ new Map();
|
|
628
|
-
let
|
|
629
|
-
const
|
|
628
|
+
let Wt = 0, Zt = 0, lr = gd, Is, Ur = null;
|
|
629
|
+
const qr = /* @__PURE__ */ new Map(), ct = /* @__PURE__ */ new Set(), ri = /* @__PURE__ */ new Set();
|
|
630
630
|
let ya = 0, va = 0;
|
|
631
631
|
const oi = /* @__PURE__ */ new Set(), ii = /* @__PURE__ */ new Map(), wa = /* @__PURE__ */ new Map();
|
|
632
632
|
let wd = 0;
|
|
@@ -676,10 +676,10 @@ function Jt(e) {
|
|
|
676
676
|
function Lc() {
|
|
677
677
|
for (const e of [...Cs]) e();
|
|
678
678
|
}
|
|
679
|
-
function
|
|
679
|
+
function xr() {
|
|
680
680
|
dr += 1;
|
|
681
681
|
}
|
|
682
|
-
function
|
|
682
|
+
function yr() {
|
|
683
683
|
if (dr = Math.max(0, dr - 1), dr > 0) return;
|
|
684
684
|
const e = ks, t = e ? [] : [...Ms], n = e ? [] : [...Es];
|
|
685
685
|
ks = !1, Ms.clear(), Es.clear();
|
|
@@ -722,7 +722,7 @@ function Id(e) {
|
|
|
722
722
|
function Cd(e, t, n) {
|
|
723
723
|
return Ca(
|
|
724
724
|
ai,
|
|
725
|
-
|
|
725
|
+
Nr({
|
|
726
726
|
id: e,
|
|
727
727
|
...t ? { fingerprint: t } : {}
|
|
728
728
|
}),
|
|
@@ -731,7 +731,7 @@ function Cd(e, t, n) {
|
|
|
731
731
|
}
|
|
732
732
|
function $d(e, t) {
|
|
733
733
|
return (Na.get(
|
|
734
|
-
|
|
734
|
+
Nr({
|
|
735
735
|
id: e,
|
|
736
736
|
...t ? { fingerprint: t } : {}
|
|
737
737
|
})
|
|
@@ -741,17 +741,17 @@ function Pd(e) {
|
|
|
741
741
|
return Cs.add(e), () => Cs.delete(e);
|
|
742
742
|
}
|
|
743
743
|
function Ls() {
|
|
744
|
-
return
|
|
744
|
+
return Kr;
|
|
745
745
|
}
|
|
746
746
|
function Yn(e) {
|
|
747
|
-
return ht.has(e) || mt.has(e) ||
|
|
747
|
+
return ht.has(e) || mt.has(e) || Ht.has(e);
|
|
748
748
|
}
|
|
749
749
|
function Pi(e) {
|
|
750
750
|
var t;
|
|
751
|
-
return Yn(e) && ((t =
|
|
751
|
+
return Yn(e) && ((t = jt.get(e)) == null ? void 0 : t.stale) !== !0;
|
|
752
752
|
}
|
|
753
753
|
function $a(e) {
|
|
754
|
-
return
|
|
754
|
+
return jt.get(e) ?? null;
|
|
755
755
|
}
|
|
756
756
|
function Ds() {
|
|
757
757
|
return va;
|
|
@@ -759,7 +759,7 @@ function Ds() {
|
|
|
759
759
|
function Md(e) {
|
|
760
760
|
return oi.add(e), () => oi.delete(e);
|
|
761
761
|
}
|
|
762
|
-
function
|
|
762
|
+
function Nr(e) {
|
|
763
763
|
return `${e.id.trim()}\0${e.fingerprint ?? ""}`;
|
|
764
764
|
}
|
|
765
765
|
function Qp(e, t) {
|
|
@@ -776,8 +776,8 @@ function Qp(e, t) {
|
|
|
776
776
|
}
|
|
777
777
|
function hn(e, t) {
|
|
778
778
|
const n = e.trim();
|
|
779
|
-
return n ?
|
|
780
|
-
|
|
779
|
+
return n ? br.get(
|
|
780
|
+
Nr({
|
|
781
781
|
id: n,
|
|
782
782
|
...t ? { fingerprint: t } : {}
|
|
783
783
|
})
|
|
@@ -788,29 +788,29 @@ function zs(e, t) {
|
|
|
788
788
|
for (const r of e) {
|
|
789
789
|
const o = r.id.trim();
|
|
790
790
|
if (!o) continue;
|
|
791
|
-
const i =
|
|
791
|
+
const i = Nr({
|
|
792
792
|
id: o,
|
|
793
793
|
...r.fingerprint ? { fingerprint: r.fingerprint } : {}
|
|
794
|
-
}), a =
|
|
795
|
-
JSON.stringify(a) !== JSON.stringify(t) && (
|
|
794
|
+
}), a = br.get(i);
|
|
795
|
+
JSON.stringify(a) !== JSON.stringify(t) && (br.set(i, t), n.push(i));
|
|
796
796
|
}
|
|
797
797
|
return n;
|
|
798
798
|
}
|
|
799
799
|
function vt(e, t) {
|
|
800
800
|
const n = zs(e, t);
|
|
801
801
|
if (n.length !== 0) {
|
|
802
|
-
|
|
802
|
+
xr();
|
|
803
803
|
try {
|
|
804
804
|
for (const r of n) Jt({ identity: r });
|
|
805
805
|
} finally {
|
|
806
|
-
|
|
806
|
+
yr();
|
|
807
807
|
}
|
|
808
808
|
}
|
|
809
809
|
}
|
|
810
810
|
function _s(e) {
|
|
811
|
-
return ht.has(e) || mt.has(e) ||
|
|
811
|
+
return ht.has(e) || mt.has(e) || Ht.has(e) || ct.has(e);
|
|
812
812
|
}
|
|
813
|
-
function
|
|
813
|
+
function Ir(e) {
|
|
814
814
|
const t = e == null ? void 0 : e.trim();
|
|
815
815
|
return t && t.length <= 512 ? t : gd;
|
|
816
816
|
}
|
|
@@ -832,7 +832,7 @@ let Pa = null, Ed = !1;
|
|
|
832
832
|
const un = /* @__PURE__ */ new Map();
|
|
833
833
|
let Hn = 0;
|
|
834
834
|
function Bs(e) {
|
|
835
|
-
Hn += 1, Pa = e, un.clear(), !e &&
|
|
835
|
+
Hn += 1, Pa = e, un.clear(), !e && br.size > 0 && (br.clear(), Jt());
|
|
836
836
|
}
|
|
837
837
|
function kd(e) {
|
|
838
838
|
Ed = e;
|
|
@@ -860,7 +860,7 @@ function js(e, t, n = {}) {
|
|
|
860
860
|
const i = {
|
|
861
861
|
id: r,
|
|
862
862
|
...t ? { fingerprint: t } : {}
|
|
863
|
-
}, a =
|
|
863
|
+
}, a = Nr(i), c = un.get(a);
|
|
864
864
|
if (c) return c;
|
|
865
865
|
const l = hn(r, t);
|
|
866
866
|
if (l.status === "exact" || l.status === "error" && !n.retry)
|
|
@@ -913,7 +913,7 @@ function Td(e, t = {}) {
|
|
|
913
913
|
const p = {
|
|
914
914
|
id: u,
|
|
915
915
|
...d.fingerprint ? { fingerprint: d.fingerprint } : {}
|
|
916
|
-
}, m =
|
|
916
|
+
}, m = Nr(p);
|
|
917
917
|
if (i.has(m) || un.has(m)) continue;
|
|
918
918
|
const b = hn(
|
|
919
919
|
u,
|
|
@@ -964,7 +964,7 @@ function Td(e, t = {}) {
|
|
|
964
964
|
}), l;
|
|
965
965
|
}
|
|
966
966
|
function Mi(e) {
|
|
967
|
-
const t =
|
|
967
|
+
const t = Ir(e.namespace ?? lr), n = Os({
|
|
968
968
|
version: no,
|
|
969
969
|
previewRevision: e.previewRevision ?? "",
|
|
970
970
|
route: e.route,
|
|
@@ -1068,10 +1068,10 @@ function Ma(e) {
|
|
|
1068
1068
|
function ci(e) {
|
|
1069
1069
|
const t = mt.get(e);
|
|
1070
1070
|
if (!t) return !1;
|
|
1071
|
-
mt.delete(e),
|
|
1071
|
+
mt.delete(e), Wt = Math.max(0, Wt - t.ownBytes);
|
|
1072
1072
|
for (const n of t.head) {
|
|
1073
1073
|
const r = Ma(n.kind), o = r.get(n.key);
|
|
1074
|
-
o && (o.references -= 1, !(o.references > 0) && (r.delete(n.key),
|
|
1074
|
+
o && (o.references -= 1, !(o.references > 0) && (r.delete(n.key), Wt = Math.max(0, Wt - o.bytes)));
|
|
1075
1075
|
}
|
|
1076
1076
|
return !0;
|
|
1077
1077
|
}
|
|
@@ -1117,7 +1117,7 @@ function om(e, t, n, r) {
|
|
|
1117
1117
|
p.references += 1;
|
|
1118
1118
|
else {
|
|
1119
1119
|
const m = l.length * 2;
|
|
1120
|
-
d.set(u, { content: l, bytes: m, references: 1 }),
|
|
1120
|
+
d.set(u, { content: l, bytes: m, references: 1 }), Wt += m;
|
|
1121
1121
|
}
|
|
1122
1122
|
return { kind: c, key: u };
|
|
1123
1123
|
}), a = (o.body.length + o.document.doctype.length + o.document.htmlAttributes.length + o.document.headAttributes.length + o.document.bodyAttributes.length + i.reduce((c, l) => c + l.key.length, 0)) * 2;
|
|
@@ -1129,7 +1129,7 @@ function om(e, t, n, r) {
|
|
|
1129
1129
|
head: i,
|
|
1130
1130
|
body: o.body,
|
|
1131
1131
|
shadow: null
|
|
1132
|
-
}),
|
|
1132
|
+
}), Wt += a, !0;
|
|
1133
1133
|
}
|
|
1134
1134
|
function im(e, t) {
|
|
1135
1135
|
let n = Fc.get(e);
|
|
@@ -1193,7 +1193,7 @@ function sm(e) {
|
|
|
1193
1193
|
}, e.shadow;
|
|
1194
1194
|
}
|
|
1195
1195
|
function _n(e) {
|
|
1196
|
-
const t =
|
|
1196
|
+
const t = Ht.get(e);
|
|
1197
1197
|
if (t) return sm(t);
|
|
1198
1198
|
const n = mt.get(e);
|
|
1199
1199
|
return n ? (mt.delete(e), n.lastAccess = Date.now(), mt.set(e, n), rm(n)) : null;
|
|
@@ -1203,7 +1203,7 @@ function Ea(e) {
|
|
|
1203
1203
|
}
|
|
1204
1204
|
function Ws(e, t) {
|
|
1205
1205
|
var b;
|
|
1206
|
-
const n =
|
|
1206
|
+
const n = Ir(t.namespace), r = (e == null ? void 0 : e.version) === 2 ? Ci(e) : null, o = (e == null ? void 0 : e.version) === 3 ? $i(e) : null;
|
|
1207
1207
|
if (!e || e.version !== 1 && e.version !== 2 && e.version !== 3 || typeof e.namespace != "string" || !e.namespace.trim() || e.namespace !== e.namespace.trim() || e.sourceRevision != null && (typeof e.sourceRevision != "string" || !e.sourceRevision.trim() || e.sourceRevision !== e.sourceRevision.trim()) || e.version === 1 && (!e.snapshots || typeof e.snapshots != "object" || Array.isArray(e.snapshots)) || e.version === 2 && !(r != null && r.valid) || e.version === 3 && !(o != null && o.valid))
|
|
1208
1208
|
return { accepted: 0, rejected: 0, reason: "invalid-bundle" };
|
|
1209
1209
|
const i = e.namespace !== n;
|
|
@@ -1248,7 +1248,7 @@ function Ws(e, t) {
|
|
|
1248
1248
|
)
|
|
1249
1249
|
)
|
|
1250
1250
|
} : null;
|
|
1251
|
-
|
|
1251
|
+
xr();
|
|
1252
1252
|
try {
|
|
1253
1253
|
for (const x of t.pages) {
|
|
1254
1254
|
const w = x.canonicalId.trim();
|
|
@@ -1262,7 +1262,7 @@ function Ws(e, t) {
|
|
|
1262
1262
|
route: x.route,
|
|
1263
1263
|
width: x.width ?? 390,
|
|
1264
1264
|
height: x.height ?? 600,
|
|
1265
|
-
environment:
|
|
1265
|
+
environment: Tt(
|
|
1266
1266
|
t.baselineEnvironment,
|
|
1267
1267
|
x.environment
|
|
1268
1268
|
),
|
|
@@ -1274,7 +1274,7 @@ function Ws(e, t) {
|
|
|
1274
1274
|
const R = e.frames[w];
|
|
1275
1275
|
if (!R) continue;
|
|
1276
1276
|
const H = x.fingerprint != null && R.fingerprint === x.fingerprint, A = l && !(t.allowMatchingFrameIdentity && H) || x.fingerprint != null && !H;
|
|
1277
|
-
if (
|
|
1277
|
+
if (jt.set(v, {
|
|
1278
1278
|
status: R.status,
|
|
1279
1279
|
diagnostics: R.diagnostics,
|
|
1280
1280
|
...A ? { stale: !0 } : {},
|
|
@@ -1284,7 +1284,7 @@ function Ws(e, t) {
|
|
|
1284
1284
|
)
|
|
1285
1285
|
}), ct.add(v), R.snapshot && m) {
|
|
1286
1286
|
const N = os(t.appOrigin, x.route);
|
|
1287
|
-
|
|
1287
|
+
gr.delete(v), Ht.set(v, {
|
|
1288
1288
|
bundle: m,
|
|
1289
1289
|
frameId: w,
|
|
1290
1290
|
previewBase: N,
|
|
@@ -1294,19 +1294,19 @@ function Ws(e, t) {
|
|
|
1294
1294
|
Jt({ key: v }), fn(v), d(x, A), u += 1;
|
|
1295
1295
|
continue;
|
|
1296
1296
|
}
|
|
1297
|
-
if (Yn(v) && ((b =
|
|
1297
|
+
if (Yn(v) && ((b = jt.get(v)) == null ? void 0 : b.stale) !== !0) {
|
|
1298
1298
|
d(x, !1);
|
|
1299
1299
|
continue;
|
|
1300
1300
|
}
|
|
1301
1301
|
if (e.version === 2) {
|
|
1302
1302
|
if (!e.frames[w]) continue;
|
|
1303
1303
|
const H = os(t.appOrigin, x.route);
|
|
1304
|
-
|
|
1304
|
+
gr.delete(v), Ht.set(v, {
|
|
1305
1305
|
bundle: e,
|
|
1306
1306
|
frameId: w,
|
|
1307
1307
|
previewBase: H,
|
|
1308
1308
|
shadow: null
|
|
1309
|
-
}),
|
|
1309
|
+
}), jt.set(v, {
|
|
1310
1310
|
status: "ready",
|
|
1311
1311
|
diagnostics: [],
|
|
1312
1312
|
...l ? { stale: !0 } : {},
|
|
@@ -1329,7 +1329,7 @@ function Ws(e, t) {
|
|
|
1329
1329
|
}
|
|
1330
1330
|
$ = $.replaceAll("__PYGMALION_PREVIEW_BASE__", R);
|
|
1331
1331
|
}
|
|
1332
|
-
Ai(v, $) ? (
|
|
1332
|
+
Ai(v, $) ? (jt.set(v, {
|
|
1333
1333
|
status: "ready",
|
|
1334
1334
|
diagnostics: [],
|
|
1335
1335
|
...l ? { stale: !0 } : {},
|
|
@@ -1337,7 +1337,7 @@ function Ws(e, t) {
|
|
|
1337
1337
|
}), Jt({ key: v }), d(x, l), u += 1) : p += 1;
|
|
1338
1338
|
}
|
|
1339
1339
|
} finally {
|
|
1340
|
-
|
|
1340
|
+
yr();
|
|
1341
1341
|
}
|
|
1342
1342
|
return { accepted: u, rejected: p };
|
|
1343
1343
|
}
|
|
@@ -1347,13 +1347,13 @@ function hr(e) {
|
|
|
1347
1347
|
const n = e.indexOf(":", t.length);
|
|
1348
1348
|
if (n < 0) return lr;
|
|
1349
1349
|
try {
|
|
1350
|
-
return
|
|
1350
|
+
return Ir(decodeURIComponent(e.slice(t.length, n)));
|
|
1351
1351
|
} catch {
|
|
1352
1352
|
return lr;
|
|
1353
1353
|
}
|
|
1354
1354
|
}
|
|
1355
1355
|
function Ld(e) {
|
|
1356
|
-
lr =
|
|
1356
|
+
lr = Ir(e), Hf();
|
|
1357
1357
|
}
|
|
1358
1358
|
function ka() {
|
|
1359
1359
|
return lr;
|
|
@@ -1464,7 +1464,7 @@ class cm {
|
|
|
1464
1464
|
}
|
|
1465
1465
|
}
|
|
1466
1466
|
async function ki() {
|
|
1467
|
-
return Is !== void 0 ? Is :
|
|
1467
|
+
return Is !== void 0 ? Is : Ur || (Ur = (async () => {
|
|
1468
1468
|
try {
|
|
1469
1469
|
return new cm(
|
|
1470
1470
|
await am()
|
|
@@ -1472,10 +1472,10 @@ async function ki() {
|
|
|
1472
1472
|
} catch {
|
|
1473
1473
|
return null;
|
|
1474
1474
|
}
|
|
1475
|
-
})(),
|
|
1475
|
+
})(), Ur);
|
|
1476
1476
|
}
|
|
1477
1477
|
function lm(e) {
|
|
1478
|
-
Is = e,
|
|
1478
|
+
Is = e, Ur = null, qr.clear(), ct.clear();
|
|
1479
1479
|
}
|
|
1480
1480
|
function Hs() {
|
|
1481
1481
|
rs || (rs = !0, queueMicrotask(() => {
|
|
@@ -1514,38 +1514,38 @@ function zd(e, t, n) {
|
|
|
1514
1514
|
request: o
|
|
1515
1515
|
}), Ko.push(o), Hs(), i;
|
|
1516
1516
|
}
|
|
1517
|
-
function
|
|
1517
|
+
function Qr() {
|
|
1518
1518
|
ns || (ns = !0, queueMicrotask(() => {
|
|
1519
1519
|
ns = !1, fm();
|
|
1520
1520
|
}));
|
|
1521
1521
|
}
|
|
1522
1522
|
function dm() {
|
|
1523
1523
|
var e;
|
|
1524
|
-
for (let t =
|
|
1525
|
-
(e =
|
|
1524
|
+
for (let t = zt.length - 1; t >= 0; t -= 1)
|
|
1525
|
+
(e = zt[t]) != null && e.cancelled && zt.splice(t, 1);
|
|
1526
1526
|
}
|
|
1527
1527
|
function um() {
|
|
1528
|
-
if (dm(),
|
|
1528
|
+
if (dm(), zt.length === 0) return null;
|
|
1529
1529
|
let e = 0, t = 0;
|
|
1530
|
-
for (let o = 1; o <
|
|
1531
|
-
const i =
|
|
1530
|
+
for (let o = 1; o < zt.length; o += 1) {
|
|
1531
|
+
const i = zt[o], a = zt[e], c = zt[t];
|
|
1532
1532
|
i.order < a.order && (e = o), (i.priority < c.priority || i.priority === c.priority && i.order < c.order) && (t = o);
|
|
1533
1533
|
}
|
|
1534
1534
|
const r = t !== e && Vo >= Hp ? e : t;
|
|
1535
|
-
return r === e ? Vo = 0 : Vo += 1,
|
|
1535
|
+
return r === e ? Vo = 0 : Vo += 1, zt.splice(r, 1)[0] ?? null;
|
|
1536
1536
|
}
|
|
1537
1537
|
function fm() {
|
|
1538
|
-
for (;
|
|
1538
|
+
for (; Kr < yd && zt.length > 0; ) {
|
|
1539
1539
|
const e = um();
|
|
1540
1540
|
if (!e) break;
|
|
1541
|
-
|
|
1541
|
+
Kr += 1, Lc();
|
|
1542
1542
|
let t = !1;
|
|
1543
1543
|
const n = () => {
|
|
1544
|
-
t || (t = !0,
|
|
1544
|
+
t || (t = !0, Kr = Math.max(0, Kr - 1), Lc(), Qr());
|
|
1545
1545
|
};
|
|
1546
1546
|
e.release = n, e.resolve(n);
|
|
1547
1547
|
}
|
|
1548
|
-
|
|
1548
|
+
zt.length === 0 && (Vo = 0);
|
|
1549
1549
|
}
|
|
1550
1550
|
function _d(e = 0) {
|
|
1551
1551
|
let t;
|
|
@@ -1557,24 +1557,24 @@ function _d(e = 0) {
|
|
|
1557
1557
|
priority: Number.isFinite(e) ? e : 0,
|
|
1558
1558
|
release: null,
|
|
1559
1559
|
resolve: r
|
|
1560
|
-
}, Tc += 1,
|
|
1560
|
+
}, Tc += 1, zt.push(t), Qr();
|
|
1561
1561
|
}),
|
|
1562
1562
|
updatePriority: (r) => {
|
|
1563
1563
|
if (t.cancelled || t.release) return;
|
|
1564
1564
|
const o = Number.isFinite(r) ? r : 0;
|
|
1565
|
-
t.priority = Math.min(t.priority, o),
|
|
1565
|
+
t.priority = Math.min(t.priority, o), Qr();
|
|
1566
1566
|
},
|
|
1567
1567
|
cancel: () => {
|
|
1568
1568
|
var r;
|
|
1569
|
-
t.cancelled || (t.cancelled = !0, (r = t.release) == null || r.call(t),
|
|
1569
|
+
t.cancelled || (t.cancelled = !0, (r = t.release) == null || r.call(t), Qr());
|
|
1570
1570
|
}
|
|
1571
1571
|
};
|
|
1572
1572
|
}
|
|
1573
1573
|
function Od(e) {
|
|
1574
1574
|
const t = Number.isFinite(e) ? Math.floor(e) : ba();
|
|
1575
|
-
yd = Math.min(md, Math.max(1, t)),
|
|
1575
|
+
yd = Math.min(md, Math.max(1, t)), Qr();
|
|
1576
1576
|
}
|
|
1577
|
-
function
|
|
1577
|
+
function Ut(e) {
|
|
1578
1578
|
var a;
|
|
1579
1579
|
const t = ht.get(e);
|
|
1580
1580
|
if (t)
|
|
@@ -1582,7 +1582,7 @@ function Kt(e) {
|
|
|
1582
1582
|
const n = mt.get(e);
|
|
1583
1583
|
if (n)
|
|
1584
1584
|
return mt.delete(e), n.lastAccess = Date.now(), mt.set(e, n), nm(n);
|
|
1585
|
-
const r =
|
|
1585
|
+
const r = Ht.get(e);
|
|
1586
1586
|
if (!r) return null;
|
|
1587
1587
|
const o = dd(
|
|
1588
1588
|
r.bundle,
|
|
@@ -1593,33 +1593,33 @@ function Kt(e) {
|
|
|
1593
1593
|
o,
|
|
1594
1594
|
r.previewBase
|
|
1595
1595
|
);
|
|
1596
|
-
return ((a =
|
|
1596
|
+
return ((a = jt.get(e)) == null ? void 0 : a.stale) !== !0 && Ei(i) && !gr.has(e) && (gr.add(e), Ra(e, i)), i;
|
|
1597
1597
|
}
|
|
1598
1598
|
function Aa(e, t, n = hr(e), r = Date.now()) {
|
|
1599
1599
|
var c, l, d;
|
|
1600
1600
|
const o = t.length * 2;
|
|
1601
1601
|
if (!e || !Ei(t) || o > ga)
|
|
1602
1602
|
return !1;
|
|
1603
|
-
|
|
1603
|
+
Ht.delete(e), ci(e);
|
|
1604
1604
|
const i = ht.get(e);
|
|
1605
|
-
i && (
|
|
1606
|
-
const a =
|
|
1605
|
+
i && (Wt -= i.bytes, ht.delete(e));
|
|
1606
|
+
const a = Ir(n);
|
|
1607
1607
|
om(e, t, a, r) || (ht.set(e, {
|
|
1608
1608
|
bytes: o,
|
|
1609
1609
|
value: t,
|
|
1610
1610
|
namespace: a,
|
|
1611
1611
|
lastAccess: r
|
|
1612
|
-
}),
|
|
1612
|
+
}), Wt += o), xr();
|
|
1613
1613
|
try {
|
|
1614
|
-
for (((c =
|
|
1614
|
+
for (((c = jt.get(e)) == null ? void 0 : c.stale) === !0 && (jt.delete(e), Jt({ key: e })); ht.size + mt.size > Vp || Wt > Kp; ) {
|
|
1615
1615
|
const u = ht.keys().next().value, p = mt.keys().next().value, m = u ? ((l = ht.get(u)) == null ? void 0 : l.lastAccess) ?? Number.POSITIVE_INFINITY : Number.POSITIVE_INFINITY, b = p ? ((d = mt.get(p)) == null ? void 0 : d.lastAccess) ?? Number.POSITIVE_INFINITY : Number.POSITIVE_INFINITY, x = m <= b ? u : p;
|
|
1616
1616
|
if (!x) break;
|
|
1617
1617
|
const w = ht.get(x);
|
|
1618
|
-
w ? (
|
|
1618
|
+
w ? (Wt -= w.bytes, ht.delete(x)) : ci(x), ct.delete(x), fn(x);
|
|
1619
1619
|
}
|
|
1620
1620
|
ct.add(e), fn(e);
|
|
1621
1621
|
} finally {
|
|
1622
|
-
|
|
1622
|
+
yr();
|
|
1623
1623
|
}
|
|
1624
1624
|
return !0;
|
|
1625
1625
|
}
|
|
@@ -1648,11 +1648,11 @@ function Ai(e, t) {
|
|
|
1648
1648
|
return n && Ra(e, t), n;
|
|
1649
1649
|
}
|
|
1650
1650
|
function jd(e) {
|
|
1651
|
-
if (
|
|
1652
|
-
const t =
|
|
1651
|
+
if (Ht.has(e)) return Promise.resolve(null);
|
|
1652
|
+
const t = Ut(e);
|
|
1653
1653
|
if (t) return Promise.resolve(t);
|
|
1654
1654
|
if (ct.has(e)) return Promise.resolve(null);
|
|
1655
|
-
const n =
|
|
1655
|
+
const n = qr.get(e);
|
|
1656
1656
|
if (n) return n;
|
|
1657
1657
|
const r = Zt, o = (async () => {
|
|
1658
1658
|
const i = await ki();
|
|
@@ -1681,27 +1681,27 @@ function jd(e) {
|
|
|
1681
1681
|
l
|
|
1682
1682
|
), ct.add(e), Ra(e, c.snapshot, l), c.snapshot;
|
|
1683
1683
|
})().finally(() => {
|
|
1684
|
-
|
|
1684
|
+
qr.get(e) === o && qr.delete(e);
|
|
1685
1685
|
});
|
|
1686
|
-
return
|
|
1686
|
+
return qr.set(e, o), o;
|
|
1687
1687
|
}
|
|
1688
1688
|
async function Ta(e) {
|
|
1689
1689
|
const t = [...new Set(e.filter(Boolean))], n = /* @__PURE__ */ new Map(), r = [];
|
|
1690
1690
|
for (const u of t) {
|
|
1691
|
-
if (
|
|
1692
|
-
const p =
|
|
1691
|
+
if (Ht.has(u)) continue;
|
|
1692
|
+
const p = Ut(u);
|
|
1693
1693
|
p ? n.set(u, p) : ct.has(u) || r.push(u);
|
|
1694
1694
|
}
|
|
1695
1695
|
if (!r.length) return n;
|
|
1696
1696
|
const o = await ki();
|
|
1697
1697
|
if (!o) {
|
|
1698
|
-
|
|
1698
|
+
xr();
|
|
1699
1699
|
try {
|
|
1700
1700
|
r.forEach((u) => {
|
|
1701
1701
|
ct.add(u), fn(u);
|
|
1702
1702
|
});
|
|
1703
1703
|
} finally {
|
|
1704
|
-
|
|
1704
|
+
yr();
|
|
1705
1705
|
}
|
|
1706
1706
|
return n;
|
|
1707
1707
|
}
|
|
@@ -1758,7 +1758,7 @@ async function Ta(e) {
|
|
|
1758
1758
|
);
|
|
1759
1759
|
}
|
|
1760
1760
|
}
|
|
1761
|
-
|
|
1761
|
+
xr();
|
|
1762
1762
|
try {
|
|
1763
1763
|
await Promise.all(
|
|
1764
1764
|
Array.from(
|
|
@@ -1767,23 +1767,23 @@ async function Ta(e) {
|
|
|
1767
1767
|
)
|
|
1768
1768
|
);
|
|
1769
1769
|
} finally {
|
|
1770
|
-
|
|
1770
|
+
yr();
|
|
1771
1771
|
}
|
|
1772
1772
|
return n;
|
|
1773
1773
|
}
|
|
1774
1774
|
function hm(e) {
|
|
1775
|
-
const t = e ?
|
|
1775
|
+
const t = e ? Ir(e) : null;
|
|
1776
1776
|
if (!t)
|
|
1777
|
-
ht.clear(), mt.clear(), vd.clear(), xa.clear(),
|
|
1777
|
+
ht.clear(), mt.clear(), vd.clear(), xa.clear(), Ht.clear(), gr.clear(), jt.clear(), br.clear(), Wt = 0;
|
|
1778
1778
|
else {
|
|
1779
1779
|
for (const [r, o] of ht)
|
|
1780
|
-
o.namespace === t && (ht.delete(r),
|
|
1780
|
+
o.namespace === t && (ht.delete(r), Wt -= o.bytes);
|
|
1781
1781
|
for (const [r, o] of [...mt])
|
|
1782
1782
|
o.namespace === t && ci(r);
|
|
1783
|
-
for (const r of
|
|
1784
|
-
hr(r) === t && (
|
|
1785
|
-
for (const r of
|
|
1786
|
-
hr(r) === t &&
|
|
1783
|
+
for (const r of Ht.keys())
|
|
1784
|
+
hr(r) === t && (Ht.delete(r), gr.delete(r));
|
|
1785
|
+
for (const r of jt.keys())
|
|
1786
|
+
hr(r) === t && jt.delete(r);
|
|
1787
1787
|
}
|
|
1788
1788
|
if (Zt += 1, !t) ct.clear();
|
|
1789
1789
|
else
|
|
@@ -1824,7 +1824,7 @@ function Fa(e, t, n) {
|
|
|
1824
1824
|
), i;
|
|
1825
1825
|
}
|
|
1826
1826
|
function li(e, t, n, r = e) {
|
|
1827
|
-
const o =
|
|
1827
|
+
const o = Ut(e);
|
|
1828
1828
|
if (o) return Promise.resolve(o);
|
|
1829
1829
|
const i = Mo.get(r);
|
|
1830
1830
|
if (i) {
|
|
@@ -1838,7 +1838,7 @@ function li(e, t, n, r = e) {
|
|
|
1838
1838
|
promise: Promise.resolve(null)
|
|
1839
1839
|
};
|
|
1840
1840
|
return l.promise = jd(e).then((d) => d || Zt !== a ? d : Fa(c, l.priority, async () => {
|
|
1841
|
-
const u =
|
|
1841
|
+
const u = Ut(e);
|
|
1842
1842
|
if (u) return u;
|
|
1843
1843
|
const p = await n();
|
|
1844
1844
|
return p && Zt === a && Ai(e, p), p;
|
|
@@ -1957,10 +1957,10 @@ function vm(e = 350) {
|
|
|
1957
1957
|
const Vs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
1958
1958
|
__proto__: null,
|
|
1959
1959
|
acquireRoutePreviewSlot: _d,
|
|
1960
|
-
beginSnapshotNotificationBatch:
|
|
1960
|
+
beginSnapshotNotificationBatch: xr,
|
|
1961
1961
|
clearRoutePreviewSnapshots: hm,
|
|
1962
1962
|
createRoutePreviewRecipeKey: Mi,
|
|
1963
|
-
endSnapshotNotificationBatch:
|
|
1963
|
+
endSnapshotNotificationBatch: yr,
|
|
1964
1964
|
getActiveRoutePreviewCount: Ls,
|
|
1965
1965
|
getRoutePreviewArtifactIdentityVersion: $d,
|
|
1966
1966
|
getRoutePreviewArtifactKeyVersion: Id,
|
|
@@ -1969,7 +1969,7 @@ const Vs = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
1969
1969
|
getRoutePreviewArtifactRevision: Ds,
|
|
1970
1970
|
getRoutePreviewCacheNamespace: ka,
|
|
1971
1971
|
getRoutePreviewShadowArtifact: _n,
|
|
1972
|
-
getRoutePreviewSnapshot:
|
|
1972
|
+
getRoutePreviewSnapshot: Ut,
|
|
1973
1973
|
getRoutePreviewSnapshotKeyVersion: Fs,
|
|
1974
1974
|
getRoutePreviewSnapshotRevision: Rs,
|
|
1975
1975
|
hasExactRoutePreviewSnapshot: Pi,
|
|
@@ -2088,30 +2088,30 @@ function Pm() {
|
|
|
2088
2088
|
const n = Gn.get(t.id);
|
|
2089
2089
|
if (n == null) continue;
|
|
2090
2090
|
const r = t.options.find((o) => o.value === n);
|
|
2091
|
-
e =
|
|
2091
|
+
e = Tt(e, r == null ? void 0 : r.environment);
|
|
2092
2092
|
}
|
|
2093
2093
|
return e;
|
|
2094
2094
|
}
|
|
2095
2095
|
function za(e) {
|
|
2096
2096
|
return Ks.add(e), () => Ks.delete(e);
|
|
2097
2097
|
}
|
|
2098
|
-
function
|
|
2098
|
+
function vr() {
|
|
2099
2099
|
return Wd;
|
|
2100
2100
|
}
|
|
2101
|
-
function
|
|
2101
|
+
function pn(e, t) {
|
|
2102
2102
|
const n = t ?? e.id === f.activePageId;
|
|
2103
|
-
return
|
|
2103
|
+
return Tt(
|
|
2104
2104
|
e.environment,
|
|
2105
2105
|
n ? Pm() : void 0
|
|
2106
2106
|
);
|
|
2107
2107
|
}
|
|
2108
|
-
function
|
|
2108
|
+
function Ot(e, t, n = {
|
|
2109
2109
|
width: e.width ?? 390,
|
|
2110
2110
|
height: e.height ?? 600
|
|
2111
2111
|
}, r) {
|
|
2112
|
-
const o =
|
|
2113
|
-
|
|
2114
|
-
|
|
2112
|
+
const o = Tt(
|
|
2113
|
+
Kt(),
|
|
2114
|
+
pn(e, r)
|
|
2115
2115
|
);
|
|
2116
2116
|
return Mi({
|
|
2117
2117
|
namespace: ka(),
|
|
@@ -2127,9 +2127,9 @@ function _t(e, t, n = {
|
|
|
2127
2127
|
}
|
|
2128
2128
|
const Mm = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
2129
2129
|
__proto__: null,
|
|
2130
|
-
pagePreviewEnvironment:
|
|
2131
|
-
routePreviewCacheKey:
|
|
2132
|
-
}, Symbol.toStringTag, { value: "Module" })), Em = /* @__PURE__ */ new Set(),
|
|
2130
|
+
pagePreviewEnvironment: pn,
|
|
2131
|
+
routePreviewCacheKey: Ot
|
|
2132
|
+
}, Symbol.toStringTag, { value: "Module" })), Em = /* @__PURE__ */ new Set(), Yr = /* @__PURE__ */ new Map();
|
|
2133
2133
|
let $t = [];
|
|
2134
2134
|
const Hd = 2;
|
|
2135
2135
|
function Vd(e, t) {
|
|
@@ -2138,7 +2138,7 @@ function Vd(e, t) {
|
|
|
2138
2138
|
for (const r of e) t.includes(r) || n.add(r);
|
|
2139
2139
|
for (const r of t) e.includes(r) || n.add(r);
|
|
2140
2140
|
for (const r of n) {
|
|
2141
|
-
const o =
|
|
2141
|
+
const o = Yr.get(r);
|
|
2142
2142
|
if (o)
|
|
2143
2143
|
for (const i of [...o]) i();
|
|
2144
2144
|
}
|
|
@@ -2165,9 +2165,9 @@ function Kd() {
|
|
|
2165
2165
|
return $t;
|
|
2166
2166
|
}
|
|
2167
2167
|
function Am(e, t) {
|
|
2168
|
-
let n =
|
|
2169
|
-
return n || (n = /* @__PURE__ */ new Set(),
|
|
2170
|
-
n.delete(t), n.size === 0 &&
|
|
2168
|
+
let n = Yr.get(e);
|
|
2169
|
+
return n || (n = /* @__PURE__ */ new Set(), Yr.set(e, n)), n.add(t), () => {
|
|
2170
|
+
n.delete(t), n.size === 0 && Yr.get(e) === n && Yr.delete(e);
|
|
2171
2171
|
};
|
|
2172
2172
|
}
|
|
2173
2173
|
function zc() {
|
|
@@ -2187,9 +2187,9 @@ function Rm(e, t) {
|
|
|
2187
2187
|
route: e.route,
|
|
2188
2188
|
width: n,
|
|
2189
2189
|
height: r,
|
|
2190
|
-
key:
|
|
2190
|
+
key: Ot(e, t)
|
|
2191
2191
|
}, di.set(e, i));
|
|
2192
|
-
const a =
|
|
2192
|
+
const a = Ut(i.key);
|
|
2193
2193
|
if (a != null) return a.length * 2;
|
|
2194
2194
|
const c = _n(i.key);
|
|
2195
2195
|
return c ? c.bodyHtml.length * 2 : 0;
|
|
@@ -2197,7 +2197,7 @@ function Rm(e, t) {
|
|
|
2197
2197
|
function Tm(e, t) {
|
|
2198
2198
|
var a;
|
|
2199
2199
|
if (e.route == null) return null;
|
|
2200
|
-
const n = di.get(e), r = (n == null ? void 0 : n.key) ??
|
|
2200
|
+
const n = di.get(e), r = (n == null ? void 0 : n.key) ?? Ot(e, t), o = (a = $a(r)) == null ? void 0 : a.screenshot;
|
|
2201
2201
|
if (!o) return null;
|
|
2202
2202
|
const i = e.width ?? 390;
|
|
2203
2203
|
return i > 0 ? o.width / i : null;
|
|
@@ -2289,7 +2289,7 @@ const Dm = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
2289
2289
|
CameraLayer: qd,
|
|
2290
2290
|
__debugReadEditorFrames: Fm
|
|
2291
2291
|
}, Symbol.toStringTag, { value: "Module" }));
|
|
2292
|
-
function
|
|
2292
|
+
function _t(e) {
|
|
2293
2293
|
return typeof e == "number" && Number.isFinite(e) ? Math.max(0, e) : 0;
|
|
2294
2294
|
}
|
|
2295
2295
|
function Us(e) {
|
|
@@ -2317,9 +2317,9 @@ function Yd(e) {
|
|
|
2317
2317
|
1,
|
|
2318
2318
|
Math.ceil(
|
|
2319
2319
|
Math.max(
|
|
2320
|
-
|
|
2321
|
-
|
|
2322
|
-
|
|
2320
|
+
_t(t.clientWidth),
|
|
2321
|
+
_t(t.offsetWidth),
|
|
2322
|
+
_t(t.scrollWidth),
|
|
2323
2323
|
n.width,
|
|
2324
2324
|
i - r
|
|
2325
2325
|
)
|
|
@@ -2329,9 +2329,9 @@ function Yd(e) {
|
|
|
2329
2329
|
1,
|
|
2330
2330
|
Math.ceil(
|
|
2331
2331
|
Math.max(
|
|
2332
|
-
|
|
2333
|
-
|
|
2334
|
-
|
|
2332
|
+
_t(t.clientHeight),
|
|
2333
|
+
_t(t.offsetHeight),
|
|
2334
|
+
_t(t.scrollHeight),
|
|
2335
2335
|
n.height,
|
|
2336
2336
|
a - o
|
|
2337
2337
|
)
|
|
@@ -2340,15 +2340,15 @@ function Yd(e) {
|
|
|
2340
2340
|
};
|
|
2341
2341
|
}
|
|
2342
2342
|
function Oc(e) {
|
|
2343
|
-
const t = e, n = Us(e), r =
|
|
2343
|
+
const t = e, n = Us(e), r = _t(t.offsetWidth), o = _t(t.offsetHeight), i = _t(t.clientWidth), a = _t(t.clientHeight);
|
|
2344
2344
|
return {
|
|
2345
2345
|
width: Math.max(
|
|
2346
2346
|
1,
|
|
2347
|
-
Math.ceil(r || i ||
|
|
2347
|
+
Math.ceil(r || i || _t(n.width))
|
|
2348
2348
|
),
|
|
2349
2349
|
height: Math.max(
|
|
2350
2350
|
1,
|
|
2351
|
-
Math.ceil(o || a ||
|
|
2351
|
+
Math.ceil(o || a || _t(n.height))
|
|
2352
2352
|
)
|
|
2353
2353
|
};
|
|
2354
2354
|
}
|
|
@@ -2432,8 +2432,8 @@ function Hm() {
|
|
|
2432
2432
|
qn
|
|
2433
2433
|
), n = Je(
|
|
2434
2434
|
za,
|
|
2435
|
-
|
|
2436
|
-
|
|
2435
|
+
vr,
|
|
2436
|
+
vr
|
|
2437
2437
|
);
|
|
2438
2438
|
return { appOrigin: e, previewRevision: t, environmentControlRevision: n };
|
|
2439
2439
|
}
|
|
@@ -2527,7 +2527,7 @@ function Xd() {
|
|
|
2527
2527
|
}
|
|
2528
2528
|
const Ym = 2, Gm = 18e4;
|
|
2529
2529
|
let Xm = Gm;
|
|
2530
|
-
const
|
|
2530
|
+
const Bt = [], Vn = {
|
|
2531
2531
|
boots: 0,
|
|
2532
2532
|
reuses: 0,
|
|
2533
2533
|
parks: 0,
|
|
@@ -2551,7 +2551,7 @@ function qs(e) {
|
|
|
2551
2551
|
e.timer != null && clearTimeout(e.timer), e.iframe.remove(), Vn.evictions += 1;
|
|
2552
2552
|
}
|
|
2553
2553
|
function Ba() {
|
|
2554
|
-
const e =
|
|
2554
|
+
const e = Bt.splice(0, Bt.length);
|
|
2555
2555
|
for (const t of e) qs(t);
|
|
2556
2556
|
}
|
|
2557
2557
|
function Zd(e, t) {
|
|
@@ -2569,16 +2569,16 @@ function Zd(e, t) {
|
|
|
2569
2569
|
return !0;
|
|
2570
2570
|
}
|
|
2571
2571
|
function eu(e) {
|
|
2572
|
-
return
|
|
2572
|
+
return Bt.some((t) => Zd(t, e));
|
|
2573
2573
|
}
|
|
2574
2574
|
function Qm(e) {
|
|
2575
2575
|
let t = -1, n = -1;
|
|
2576
|
-
for (let o = 0; o <
|
|
2577
|
-
const i =
|
|
2576
|
+
for (let o = 0; o < Bt.length; o += 1) {
|
|
2577
|
+
const i = Bt[o];
|
|
2578
2578
|
Zd(i, e) && i.executed.length > n && (n = i.executed.length, t = o);
|
|
2579
2579
|
}
|
|
2580
2580
|
if (t < 0) return null;
|
|
2581
|
-
const [r] =
|
|
2581
|
+
const [r] = Bt.splice(t, 1);
|
|
2582
2582
|
return r.timer != null && clearTimeout(r.timer), Vn.reuses += 1, { iframe: r.iframe, skip: r.executed.length };
|
|
2583
2583
|
}
|
|
2584
2584
|
function Zm(e, t, n) {
|
|
@@ -2593,10 +2593,10 @@ function Zm(e, t, n) {
|
|
|
2593
2593
|
timer: null
|
|
2594
2594
|
};
|
|
2595
2595
|
for (o.timer = setTimeout(() => {
|
|
2596
|
-
const c =
|
|
2597
|
-
c < 0 || (
|
|
2598
|
-
}, Xm), (a = (i = o.timer) == null ? void 0 : i.unref) == null || a.call(i),
|
|
2599
|
-
const c =
|
|
2596
|
+
const c = Bt.indexOf(o);
|
|
2597
|
+
c < 0 || (Bt.splice(c, 1), qs(o));
|
|
2598
|
+
}, Xm), (a = (i = o.timer) == null ? void 0 : i.unref) == null || a.call(i), Bt.push(o), Vn.parks += 1; Bt.length > Ym; ) {
|
|
2599
|
+
const c = Bt.shift();
|
|
2600
2600
|
c && qs(c);
|
|
2601
2601
|
}
|
|
2602
2602
|
}
|
|
@@ -2773,7 +2773,7 @@ function Ri(e = {}) {
|
|
|
2773
2773
|
},
|
|
2774
2774
|
/** How many finished walks currently have an instance parked for reuse. */
|
|
2775
2775
|
debugWarmInstancesParked() {
|
|
2776
|
-
return
|
|
2776
|
+
return Bt.length;
|
|
2777
2777
|
}
|
|
2778
2778
|
};
|
|
2779
2779
|
}
|
|
@@ -2866,7 +2866,7 @@ function Ti(e, t, n) {
|
|
|
2866
2866
|
const u = l.interactiveStateId ? (l.interactions ?? []).slice(((a = l.baseInteractions) == null ? void 0 : a.length) ?? 0) : [];
|
|
2867
2867
|
r.push({
|
|
2868
2868
|
screenId: c.screenId,
|
|
2869
|
-
cacheKey:
|
|
2869
|
+
cacheKey: Ot(l, n, void 0, !1),
|
|
2870
2870
|
width: l.width ?? 390,
|
|
2871
2871
|
height: dn(l),
|
|
2872
2872
|
steps: [...c.steps ?? [], ...u],
|
|
@@ -2875,11 +2875,11 @@ function Ti(e, t, n) {
|
|
|
2875
2875
|
}
|
|
2876
2876
|
return r.length === 0 ? null : {
|
|
2877
2877
|
id: e.id,
|
|
2878
|
-
url:
|
|
2879
|
-
...
|
|
2880
|
-
|
|
2878
|
+
url: pr(Qt(), e.route, {
|
|
2879
|
+
...Tt(
|
|
2880
|
+
Tt(
|
|
2881
2881
|
Vf(i),
|
|
2882
|
-
|
|
2882
|
+
Kt()
|
|
2883
2883
|
),
|
|
2884
2884
|
e.environment
|
|
2885
2885
|
) ?? {},
|
|
@@ -2972,7 +2972,7 @@ function Fi() {
|
|
|
2972
2972
|
}
|
|
2973
2973
|
function au(e, t, n) {
|
|
2974
2974
|
if (e.route == null) return !1;
|
|
2975
|
-
|
|
2975
|
+
$n.requested += 1;
|
|
2976
2976
|
const r = e.importPageId ?? e.id, o = fo(r);
|
|
2977
2977
|
if (!o) return !1;
|
|
2978
2978
|
const i = /* @__PURE__ */ new Map();
|
|
@@ -2980,32 +2980,32 @@ function au(e, t, n) {
|
|
|
2980
2980
|
p.route == null || p.importLayers !== !0 || i.set(p.importPageId ?? p.id, p);
|
|
2981
2981
|
const a = Ti(o, i, n);
|
|
2982
2982
|
if (!a)
|
|
2983
|
-
return
|
|
2983
|
+
return $n.resolvedNull += 1, !1;
|
|
2984
2984
|
const c = a.waypoints.findIndex(
|
|
2985
2985
|
(p) => p.screenId === r
|
|
2986
2986
|
);
|
|
2987
2987
|
if (c < 0) return !1;
|
|
2988
|
-
const l =
|
|
2988
|
+
const l = Ot(e, n, t, !1), d = async (p) => {
|
|
2989
2989
|
const m = Wn();
|
|
2990
2990
|
if (!m) {
|
|
2991
|
-
|
|
2991
|
+
$n.controllerMissing += 1;
|
|
2992
2992
|
return;
|
|
2993
2993
|
}
|
|
2994
2994
|
const b = f.provisionalLayerImportRevision(e.id);
|
|
2995
2995
|
if (b == null) {
|
|
2996
|
-
|
|
2996
|
+
$n.markerGone += 1;
|
|
2997
2997
|
return;
|
|
2998
2998
|
}
|
|
2999
2999
|
if (f.pageEditRevision(e.id) !== b) {
|
|
3000
|
-
|
|
3000
|
+
$n.editsWon += 1, f.discardProvisionalLayerImport(e.id);
|
|
3001
3001
|
return;
|
|
3002
3002
|
}
|
|
3003
3003
|
const x = await m.captureIframeWhenStable(p);
|
|
3004
3004
|
if (!x) {
|
|
3005
|
-
|
|
3005
|
+
$n.captureNull += 1;
|
|
3006
3006
|
return;
|
|
3007
3007
|
}
|
|
3008
|
-
f.replacePageRootFromDom(e.id, x.root, x),
|
|
3008
|
+
f.replacePageRootFromDom(e.id, x.root, x), $n.committed += 1;
|
|
3009
3009
|
}, u = a.waypoints.slice(0, c + 1).map((p, m) => ({
|
|
3010
3010
|
...p,
|
|
3011
3011
|
width: t.width,
|
|
@@ -3048,16 +3048,16 @@ function Gs(e) {
|
|
|
3048
3048
|
}
|
|
3049
3049
|
function uu(e, t) {
|
|
3050
3050
|
if (e.route == null || e.interactiveStateId == null) return !1;
|
|
3051
|
-
|
|
3051
|
+
Gr.requested += 1;
|
|
3052
3052
|
const n = e.importPageId ?? e.id, r = Gs(e), o = fo(n);
|
|
3053
3053
|
if (!o)
|
|
3054
|
-
return
|
|
3054
|
+
return Gr.noPath += 1, Ao(r), !1;
|
|
3055
3055
|
const i = /* @__PURE__ */ new Map();
|
|
3056
3056
|
for (const p of f.pages)
|
|
3057
3057
|
p.route == null || p.importLayers !== !0 || i.set(p.importPageId ?? p.id, p);
|
|
3058
3058
|
const a = Ti(o, i, t);
|
|
3059
3059
|
if (!a)
|
|
3060
|
-
return
|
|
3060
|
+
return Gr.resolvedNull += 1, Ao(r), !1;
|
|
3061
3061
|
const c = a.waypoints.findIndex(
|
|
3062
3062
|
(p) => p.screenId === n
|
|
3063
3063
|
);
|
|
@@ -3077,7 +3077,7 @@ function uu(e, t) {
|
|
|
3077
3077
|
id: `${a.id}!${e.interactiveStateId}:${e.interactiveOptionId}`,
|
|
3078
3078
|
waypoints: l
|
|
3079
3079
|
}
|
|
3080
|
-
]) > 0 ? (
|
|
3080
|
+
]) > 0 ? (Gr.queued += 1, ui.delete(r), !0) : (d.screenState(r) == null && Ao(r), !1);
|
|
3081
3081
|
}
|
|
3082
3082
|
function fu(e) {
|
|
3083
3083
|
if (e.interactiveStateId == null) return !1;
|
|
@@ -3093,7 +3093,7 @@ function hu(e) {
|
|
|
3093
3093
|
Ys.delete(e), t();
|
|
3094
3094
|
};
|
|
3095
3095
|
}
|
|
3096
|
-
const
|
|
3096
|
+
const Gr = {
|
|
3097
3097
|
requested: 0,
|
|
3098
3098
|
noPath: 0,
|
|
3099
3099
|
resolvedNull: 0,
|
|
@@ -3102,7 +3102,7 @@ const Yr = {
|
|
|
3102
3102
|
function og() {
|
|
3103
3103
|
return Li().debugScreenStates();
|
|
3104
3104
|
}
|
|
3105
|
-
const
|
|
3105
|
+
const $n = {
|
|
3106
3106
|
requested: 0,
|
|
3107
3107
|
resolvedNull: 0,
|
|
3108
3108
|
controllerMissing: 0,
|
|
@@ -3119,8 +3119,8 @@ const sg = /* @__PURE__ */ Object.freeze(/* @__PURE__ */ Object.defineProperty({
|
|
|
3119
3119
|
__debugInteractiveSessionStates: og,
|
|
3120
3120
|
__debugViewportSessionStates: ig,
|
|
3121
3121
|
__flowSchedulerDebug: or,
|
|
3122
|
-
__interactiveSessionDebug:
|
|
3123
|
-
__viewportCommitDebug:
|
|
3122
|
+
__interactiveSessionDebug: Gr,
|
|
3123
|
+
__viewportCommitDebug: $n,
|
|
3124
3124
|
__warmingDebug: ir,
|
|
3125
3125
|
interactiveSessionWillDeliver: fu,
|
|
3126
3126
|
materializeCanvasFlows: iu,
|
|
@@ -3441,7 +3441,7 @@ function jc(e, t = Pg) {
|
|
|
3441
3441
|
n.push(e.slice(r, r + t));
|
|
3442
3442
|
return n;
|
|
3443
3443
|
}
|
|
3444
|
-
function
|
|
3444
|
+
function qt(e, t) {
|
|
3445
3445
|
const n = e.trim();
|
|
3446
3446
|
if (!n && t != null) return t;
|
|
3447
3447
|
if (qo(n)) return n;
|
|
@@ -3486,7 +3486,7 @@ function mu(e) {
|
|
|
3486
3486
|
if (!Array.isArray(e))
|
|
3487
3487
|
throw new TypeError("Preview recipes must be an array.");
|
|
3488
3488
|
const t = /* @__PURE__ */ new Set(), n = e.map(({ id: r, recipe: o }) => {
|
|
3489
|
-
const i =
|
|
3489
|
+
const i = qt(r);
|
|
3490
3490
|
if (t.has(i))
|
|
3491
3491
|
throw new TypeError(`Duplicate preview recipe identity: ${i}`);
|
|
3492
3492
|
return t.add(i), {
|
|
@@ -3500,8 +3500,8 @@ function kg(e, t = {}) {
|
|
|
3500
3500
|
const n = Fg(e), r = t.dependencyDigest;
|
|
3501
3501
|
return mu([
|
|
3502
3502
|
{
|
|
3503
|
-
id:
|
|
3504
|
-
recipe: r == null ? n : { recipe: n, dependencyDigest:
|
|
3503
|
+
id: qt(e.id ?? "", "frame"),
|
|
3504
|
+
recipe: r == null ? n : { recipe: n, dependencyDigest: qt(r) }
|
|
3505
3505
|
}
|
|
3506
3506
|
]);
|
|
3507
3507
|
}
|
|
@@ -3524,7 +3524,7 @@ function Ag(e, t) {
|
|
|
3524
3524
|
}
|
|
3525
3525
|
return t.length === e.length;
|
|
3526
3526
|
}
|
|
3527
|
-
function
|
|
3527
|
+
function Dr(e) {
|
|
3528
3528
|
Qs.clear();
|
|
3529
3529
|
const t = /* @__PURE__ */ new Map();
|
|
3530
3530
|
for (const [n, r] of (e ?? []).entries()) {
|
|
@@ -3569,7 +3569,7 @@ function Va(e, t, n) {
|
|
|
3569
3569
|
route: e.route,
|
|
3570
3570
|
width: e.width ?? 390,
|
|
3571
3571
|
height: e.height ?? 600,
|
|
3572
|
-
environment:
|
|
3572
|
+
environment: Tt(
|
|
3573
3573
|
n,
|
|
3574
3574
|
e.environment
|
|
3575
3575
|
),
|
|
@@ -3590,7 +3590,7 @@ function jw({
|
|
|
3590
3590
|
recipeVersion: n,
|
|
3591
3591
|
scope: r = vg
|
|
3592
3592
|
}) {
|
|
3593
|
-
const o =
|
|
3593
|
+
const o = qt(r), i = qt(
|
|
3594
3594
|
e,
|
|
3595
3595
|
wg
|
|
3596
3596
|
), a = Mg(n), c = mu(t);
|
|
@@ -3696,8 +3696,8 @@ async function zg({
|
|
|
3696
3696
|
frames: o
|
|
3697
3697
|
}) {
|
|
3698
3698
|
const i = {
|
|
3699
|
-
namespace:
|
|
3700
|
-
sourceRevision:
|
|
3699
|
+
namespace: qt(e),
|
|
3700
|
+
sourceRevision: qt(t)
|
|
3701
3701
|
};
|
|
3702
3702
|
let a;
|
|
3703
3703
|
try {
|
|
@@ -3797,7 +3797,7 @@ function jg(e, t, n = {}) {
|
|
|
3797
3797
|
artifact: null,
|
|
3798
3798
|
reason: "invalid-bundle",
|
|
3799
3799
|
errors: r.errors
|
|
3800
|
-
} : t && r.artifact.namespace !==
|
|
3800
|
+
} : t && r.artifact.namespace !== qt(t.namespace) ? {
|
|
3801
3801
|
valid: !1,
|
|
3802
3802
|
artifact: null,
|
|
3803
3803
|
reason: "namespace-mismatch",
|
|
@@ -3807,7 +3807,7 @@ function jg(e, t, n = {}) {
|
|
|
3807
3807
|
} : t && // A per-frame answer is judged frame by frame: the bundle names the last
|
|
3808
3808
|
// publish, not the revision every frame in it came from. Rejecting on that
|
|
3809
3809
|
// value would undo the point of asking per frame.
|
|
3810
|
-
!n.perFrameIdentity && r.artifact.sourceRevision !==
|
|
3810
|
+
!n.perFrameIdentity && r.artifact.sourceRevision !== qt(t.sourceRevision) ? {
|
|
3811
3811
|
valid: !1,
|
|
3812
3812
|
artifact: null,
|
|
3813
3813
|
reason: "revision-mismatch",
|
|
@@ -3843,8 +3843,8 @@ async function Hg({
|
|
|
3843
3843
|
generate: i
|
|
3844
3844
|
}) {
|
|
3845
3845
|
const a = {
|
|
3846
|
-
namespace:
|
|
3847
|
-
sourceRevision:
|
|
3846
|
+
namespace: qt(e),
|
|
3847
|
+
sourceRevision: qt(t)
|
|
3848
3848
|
};
|
|
3849
3849
|
let c;
|
|
3850
3850
|
try {
|
|
@@ -4297,7 +4297,7 @@ const hb = [
|
|
|
4297
4297
|
{ pos: { left: -3, top: 8, bottom: 8, width: 6 }, dx: -1, dy: 0, cursor: "ew-resize", label: "left side" },
|
|
4298
4298
|
{ pos: { right: -3, top: 8, bottom: 8, width: 6 }, dx: 1, dy: 0, cursor: "ew-resize", label: "right side" }
|
|
4299
4299
|
];
|
|
4300
|
-
function
|
|
4300
|
+
function zr({ node: e }) {
|
|
4301
4301
|
const t = (n, r, o) => {
|
|
4302
4302
|
n.stopPropagation(), n.preventDefault();
|
|
4303
4303
|
const i = n.currentTarget.parentElement;
|
|
@@ -4339,7 +4339,7 @@ function Dr({ node: e }) {
|
|
|
4339
4339
|
))
|
|
4340
4340
|
] });
|
|
4341
4341
|
}
|
|
4342
|
-
function
|
|
4342
|
+
function _r({ node: e }) {
|
|
4343
4343
|
if (!e.linkTo) return null;
|
|
4344
4344
|
const t = f.pages.find((n) => n.id === e.linkTo);
|
|
4345
4345
|
return /* @__PURE__ */ s(
|
|
@@ -4369,7 +4369,7 @@ function zr({ node: e }) {
|
|
|
4369
4369
|
}
|
|
4370
4370
|
);
|
|
4371
4371
|
}
|
|
4372
|
-
const
|
|
4372
|
+
const Or = He(function({ count: t }) {
|
|
4373
4373
|
return f.showRenderCount ? /* @__PURE__ */ s(
|
|
4374
4374
|
"span",
|
|
4375
4375
|
{
|
|
@@ -4491,9 +4491,9 @@ const Uc = /* @__PURE__ */ new WeakMap(), qc = ed(function e({ node: t }) {
|
|
|
4491
4491
|
...d,
|
|
4492
4492
|
children: [
|
|
4493
4493
|
c ? /* @__PURE__ */ s(Kc, { node: t }) : t.text,
|
|
4494
|
-
o && !c && /* @__PURE__ */ s(
|
|
4495
|
-
/* @__PURE__ */ s(
|
|
4496
|
-
/* @__PURE__ */ s(
|
|
4494
|
+
o && !c && /* @__PURE__ */ s(zr, { node: t }),
|
|
4495
|
+
/* @__PURE__ */ s(_r, { node: t }),
|
|
4496
|
+
/* @__PURE__ */ s(Or, { count: n.current })
|
|
4497
4497
|
]
|
|
4498
4498
|
}
|
|
4499
4499
|
);
|
|
@@ -4501,17 +4501,17 @@ const Uc = /* @__PURE__ */ new WeakMap(), qc = ed(function e({ node: t }) {
|
|
|
4501
4501
|
const u = Qe()[t.componentName], p = u == null ? void 0 : u.component, m = { ...l, ...Cu(t) };
|
|
4502
4502
|
return p && u.children === "nodes" ? /* @__PURE__ */ g("div", { "data-node-id": t.id, style: m, ...d, children: [
|
|
4503
4503
|
/* @__PURE__ */ s(p, { ...t.componentProps, children: t.children.map((b) => /* @__PURE__ */ s(e, { node: b }, b.id)) }),
|
|
4504
|
-
o && /* @__PURE__ */ s(
|
|
4505
|
-
/* @__PURE__ */ s(
|
|
4506
|
-
/* @__PURE__ */ s(
|
|
4504
|
+
o && /* @__PURE__ */ s(zr, { node: t }),
|
|
4505
|
+
/* @__PURE__ */ s(_r, { node: t }),
|
|
4506
|
+
/* @__PURE__ */ s(Or, { count: n.current })
|
|
4507
4507
|
] }) : /* @__PURE__ */ g("div", { "data-node-id": t.id, style: m, ...d, children: [
|
|
4508
4508
|
/* @__PURE__ */ s("div", { style: { pointerEvents: "none" }, children: p ? /* @__PURE__ */ s(p, { ...t.componentProps, children: u.children === "text" ? t.childrenText : void 0 }) : /* @__PURE__ */ g("span", { style: { fontSize: 11, color: "#f04452" }, children: [
|
|
4509
4509
|
"Unregistered components: ",
|
|
4510
4510
|
t.componentName
|
|
4511
4511
|
] }) }),
|
|
4512
|
-
o && /* @__PURE__ */ s(
|
|
4513
|
-
/* @__PURE__ */ s(
|
|
4514
|
-
/* @__PURE__ */ s(
|
|
4512
|
+
o && /* @__PURE__ */ s(zr, { node: t }),
|
|
4513
|
+
/* @__PURE__ */ s(_r, { node: t }),
|
|
4514
|
+
/* @__PURE__ */ s(Or, { count: n.current })
|
|
4515
4515
|
] });
|
|
4516
4516
|
}
|
|
4517
4517
|
if (t.domTag) {
|
|
@@ -4534,9 +4534,9 @@ const Uc = /* @__PURE__ */ new WeakMap(), qc = ed(function e({ node: t }) {
|
|
|
4534
4534
|
"value" in m && (m.defaultValue = m.value, delete m.value), t.domTag === "textarea" && m.defaultValue == null && (m.defaultValue = t.children.filter((x) => x.domTag === "#text").map((x) => x.text).join(""));
|
|
4535
4535
|
const b = Nu.has(t.domTag) ? void 0 : [
|
|
4536
4536
|
...t.children.map((x) => /* @__PURE__ */ s(e, { node: x }, x.id)),
|
|
4537
|
-
...o ? [/* @__PURE__ */ s(
|
|
4538
|
-
/* @__PURE__ */ s(
|
|
4539
|
-
/* @__PURE__ */ s(
|
|
4537
|
+
...o ? [/* @__PURE__ */ s(zr, { node: t }, "selection")] : [],
|
|
4538
|
+
/* @__PURE__ */ s(_r, { node: t }, "prototype"),
|
|
4539
|
+
/* @__PURE__ */ s(Or, { count: n.current }, "renders")
|
|
4540
4540
|
];
|
|
4541
4541
|
return to(
|
|
4542
4542
|
u,
|
|
@@ -4566,9 +4566,9 @@ const Uc = /* @__PURE__ */ new WeakMap(), qc = ed(function e({ node: t }) {
|
|
|
4566
4566
|
...d,
|
|
4567
4567
|
children: [
|
|
4568
4568
|
t.children.map((u) => /* @__PURE__ */ s(e, { node: u }, u.id)),
|
|
4569
|
-
o && /* @__PURE__ */ s(
|
|
4570
|
-
/* @__PURE__ */ s(
|
|
4571
|
-
/* @__PURE__ */ s(
|
|
4569
|
+
o && /* @__PURE__ */ s(zr, { node: t }),
|
|
4570
|
+
/* @__PURE__ */ s(_r, { node: t }),
|
|
4571
|
+
/* @__PURE__ */ s(Or, { count: n.current })
|
|
4572
4572
|
]
|
|
4573
4573
|
}
|
|
4574
4574
|
);
|
|
@@ -4714,7 +4714,7 @@ const Gc = ({ size: e }) => /* @__PURE__ */ s(et, { size: e, fill: !0, children:
|
|
|
4714
4714
|
] }), bb = ({ size: e }) => /* @__PURE__ */ s(et, { size: e, children: /* @__PURE__ */ s("path", { d: "M1.8 8s2.4-4 6.2-4 6.2 4 6.2 4-2.4 4-6.2 4-6.2-4-6.2-4zM3 13 13 3" }) }), xb = ({ size: e }) => /* @__PURE__ */ g(et, { size: e, children: [
|
|
4715
4715
|
/* @__PURE__ */ s("rect", { x: "3.5", y: "7", width: "9", height: "6", rx: "1" }),
|
|
4716
4716
|
/* @__PURE__ */ s("path", { d: "M5.5 7V5a2.5 2.5 0 0 1 5 0v2" })
|
|
4717
|
-
] }),
|
|
4717
|
+
] }), Zr = ({ size: e = 8, open: t }) => /* @__PURE__ */ s(
|
|
4718
4718
|
"svg",
|
|
4719
4719
|
{
|
|
4720
4720
|
width: e,
|
|
@@ -5173,7 +5173,7 @@ const wb = He(function({
|
|
|
5173
5173
|
":host>html,:host>html>body{display:block;box-sizing:border-box;width:100%;height:100%;margin:0;}",
|
|
5174
5174
|
"*,*::before,*::after{animation:none!important;transition:none!important;caret-color:transparent!important;}",
|
|
5175
5175
|
'a,button,input,select,textarea,[role="button"]{pointer-events:none!important;}'
|
|
5176
|
-
].join(""), Cb =
|
|
5176
|
+
].join(""), Cb = Xr(zu);
|
|
5177
5177
|
function gi(e) {
|
|
5178
5178
|
return e.replaceAll(`\r
|
|
5179
5179
|
`, `
|
|
@@ -5231,7 +5231,7 @@ function Zc(e) {
|
|
|
5231
5231
|
}
|
|
5232
5232
|
return o(e.length), t;
|
|
5233
5233
|
}
|
|
5234
|
-
function
|
|
5234
|
+
function Xr(e) {
|
|
5235
5235
|
const t = gi(e);
|
|
5236
5236
|
let n = 2166136261, r = 2654435769;
|
|
5237
5237
|
for (let o = 0; o < t.length; o += 1) {
|
|
@@ -5255,7 +5255,7 @@ function io(e) {
|
|
|
5255
5255
|
function Ja(e) {
|
|
5256
5256
|
return /^\s*(?:javascript|vbscript|data\s*:\s*text\/html)\s*:/i.test(e);
|
|
5257
5257
|
}
|
|
5258
|
-
function
|
|
5258
|
+
function wr(e) {
|
|
5259
5259
|
if (/(?:expression\s*\(|url\s*\(\s*["']?\s*(?:javascript|vbscript|data\s*:\s*text\/html)\s*:|@import\s+(?:url\s*\(\s*)?["']?\s*(?:javascript|vbscript|data\s*:\s*text\/html)\s*:)/i.test(
|
|
5260
5260
|
e
|
|
5261
5261
|
))
|
|
@@ -5271,7 +5271,7 @@ function Eb(e) {
|
|
|
5271
5271
|
const t = [];
|
|
5272
5272
|
return e.replace(
|
|
5273
5273
|
/<style\b[^>]*>([\s\S]*?)<\/style\s*>/gi,
|
|
5274
|
-
(n, r) => (
|
|
5274
|
+
(n, r) => (wr(r), t.push(r), "")
|
|
5275
5275
|
), t.join(`
|
|
5276
5276
|
`);
|
|
5277
5277
|
}
|
|
@@ -5293,14 +5293,14 @@ function Ab(e) {
|
|
|
5293
5293
|
""
|
|
5294
5294
|
), i = [e.sharedCssText ?? "", n].map(gi).filter(Boolean).join(`
|
|
5295
5295
|
`);
|
|
5296
|
-
return
|
|
5296
|
+
return wr(i), {
|
|
5297
5297
|
bodyHtml: o,
|
|
5298
5298
|
sharedCssText: i,
|
|
5299
5299
|
stylesheetLinksHtml: e.snapshot ? kb(e.snapshot) : ""
|
|
5300
5300
|
};
|
|
5301
5301
|
}
|
|
5302
5302
|
function On(e, t) {
|
|
5303
|
-
|
|
5303
|
+
wr(e);
|
|
5304
5304
|
const n = $b(e), r = io(t);
|
|
5305
5305
|
if (!r) return Zc(n);
|
|
5306
5306
|
const o = (c) => {
|
|
@@ -5347,7 +5347,7 @@ function Xo(e, t, n) {
|
|
|
5347
5347
|
if (l.startsWith("on") || l === "srcdoc")
|
|
5348
5348
|
throw new Error("The frozen preview contains an active attribute.");
|
|
5349
5349
|
if (l === "style") {
|
|
5350
|
-
|
|
5350
|
+
wr(c.value), o && a.setAttribute(
|
|
5351
5351
|
c.name,
|
|
5352
5352
|
On(c.value, o)
|
|
5353
5353
|
);
|
|
@@ -5630,12 +5630,12 @@ class Lb {
|
|
|
5630
5630
|
/** Updates every root using this shared style without rebuilding its DOM. */
|
|
5631
5631
|
updateSharedCss(t, n) {
|
|
5632
5632
|
const r = this.sharedStyles.get(t);
|
|
5633
|
-
return r ? (
|
|
5633
|
+
return r ? (wr(n), this.replaceEntryText(r, n), !0) : !1;
|
|
5634
5634
|
}
|
|
5635
5635
|
/** Updates every mounted preview subscribed to the same override channel. */
|
|
5636
5636
|
updateOverrideCss(t, n) {
|
|
5637
5637
|
const r = this.overrideStyles.get(t);
|
|
5638
|
-
return r ? (
|
|
5638
|
+
return r ? (wr(n), this.replaceEntryText(r, n), !0) : !1;
|
|
5639
5639
|
}
|
|
5640
5640
|
dispose() {
|
|
5641
5641
|
var t;
|
|
@@ -5690,16 +5690,16 @@ function zb(e, t, n = Db) {
|
|
|
5690
5690
|
a
|
|
5691
5691
|
), u = [...d.childNodes];
|
|
5692
5692
|
o.append(d, c);
|
|
5693
|
-
const p =
|
|
5693
|
+
const p = Xr(r.sharedCssText);
|
|
5694
5694
|
if (t.sharedCssHash && t.sharedCssHash !== p)
|
|
5695
5695
|
throw new Error("The provided shared CSS hash does not match its content.");
|
|
5696
|
-
const m = On(r.sharedCssText, a), b =
|
|
5696
|
+
const m = On(r.sharedCssText, a), b = Xr(m), x = (t.sharedStylesheets ?? []).map((z) => {
|
|
5697
5697
|
const X = On(z.cssText, a);
|
|
5698
5698
|
return {
|
|
5699
5699
|
cssText: X,
|
|
5700
|
-
key: `${z.key}:${
|
|
5700
|
+
key: `${z.key}:${Xr(X)}`
|
|
5701
5701
|
};
|
|
5702
|
-
}), w =
|
|
5702
|
+
}), w = Xr(
|
|
5703
5703
|
[b, ...x.map((z) => z.key)].join(":")
|
|
5704
5704
|
), v = ((E = t.overrideKey) == null ? void 0 : E.trim()) || `preview:${w}`, S = n.acquireShared(
|
|
5705
5705
|
o,
|
|
@@ -6073,15 +6073,15 @@ const Xb = He(function({
|
|
|
6073
6073
|
const { appOrigin: c, previewRevision: l } = Hm(), d = Ce(null), u = Ce(null), p = Ce(null), m = Ce(null), b = Ce(null), x = Ce(!1), w = Ce(Wm()), v = Ce(
|
|
6074
6074
|
() => {
|
|
6075
6075
|
}
|
|
6076
|
-
), S = Ce(null), $ = Ce(!1), R = Ce(null), H = Ce(0), A = Ce(null), [N, T] = q(null), [j, E] = q(!1), z = (N == null ? void 0 : N.width) ?? t.width ?? 390, X = (N == null ? void 0 : N.height) ?? dn(t), M = (N == null ? void 0 : N.x) ?? t.x ?? 0, W = (N == null ? void 0 : N.y) ?? t.y ?? 0, J =
|
|
6077
|
-
|
|
6078
|
-
|
|
6079
|
-
), U =
|
|
6076
|
+
), S = Ce(null), $ = Ce(!1), R = Ce(null), H = Ce(0), A = Ce(null), [N, T] = q(null), [j, E] = q(!1), z = (N == null ? void 0 : N.width) ?? t.width ?? 390, X = (N == null ? void 0 : N.height) ?? dn(t), M = (N == null ? void 0 : N.x) ?? t.x ?? 0, W = (N == null ? void 0 : N.y) ?? t.y ?? 0, J = Tt(
|
|
6077
|
+
Kt(),
|
|
6078
|
+
pn(t, n)
|
|
6079
|
+
), U = Ot(
|
|
6080
6080
|
t,
|
|
6081
6081
|
l,
|
|
6082
6082
|
void 0,
|
|
6083
6083
|
n
|
|
6084
|
-
), Me =
|
|
6084
|
+
), Me = Ot(
|
|
6085
6085
|
t,
|
|
6086
6086
|
l,
|
|
6087
6087
|
t.authoredFrameSize ?? {
|
|
@@ -6095,13 +6095,13 @@ const Xb = He(function({
|
|
|
6095
6095
|
route: t.route,
|
|
6096
6096
|
width: t.width,
|
|
6097
6097
|
height: t.height,
|
|
6098
|
-
environment:
|
|
6098
|
+
environment: pn(t, n),
|
|
6099
6099
|
preset: t.preset,
|
|
6100
6100
|
interactions: t.interactions,
|
|
6101
6101
|
assertions: t.assertions
|
|
6102
6102
|
},
|
|
6103
6103
|
l,
|
|
6104
|
-
|
|
6104
|
+
Kt()
|
|
6105
6105
|
) : null, te = Vm({
|
|
6106
6106
|
pageId: t.id,
|
|
6107
6107
|
routePreviewKey: U,
|
|
@@ -6128,7 +6128,7 @@ const Xb = He(function({
|
|
|
6128
6128
|
captureStatus: I == null ? void 0 : I.status,
|
|
6129
6129
|
diagnostic: (Qn = I == null ? void 0 : I.diagnostics[0]) == null ? void 0 : Qn.message
|
|
6130
6130
|
}), [De, ze] = q(
|
|
6131
|
-
() => a && !k ?
|
|
6131
|
+
() => a && !k ? Ut(U) : null
|
|
6132
6132
|
), [Ue, rt] = q(!1), [F, xe] = q(!1), ne = Ce(null), Pe = () => {
|
|
6133
6133
|
!a || t.route == null || t.layersImported || re || ne.current == null && (ne.current = setTimeout(() => {
|
|
6134
6134
|
ne.current = null, _a(t.id);
|
|
@@ -6141,10 +6141,10 @@ const Xb = He(function({
|
|
|
6141
6141
|
}, [t.layersImported, t.id]);
|
|
6142
6142
|
const [Ie, we] = q(!1), Q = n || r || se || Ue || Ie, be = Vb(t.id, Q), Z = Kb(t.id);
|
|
6143
6143
|
Gb(t.id, be);
|
|
6144
|
-
const [_, ue] = q(null), [je, ie] = q(0), [Oe, Se] = q([]), We = De ?? (P && !k ?
|
|
6144
|
+
const [_, ue] = q(null), [je, ie] = q(0), [Oe, Se] = q([]), We = De ?? (P && !k ? Ut(U) : null), Ae = k != null || We != null || (I == null ? void 0 : I.screenshot) != null, re = n, Ne = a && Ad({
|
|
6145
6145
|
detailActive: re,
|
|
6146
6146
|
previewIntended: se
|
|
6147
|
-
}), Fe = Rt(() => !r || t.route == null || !t.layersImported ? null : Me === U && We != null ? We :
|
|
6147
|
+
}), Fe = Rt(() => !r || t.route == null || !t.layersImported ? null : Me === U && We != null ? We : Ut(Me) ?? We, [
|
|
6148
6148
|
Me,
|
|
6149
6149
|
P,
|
|
6150
6150
|
We,
|
|
@@ -6159,21 +6159,21 @@ const Xb = He(function({
|
|
|
6159
6159
|
importedAtCommittedWidth: t.layerImportViewportWidth == null || t.layerImportViewportWidth === (t.width ?? 390),
|
|
6160
6160
|
reimportScheduled: f.provisionalLayerImportRevision(t.id) != null
|
|
6161
6161
|
})
|
|
6162
|
-
) === "responsive-preview",
|
|
6162
|
+
) === "responsive-preview", Lt = {
|
|
6163
6163
|
width: t.width ?? 390,
|
|
6164
6164
|
height: t.height ?? 600
|
|
6165
|
-
},
|
|
6165
|
+
}, Yt = f.provisionalLayerImportRevision(t.id) != null, mn = fg(
|
|
6166
6166
|
t,
|
|
6167
|
-
|
|
6167
|
+
Lt
|
|
6168
6168
|
);
|
|
6169
6169
|
ce(() => {
|
|
6170
|
-
!
|
|
6170
|
+
!Yt || t.route == null || au(
|
|
6171
6171
|
t,
|
|
6172
6172
|
{ width: t.width ?? 390, height: t.height ?? 600 },
|
|
6173
6173
|
l
|
|
6174
6174
|
);
|
|
6175
6175
|
}, [
|
|
6176
|
-
|
|
6176
|
+
Yt,
|
|
6177
6177
|
t,
|
|
6178
6178
|
t.id,
|
|
6179
6179
|
t.route,
|
|
@@ -6181,7 +6181,7 @@ const Xb = He(function({
|
|
|
6181
6181
|
t.height,
|
|
6182
6182
|
l
|
|
6183
6183
|
]);
|
|
6184
|
-
const
|
|
6184
|
+
const gn = hg(t);
|
|
6185
6185
|
ce(() => {
|
|
6186
6186
|
t.route == null || t.interactiveStateId == null || t.layersImported || uu(t, l);
|
|
6187
6187
|
}, [
|
|
@@ -6229,7 +6229,7 @@ const Xb = He(function({
|
|
|
6229
6229
|
}, [n, t.id, t.importLayers, t.layersImported, t.route]), ce(() => {
|
|
6230
6230
|
var K, ge;
|
|
6231
6231
|
(K = m.current) == null || K.resolve(null), m.current = null, (ge = b.current) == null || ge.resolve(), b.current = null, rt(!1), we(!1), ue(null), ie(0), Se([]), ze(
|
|
6232
|
-
_n(U) ? null :
|
|
6232
|
+
_n(U) ? null : Ut(U)
|
|
6233
6233
|
), H.current += 1, $.current = !1, R.current = null, S.current = null, v.current(), v.current = () => {
|
|
6234
6234
|
}, f.resetPageDocumentHeight(t.id);
|
|
6235
6235
|
}, [U]), ce(
|
|
@@ -6246,7 +6246,7 @@ const Xb = He(function({
|
|
|
6246
6246
|
return;
|
|
6247
6247
|
}
|
|
6248
6248
|
ze(
|
|
6249
|
-
_n(U) ? null :
|
|
6249
|
+
_n(U) ? null : Ut(U)
|
|
6250
6250
|
);
|
|
6251
6251
|
}, [P, a, U]), ce(() => {
|
|
6252
6252
|
var ke, $e;
|
|
@@ -6349,7 +6349,7 @@ const Xb = He(function({
|
|
|
6349
6349
|
[We, k, I == null ? void 0 : I.stale]
|
|
6350
6350
|
), Le = a && !P, lt = ug(
|
|
6351
6351
|
t.importPageId ?? t.id
|
|
6352
|
-
),
|
|
6352
|
+
), bn = pg(t.id), _i = f.frozenPromotionRefused(t.id), xn = (qe || Le || lt || gn) && !_i && !t.layersImported && t.importLayers === !0 && t.route != null && // A replay that reported issues registers stale and cannot promote —
|
|
6353
6353
|
// fall back to the boot path instead of holding the frame on it.
|
|
6354
6354
|
Oe.length === 0;
|
|
6355
6355
|
ce(() => {
|
|
@@ -6367,7 +6367,7 @@ const Xb = He(function({
|
|
|
6367
6367
|
// here regardless was the bypass that let a live boot — against a dead
|
|
6368
6368
|
// backend, a cold dev server — deliver the import a healthy capture
|
|
6369
6369
|
// already covered.
|
|
6370
|
-
|
|
6370
|
+
xn || t.route == null || t.layersImported || !Ae || _)
|
|
6371
6371
|
return;
|
|
6372
6372
|
let K = !0;
|
|
6373
6373
|
const ge = `detail:${oe}`;
|
|
@@ -6393,7 +6393,7 @@ const Xb = He(function({
|
|
|
6393
6393
|
}, [
|
|
6394
6394
|
re,
|
|
6395
6395
|
P,
|
|
6396
|
-
|
|
6396
|
+
xn,
|
|
6397
6397
|
Ae,
|
|
6398
6398
|
t.importLayers,
|
|
6399
6399
|
t.layersImported,
|
|
@@ -6421,7 +6421,7 @@ const Xb = He(function({
|
|
|
6421
6421
|
const Oi = Wa(t, { detailActive: re }) ? ja({
|
|
6422
6422
|
origin: c,
|
|
6423
6423
|
route: t.route ?? "",
|
|
6424
|
-
environment:
|
|
6424
|
+
environment: pn(t, n),
|
|
6425
6425
|
width: z,
|
|
6426
6426
|
height: X
|
|
6427
6427
|
}) : null, Bi = async (K, ge, ye) => {
|
|
@@ -6432,7 +6432,7 @@ const Xb = He(function({
|
|
|
6432
6432
|
try {
|
|
6433
6433
|
$e = await ke.lease({
|
|
6434
6434
|
key: Re,
|
|
6435
|
-
url:
|
|
6435
|
+
url: pr(c, t.route ?? "", J),
|
|
6436
6436
|
width: z,
|
|
6437
6437
|
height: X
|
|
6438
6438
|
});
|
|
@@ -6471,7 +6471,7 @@ const Xb = He(function({
|
|
|
6471
6471
|
S.current === Re && (S.current = null);
|
|
6472
6472
|
});
|
|
6473
6473
|
return S.current = Re, Re;
|
|
6474
|
-
},
|
|
6474
|
+
}, yn = (K) => {
|
|
6475
6475
|
if (v.current(), v.current = () => {
|
|
6476
6476
|
}, t.heightMode !== "document") return !1;
|
|
6477
6477
|
const ge = K.contentDocument;
|
|
@@ -6538,10 +6538,10 @@ const Xb = He(function({
|
|
|
6538
6538
|
}, Ze = () => {
|
|
6539
6539
|
if (window.removeEventListener("mousemove", ae), window.removeEventListener("mouseup", Ze), !$e) return;
|
|
6540
6540
|
const tt = t.x ?? 0, tn = t.y ?? 0, dt = tt + (t.width ?? 390), Zn = tn + X;
|
|
6541
|
-
for (const [
|
|
6542
|
-
const
|
|
6543
|
-
if (
|
|
6544
|
-
f.setPageSection(t.id,
|
|
6541
|
+
for (const [wn, xt] of Lu()) {
|
|
6542
|
+
const Dt = xt.explicit ? 0 : Fu, Pr = xt.x0 - Dt, po = xt.y0 - Dt, mo = xt.x1 + Dt, nn = xt.y1 + Dt;
|
|
6543
|
+
if (wn !== t.section && tt < mo && dt > Pr && tn < nn && Zn > po) {
|
|
6544
|
+
f.setPageSection(t.id, wn);
|
|
6545
6545
|
break;
|
|
6546
6546
|
}
|
|
6547
6547
|
}
|
|
@@ -6553,7 +6553,7 @@ const Xb = He(function({
|
|
|
6553
6553
|
const ye = ge.clientX, Re = ge.clientY, ke = { x: t.x ?? 0, y: t.y ?? 0, width: z, height: X }, $e = K.includes("e") || K.includes("w"), ae = K.includes("n") || K.includes("s");
|
|
6554
6554
|
let Ze = !1;
|
|
6555
6555
|
const tt = (dt) => {
|
|
6556
|
-
const Zn = (dt.clientX - ye) / f.zoom,
|
|
6556
|
+
const Zn = (dt.clientX - ye) / f.zoom, wn = (dt.clientY - Re) / f.zoom, xt = Ru(ke, K, Zn, wn, 1, 1);
|
|
6557
6557
|
if (!(Math.round(xt.x) === Math.round(ke.x) && Math.round(xt.y) === Math.round(ke.y) && Math.round(xt.width) === Math.round(ke.width) && Math.round(xt.height) === Math.round(ke.height))) {
|
|
6558
6558
|
if (!Ze) {
|
|
6559
6559
|
if (!f.beginFrameTransform(t.id, "resize")) return;
|
|
@@ -6571,7 +6571,7 @@ const Xb = He(function({
|
|
|
6571
6571
|
}), T(null);
|
|
6572
6572
|
};
|
|
6573
6573
|
window.addEventListener("mousemove", tt), window.addEventListener("mouseup", tn);
|
|
6574
|
-
}, en = t.frameSizeMode === "content" || re || j && be !== "detached",
|
|
6574
|
+
}, en = t.frameSizeMode === "content" || re || j && be !== "detached", Cr = bd({
|
|
6575
6575
|
hasRoute: t.route != null,
|
|
6576
6576
|
layersImported: !!t.layersImported,
|
|
6577
6577
|
cacheHydrated: P,
|
|
@@ -6579,29 +6579,29 @@ const Xb = He(function({
|
|
|
6579
6579
|
liveGranted: Ue
|
|
6580
6580
|
}), it = f.provisionalLayerImportRevision(
|
|
6581
6581
|
t.id
|
|
6582
|
-
), Ve = !t.layersImported || it != null, Jn = a && (
|
|
6582
|
+
), Ve = !t.layersImported || it != null, Jn = a && (bn || Cr === "live" || Ie || (re && !xn || // Hover intent while the artifact cache is still hydrating — or a
|
|
6583
6583
|
// flow session owes this screen — must not warm-boot the app: the
|
|
6584
6584
|
// capture that makes the boot unnecessary may simply not have
|
|
6585
6585
|
// arrived yet. Intent prepares the frozen mount.
|
|
6586
|
-
se && !qe && !Le && !lt && !
|
|
6586
|
+
se && !qe && !Le && !lt && !gn) && t.route != null && Ve && // A viewport-variant session owes the resized screen its exact-width
|
|
6587
6587
|
// replay; the live re-measure stays parked unless the session fails.
|
|
6588
|
-
!
|
|
6588
|
+
!mn), bt = sb({
|
|
6589
6589
|
// Keep a frame being prepared at its canvas position. Preparing it elsewhere
|
|
6590
6590
|
// would move the iframe to another parent on open, reload it, and waste the
|
|
6591
6591
|
// work. A provisionally imported page shows its tree in the frame instead,
|
|
6592
6592
|
// so its live producer boots offscreen.
|
|
6593
6593
|
active: (re || se) && it == null,
|
|
6594
6594
|
live: Jn
|
|
6595
|
-
}), st = !o && Ae && !
|
|
6595
|
+
}), st = !o && Ae && !bn, Vt = ab({
|
|
6596
6596
|
hasScreenshot: (I == null ? void 0 : I.screenshot) != null,
|
|
6597
6597
|
hasDomSnapshot: k != null || We != null,
|
|
6598
6598
|
magnifiedPastBitmap: Z,
|
|
6599
6599
|
// Hover intent mounts the frozen DOM so the activation click promotes
|
|
6600
6600
|
// through D2 (~50ms) instead of waiting on a live boot; an activation
|
|
6601
6601
|
// that arrived without the hover mounts it here and promotes on mount.
|
|
6602
|
-
preparedForPromotion: se ||
|
|
6602
|
+
preparedForPromotion: se || xn,
|
|
6603
6603
|
preferDom: mh() === "dom"
|
|
6604
|
-
}),
|
|
6604
|
+
}), vn = t.layersImported && f.pageRequiresLiveSharedPreview(t), ji = Ae && f.frozenPreviewMutations().some((K) => !!K.staleReason);
|
|
6605
6605
|
ce(() => {
|
|
6606
6606
|
if (t.frameSizeMode !== "content" || !en)
|
|
6607
6607
|
return;
|
|
@@ -6623,7 +6623,7 @@ const Xb = He(function({
|
|
|
6623
6623
|
t.layersImported,
|
|
6624
6624
|
en
|
|
6625
6625
|
]);
|
|
6626
|
-
const
|
|
6626
|
+
const $r = t.route == null ? "" : pr(
|
|
6627
6627
|
c,
|
|
6628
6628
|
t.route,
|
|
6629
6629
|
J
|
|
@@ -6635,7 +6635,7 @@ const Xb = He(function({
|
|
|
6635
6635
|
const ye = await D();
|
|
6636
6636
|
ql(ye), xe(!0);
|
|
6637
6637
|
const Re = p.current;
|
|
6638
|
-
if ((Re ?
|
|
6638
|
+
if ((Re ? yn(Re) : !1) && await new Promise((ae) => {
|
|
6639
6639
|
requestAnimationFrame(
|
|
6640
6640
|
() => requestAnimationFrame(() => ae())
|
|
6641
6641
|
);
|
|
@@ -6685,7 +6685,7 @@ const Xb = He(function({
|
|
|
6685
6685
|
{
|
|
6686
6686
|
ref: p,
|
|
6687
6687
|
title: `real app${t.route}`,
|
|
6688
|
-
src:
|
|
6688
|
+
src: $r,
|
|
6689
6689
|
loading: "eager",
|
|
6690
6690
|
tabIndex: -1,
|
|
6691
6691
|
className: "block border-0 bg-white",
|
|
@@ -6707,7 +6707,7 @@ const Xb = He(function({
|
|
|
6707
6707
|
"data-canonical-frame-id": t.importPageId ?? t.id,
|
|
6708
6708
|
"data-frame-active": n || void 0,
|
|
6709
6709
|
"data-frame-detail-active": re || void 0,
|
|
6710
|
-
"data-preview-state":
|
|
6710
|
+
"data-preview-state": Cr,
|
|
6711
6711
|
"data-frame-lod": be,
|
|
6712
6712
|
"data-artifact-status": I == null ? void 0 : I.status,
|
|
6713
6713
|
"data-artifact-resolution": Ee.status,
|
|
@@ -6856,7 +6856,7 @@ const Xb = He(function({
|
|
|
6856
6856
|
)
|
|
6857
6857
|
}
|
|
6858
6858
|
)
|
|
6859
|
-
] }) : t.layersImported && en && (re || t.route == null ||
|
|
6859
|
+
] }) : t.layersImported && en && (re || t.route == null || vn) ? re ? Be && Fe != null ? /* @__PURE__ */ s(
|
|
6860
6860
|
ph,
|
|
6861
6861
|
{
|
|
6862
6862
|
page: t,
|
|
@@ -6926,7 +6926,7 @@ const Xb = He(function({
|
|
|
6926
6926
|
snapshot: We ?? void 0,
|
|
6927
6927
|
artifact: k ?? void 0,
|
|
6928
6928
|
height: X,
|
|
6929
|
-
baseUrl:
|
|
6929
|
+
baseUrl: $r,
|
|
6930
6930
|
revision: l,
|
|
6931
6931
|
sourceStale: (I == null ? void 0 : I.stale) === !0,
|
|
6932
6932
|
onDocumentHeightChange: (K) => {
|
|
@@ -7100,7 +7100,7 @@ const Xb = He(function({
|
|
|
7100
7100
|
`preview-producer:${oe}`
|
|
7101
7101
|
)
|
|
7102
7102
|
] });
|
|
7103
|
-
}),
|
|
7103
|
+
}), Sr = /* @__PURE__ */ new Map(), na = /* @__PURE__ */ new Map();
|
|
7104
7104
|
let rl = "[]";
|
|
7105
7105
|
function Di(e) {
|
|
7106
7106
|
var t;
|
|
@@ -7165,17 +7165,17 @@ ${o.join(`
|
|
|
7165
7165
|
`)}`);
|
|
7166
7166
|
const i = JSON.stringify(t);
|
|
7167
7167
|
if (i !== rl) {
|
|
7168
|
-
|
|
7168
|
+
Sr.clear(), na.clear();
|
|
7169
7169
|
for (const a of t)
|
|
7170
|
-
|
|
7170
|
+
Sr.set(a.id, a), na.set(a.componentName, a);
|
|
7171
7171
|
rl = i;
|
|
7172
7172
|
}
|
|
7173
7173
|
}
|
|
7174
7174
|
function Vw() {
|
|
7175
|
-
return [...
|
|
7175
|
+
return [...Sr.values()].map(Di);
|
|
7176
7176
|
}
|
|
7177
7177
|
function Kw(e) {
|
|
7178
|
-
const t =
|
|
7178
|
+
const t = Sr.get(e);
|
|
7179
7179
|
return t ? Di(t) : void 0;
|
|
7180
7180
|
}
|
|
7181
7181
|
function so(e) {
|
|
@@ -7189,7 +7189,7 @@ function Jo(e, t) {
|
|
|
7189
7189
|
function ju() {
|
|
7190
7190
|
var n;
|
|
7191
7191
|
const e = Qe(), t = [];
|
|
7192
|
-
for (const r of
|
|
7192
|
+
for (const r of Sr.values()) {
|
|
7193
7193
|
const o = e[r.componentName];
|
|
7194
7194
|
if (!o) {
|
|
7195
7195
|
t.push({
|
|
@@ -7235,7 +7235,7 @@ function ju() {
|
|
|
7235
7235
|
);
|
|
7236
7236
|
}
|
|
7237
7237
|
function Zb(e, t = {}) {
|
|
7238
|
-
const n =
|
|
7238
|
+
const n = Sr.get(e);
|
|
7239
7239
|
if (!n)
|
|
7240
7240
|
throw new Error(`Unknown component connection "${e}".`);
|
|
7241
7241
|
const r = t.limit ?? 64;
|
|
@@ -7455,7 +7455,7 @@ function bi(e) {
|
|
|
7455
7455
|
function al(e) {
|
|
7456
7456
|
return JSON.stringify(e);
|
|
7457
7457
|
}
|
|
7458
|
-
let
|
|
7458
|
+
let In = null, Fo = /* @__PURE__ */ new Map(), ls = /* @__PURE__ */ new Map(), Kn = /* @__PURE__ */ new Map(), jn = null, Br = null, ux = 0;
|
|
7459
7459
|
function tc() {
|
|
7460
7460
|
kt.setPending(Kn.size);
|
|
7461
7461
|
}
|
|
@@ -7474,7 +7474,7 @@ function cl(e) {
|
|
|
7474
7474
|
Kn = t, tc();
|
|
7475
7475
|
}
|
|
7476
7476
|
async function Hu() {
|
|
7477
|
-
return
|
|
7477
|
+
return Br || (Br = (async () => {
|
|
7478
7478
|
for (; Kn.size > 0; ) {
|
|
7479
7479
|
const e = [...Kn.values()];
|
|
7480
7480
|
Kn = /* @__PURE__ */ new Map(), tc();
|
|
@@ -7496,13 +7496,13 @@ async function Hu() {
|
|
|
7496
7496
|
}
|
|
7497
7497
|
}
|
|
7498
7498
|
})().finally(() => {
|
|
7499
|
-
|
|
7500
|
-
}),
|
|
7499
|
+
Br = null;
|
|
7500
|
+
}), Br);
|
|
7501
7501
|
}
|
|
7502
7502
|
function fx(e) {
|
|
7503
|
-
|
|
7503
|
+
In == null || In();
|
|
7504
7504
|
const t = sl(e);
|
|
7505
|
-
return Fo = new Map(t.map((n) => [bi(n), n])),
|
|
7505
|
+
return Fo = new Map(t.map((n) => [bi(n), n])), In = Yl(
|
|
7506
7506
|
() => sl(e),
|
|
7507
7507
|
(n) => {
|
|
7508
7508
|
const r = new Map(n.map((i) => [bi(i), i])), o = [];
|
|
@@ -7516,7 +7516,7 @@ function fx(e) {
|
|
|
7516
7516
|
},
|
|
7517
7517
|
{ equals: wh.structural }
|
|
7518
7518
|
), () => {
|
|
7519
|
-
|
|
7519
|
+
In == null || In(), In = null;
|
|
7520
7520
|
};
|
|
7521
7521
|
}
|
|
7522
7522
|
function Vu(e) {
|
|
@@ -7787,13 +7787,13 @@ function Rx(e, t, n) {
|
|
|
7787
7787
|
const r = new Set(Object.keys(t ?? {}).map((c) => c.toLowerCase())), o = [], i = e.getAttribute("role") ?? "";
|
|
7788
7788
|
return (e.hasAttribute("aria-selected") || e.hasAttribute("aria-pressed") || e.hasAttribute("aria-checked") || ["option", "radio", "tab", "treeitem"].includes(i) || ["selected", "checked", "active", "pressed", "open", "expanded"].some((c) => r.has(c))) && o.push("selected"), ("disabled" in e || e.hasAttribute("aria-disabled") || ["disabled", "isdisabled"].some((c) => r.has(c))) && o.push("disabled"), (e.hasAttribute("aria-busy") || ["loading", "isloading", "pending", "busy"].some((c) => r.has(c))) && o.push("loading"), o;
|
|
7789
7789
|
}
|
|
7790
|
-
function
|
|
7790
|
+
function jr(e, t, n, r) {
|
|
7791
7791
|
const o = e.hasAttribute(t), i = e.getAttribute(t);
|
|
7792
7792
|
r.push(() => {
|
|
7793
7793
|
o ? e.setAttribute(t, i ?? "") : e.removeAttribute(t);
|
|
7794
7794
|
}), n == null ? e.removeAttribute(t) : e.setAttribute(t, n);
|
|
7795
7795
|
}
|
|
7796
|
-
function
|
|
7796
|
+
function Wr(e, t, n, r) {
|
|
7797
7797
|
const o = e.style.getPropertyValue(t);
|
|
7798
7798
|
r.push(() => {
|
|
7799
7799
|
o ? e.style.setProperty(t, o) : e.style.removeProperty(t);
|
|
@@ -7827,7 +7827,7 @@ function Tx(e, t) {
|
|
|
7827
7827
|
l.nodeValue = u;
|
|
7828
7828
|
}), l.nodeValue = kx(t.text, u, d);
|
|
7829
7829
|
}), t.state !== "default" && i.forEach((l) => {
|
|
7830
|
-
t.state === "selected" ? (
|
|
7830
|
+
t.state === "selected" ? (jr(l, "aria-selected", "true", n), jr(l, "data-state", "active", n), Wr(l, "outline", "2px solid #0d99ff", n), Wr(l, "outline-offset", "-2px", n)) : t.state === "disabled" ? ("disabled" in l && jr(l, "disabled", "", n), jr(l, "aria-disabled", "true", n), Wr(l, "opacity", "0.45", n), Wr(l, "pointer-events", "none", n)) : t.state === "loading" && (jr(l, "aria-busy", "true", n), Wr(l, "opacity", "0.62", n), fl([l]).slice(0, 1).forEach((d) => {
|
|
7831
7831
|
const u = d.nodeValue ?? "";
|
|
7832
7832
|
n.push(() => {
|
|
7833
7833
|
d.nodeValue = u;
|
|
@@ -8034,12 +8034,12 @@ function pl({
|
|
|
8034
8034
|
var h;
|
|
8035
8035
|
(h = _.current) == null || h.cleanup(), _.current = null;
|
|
8036
8036
|
}
|
|
8037
|
-
const Ne = !!e, Fe = Ne ? ((gc = e.current) == null ? void 0 : gc.contentDocument) ?? null : ((bc = t == null ? void 0 : t.current) == null ? void 0 : bc.ownerDocument) ?? null, Be = (Fe == null ? void 0 : Fe.defaultView) ?? null,
|
|
8037
|
+
const Ne = !!e, Fe = Ne ? ((gc = e.current) == null ? void 0 : gc.contentDocument) ?? null : ((bc = t == null ? void 0 : t.current) == null ? void 0 : bc.ownerDocument) ?? null, Be = (Fe == null ? void 0 : Fe.defaultView) ?? null, Lt = Rt(() => fa(Qe()), []), Yt = Rt(
|
|
8038
8038
|
() => Object.entries(Qe()).filter(
|
|
8039
8039
|
([h, y]) => /^[A-Z][A-Za-z0-9_$]*$/.test(h) && !!y.importPath && Sc(h) != null
|
|
8040
8040
|
).sort(([h], [y]) => h.localeCompare(y)),
|
|
8041
8041
|
[]
|
|
8042
|
-
),
|
|
8042
|
+
), mn = Rt(() => {
|
|
8043
8043
|
const h = xi(), y = {};
|
|
8044
8044
|
for (const [C, O] of Object.entries(vx))
|
|
8045
8045
|
y[C] = h.filter((L) => O.test(L.name));
|
|
@@ -8147,7 +8147,7 @@ function pl({
|
|
|
8147
8147
|
return () => window.clearTimeout(h);
|
|
8148
8148
|
}, [G.toastSeq]), !Fe || !Be)
|
|
8149
8149
|
return /* @__PURE__ */ s("div", { ref: r, className: "absolute inset-0 flex items-start justify-center pt-10", children: Ne && /* @__PURE__ */ s("span", { className: "rounded bg-black/70 px-3 py-1.5 text-[12px] text-white", children: "Cross-origin applications cannot be inspected." }) });
|
|
8150
|
-
const
|
|
8150
|
+
const gn = Ne ? Fe.body : (t == null ? void 0 : t.current) ?? null, qe = (h) => {
|
|
8151
8151
|
if (Ne) {
|
|
8152
8152
|
const C = e.current;
|
|
8153
8153
|
if (!C) return null;
|
|
@@ -8167,13 +8167,13 @@ function pl({
|
|
|
8167
8167
|
const y = (C = r.current) == null ? void 0 : C.getBoundingClientRect();
|
|
8168
8168
|
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 };
|
|
8169
8169
|
}, lt = (h) => {
|
|
8170
|
-
const y =
|
|
8170
|
+
const y = Lt(h);
|
|
8171
8171
|
if (y) return y.name;
|
|
8172
8172
|
const C = qu(h), O = h.tagName.toLowerCase();
|
|
8173
8173
|
return C ? `${O}.${C}` : O;
|
|
8174
|
-
},
|
|
8174
|
+
}, bn = (h) => {
|
|
8175
8175
|
const y = [];
|
|
8176
|
-
for (let C = h; C && C !==
|
|
8176
|
+
for (let C = h; C && C !== gn && y.length < 8; C = C.parentElement)
|
|
8177
8177
|
y.unshift(C);
|
|
8178
8178
|
return y;
|
|
8179
8179
|
}, _i = (h) => {
|
|
@@ -8186,7 +8186,7 @@ function pl({
|
|
|
8186
8186
|
y.selectNodeContents(h);
|
|
8187
8187
|
const C = Be.getSelection();
|
|
8188
8188
|
C == null || C.removeAllRanges(), C == null || C.addRange(y);
|
|
8189
|
-
},
|
|
8189
|
+
}, xn = (h, y) => {
|
|
8190
8190
|
var C;
|
|
8191
8191
|
gt && (G.recordStyle(
|
|
8192
8192
|
gt,
|
|
@@ -8237,14 +8237,14 @@ function pl({
|
|
|
8237
8237
|
} catch (L) {
|
|
8238
8238
|
G.toast(`Apply failed:${String(L).slice(0, 80)}`);
|
|
8239
8239
|
}
|
|
8240
|
-
}, D = a != null && a.isConnected ? a : null,
|
|
8240
|
+
}, D = a != null && a.isConnected ? a : null, yn = o != null && o.isConnected ? o : null, fe = D != null && D.parentElement && D.parentElement !== gn ? D.parentElement : null, gt = N === "container" && fe ? fe : D, ee = D ? Le(D.getBoundingClientRect()) : null, Y = fe ? Le(fe.getBoundingClientRect()) : null, en = N === "container" && gt && gt !== D ? Le(gt.getBoundingClientRect()) : null, Cr = yn && yn !== D ? Le(yn.getBoundingClientRect()) : null, it = D ? Be.getComputedStyle(D) : null, Ve = fe ? Be.getComputedStyle(fe) : null, Jn = gt ? Be.getComputedStyle(gt) : null, bt = D ? lt(D) : "", st = D ? Lt(D) : null, Vt = D ? Nh(D) : null, vn = D ? G.structuralEditKind(D) : null, ji = D ? G.hasPendingValueEdit(D) : !1, $r = D ? G.structuralBlockReason(D, "insert") : "No elements are selected.", ho = D ? G.structuralBlockReason(D, "remove") : "No elements are selected.", Mn = D ? G.structuralBlockReason(D, "move") : "No elements are selected.", Qn = D && D.parentElement ? Array.from(D.parentElement.children).indexOf(D) : -1, K = ((xc = D == null ? void 0 : D.parentElement) == null ? void 0 : xc.children.length) ?? 0, ge = st ? Qe()[st.name] ?? null : null, ye = Vt && /^[A-Z]/.test(Vt.elementName) ? (st == null ? void 0 : st.name) ?? null : null, Re = D ? G.componentInsertBlockReason(D, ye) : "No elements are selected.", ke = xe.trim().toLocaleLowerCase(), $e = Yt.filter(
|
|
8241
8241
|
([h, y]) => !ke || h.toLocaleLowerCase().includes(ke) || y.importPath.toLocaleLowerCase().includes(ke)
|
|
8242
|
-
), ae = $e.find(([h]) => h === Pe) ?? $e[0] ?? null, Ze = (ae == null ? void 0 : ae[1]) ?? null, tt = ae ? Sc(ae[0]) : null, dt = (D ? Nc(D) : null) ?? 0, Zn = D ? Ax(D, (st == null ? void 0 : st.props) ?? null, ge) : !1,
|
|
8242
|
+
), ae = $e.find(([h]) => h === Pe) ?? $e[0] ?? null, Ze = (ae == null ? void 0 : ae[1]) ?? null, tt = ae ? Sc(ae[0]) : null, dt = (D ? Nc(D) : null) ?? 0, Zn = D ? Ax(D, (st == null ? void 0 : st.props) ?? null, ge) : !1, wn = D ? Rx(D, (st == null ? void 0 : st.props) ?? null, ge) : [], xt = D ? Yu(D) : [], Dt = { count: xt.length }, Pr = Me && D && yn && yn !== D ? [D, yn] : null, po = G.entries, mo = Object.entries((st == null ? void 0 : st.primitiveProps) ?? {}), nn = Oe, rn = po.reduce((h, y) => {
|
|
8243
8243
|
const C = h.find((O) => O.el === y.el);
|
|
8244
8244
|
return C ? (C.label = y.label, C.items.push(y)) : h.push({ id: y.id, el: y.el, label: y.label, items: [y] }), h;
|
|
8245
8245
|
}, []), go = nn.styles.length + nn.texts.length + nn.operations.length, bo = Wo() != null, Wi = bo && k !== Se, gf = rn.filter(
|
|
8246
8246
|
(h) => h.items.some((y) => !Qi(y))
|
|
8247
|
-
).length, Hi = v != null || $ !== "original" || H !== "default",
|
|
8247
|
+
).length, Hi = v != null || $ !== "original" || H !== "default", Mr = Hi && D ? zx(D, Be) : null, Ye = Lx(Ve), er = Ye != null, Nt = Dx(fe), on = j === "custom" ? z.minWidth != null || z.maxWidth != null ? {
|
|
8248
8248
|
...z.minWidth != null ? { minWidth: Math.max(0, Math.round(z.minWidth)) } : {},
|
|
8249
8249
|
...z.maxWidth != null ? { maxWidth: Math.max(0, Math.round(z.maxWidth)) } : {}
|
|
8250
8250
|
} : null : ((yc = dl.find((h) => h.id === j)) == null ? void 0 : yc.media) ?? null, Vi = xt.filter((h) => h.isConnected && Be.getComputedStyle(h).getPropertyValue("display") !== "none").map((h, y) => ({ el: h, index: y, rect: Le(h.getBoundingClientRect()) })).filter(({ rect: h }) => h.width > 0 && h.height > 0), Ki = Vi.slice().sort((h, y) => h.rect.top - y.rect.top || h.rect.left - y.rect.left).reduce((h, y) => {
|
|
@@ -8270,18 +8270,18 @@ function pl({
|
|
|
8270
8270
|
width: Math.max(16, Math.min(h.right, C.right) - Math.max(h.left, C.left)),
|
|
8271
8271
|
height: Math.max(0, C.top - h.bottom)
|
|
8272
8272
|
};
|
|
8273
|
-
}), sn = Math.max(0, Et(Ve, "column-gap", Et(Ve, "gap"))),
|
|
8273
|
+
}), sn = Math.max(0, Et(Ve, "column-gap", Et(Ve, "gap"))), Er = Math.max(0, Et(Ve, "row-gap", Et(Ve, "gap"))), It = {
|
|
8274
8274
|
top: Math.max(0, Et(Ve, "padding-top")),
|
|
8275
8275
|
right: Math.max(0, Et(Ve, "padding-right")),
|
|
8276
8276
|
bottom: Math.max(0, Et(Ve, "padding-bottom")),
|
|
8277
8277
|
left: Math.max(0, Et(Ve, "padding-left"))
|
|
8278
|
-
}, yf = It.left, vf = It.top,
|
|
8278
|
+
}, yf = It.left, vf = It.top, kr = (Ve == null ? void 0 : Ve.getPropertyValue("justify-content")) || "normal", ic = (Ve == null ? void 0 : Ve.getPropertyValue("align-items")) || "normal", Ui = (Ve == null ? void 0 : Ve.getPropertyValue("flex-direction")) || "row", wf = hl(Ui.includes("column") ? ic : kr), Sf = hl(Ui.includes("column") ? kr : ic), Nf = Lo(
|
|
8279
8279
|
(fe == null ? void 0 : fe.style.getPropertyValue("width")) || (Y && Y.width >= window.innerWidth * 0.8 ? "100%" : ""),
|
|
8280
8280
|
(Y == null ? void 0 : Y.width) ?? 0
|
|
8281
8281
|
), If = Lo(
|
|
8282
8282
|
(fe == null ? void 0 : fe.style.getPropertyValue("height")) || "",
|
|
8283
8283
|
(Y == null ? void 0 : Y.height) ?? 0
|
|
8284
|
-
), Cf = Lo((D == null ? void 0 : D.style.getPropertyValue("width")) || "", (ee == null ? void 0 : ee.width) ?? 0), $f = Lo((D == null ? void 0 : D.style.getPropertyValue("height")) || "", (ee == null ? void 0 : ee.height) ?? 0), sc = (it == null ? void 0 : it.getPropertyValue("align-self")) || "auto", Pf = Et(it, "order"),
|
|
8284
|
+
), Cf = Lo((D == null ? void 0 : D.style.getPropertyValue("width")) || "", (ee == null ? void 0 : ee.width) ?? 0), $f = Lo((D == null ? void 0 : D.style.getPropertyValue("height")) || "", (ee == null ? void 0 : ee.height) ?? 0), sc = (it == null ? void 0 : it.getPropertyValue("align-self")) || "auto", Pf = Et(it, "order"), Ar = (D == null ? void 0 : D.style.getPropertyValue("grid-column")) || (it == null ? void 0 : it.getPropertyValue("grid-column")) || "auto", ac = Number(((vc = /span\s+(\d+)/.exec(Ar)) == null ? void 0 : vc[1]) ?? 1), qi = (it == null ? void 0 : it.getPropertyValue("position")) === "absolute", tr = us(fe, (ee == null ? void 0 : ee.width) ?? 240), yt = v ?? Math.max(1, Dt.count), xo = Math.max(
|
|
8285
8285
|
0,
|
|
8286
8286
|
((Y == null ? void 0 : Y.width) ?? 0) - It.left - It.right
|
|
8287
8287
|
), Mf = Math.max(
|
|
@@ -8307,12 +8307,12 @@ function pl({
|
|
|
8307
8307
|
h.preventDefault(), h.stopPropagation();
|
|
8308
8308
|
const L = h.clientX, de = h.clientY, he = document.body.style.cursor, _e = document.body.style.userSelect;
|
|
8309
8309
|
document.body.style.cursor = y, document.body.style.userSelect = "none";
|
|
8310
|
-
const ut = (
|
|
8311
|
-
C(
|
|
8312
|
-
},
|
|
8313
|
-
window.removeEventListener("pointermove", ut), window.removeEventListener("pointerup",
|
|
8310
|
+
const ut = (Nn) => {
|
|
8311
|
+
C(Nn.clientX - L, Nn.clientY - de), be();
|
|
8312
|
+
}, Sn = () => {
|
|
8313
|
+
window.removeEventListener("pointermove", ut), window.removeEventListener("pointerup", Sn), document.body.style.cursor = he, document.body.style.userSelect = _e, O(), be();
|
|
8314
8314
|
};
|
|
8315
|
-
window.addEventListener("pointermove", ut), window.addEventListener("pointerup",
|
|
8315
|
+
window.addEventListener("pointermove", ut), window.addEventListener("pointerup", Sn, { once: !0 });
|
|
8316
8316
|
}, Ge = (h, y) => {
|
|
8317
8317
|
fe && G.recordStyle(
|
|
8318
8318
|
fe,
|
|
@@ -8342,7 +8342,7 @@ function pl({
|
|
|
8342
8342
|
nt(C, O);
|
|
8343
8343
|
T("container"), G.toast(`${y.label}change to batch`);
|
|
8344
8344
|
}
|
|
8345
|
-
},
|
|
8345
|
+
}, Rr = (h) => {
|
|
8346
8346
|
!fe || !D || (Ge("display", "grid"), Ge("grid-template-columns", `repeat(${h}, minmax(0, 1fr))`), nt("width", "auto"), nt("min-width", "0"), G.toast(`Maximum ${h} per row · ${Rn(on)}`));
|
|
8347
8347
|
}, So = (h) => {
|
|
8348
8348
|
if (!fe || !D) return;
|
|
@@ -8358,7 +8358,7 @@ function pl({
|
|
|
8358
8358
|
Ge("display", "grid"), Ge("grid-template-columns", `repeat(auto-fit, minmax(min(${y}px, 100%), 1fr))`), nt("width", "auto"), nt("min-width", "0"), G.toast(`Automatic columns · minimum ${y}px · ${Rn(on)}`);
|
|
8359
8359
|
}, Xi = (h, y) => {
|
|
8360
8360
|
if (!fe) return;
|
|
8361
|
-
const C = fe.style.getPropertyValue(h), O = h === "column-gap" ? sn : h === "row-gap" ?
|
|
8361
|
+
const C = fe.style.getPropertyValue(h), O = h === "column-gap" ? sn : h === "row-gap" ? Er : It[h.replace("padding-", "")];
|
|
8362
8362
|
let L = O;
|
|
8363
8363
|
const de = h === "column-gap" || h === "padding-left" || h === "padding-right", he = h === "padding-right" || h === "padding-bottom" ? -1 : 1;
|
|
8364
8364
|
W(h), h.startsWith("padding-") && U(!1), wo(
|
|
@@ -8435,7 +8435,7 @@ function pl({
|
|
|
8435
8435
|
T(h), p("edit");
|
|
8436
8436
|
}, hc = (h) => {
|
|
8437
8437
|
var O;
|
|
8438
|
-
const y = (
|
|
8438
|
+
const y = (Mr == null ? void 0 : Mr.el) ?? D;
|
|
8439
8439
|
if (!y) return;
|
|
8440
8440
|
const C = h === "wrap" ? {
|
|
8441
8441
|
"white-space": "normal",
|
|
@@ -8459,14 +8459,14 @@ function pl({
|
|
|
8459
8459
|
ie.current
|
|
8460
8460
|
), (O = _.current) == null || O.mirrorStyle(y, L, de);
|
|
8461
8461
|
G.toast(h === "wrap" ? "Change to multi-line content" : "Change to one line abbreviation");
|
|
8462
|
-
},
|
|
8462
|
+
}, Tr = m ? Nx : Sx, Df = u === "cases" && Y && Y.left + Y.width > window.innerWidth - Tr - 32 || ee && ee.left + ee.width / 2 > window.innerWidth / 2 ? 16 : Math.max(16, window.innerWidth - Tr - 16), zf = Ne ? 54 : 64, pc = Math.max(8, Math.min((x == null ? void 0 : x.x) ?? Df, window.innerWidth - Tr - 8)), mc = Math.max(8, Math.min((x == null ? void 0 : x.y) ?? zf, window.innerHeight - 80)), _f = (h) => {
|
|
8463
8463
|
if (h.button !== 0) return;
|
|
8464
8464
|
h.preventDefault();
|
|
8465
8465
|
const y = { x: h.clientX, y: h.clientY, left: pc, top: mc };
|
|
8466
8466
|
let C = { x: y.left, y: y.top };
|
|
8467
8467
|
const O = (de) => {
|
|
8468
8468
|
C = {
|
|
8469
|
-
x: Math.max(8, Math.min(y.left + de.clientX - y.x, window.innerWidth -
|
|
8469
|
+
x: Math.max(8, Math.min(y.left + de.clientX - y.x, window.innerWidth - Tr - 8)),
|
|
8470
8470
|
y: Math.max(8, Math.min(y.top + de.clientY - y.y, window.innerHeight - 80))
|
|
8471
8471
|
}, w(C);
|
|
8472
8472
|
}, L = () => {
|
|
@@ -8483,15 +8483,15 @@ function pl({
|
|
|
8483
8483
|
outlineOffset: -1,
|
|
8484
8484
|
pointerEvents: "none"
|
|
8485
8485
|
}), nr = { lines: [], labels: [] };
|
|
8486
|
-
if (
|
|
8487
|
-
const h = Le(
|
|
8486
|
+
if (Pr) {
|
|
8487
|
+
const h = Le(Pr[0].getBoundingClientRect()), y = Le(Pr[1].getBoundingClientRect()), C = h.left + h.width, O = h.top + h.height, L = y.left + y.width, de = y.top + y.height, he = C <= y.left ? { from: C, to: y.left } : L <= h.left ? { from: L, to: h.left } : null, _e = O <= y.top ? { from: O, to: y.top } : de <= h.top ? { from: de, to: h.top } : null;
|
|
8488
8488
|
if (he && he.to - he.from > 0.5) {
|
|
8489
|
-
const ut = he.to - he.from,
|
|
8490
|
-
nr.lines.push({ left: he.from, top:
|
|
8489
|
+
const ut = he.to - he.from, Sn = Math.max(h.top, y.top), Nn = Math.min(O, de), Fr = Nn > Sn ? (Sn + Nn) / 2 : (h.top + O + y.top + de) / 4;
|
|
8490
|
+
nr.lines.push({ left: he.from, top: Fr - 0.5, width: ut, height: 1 }), nr.labels.push({ x: he.from + ut / 2, y: Fr, text: `${Math.round(ut)}px` });
|
|
8491
8491
|
}
|
|
8492
8492
|
if (_e && _e.to - _e.from > 0.5) {
|
|
8493
|
-
const ut = _e.to - _e.from,
|
|
8494
|
-
nr.lines.push({ left:
|
|
8493
|
+
const ut = _e.to - _e.from, Sn = Math.max(h.left, y.left), Nn = Math.min(C, L), Fr = Nn > Sn ? (Sn + Nn) / 2 : (h.left + C + y.left + L) / 4;
|
|
8494
|
+
nr.lines.push({ left: Fr - 0.5, top: _e.from, width: 1, height: ut }), nr.labels.push({ x: Fr, y: _e.from + ut / 2, text: `${Math.round(ut)}px` });
|
|
8495
8495
|
}
|
|
8496
8496
|
}
|
|
8497
8497
|
const $o = 7, Of = ee ? [
|
|
@@ -8523,7 +8523,7 @@ function pl({
|
|
|
8523
8523
|
}
|
|
8524
8524
|
}
|
|
8525
8525
|
),
|
|
8526
|
-
|
|
8526
|
+
Cr && !l && /* @__PURE__ */ s("div", { style: Co(Cr, "#7cc4f8", !0) }),
|
|
8527
8527
|
en && gt && /* @__PURE__ */ g(Ke, { children: [
|
|
8528
8528
|
/* @__PURE__ */ s("div", { style: Co(en, "#9747ff", !0) }),
|
|
8529
8529
|
/* @__PURE__ */ g(
|
|
@@ -8612,7 +8612,7 @@ function pl({
|
|
|
8612
8612
|
},
|
|
8613
8613
|
className: `flex h-[22px] w-[22px] items-center justify-center rounded-full border text-[12px] font-bold shadow-sm ${Nt === y + 1 ? "border-[#9747ff] bg-[#9747ff] text-white" : "border-[#c4b5fd] bg-white text-[#7c3aed] hover:bg-[#f5f3ff]"}`,
|
|
8614
8614
|
onClick: (C) => {
|
|
8615
|
-
C.stopPropagation(),
|
|
8615
|
+
C.stopPropagation(), Rr(y + 1);
|
|
8616
8616
|
},
|
|
8617
8617
|
children: "↵"
|
|
8618
8618
|
},
|
|
@@ -8678,8 +8678,8 @@ function pl({
|
|
|
8678
8678
|
{
|
|
8679
8679
|
type: "button",
|
|
8680
8680
|
"data-case-row-gap-handle": y,
|
|
8681
|
-
"aria-label": `row spacing${Math.round(
|
|
8682
|
-
title: `row spacing${Math.round(
|
|
8681
|
+
"aria-label": `row spacing${Math.round(Er)}px`,
|
|
8682
|
+
title: `row spacing${Math.round(Er)}px`,
|
|
8683
8683
|
style: {
|
|
8684
8684
|
position: "absolute",
|
|
8685
8685
|
left: h.left + h.width / 2,
|
|
@@ -8692,7 +8692,7 @@ function pl({
|
|
|
8692
8692
|
onPointerEnter: () => W("row-gap"),
|
|
8693
8693
|
onPointerLeave: () => W(null),
|
|
8694
8694
|
onPointerDown: (C) => Xi("row-gap", C),
|
|
8695
|
-
children: Math.round(
|
|
8695
|
+
children: Math.round(Er)
|
|
8696
8696
|
}
|
|
8697
8697
|
)
|
|
8698
8698
|
] }, `row-gap-${h.key}`)),
|
|
@@ -8899,7 +8899,7 @@ function pl({
|
|
|
8899
8899
|
{
|
|
8900
8900
|
"data-inspector-panel": !0,
|
|
8901
8901
|
className: "fixed z-20 flex max-h-[min(720px,calc(100vh-72px))] flex-col overflow-hidden rounded-xl border border-[#e4e4e7] bg-white text-[#18181b] shadow-[0_16px_48px_rgba(15,23,42,.22)]",
|
|
8902
|
-
style: { left: pc, top: mc, width:
|
|
8902
|
+
style: { left: pc, top: mc, width: Tr },
|
|
8903
8903
|
children: [
|
|
8904
8904
|
/* @__PURE__ */ g("div", { className: "border-b border-[#e4e4e7] px-4 py-3", children: [
|
|
8905
8905
|
/* @__PURE__ */ g("div", { className: "mb-2 flex cursor-move select-none items-start justify-between gap-3", onMouseDown: _f, children: [
|
|
@@ -8909,7 +8909,7 @@ function pl({
|
|
|
8909
8909
|
/* @__PURE__ */ s("span", { className: `h-2 w-2 rounded-full ${Hi ? "bg-[#0d99ff]" : "bg-[#d4d4d8]"}` })
|
|
8910
8910
|
] }),
|
|
8911
8911
|
/* @__PURE__ */ s("h2", { className: "truncate text-[14px] font-semibold", children: D ? bt : "Select a DOM element" }),
|
|
8912
|
-
/* @__PURE__ */ s("p", { className: "mt-0.5 truncate text-[10px] text-[#71717a]", children: D ? `${
|
|
8912
|
+
/* @__PURE__ */ s("p", { className: "mt-0.5 truncate text-[10px] text-[#71717a]", children: D ? `${Dt.count || 1} matching elements · Test realistic content states` : "Click an element on the canvas to inspect it" })
|
|
8913
8913
|
] }),
|
|
8914
8914
|
/* @__PURE__ */ g("div", { className: "flex shrink-0 items-center gap-1", onMouseDown: (h) => h.stopPropagation(), children: [
|
|
8915
8915
|
/* @__PURE__ */ s(
|
|
@@ -8972,7 +8972,7 @@ function pl({
|
|
|
8972
8972
|
}
|
|
8973
8973
|
)
|
|
8974
8974
|
] }) : u === "cases" ? /* @__PURE__ */ g("div", { className: "min-h-0 flex-1 overflow-auto", children: [
|
|
8975
|
-
/* @__PURE__ */ s(Xe, { title: "Selection path", children: /* @__PURE__ */ s("div", { className: "flex flex-wrap items-center gap-1 text-[10px] text-[#71717a]", children:
|
|
8975
|
+
/* @__PURE__ */ s(Xe, { title: "Selection path", children: /* @__PURE__ */ s("div", { className: "flex flex-wrap items-center gap-1 text-[10px] text-[#71717a]", children: bn(D).map((h, y, C) => /* @__PURE__ */ g("span", { className: "flex items-center gap-1", children: [
|
|
8976
8976
|
y > 0 && /* @__PURE__ */ s("span", { className: "text-[#c4c4c8]", children: "›" }),
|
|
8977
8977
|
/* @__PURE__ */ s(
|
|
8978
8978
|
"button",
|
|
@@ -9013,7 +9013,7 @@ function pl({
|
|
|
9013
9013
|
title: "Item count",
|
|
9014
9014
|
action: /* @__PURE__ */ g("span", { className: "text-[10px] text-[#71717a]", children: [
|
|
9015
9015
|
"Current: ",
|
|
9016
|
-
|
|
9016
|
+
Dt.count || 1
|
|
9017
9017
|
] }),
|
|
9018
9018
|
children: [
|
|
9019
9019
|
/* @__PURE__ */ g("div", { className: "grid grid-cols-[32px_minmax(0,1fr)_32px] gap-1", children: [
|
|
@@ -9023,8 +9023,8 @@ function pl({
|
|
|
9023
9023
|
type: "button",
|
|
9024
9024
|
"aria-label": "Decrease item count",
|
|
9025
9025
|
className: "h-8 rounded-md bg-[#f4f4f5] text-[16px] text-[#52525b] hover:bg-[#e9e9ee] disabled:text-[#c4c4c8]",
|
|
9026
|
-
disabled: (v ?? (
|
|
9027
|
-
onClick: () => vo((v ?? (
|
|
9026
|
+
disabled: (v ?? (Dt.count || 1)) <= 1,
|
|
9027
|
+
onClick: () => vo((v ?? (Dt.count || 1)) - 1),
|
|
9028
9028
|
children: "−"
|
|
9029
9029
|
}
|
|
9030
9030
|
),
|
|
@@ -9038,7 +9038,7 @@ function pl({
|
|
|
9038
9038
|
inputMode: "numeric",
|
|
9039
9039
|
"aria-label": "Enter item count",
|
|
9040
9040
|
value: v ?? "",
|
|
9041
|
-
placeholder: String(
|
|
9041
|
+
placeholder: String(Dt.count || 1),
|
|
9042
9042
|
className: "h-8 w-full rounded-md bg-[#f4f4f5] px-2 pr-8 text-center text-[12px] font-semibold tabular-nums text-[#18181b] outline-none focus:ring-1 focus:ring-inset focus:ring-[#0d99ff]",
|
|
9043
9043
|
onChange: (h) => vo(h.currentTarget.value === "" ? null : Number(h.currentTarget.value))
|
|
9044
9044
|
}
|
|
@@ -9051,7 +9051,7 @@ function pl({
|
|
|
9051
9051
|
type: "button",
|
|
9052
9052
|
"aria-label": "Increase item count",
|
|
9053
9053
|
className: "h-8 rounded-md bg-[#f4f4f5] text-[16px] text-[#52525b] hover:bg-[#e9e9ee]",
|
|
9054
|
-
onClick: () => vo((v ?? (
|
|
9054
|
+
onClick: () => vo((v ?? (Dt.count || 1)) + 1),
|
|
9055
9055
|
children: "+"
|
|
9056
9056
|
}
|
|
9057
9057
|
)
|
|
@@ -9102,7 +9102,7 @@ function pl({
|
|
|
9102
9102
|
Xe,
|
|
9103
9103
|
{
|
|
9104
9104
|
title: "Content behavior",
|
|
9105
|
-
action: /* @__PURE__ */ s("span", { className: "max-w-32 truncate text-[10px] text-[#71717a]", children:
|
|
9105
|
+
action: /* @__PURE__ */ s("span", { className: "max-w-32 truncate text-[10px] text-[#71717a]", children: Mr ? oa(Mr.el) : bt }),
|
|
9106
9106
|
children: /* @__PURE__ */ g("div", { className: "grid grid-cols-2 gap-1", children: [
|
|
9107
9107
|
/* @__PURE__ */ g(
|
|
9108
9108
|
"button",
|
|
@@ -9131,12 +9131,12 @@ function pl({
|
|
|
9131
9131
|
] })
|
|
9132
9132
|
}
|
|
9133
9133
|
),
|
|
9134
|
-
|
|
9134
|
+
wn.length > 0 && /* @__PURE__ */ s(Xe, { title: "State preview", children: /* @__PURE__ */ s("div", { className: `grid gap-1 ${wn.length >= 3 ? "grid-cols-4" : "grid-cols-3"}`, children: [
|
|
9135
9135
|
["default", "Default"],
|
|
9136
9136
|
["selected", "Selected"],
|
|
9137
9137
|
["disabled", "Disabled"],
|
|
9138
9138
|
["loading", "Loading"]
|
|
9139
|
-
].filter(([h]) => h === "default" ||
|
|
9139
|
+
].filter(([h]) => h === "default" || wn.includes(h)).map(([h, y]) => /* @__PURE__ */ s(
|
|
9140
9140
|
"button",
|
|
9141
9141
|
{
|
|
9142
9142
|
type: "button",
|
|
@@ -9229,7 +9229,7 @@ function pl({
|
|
|
9229
9229
|
"aria-label": `Fit all ${yt} items in one row`,
|
|
9230
9230
|
"aria-pressed": dc,
|
|
9231
9231
|
className: `w-full rounded-lg border px-3 py-2.5 text-left ${dc ? "border-[#7c3aed] bg-[#f5f3ff] text-[#5b21b6]" : "border-[#dedee3] bg-white text-[#27272a] hover:border-[#a78bfa] hover:bg-[#faf8ff]"}`,
|
|
9232
|
-
onClick: () =>
|
|
9232
|
+
onClick: () => Rr(yt),
|
|
9233
9233
|
children: [
|
|
9234
9234
|
/* @__PURE__ */ g("span", { className: "flex items-center justify-between gap-2", children: [
|
|
9235
9235
|
/* @__PURE__ */ g("span", { className: "text-[11px] font-semibold", children: [
|
|
@@ -9257,7 +9257,7 @@ function pl({
|
|
|
9257
9257
|
detail: `${Nt ?? yt} Columns`,
|
|
9258
9258
|
active: Ye === "grid" && Nt != null,
|
|
9259
9259
|
icon: /* @__PURE__ */ s(Do, { mode: "grid" }),
|
|
9260
|
-
action: () =>
|
|
9260
|
+
action: () => Rr(Nt ?? yt)
|
|
9261
9261
|
},
|
|
9262
9262
|
{
|
|
9263
9263
|
key: "auto",
|
|
@@ -9361,7 +9361,7 @@ function pl({
|
|
|
9361
9361
|
"aria-label": `${h} items per row`,
|
|
9362
9362
|
"aria-pressed": Nt === h,
|
|
9363
9363
|
className: `h-8 rounded-md text-[10px] font-semibold ${Nt === h ? "bg-[#18181b] text-white" : "bg-white text-[#52525b] hover:bg-[#e9e9ee]"}`,
|
|
9364
|
-
onClick: () =>
|
|
9364
|
+
onClick: () => Rr(h),
|
|
9365
9365
|
children: h
|
|
9366
9366
|
},
|
|
9367
9367
|
h
|
|
@@ -9372,7 +9372,7 @@ function pl({
|
|
|
9372
9372
|
label: "directly",
|
|
9373
9373
|
value: Nt,
|
|
9374
9374
|
min: 1,
|
|
9375
|
-
onCommit: (h) =>
|
|
9375
|
+
onCommit: (h) => Rr(Math.min(24, h))
|
|
9376
9376
|
}
|
|
9377
9377
|
)
|
|
9378
9378
|
] })
|
|
@@ -9444,7 +9444,7 @@ function pl({
|
|
|
9444
9444
|
Ct,
|
|
9445
9445
|
{
|
|
9446
9446
|
label: "↕",
|
|
9447
|
-
value:
|
|
9447
|
+
value: Er,
|
|
9448
9448
|
onCommit: (h) => Ge("row-gap", `${h}px`)
|
|
9449
9449
|
}
|
|
9450
9450
|
),
|
|
@@ -9452,9 +9452,9 @@ function pl({
|
|
|
9452
9452
|
"button",
|
|
9453
9453
|
{
|
|
9454
9454
|
type: "button",
|
|
9455
|
-
"aria-pressed":
|
|
9456
|
-
className: `h-7 rounded-md text-[9px] font-semibold ${
|
|
9457
|
-
onClick: () => Ge("justify-content",
|
|
9455
|
+
"aria-pressed": kr === "space-between",
|
|
9456
|
+
className: `h-7 rounded-md text-[9px] font-semibold ${kr === "space-between" ? "bg-[#e5f4ff] text-[#007be5]" : "bg-[#f4f4f5] text-[#52525b]"}`,
|
|
9457
|
+
onClick: () => Ge("justify-content", kr === "space-between" ? "flex-start" : "space-between"),
|
|
9458
9458
|
children: "Space between"
|
|
9459
9459
|
}
|
|
9460
9460
|
)
|
|
@@ -9590,8 +9590,8 @@ function pl({
|
|
|
9590
9590
|
{
|
|
9591
9591
|
type: "button",
|
|
9592
9592
|
"aria-label": `Span ${h} columns`,
|
|
9593
|
-
"aria-pressed": ac === h &&
|
|
9594
|
-
className: `h-7 rounded-md text-[9px] font-semibold ${ac === h &&
|
|
9593
|
+
"aria-pressed": ac === h && Ar !== "1 / -1",
|
|
9594
|
+
className: `h-7 rounded-md text-[9px] font-semibold ${ac === h && Ar !== "1 / -1" ? "bg-[#9747ff] text-white" : "bg-[#f4f4f5] text-[#52525b]"}`,
|
|
9595
9595
|
onClick: () => nt("grid-column", `span ${h}`),
|
|
9596
9596
|
children: h
|
|
9597
9597
|
},
|
|
@@ -9602,8 +9602,8 @@ function pl({
|
|
|
9602
9602
|
{
|
|
9603
9603
|
type: "button",
|
|
9604
9604
|
"aria-label": "Span all columns",
|
|
9605
|
-
"aria-pressed":
|
|
9606
|
-
className: `h-7 rounded-md text-[9px] font-semibold ${
|
|
9605
|
+
"aria-pressed": Ar === "1 / -1",
|
|
9606
|
+
className: `h-7 rounded-md text-[9px] font-semibold ${Ar === "1 / -1" ? "bg-[#9747ff] text-white" : "bg-[#f4f4f5] text-[#52525b]"}`,
|
|
9607
9607
|
onClick: () => nt("grid-column", "1 / -1"),
|
|
9608
9608
|
children: "All"
|
|
9609
9609
|
}
|
|
@@ -9702,7 +9702,7 @@ function pl({
|
|
|
9702
9702
|
"button",
|
|
9703
9703
|
{
|
|
9704
9704
|
type: "button",
|
|
9705
|
-
disabled:
|
|
9705
|
+
disabled: $r != null,
|
|
9706
9706
|
className: "h-8 rounded-md bg-[#f4f4f5] text-[10px] font-semibold text-[#52525b] hover:bg-[#e9e9ee] disabled:text-[#c4c4c8]",
|
|
9707
9707
|
onClick: () => {
|
|
9708
9708
|
G.recordDuplicate(
|
|
@@ -9765,7 +9765,7 @@ function pl({
|
|
|
9765
9765
|
}
|
|
9766
9766
|
)
|
|
9767
9767
|
] }),
|
|
9768
|
-
/* @__PURE__ */ s("p", { className: "mt-1.5 text-[9px] leading-relaxed text-[#71717a]", children: ji ? "Prop/text changes and structural changes cannot be applied together to the same source element. Please undo existing changes." :
|
|
9768
|
+
/* @__PURE__ */ s("p", { className: "mt-1.5 text-[9px] leading-relaxed text-[#71717a]", children: ji ? "Prop/text changes and structural changes cannot be applied together to the same source element. Please undo existing changes." : vn ? `${vn === "insert" ? "Duplicate" : vn === "remove" ? "Delete" : "Move"} is pending. Undo it before editing props or text.` : $r ?? "Only direct siblings of the same parent can be duplicated, deleted, or moved. Only one structural change is staged to a parent at a time." })
|
|
9769
9769
|
] }),
|
|
9770
9770
|
N === "item" && D && /* @__PURE__ */ g(Xe, { title: "Insert component", children: [
|
|
9771
9771
|
/* @__PURE__ */ s(
|
|
@@ -9868,7 +9868,7 @@ function pl({
|
|
|
9868
9868
|
title: "Styles",
|
|
9869
9869
|
action: Hi ? /* @__PURE__ */ s("button", { type: "button", className: "text-[10px] font-semibold text-[#0d99ff]", onClick: () => p("cases"), children: "Back to cases" }) : void 0,
|
|
9870
9870
|
children: /* @__PURE__ */ s("div", { className: "flex flex-col gap-1.5", children: (N === "container" ? yx : xx).map(({ label: h, prop: y, tokenGroup: C }) => {
|
|
9871
|
-
const O = C ?
|
|
9871
|
+
const O = C ? mn[C] : [];
|
|
9872
9872
|
return /* @__PURE__ */ g("label", { className: "grid grid-cols-[56px_minmax(0,1fr)_82px] items-center gap-1.5 text-[10px] text-[#71717a]", children: [
|
|
9873
9873
|
/* @__PURE__ */ s("span", { className: "shrink-0", children: h }),
|
|
9874
9874
|
/* @__PURE__ */ s(
|
|
@@ -9878,10 +9878,10 @@ function pl({
|
|
|
9878
9878
|
defaultValue: Jn.getPropertyValue(y),
|
|
9879
9879
|
className: "h-7 min-w-0 rounded-md bg-[#f4f4f5] px-2 text-[11px] text-[#18181b] outline-none focus:ring-1 focus:ring-inset focus:ring-[#0d99ff]",
|
|
9880
9880
|
onKeyDown: (L) => {
|
|
9881
|
-
L.key === "Enter" &&
|
|
9881
|
+
L.key === "Enter" && xn(y, L.target.value);
|
|
9882
9882
|
},
|
|
9883
9883
|
onBlur: (L) => {
|
|
9884
|
-
L.currentTarget.value !== Jn.getPropertyValue(y) &&
|
|
9884
|
+
L.currentTarget.value !== Jn.getPropertyValue(y) && xn(y, L.currentTarget.value);
|
|
9885
9885
|
}
|
|
9886
9886
|
},
|
|
9887
9887
|
`${Q}-${N}-${y}`
|
|
@@ -9893,7 +9893,7 @@ function pl({
|
|
|
9893
9893
|
value: "",
|
|
9894
9894
|
className: "h-7 min-w-0 rounded-md bg-[#f4f4f5] px-1.5 text-[10px] text-[#52525b] outline-none focus:ring-1 focus:ring-inset focus:ring-[#0d99ff]",
|
|
9895
9895
|
onChange: (L) => {
|
|
9896
|
-
L.target.value &&
|
|
9896
|
+
L.target.value && xn(y, `var(${L.target.value})`);
|
|
9897
9897
|
},
|
|
9898
9898
|
children: [
|
|
9899
9899
|
/* @__PURE__ */ s("option", { value: "", children: "Token" }),
|
|
@@ -9945,7 +9945,7 @@ function pl({
|
|
|
9945
9945
|
"select",
|
|
9946
9946
|
{
|
|
9947
9947
|
"aria-label": `${h} prop`,
|
|
9948
|
-
disabled:
|
|
9948
|
+
disabled: vn != null,
|
|
9949
9949
|
value: String(O),
|
|
9950
9950
|
className: "h-7 min-w-0 rounded-md bg-[#f4f4f5] px-2 text-[11px] text-[#18181b] outline-none focus:ring-1 focus:ring-inset focus:ring-[#0d99ff] disabled:text-[#a1a1aa]",
|
|
9951
9951
|
onChange: (he) => G.recordProp(
|
|
@@ -9967,7 +9967,7 @@ function pl({
|
|
|
9967
9967
|
{
|
|
9968
9968
|
type: typeof y == "number" ? "number" : "text",
|
|
9969
9969
|
"aria-label": `${h} prop`,
|
|
9970
|
-
disabled:
|
|
9970
|
+
disabled: vn != null,
|
|
9971
9971
|
defaultValue: String(O),
|
|
9972
9972
|
className: "h-7 min-w-0 rounded-md bg-[#f4f4f5] px-2 text-[11px] text-[#18181b] outline-none focus:ring-1 focus:ring-inset focus:ring-[#0d99ff] disabled:text-[#a1a1aa]",
|
|
9973
9973
|
onKeyDown: (he) => {
|
|
@@ -9995,7 +9995,7 @@ function pl({
|
|
|
9995
9995
|
"input",
|
|
9996
9996
|
{
|
|
9997
9997
|
"aria-label": "Edit text",
|
|
9998
|
-
disabled:
|
|
9998
|
+
disabled: vn != null,
|
|
9999
9999
|
defaultValue: D.textContent ?? "",
|
|
10000
10000
|
className: "h-8 w-full rounded-md bg-[#f4f4f5] px-2 text-[11px] text-[#18181b] outline-none focus:ring-1 focus:ring-inset focus:ring-[#0d99ff] disabled:text-[#a1a1aa]",
|
|
10001
10001
|
onKeyDown: (h) => {
|
|
@@ -10492,7 +10492,14 @@ const _x = He(function({ onClose: t }) {
|
|
|
10492
10492
|
{
|
|
10493
10493
|
ref: o,
|
|
10494
10494
|
title: `Application preview ${r.route}`,
|
|
10495
|
-
src:
|
|
10495
|
+
src: pr(
|
|
10496
|
+
n,
|
|
10497
|
+
r.route ?? "",
|
|
10498
|
+
Tt(
|
|
10499
|
+
Kt(),
|
|
10500
|
+
pn(r, !0)
|
|
10501
|
+
)
|
|
10502
|
+
),
|
|
10496
10503
|
className: "h-full w-full border-0 bg-white"
|
|
10497
10504
|
}
|
|
10498
10505
|
),
|
|
@@ -11268,7 +11275,7 @@ function wl({
|
|
|
11268
11275
|
"aria-label": `${e} variants ${o ? "Collapse" : "Expand"}`,
|
|
11269
11276
|
className: "flex h-4 w-4 shrink-0 items-center justify-center text-[#999]",
|
|
11270
11277
|
onClick: () => i((l) => !l),
|
|
11271
|
-
children: /* @__PURE__ */ s(
|
|
11278
|
+
children: /* @__PURE__ */ s(Zr, { open: o })
|
|
11272
11279
|
}
|
|
11273
11280
|
),
|
|
11274
11281
|
/* @__PURE__ */ g(
|
|
@@ -11924,7 +11931,7 @@ const vy = He(function() {
|
|
|
11924
11931
|
});
|
|
11925
11932
|
let sa = null;
|
|
11926
11933
|
const aa = /* @__PURE__ */ new Set();
|
|
11927
|
-
function
|
|
11934
|
+
function Pn(e) {
|
|
11928
11935
|
if (!Object.is(sa, e)) {
|
|
11929
11936
|
sa = e;
|
|
11930
11937
|
for (const t of aa) t();
|
|
@@ -12285,7 +12292,7 @@ function rf(e, t) {
|
|
|
12285
12292
|
unplacedFrames: X
|
|
12286
12293
|
};
|
|
12287
12294
|
}
|
|
12288
|
-
function
|
|
12295
|
+
function Hr({
|
|
12289
12296
|
frame: e,
|
|
12290
12297
|
label: t,
|
|
12291
12298
|
onSelectFrame: n
|
|
@@ -12340,7 +12347,7 @@ function Fy({
|
|
|
12340
12347
|
/* @__PURE__ */ s("span", { children: t })
|
|
12341
12348
|
] });
|
|
12342
12349
|
}
|
|
12343
|
-
function
|
|
12350
|
+
function Cn({
|
|
12344
12351
|
label: e,
|
|
12345
12352
|
count: t,
|
|
12346
12353
|
defaultOpen: n = !1,
|
|
@@ -12589,7 +12596,7 @@ function Ly({
|
|
|
12589
12596
|
) : null,
|
|
12590
12597
|
/* @__PURE__ */ g("div", { className: "mt-2 flex flex-col gap-2", children: [
|
|
12591
12598
|
e.startFrameIds.length > 0 && /* @__PURE__ */ s(
|
|
12592
|
-
|
|
12599
|
+
Cn,
|
|
12593
12600
|
{
|
|
12594
12601
|
label: "Starts",
|
|
12595
12602
|
count: e.startFrameIds.length,
|
|
@@ -12597,7 +12604,7 @@ function Ly({
|
|
|
12597
12604
|
children: e.startFrameIds.map((S) => {
|
|
12598
12605
|
const $ = c.get(S);
|
|
12599
12606
|
return $ ? /* @__PURE__ */ s(
|
|
12600
|
-
|
|
12607
|
+
Hr,
|
|
12601
12608
|
{
|
|
12602
12609
|
frame: $,
|
|
12603
12610
|
onSelectFrame: t
|
|
@@ -12607,10 +12614,10 @@ function Ly({
|
|
|
12607
12614
|
})
|
|
12608
12615
|
}
|
|
12609
12616
|
),
|
|
12610
|
-
e.branchFrameIds.length > 0 && /* @__PURE__ */ s(
|
|
12617
|
+
e.branchFrameIds.length > 0 && /* @__PURE__ */ s(Cn, { label: "Branches", count: e.branchFrameIds.length, children: e.branchFrameIds.map((S) => {
|
|
12611
12618
|
const $ = c.get(S);
|
|
12612
12619
|
return $ ? /* @__PURE__ */ s(
|
|
12613
|
-
|
|
12620
|
+
Hr,
|
|
12614
12621
|
{
|
|
12615
12622
|
frame: $,
|
|
12616
12623
|
label: `${$.name} · ${$.branchTargetFrameIds.length} targets`,
|
|
@@ -12619,7 +12626,7 @@ function Ly({
|
|
|
12619
12626
|
S
|
|
12620
12627
|
) : null;
|
|
12621
12628
|
}) }),
|
|
12622
|
-
e.canonicalGroups.length > 0 && /* @__PURE__ */ s(
|
|
12629
|
+
e.canonicalGroups.length > 0 && /* @__PURE__ */ s(Cn, { label: "Canonical", count: e.canonicalGroups.length, children: e.canonicalGroups.map((S) => {
|
|
12623
12630
|
const $ = S.canonicalFrameId ? c.get(S.canonicalFrameId) : void 0;
|
|
12624
12631
|
return /* @__PURE__ */ g(
|
|
12625
12632
|
"div",
|
|
@@ -12628,7 +12635,7 @@ function Ly({
|
|
|
12628
12635
|
title: `${S.aliasScreenIds.length} aliases`,
|
|
12629
12636
|
children: [
|
|
12630
12637
|
$ ? /* @__PURE__ */ s(
|
|
12631
|
-
|
|
12638
|
+
Hr,
|
|
12632
12639
|
{
|
|
12633
12640
|
frame: $,
|
|
12634
12641
|
label: S.canonicalScreenId,
|
|
@@ -12645,7 +12652,7 @@ function Ly({
|
|
|
12645
12652
|
);
|
|
12646
12653
|
}) }),
|
|
12647
12654
|
e.sharedSources.length > 0 && /* @__PURE__ */ s(
|
|
12648
|
-
|
|
12655
|
+
Cn,
|
|
12649
12656
|
{
|
|
12650
12657
|
label: "Shared sources",
|
|
12651
12658
|
count: e.sharedSources.length,
|
|
@@ -12665,7 +12672,7 @@ function Ly({
|
|
|
12665
12672
|
/* @__PURE__ */ s("div", { className: "flex flex-col", children: S.frameIds.map(($) => {
|
|
12666
12673
|
const R = c.get($);
|
|
12667
12674
|
return R ? /* @__PURE__ */ s(
|
|
12668
|
-
|
|
12675
|
+
Hr,
|
|
12669
12676
|
{
|
|
12670
12677
|
frame: R,
|
|
12671
12678
|
onSelectFrame: t
|
|
@@ -12677,7 +12684,7 @@ function Ly({
|
|
|
12677
12684
|
}
|
|
12678
12685
|
),
|
|
12679
12686
|
x.length > 0 && /* @__PURE__ */ s(
|
|
12680
|
-
|
|
12687
|
+
Cn,
|
|
12681
12688
|
{
|
|
12682
12689
|
label: "Used by",
|
|
12683
12690
|
count: x.length,
|
|
@@ -12730,7 +12737,7 @@ function Ly({
|
|
|
12730
12737
|
}
|
|
12731
12738
|
),
|
|
12732
12739
|
w.length > 0 && /* @__PURE__ */ s(
|
|
12733
|
-
|
|
12740
|
+
Cn,
|
|
12734
12741
|
{
|
|
12735
12742
|
label: "Not traced yet",
|
|
12736
12743
|
count: w.length,
|
|
@@ -12748,7 +12755,7 @@ function Ly({
|
|
|
12748
12755
|
}
|
|
12749
12756
|
),
|
|
12750
12757
|
e.unplacedFrames.length > 0 && /* @__PURE__ */ s(
|
|
12751
|
-
|
|
12758
|
+
Cn,
|
|
12752
12759
|
{
|
|
12753
12760
|
label: "Unplaced",
|
|
12754
12761
|
count: e.unplacedFrames.length,
|
|
@@ -12765,9 +12772,9 @@ function Ly({
|
|
|
12765
12772
|
))
|
|
12766
12773
|
}
|
|
12767
12774
|
),
|
|
12768
|
-
e.warnings.length > 0 && /* @__PURE__ */ g(
|
|
12775
|
+
e.warnings.length > 0 && /* @__PURE__ */ g(Cn, { label: "Warnings", count: e.warnings.length, children: [
|
|
12769
12776
|
b.map((S) => /* @__PURE__ */ s(
|
|
12770
|
-
|
|
12777
|
+
Hr,
|
|
12771
12778
|
{
|
|
12772
12779
|
frame: S,
|
|
12773
12780
|
label: `${S.name} · ${S.warnings.length}`,
|
|
@@ -12827,7 +12834,7 @@ const zy = ed(function e({ node: t, depth: n }) {
|
|
|
12827
12834
|
onClick: (d) => {
|
|
12828
12835
|
d.stopPropagation(), f.toggleCollapsed(t.id);
|
|
12829
12836
|
},
|
|
12830
|
-
children: /* @__PURE__ */ s(
|
|
12837
|
+
children: /* @__PURE__ */ s(Zr, { open: !o })
|
|
12831
12838
|
}
|
|
12832
12839
|
),
|
|
12833
12840
|
/* @__PURE__ */ s(Dy, { type: t.type }),
|
|
@@ -13326,21 +13333,21 @@ function Ky(e) {
|
|
|
13326
13333
|
message: `no "${e.componentName}" instance in the imported tree`
|
|
13327
13334
|
};
|
|
13328
13335
|
}
|
|
13329
|
-
const
|
|
13336
|
+
const eo = /* @__PURE__ */ new Map();
|
|
13330
13337
|
function Uy(e) {
|
|
13331
|
-
|
|
13338
|
+
eo.clear();
|
|
13332
13339
|
for (const t of e) {
|
|
13333
13340
|
if (t.kind === "behavior" || t.kind === "todo") continue;
|
|
13334
|
-
const n =
|
|
13335
|
-
n.push(t),
|
|
13341
|
+
const n = eo.get(t.screenId) ?? [];
|
|
13342
|
+
n.push(t), eo.set(t.screenId, n);
|
|
13336
13343
|
}
|
|
13337
13344
|
}
|
|
13338
13345
|
function qy(e) {
|
|
13339
|
-
return
|
|
13346
|
+
return eo.get(e) ?? [];
|
|
13340
13347
|
}
|
|
13341
13348
|
function Yy(e, t, n) {
|
|
13342
13349
|
const r = [];
|
|
13343
|
-
for (const o of
|
|
13350
|
+
for (const o of eo.get(e) ?? [])
|
|
13344
13351
|
o.kind === "component-state" && o.componentName === t && o.prop === n && r.push(o.scenarioId);
|
|
13345
13352
|
return r;
|
|
13346
13353
|
}
|
|
@@ -14224,8 +14231,8 @@ function bv({ mode: e }) {
|
|
|
14224
14231
|
const xv = He(function({ page: t }) {
|
|
14225
14232
|
Je(
|
|
14226
14233
|
za,
|
|
14227
|
-
|
|
14228
|
-
|
|
14234
|
+
vr,
|
|
14235
|
+
vr
|
|
14229
14236
|
);
|
|
14230
14237
|
const n = t.route == null, r = (b) => f.patchPage(t.id, b), o = gv(t), i = (b) => {
|
|
14231
14238
|
const x = { ...t.root.domStyle };
|
|
@@ -15027,7 +15034,7 @@ function Av(e, t = {}) {
|
|
|
15027
15034
|
}
|
|
15028
15035
|
return { run: w, cancel: v };
|
|
15029
15036
|
}
|
|
15030
|
-
const Fl = "absolute z-20 flex flex-col overflow-hidden rounded-[13px] border border-[#e6e6e6] bg-white shadow-[0_2px_14px_rgba(0,0,0,.08)]", Rv = 600, cn = 200,
|
|
15037
|
+
const Fl = "absolute z-20 flex flex-col overflow-hidden rounded-[13px] border border-[#e6e6e6] bg-white shadow-[0_2px_14px_rgba(0,0,0,.08)]", Rv = 600, cn = 200, Gt = 280, Tv = 480, ps = "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)]", Vr = (e) => `flex h-9 w-9 items-center justify-center rounded-lg ${e ? "bg-[#0d99ff] text-white" : "text-[#333] hover:bg-[#f5f5f5]"}`;
|
|
15031
15038
|
function Fn({
|
|
15032
15039
|
icon: e,
|
|
15033
15040
|
label: t,
|
|
@@ -15074,8 +15081,8 @@ const Fv = He(function({
|
|
|
15074
15081
|
);
|
|
15075
15082
|
Je(
|
|
15076
15083
|
za,
|
|
15077
|
-
|
|
15078
|
-
|
|
15084
|
+
vr,
|
|
15085
|
+
vr
|
|
15079
15086
|
);
|
|
15080
15087
|
const l = Je(
|
|
15081
15088
|
tf,
|
|
@@ -15101,11 +15108,11 @@ const Fv = He(function({
|
|
|
15101
15108
|
if (xe.id === f.activePageId) return 1;
|
|
15102
15109
|
const ne = (F.canvas ?? "default") === f.activeCanvas, Pe = (xe.canvas ?? "default") === f.activeCanvas;
|
|
15103
15110
|
return ne !== Pe ? ne ? -1 : 1 : 0;
|
|
15104
|
-
}), b = m.map((F) =>
|
|
15111
|
+
}), b = m.map((F) => Ot(F, a)), x = [
|
|
15105
15112
|
...new Set(
|
|
15106
15113
|
m.flatMap((F) => [
|
|
15107
|
-
|
|
15108
|
-
|
|
15114
|
+
Ot(F, a),
|
|
15115
|
+
Ot(
|
|
15109
15116
|
F,
|
|
15110
15117
|
a,
|
|
15111
15118
|
F.authoredFrameSize ?? {
|
|
@@ -15132,7 +15139,7 @@ const Fv = He(function({
|
|
|
15132
15139
|
if (!t || !$ || typeof document > "u") return;
|
|
15133
15140
|
const F = Wn();
|
|
15134
15141
|
if (!F) return;
|
|
15135
|
-
const xe =
|
|
15142
|
+
const xe = Kt(), ne = n.current, Pe = ne ? {
|
|
15136
15143
|
panX: f.panX,
|
|
15137
15144
|
panY: f.panY,
|
|
15138
15145
|
zoom: f.zoom,
|
|
@@ -15141,13 +15148,13 @@ const Fv = He(function({
|
|
|
15141
15148
|
} : null, B = new Map(f.pages.map((_) => [_.id, _])), Ie = [];
|
|
15142
15149
|
for (const _ of f.pages) {
|
|
15143
15150
|
if (_.route == null || _.layersImported || fo(_.importPageId ?? _.id)) continue;
|
|
15144
|
-
const ue =
|
|
15151
|
+
const ue = Ot(_, a), je = _.width ?? 390, ie = dn(_), Oe = (((Z = _.interactions) == null ? void 0 : Z.length) ?? 0) > 0, Se = _.importPageId ?? _.id, We = Va(
|
|
15145
15152
|
{
|
|
15146
15153
|
canonicalId: Se,
|
|
15147
15154
|
route: _.route,
|
|
15148
15155
|
width: _.width,
|
|
15149
15156
|
height: _.height,
|
|
15150
|
-
environment:
|
|
15157
|
+
environment: pn(_),
|
|
15151
15158
|
preset: _.preset,
|
|
15152
15159
|
interactions: _.interactions,
|
|
15153
15160
|
assertions: _.assertions
|
|
@@ -15164,7 +15171,7 @@ const Fv = He(function({
|
|
|
15164
15171
|
}) ? ja({
|
|
15165
15172
|
origin: c,
|
|
15166
15173
|
route: _.route,
|
|
15167
|
-
environment:
|
|
15174
|
+
environment: pn(_),
|
|
15168
15175
|
width: je,
|
|
15169
15176
|
height: ie
|
|
15170
15177
|
}) : null,
|
|
@@ -15183,12 +15190,12 @@ const Fv = He(function({
|
|
|
15183
15190
|
leaseInstance: async (_) => {
|
|
15184
15191
|
const ue = B.get(_.pageId);
|
|
15185
15192
|
if (!ue || ue.route == null) return null;
|
|
15186
|
-
const je = ue.width ?? 390, ie = dn(ue), Oe =
|
|
15193
|
+
const je = ue.width ?? 390, ie = dn(ue), Oe = pr(
|
|
15187
15194
|
c,
|
|
15188
15195
|
ue.route,
|
|
15189
|
-
|
|
15196
|
+
Tt(
|
|
15190
15197
|
xe,
|
|
15191
|
-
|
|
15198
|
+
pn(ue)
|
|
15192
15199
|
)
|
|
15193
15200
|
);
|
|
15194
15201
|
if (_.groupKey != null) {
|
|
@@ -15213,13 +15220,13 @@ const Fv = He(function({
|
|
|
15213
15220
|
try {
|
|
15214
15221
|
await new Promise((re, Ne) => {
|
|
15215
15222
|
const Fe = () => {
|
|
15216
|
-
Se.removeEventListener("load", Be), Se.removeEventListener("error",
|
|
15223
|
+
Se.removeEventListener("load", Be), Se.removeEventListener("error", Lt);
|
|
15217
15224
|
}, Be = () => {
|
|
15218
15225
|
Fe(), re();
|
|
15219
|
-
},
|
|
15226
|
+
}, Lt = () => {
|
|
15220
15227
|
Fe(), Ne(new Error(`The sweep preview failed to load ${Oe}.`));
|
|
15221
15228
|
};
|
|
15222
|
-
Se.addEventListener("load", Be), Se.addEventListener("error",
|
|
15229
|
+
Se.addEventListener("load", Be), Se.addEventListener("error", Lt), Se.src = Oe;
|
|
15223
15230
|
});
|
|
15224
15231
|
} catch (re) {
|
|
15225
15232
|
throw Se.remove(), re;
|
|
@@ -15266,7 +15273,7 @@ const Fv = He(function({
|
|
|
15266
15273
|
(ue) => ue.id === f.activePageId
|
|
15267
15274
|
);
|
|
15268
15275
|
return !_ || _.route == null ? !1 : _.importLayers && !_.layersImported ? !0 : !_.layersImported && !Yn(
|
|
15269
|
-
|
|
15276
|
+
Ot(_, a)
|
|
15270
15277
|
);
|
|
15271
15278
|
}
|
|
15272
15279
|
});
|
|
@@ -15310,7 +15317,7 @@ const Fv = He(function({
|
|
|
15310
15317
|
]);
|
|
15311
15318
|
const [T, j] = q(!1), [E, z] = q(null), [X, M] = q("layers"), [W, J] = q("story"), [U, Me] = q(null), oe = Object.keys(Qe()), pe = f.canAddFrame, te = f.editMode, se = (F) => {
|
|
15312
15319
|
f.setTool(F), Me(null);
|
|
15313
|
-
}, [P, k] = q(!0), [I, V] = q(!0), [le, ve] = q(
|
|
15320
|
+
}, [P, k] = q(!0), [I, V] = q(!0), [le, ve] = q(Gt), [Ee, me] = q(Gt), De = Ce(!1), ze = (F) => {
|
|
15314
15321
|
const xe = f.pages.find((we) => we.id === F), ne = n.current;
|
|
15315
15322
|
if (!xe || !ne) {
|
|
15316
15323
|
f.selectFrame(F);
|
|
@@ -15786,10 +15793,10 @@ const Fv = He(function({
|
|
|
15786
15793
|
{
|
|
15787
15794
|
type: "button",
|
|
15788
15795
|
"aria-label": "Default left panel width",
|
|
15789
|
-
"aria-pressed": le ===
|
|
15790
|
-
title: `Default width · ${
|
|
15791
|
-
className: `h-5 rounded px-1.5 text-[8px] font-semibold ${le ===
|
|
15792
|
-
onClick: () => ve(
|
|
15796
|
+
"aria-pressed": le === Gt,
|
|
15797
|
+
title: `Default width · ${Gt}px`,
|
|
15798
|
+
className: `h-5 rounded px-1.5 text-[8px] font-semibold ${le === Gt ? "bg-white text-[#333] shadow-sm" : "text-[#888] hover:text-[#333]"}`,
|
|
15799
|
+
onClick: () => ve(Gt),
|
|
15793
15800
|
children: "Default"
|
|
15794
15801
|
}
|
|
15795
15802
|
)
|
|
@@ -15992,10 +15999,10 @@ const Fv = He(function({
|
|
|
15992
15999
|
{
|
|
15993
16000
|
type: "button",
|
|
15994
16001
|
"aria-label": "Default right panel width",
|
|
15995
|
-
"aria-pressed": Ee ===
|
|
15996
|
-
title: `Default panel width · ${
|
|
15997
|
-
className: `flex h-5 w-5 items-center justify-center rounded text-[10px] ${Ee ===
|
|
15998
|
-
onClick: () => me(
|
|
16002
|
+
"aria-pressed": Ee === Gt,
|
|
16003
|
+
title: `Default panel width · ${Gt}px`,
|
|
16004
|
+
className: `flex h-5 w-5 items-center justify-center rounded text-[10px] ${Ee === Gt ? "bg-[#f2f2f2] text-[#333]" : "text-[#999] hover:bg-[#f5f5f5]"}`,
|
|
16005
|
+
onClick: () => me(Gt),
|
|
15999
16006
|
children: "↔"
|
|
16000
16007
|
}
|
|
16001
16008
|
),
|
|
@@ -16075,7 +16082,7 @@ const Fv = He(function({
|
|
|
16075
16082
|
type: "button",
|
|
16076
16083
|
title: f.tool === "hand" ? "Hand Tool (H)" : f.tool === "zoom" ? "Zoom in/out (K)" : "Move (V)",
|
|
16077
16084
|
"aria-label": "Cursor tool",
|
|
16078
|
-
className:
|
|
16085
|
+
className: Vr(f.tool === "select" || f.tool === "hand" || f.tool === "zoom"),
|
|
16079
16086
|
onClick: () => se(f.tool === "hand" || f.tool === "zoom" ? f.tool : "select"),
|
|
16080
16087
|
children: f.tool === "hand" ? /* @__PURE__ */ s(Xc, { size: 15 }) : f.tool === "zoom" ? /* @__PURE__ */ s(Jc, { size: 15 }) : /* @__PURE__ */ s(Gc, { size: 15 })
|
|
16081
16088
|
}
|
|
@@ -16087,7 +16094,7 @@ const Fv = He(function({
|
|
|
16087
16094
|
"aria-label": "Select Cursor Tool",
|
|
16088
16095
|
className: "flex h-9 w-4 items-center justify-center rounded text-[#999] hover:text-[#333]",
|
|
16089
16096
|
onClick: () => Me(U === "cursor" ? null : "cursor"),
|
|
16090
|
-
children: /* @__PURE__ */ s(
|
|
16097
|
+
children: /* @__PURE__ */ s(Zr, { size: 8, open: U === "cursor" })
|
|
16091
16098
|
}
|
|
16092
16099
|
),
|
|
16093
16100
|
U === "cursor" && /* @__PURE__ */ g("div", { className: ps, children: [
|
|
@@ -16103,7 +16110,7 @@ const Fv = He(function({
|
|
|
16103
16110
|
type: "button",
|
|
16104
16111
|
title: "Section (⇧S)",
|
|
16105
16112
|
"aria-label": "Section tool",
|
|
16106
|
-
className:
|
|
16113
|
+
className: Vr(f.tool === "section"),
|
|
16107
16114
|
onClick: () => se(f.tool === "section" ? "select" : "section"),
|
|
16108
16115
|
children: f.tool === "section" ? /* @__PURE__ */ s(hi, { size: 15 }) : /* @__PURE__ */ s(Zs, { size: 15 })
|
|
16109
16116
|
}
|
|
@@ -16115,7 +16122,7 @@ const Fv = He(function({
|
|
|
16115
16122
|
"aria-label": "Select frame/section",
|
|
16116
16123
|
className: "flex h-9 w-4 items-center justify-center rounded text-[#999] hover:text-[#333]",
|
|
16117
16124
|
onClick: () => Me(U === "frame" ? null : "frame"),
|
|
16118
|
-
children: /* @__PURE__ */ s(
|
|
16125
|
+
children: /* @__PURE__ */ s(Zr, { size: 8, open: U === "frame" })
|
|
16119
16126
|
}
|
|
16120
16127
|
),
|
|
16121
16128
|
U === "frame" && /* @__PURE__ */ g("div", { className: ps, children: [
|
|
@@ -16142,7 +16149,7 @@ const Fv = He(function({
|
|
|
16142
16149
|
title: te ? "Add Rows (F)" : zn,
|
|
16143
16150
|
"aria-label": "Add Rows",
|
|
16144
16151
|
disabled: !te,
|
|
16145
|
-
className: `${
|
|
16152
|
+
className: `${Vr(!1)} disabled:cursor-not-allowed disabled:text-[#c9c9c9] disabled:hover:bg-transparent`,
|
|
16146
16153
|
onClick: () => f.addNode("rows"),
|
|
16147
16154
|
children: /* @__PURE__ */ s(pi, { size: 15 })
|
|
16148
16155
|
}
|
|
@@ -16154,7 +16161,7 @@ const Fv = He(function({
|
|
|
16154
16161
|
"aria-label": "Placement Selection",
|
|
16155
16162
|
className: "flex h-9 w-4 items-center justify-center rounded text-[#999] hover:text-[#333]",
|
|
16156
16163
|
onClick: () => Me(U === "layout" ? null : "layout"),
|
|
16157
|
-
children: /* @__PURE__ */ s(
|
|
16164
|
+
children: /* @__PURE__ */ s(Zr, { size: 8, open: U === "layout" })
|
|
16158
16165
|
}
|
|
16159
16166
|
),
|
|
16160
16167
|
U === "layout" && /* @__PURE__ */ g("div", { className: ps, children: [
|
|
@@ -16190,7 +16197,7 @@ const Fv = He(function({
|
|
|
16190
16197
|
title: te ? "Add Text (T)" : zn,
|
|
16191
16198
|
"aria-label": "Add text",
|
|
16192
16199
|
disabled: !te,
|
|
16193
|
-
className: `${
|
|
16200
|
+
className: `${Vr(!1)} disabled:cursor-not-allowed disabled:text-[#c9c9c9] disabled:hover:bg-transparent`,
|
|
16194
16201
|
onClick: () => f.addNode("text"),
|
|
16195
16202
|
children: /* @__PURE__ */ s($u, { size: 15 })
|
|
16196
16203
|
}
|
|
@@ -16202,7 +16209,7 @@ const Fv = He(function({
|
|
|
16202
16209
|
type: "button",
|
|
16203
16210
|
title: "Add component",
|
|
16204
16211
|
"aria-label": "Add component",
|
|
16205
|
-
className:
|
|
16212
|
+
className: Vr(U === "palette"),
|
|
16206
16213
|
onClick: () => Me(U === "palette" ? null : "palette"),
|
|
16207
16214
|
children: /* @__PURE__ */ s(oo, { size: 15 })
|
|
16208
16215
|
}
|
|
@@ -16277,10 +16284,10 @@ function _v(e, t, n, r = Lv) {
|
|
|
16277
16284
|
order: a,
|
|
16278
16285
|
target: {
|
|
16279
16286
|
key: d,
|
|
16280
|
-
url:
|
|
16287
|
+
url: pr(
|
|
16281
16288
|
t,
|
|
16282
16289
|
i.route ?? "",
|
|
16283
|
-
|
|
16290
|
+
Tt(n, i.environment)
|
|
16284
16291
|
),
|
|
16285
16292
|
width: c,
|
|
16286
16293
|
height: l
|
|
@@ -16717,7 +16724,7 @@ function Dl(e) {
|
|
|
16717
16724
|
function qv(e) {
|
|
16718
16725
|
return !!(e && typeof e == "object" && !Array.isArray(e));
|
|
16719
16726
|
}
|
|
16720
|
-
function
|
|
16727
|
+
function Ft(e) {
|
|
16721
16728
|
const t = e == null ? void 0 : e.trim();
|
|
16722
16729
|
if (!t) return null;
|
|
16723
16730
|
let n = t;
|
|
@@ -16729,7 +16736,7 @@ function Tt(e) {
|
|
|
16729
16736
|
return n = n.split(/[?#]/, 1)[0].replace(/\/{2,}/g, "/"), n.startsWith("/") || (n = `/${n}`), n.length > 1 && (n = n.replace(/\/+$/, "")), n || "/";
|
|
16730
16737
|
}
|
|
16731
16738
|
function cf(e) {
|
|
16732
|
-
const t =
|
|
16739
|
+
const t = Ft(e);
|
|
16733
16740
|
if (!t)
|
|
16734
16741
|
throw new Error("A storyboard source route must be a non-empty path.");
|
|
16735
16742
|
return `source-route:${encodeURIComponent(t)}`;
|
|
@@ -16749,7 +16756,7 @@ function oc(e, t) {
|
|
|
16749
16756
|
return o === r.length;
|
|
16750
16757
|
}
|
|
16751
16758
|
function zl(e, t, n) {
|
|
16752
|
-
const r =
|
|
16759
|
+
const r = Ft(e);
|
|
16753
16760
|
if (!r) return [];
|
|
16754
16761
|
const o = t.get(r);
|
|
16755
16762
|
return o && !/[:*]/.test(r) ? [
|
|
@@ -16766,7 +16773,7 @@ function Yv(e) {
|
|
|
16766
16773
|
var n;
|
|
16767
16774
|
const t = /* @__PURE__ */ new Map();
|
|
16768
16775
|
for (const r of e ?? []) {
|
|
16769
|
-
const o =
|
|
16776
|
+
const o = Ft(r.path);
|
|
16770
16777
|
!o || t.has(o) || t.set(o, {
|
|
16771
16778
|
id: cf(o),
|
|
16772
16779
|
name: o,
|
|
@@ -16801,17 +16808,17 @@ function Gv(e, t, n, r) {
|
|
|
16801
16808
|
});
|
|
16802
16809
|
}
|
|
16803
16810
|
function Xv(e, t, n) {
|
|
16804
|
-
const r =
|
|
16811
|
+
const r = Ft(e.route);
|
|
16805
16812
|
if (!r) return [];
|
|
16806
16813
|
const o = t.filter(
|
|
16807
16814
|
(c) => {
|
|
16808
|
-
const l =
|
|
16815
|
+
const l = Ft(c.route);
|
|
16809
16816
|
return l ? oc(l, r) : !1;
|
|
16810
16817
|
}
|
|
16811
16818
|
);
|
|
16812
16819
|
if (!o.length) return [];
|
|
16813
16820
|
const i = Dl(
|
|
16814
|
-
|
|
16821
|
+
Tt(n, e.environment)
|
|
16815
16822
|
), a = o.filter(
|
|
16816
16823
|
(c) => Dl(c.environment) === i
|
|
16817
16824
|
);
|
|
@@ -16866,7 +16873,7 @@ function zi(e, t) {
|
|
|
16866
16873
|
function Qv(e) {
|
|
16867
16874
|
const t = /* @__PURE__ */ new Map();
|
|
16868
16875
|
for (const n of e) {
|
|
16869
|
-
const r =
|
|
16876
|
+
const r = Ft(n.route);
|
|
16870
16877
|
if (!r) continue;
|
|
16871
16878
|
const o = t.get(r);
|
|
16872
16879
|
o ? o.push(n) : t.set(r, [n]);
|
|
@@ -16881,7 +16888,7 @@ function Qv(e) {
|
|
|
16881
16888
|
function Zv(e) {
|
|
16882
16889
|
const t = /* @__PURE__ */ new Map();
|
|
16883
16890
|
for (const n of e) {
|
|
16884
|
-
const r =
|
|
16891
|
+
const r = Ft(n.route);
|
|
16885
16892
|
if (!r) continue;
|
|
16886
16893
|
const o = t.get(r);
|
|
16887
16894
|
o ? o.push(n.id) : t.set(r, [n.id]);
|
|
@@ -16918,14 +16925,14 @@ function tw(e, t) {
|
|
|
16918
16925
|
function nw(e, t) {
|
|
16919
16926
|
const n = /* @__PURE__ */ new Map();
|
|
16920
16927
|
for (const r of e) {
|
|
16921
|
-
const o =
|
|
16928
|
+
const o = Ft(r.route);
|
|
16922
16929
|
if (!o) continue;
|
|
16923
16930
|
const i = `${o}\0${lf(r).join("")}`, a = n.get(i);
|
|
16924
16931
|
a ? a.push(r) : n.set(i, [r]);
|
|
16925
16932
|
}
|
|
16926
16933
|
return [...n.values()].flatMap((r) => {
|
|
16927
16934
|
if (r.length < 2) return [];
|
|
16928
|
-
const o =
|
|
16935
|
+
const o = Ft(r[0].route), i = t.get(o), a = r.find((c) => c.id === i) ?? [...r].sort(zi)[0];
|
|
16929
16936
|
return r.filter((c) => c.id !== a.id).sort((c, l) => c.id.localeCompare(l.id)).map((c) => ({
|
|
16930
16937
|
id: `discovery-variant:${encodeURIComponent(a.id)}:${encodeURIComponent(c.id)}`,
|
|
16931
16938
|
from: a.id,
|
|
@@ -16937,7 +16944,7 @@ function nw(e, t) {
|
|
|
16937
16944
|
function rw(e, t) {
|
|
16938
16945
|
const n = /* @__PURE__ */ new Map();
|
|
16939
16946
|
for (const r of e) {
|
|
16940
|
-
const o =
|
|
16947
|
+
const o = Ft(r.route);
|
|
16941
16948
|
if (!o) continue;
|
|
16942
16949
|
const i = n.get(o);
|
|
16943
16950
|
i ? i.push(r) : n.set(o, [r]);
|
|
@@ -16996,7 +17003,7 @@ function ow(e) {
|
|
|
16996
17003
|
return [...t.values()].flatMap((r) => {
|
|
16997
17004
|
const o = r[0], i = /* @__PURE__ */ new Map();
|
|
16998
17005
|
for (const a of r) {
|
|
16999
|
-
const c =
|
|
17006
|
+
const c = Ft(a.route);
|
|
17000
17007
|
if (!c) continue;
|
|
17001
17008
|
const l = i.get(c);
|
|
17002
17009
|
l ? l.push(a) : i.set(c, [a]);
|
|
@@ -17018,10 +17025,10 @@ function ow(e) {
|
|
|
17018
17025
|
}
|
|
17019
17026
|
function iw(e, t, n) {
|
|
17020
17027
|
const r = new Set(
|
|
17021
|
-
(t.routes ?? []).map((o) =>
|
|
17028
|
+
(t.routes ?? []).map((o) => Ft(o.path)).filter((o) => !!o)
|
|
17022
17029
|
);
|
|
17023
17030
|
return e.map((o) => {
|
|
17024
|
-
const i =
|
|
17031
|
+
const i = Ft(o.route);
|
|
17025
17032
|
if (!i || n.get(i) !== o.id)
|
|
17026
17033
|
return o;
|
|
17027
17034
|
const a = [...r].filter(
|
|
@@ -17165,12 +17172,12 @@ async function uf(e) {
|
|
|
17165
17172
|
};
|
|
17166
17173
|
}
|
|
17167
17174
|
async function Gw(e) {
|
|
17168
|
-
|
|
17175
|
+
Pn(null);
|
|
17169
17176
|
try {
|
|
17170
17177
|
const t = await uf(e);
|
|
17171
|
-
return
|
|
17178
|
+
return Pn(t.graph), t;
|
|
17172
17179
|
} catch (t) {
|
|
17173
|
-
throw
|
|
17180
|
+
throw Pn(null), t;
|
|
17174
17181
|
}
|
|
17175
17182
|
}
|
|
17176
17183
|
const wi = "var(--pygmalion-catalog-surface, #ffffff)", Si = "var(--pygmalion-catalog-canvas, #f5f5f5)", da = "var(--pygmalion-catalog-border, #e5e7eb)", Ni = "var(--pygmalion-catalog-text, #202124)", At = "var(--pygmalion-catalog-muted, #6b7280)", cw = "var(--pygmalion-catalog-header, #11182f)", lw = "var(--pygmalion-catalog-accent, #7c6cf2)";
|
|
@@ -18010,7 +18017,7 @@ function Aw(e, t) {
|
|
|
18010
18017
|
return jo.set(t, r), r;
|
|
18011
18018
|
}
|
|
18012
18019
|
}
|
|
18013
|
-
async function
|
|
18020
|
+
async function Xt(e) {
|
|
18014
18021
|
const t = await e.json();
|
|
18015
18022
|
if (!e.ok) throw new Error(t.error ?? `Pygmalion request failed (${e.status})`);
|
|
18016
18023
|
return t;
|
|
@@ -18062,13 +18069,13 @@ function n0(e = {}) {
|
|
|
18062
18069
|
} : {},
|
|
18063
18070
|
...I || ve ? {} : xs()
|
|
18064
18071
|
});
|
|
18065
|
-
let me = await
|
|
18072
|
+
let me = await Xt(Ee);
|
|
18066
18073
|
if (I || (me = await Nw({
|
|
18067
18074
|
initial: me,
|
|
18068
|
-
fetchStatus: async () =>
|
|
18075
|
+
fetchStatus: async () => Xt(
|
|
18069
18076
|
await o(`${a}/status`, xs())
|
|
18070
18077
|
),
|
|
18071
|
-
requestResync: async () =>
|
|
18078
|
+
requestResync: async () => Xt(
|
|
18072
18079
|
await o(`${a}/refresh`, {
|
|
18073
18080
|
method: "POST",
|
|
18074
18081
|
...xs(mf)
|
|
@@ -18076,7 +18083,7 @@ function n0(e = {}) {
|
|
|
18076
18083
|
)
|
|
18077
18084
|
})), me.state !== "ready" || !me.appOrigin || !me.commit)
|
|
18078
18085
|
throw new Error(me.error ?? "Pygmalion could not prepare the source preview");
|
|
18079
|
-
const De = await
|
|
18086
|
+
const De = await Xt(
|
|
18080
18087
|
await o(`${c}/open`, {
|
|
18081
18088
|
method: "POST",
|
|
18082
18089
|
headers: { "content-type": "application/json" },
|
|
@@ -18087,7 +18094,7 @@ function n0(e = {}) {
|
|
|
18087
18094
|
throw new Error(De.error ?? "Pygmalion could not open the design session");
|
|
18088
18095
|
let ze = De.session;
|
|
18089
18096
|
if (ze.branchName) {
|
|
18090
|
-
const Ue = await
|
|
18097
|
+
const Ue = await Xt(
|
|
18091
18098
|
await o(`${c}/check`, {
|
|
18092
18099
|
method: "POST",
|
|
18093
18100
|
headers: { "content-type": "application/json" },
|
|
@@ -18117,7 +18124,7 @@ function n0(e = {}) {
|
|
|
18117
18124
|
[o, a, c, b]
|
|
18118
18125
|
), E = St(async () => {
|
|
18119
18126
|
try {
|
|
18120
|
-
const I = await
|
|
18127
|
+
const I = await Xt(
|
|
18121
18128
|
await o(`${a}/refs`)
|
|
18122
18129
|
), V = {
|
|
18123
18130
|
refs: I.refs ?? [],
|
|
@@ -18144,7 +18151,7 @@ function n0(e = {}) {
|
|
|
18144
18151
|
const V = T.current;
|
|
18145
18152
|
if (V && (V.sessionId !== v.id || V.baseDevSha !== v.baseDevSha || V.revision !== v.revision || V.fingerprint !== JSON.stringify(I)))
|
|
18146
18153
|
throw new Error("The code diff you checked is out of date. Please check the diff for the current changes again.");
|
|
18147
|
-
const le = await
|
|
18154
|
+
const le = await Xt(
|
|
18148
18155
|
await o(`${c}/apply-visual`, {
|
|
18149
18156
|
method: "POST",
|
|
18150
18157
|
headers: { "content-type": "application/json" },
|
|
@@ -18194,7 +18201,7 @@ function n0(e = {}) {
|
|
|
18194
18201
|
var me;
|
|
18195
18202
|
if (!v) throw new Error("Pygmalion design session is not ready");
|
|
18196
18203
|
T.current = null;
|
|
18197
|
-
const V = await
|
|
18204
|
+
const V = await Xt(
|
|
18198
18205
|
await o(`${c}/preview-visual`, {
|
|
18199
18206
|
method: "POST",
|
|
18200
18207
|
headers: { "content-type": "application/json" },
|
|
@@ -18248,7 +18255,7 @@ function n0(e = {}) {
|
|
|
18248
18255
|
), W = St(
|
|
18249
18256
|
async (I) => {
|
|
18250
18257
|
if (I.length === 0) return { files: [] };
|
|
18251
|
-
const V = await
|
|
18258
|
+
const V = await Xt(
|
|
18252
18259
|
await o(`${l}/impact`, {
|
|
18253
18260
|
method: "POST",
|
|
18254
18261
|
headers: { "content-type": "application/json" },
|
|
@@ -18263,7 +18270,7 @@ function n0(e = {}) {
|
|
|
18263
18270
|
), J = St(async () => {
|
|
18264
18271
|
if (!(v != null && v.canRevert) || !v.headSha)
|
|
18265
18272
|
throw new Error("There are no reversible changes applied");
|
|
18266
|
-
const I = await
|
|
18273
|
+
const I = await Xt(
|
|
18267
18274
|
await o(`${c}/revert-visual`, {
|
|
18268
18275
|
method: "POST",
|
|
18269
18276
|
headers: { "content-type": "application/json" },
|
|
@@ -18571,7 +18578,7 @@ function c0({
|
|
|
18571
18578
|
fingerprint: Va(
|
|
18572
18579
|
Z,
|
|
18573
18580
|
Pe,
|
|
18574
|
-
|
|
18581
|
+
Kt()
|
|
18575
18582
|
)
|
|
18576
18583
|
})),
|
|
18577
18584
|
[ne, Pe, me]
|
|
@@ -18583,8 +18590,8 @@ function c0({
|
|
|
18583
18590
|
route: Z.route,
|
|
18584
18591
|
width: Z.width ?? 390,
|
|
18585
18592
|
height: Z.height ?? 600,
|
|
18586
|
-
environment:
|
|
18587
|
-
|
|
18593
|
+
environment: Tt(
|
|
18594
|
+
Kt(),
|
|
18588
18595
|
Z.environment
|
|
18589
18596
|
),
|
|
18590
18597
|
preset: Z.preset,
|
|
@@ -18598,7 +18605,7 @@ function c0({
|
|
|
18598
18605
|
namespace: m ?? "",
|
|
18599
18606
|
previewRevision: Pe,
|
|
18600
18607
|
appOrigin: B,
|
|
18601
|
-
baselineEnvironment:
|
|
18608
|
+
baselineEnvironment: Kt(),
|
|
18602
18609
|
allowStaleIdentity: !!x,
|
|
18603
18610
|
allowMatchingFrameIdentity: De != null,
|
|
18604
18611
|
pages: ne.map((Z, _) => {
|
|
@@ -18637,7 +18644,7 @@ function c0({
|
|
|
18637
18644
|
namespace: m,
|
|
18638
18645
|
previewRevision: p,
|
|
18639
18646
|
appOrigin: Qt(),
|
|
18640
|
-
baselineEnvironment:
|
|
18647
|
+
baselineEnvironment: Kt(),
|
|
18641
18648
|
allowStaleIdentity: !0,
|
|
18642
18649
|
allowMatchingFrameIdentity: !0,
|
|
18643
18650
|
pages: ne.map((re, Ne) => {
|
|
@@ -18664,16 +18671,16 @@ function c0({
|
|
|
18664
18671
|
const re = await ie(Ae, !0, We.signal);
|
|
18665
18672
|
if (re.status === "accepted") {
|
|
18666
18673
|
je(re.artifact);
|
|
18667
|
-
const
|
|
18668
|
-
if (Ae.every((
|
|
18674
|
+
const Lt = new Set(((Ne = re.frameResolution) == null ? void 0 : Ne.exact) ?? []);
|
|
18675
|
+
if (Ae.every((mn) => Lt.has(mn.id)))
|
|
18669
18676
|
return { status: "accepted" };
|
|
18670
|
-
const
|
|
18677
|
+
const Yt = [
|
|
18671
18678
|
...((Fe = re.frameResolution) == null ? void 0 : Fe.missing) ?? [],
|
|
18672
18679
|
...((Be = re.frameResolution) == null ? void 0 : Be.stale) ?? []
|
|
18673
18680
|
];
|
|
18674
18681
|
return {
|
|
18675
18682
|
status: "unavailable",
|
|
18676
|
-
message:
|
|
18683
|
+
message: Yt.length ? `The exact preview endpoint did not return a current capture for ${Yt.join(", ")}.` : "The exact preview endpoint returned no current capture."
|
|
18677
18684
|
};
|
|
18678
18685
|
}
|
|
18679
18686
|
return re.status === "rejected" ? {
|
|
@@ -18703,7 +18710,7 @@ function c0({
|
|
|
18703
18710
|
return Be !== "generating" && Be !== "exact";
|
|
18704
18711
|
});
|
|
18705
18712
|
(async () => {
|
|
18706
|
-
var
|
|
18713
|
+
var Yt, mn, gn;
|
|
18707
18714
|
const Ne = we.current.slice(
|
|
18708
18715
|
0,
|
|
18709
18716
|
Ie.current.length
|
|
@@ -18722,7 +18729,7 @@ function c0({
|
|
|
18722
18729
|
);
|
|
18723
18730
|
const Be = re(
|
|
18724
18731
|
Ae.filter((qe) => !Fe.has(qe.id))
|
|
18725
|
-
),
|
|
18732
|
+
), Lt = [];
|
|
18726
18733
|
for (const qe of jc(
|
|
18727
18734
|
Be
|
|
18728
18735
|
)) {
|
|
@@ -18735,14 +18742,14 @@ function c0({
|
|
|
18735
18742
|
});
|
|
18736
18743
|
if (Z.signal.aborted) return;
|
|
18737
18744
|
if (Le.status === "accepted") {
|
|
18738
|
-
|
|
18745
|
+
Lt.push(
|
|
18739
18746
|
...Oe(qe, Le.resolution.exact)
|
|
18740
18747
|
);
|
|
18741
|
-
const
|
|
18748
|
+
const bn = Oe(qe, [
|
|
18742
18749
|
...Le.resolution.missing,
|
|
18743
18750
|
...Le.resolution.stale
|
|
18744
18751
|
]);
|
|
18745
|
-
vt(re(
|
|
18752
|
+
vt(re(bn), {
|
|
18746
18753
|
status: "outdated",
|
|
18747
18754
|
message: "Select this frame to generate the exact preview."
|
|
18748
18755
|
});
|
|
@@ -18759,7 +18766,7 @@ function c0({
|
|
|
18759
18766
|
});
|
|
18760
18767
|
}
|
|
18761
18768
|
for (const qe of jc(
|
|
18762
|
-
re(
|
|
18769
|
+
re(Lt)
|
|
18763
18770
|
)) {
|
|
18764
18771
|
const Le = await ie(
|
|
18765
18772
|
qe,
|
|
@@ -18769,14 +18776,14 @@ function c0({
|
|
|
18769
18776
|
if (Z.signal.aborted) return;
|
|
18770
18777
|
if (Le.status === "accepted") {
|
|
18771
18778
|
je(Le.artifact), vt(
|
|
18772
|
-
Oe(qe, ((
|
|
18779
|
+
Oe(qe, ((Yt = Le.frameResolution) == null ? void 0 : Yt.exact) ?? []),
|
|
18773
18780
|
{ status: "exact" }
|
|
18774
18781
|
);
|
|
18775
|
-
const
|
|
18776
|
-
...((
|
|
18777
|
-
...((
|
|
18782
|
+
const bn = Oe(qe, [
|
|
18783
|
+
...((mn = Le.frameResolution) == null ? void 0 : mn.missing) ?? [],
|
|
18784
|
+
...((gn = Le.frameResolution) == null ? void 0 : gn.stale) ?? []
|
|
18778
18785
|
]);
|
|
18779
|
-
vt(re(
|
|
18786
|
+
vt(re(bn), {
|
|
18780
18787
|
status: "outdated",
|
|
18781
18788
|
message: "Select this frame to generate the exact preview."
|
|
18782
18789
|
});
|
|
@@ -18817,11 +18824,11 @@ function c0({
|
|
|
18817
18824
|
]), ce(() => {
|
|
18818
18825
|
let Z = !0;
|
|
18819
18826
|
if (!I)
|
|
18820
|
-
return
|
|
18827
|
+
return Lr(void 0), Dr(null), Pn(null), Ee(le), () => {
|
|
18821
18828
|
Z = !1;
|
|
18822
18829
|
};
|
|
18823
18830
|
const _ = new AbortController();
|
|
18824
|
-
return
|
|
18831
|
+
return Lr(void 0), Dr(null), Pn(null), uf({
|
|
18825
18832
|
endpoint: V,
|
|
18826
18833
|
signal: _.signal,
|
|
18827
18834
|
pages: f.pages.map((ue) => ({
|
|
@@ -18832,13 +18839,13 @@ function c0({
|
|
|
18832
18839
|
assets: (l == null ? void 0 : l.getAssets("screens")) ?? [],
|
|
18833
18840
|
storyboard: k
|
|
18834
18841
|
}).then((ue) => {
|
|
18835
|
-
Z && (
|
|
18842
|
+
Z && (Lr(ue.baselineEnvironment), Dr(ue.manifest.routes ?? null), Pn(ue.graph));
|
|
18836
18843
|
}).catch(() => {
|
|
18837
|
-
Z && (
|
|
18844
|
+
Z && (Lr(void 0), Dr(null), Pn(null));
|
|
18838
18845
|
}).finally(() => {
|
|
18839
18846
|
Z && Ee(le);
|
|
18840
18847
|
}), () => {
|
|
18841
|
-
Z = !1, _.abort(),
|
|
18848
|
+
Z = !1, _.abort(), Lr(void 0), Dr(null), Pn(null);
|
|
18842
18849
|
};
|
|
18843
18850
|
}, [
|
|
18844
18851
|
l,
|
|
@@ -18859,7 +18866,7 @@ function c0({
|
|
|
18859
18866
|
editor: f,
|
|
18860
18867
|
getPages: () => f.pages,
|
|
18861
18868
|
appOrigin: Z,
|
|
18862
|
-
baselineEnvironment:
|
|
18869
|
+
baselineEnvironment: Kt()
|
|
18863
18870
|
});
|
|
18864
18871
|
}, [u, me, p]), /* @__PURE__ */ s(Fv, { previewIdentityReady: me });
|
|
18865
18872
|
}
|
|
@@ -18899,7 +18906,7 @@ export {
|
|
|
18899
18906
|
rf as createStoryboardGraphViewModel,
|
|
18900
18907
|
jv as createStoryboardPathEdges,
|
|
18901
18908
|
cf as createStoryboardRouteScenarioId,
|
|
18902
|
-
|
|
18909
|
+
pr as createStoryboardRouteUrl,
|
|
18903
18910
|
dw as designCatalogKey,
|
|
18904
18911
|
ff as designCatalogRegistryName,
|
|
18905
18912
|
Qg as enumerateControlCandidates,
|
|
@@ -18919,14 +18926,14 @@ export {
|
|
|
18919
18926
|
Im as getPreviewEnvironmentControls,
|
|
18920
18927
|
Pm as getPreviewEnvironmentOverride,
|
|
18921
18928
|
ba as getRecommendedPygmalionPreviewConcurrency,
|
|
18922
|
-
|
|
18929
|
+
Kt as getStoryboardBaselineEnvironment,
|
|
18923
18930
|
df as getStoryboardDiscoveryBaselineEnvironment,
|
|
18924
18931
|
co as getStoryboardGraph,
|
|
18925
18932
|
nb as getSurfaceClassifications,
|
|
18926
18933
|
sf as getViewportPresets,
|
|
18927
18934
|
uf as loadStoryboardDiscovery,
|
|
18928
18935
|
b0 as mergeScreenPresets,
|
|
18929
|
-
|
|
18936
|
+
Tt as mergeStoryboardEnvironment,
|
|
18930
18937
|
Gw as publishStoryboardDiscovery,
|
|
18931
18938
|
i0 as pygmalionNavigate,
|
|
18932
18939
|
s0 as pygmalionOpenPreview,
|
|
@@ -18946,8 +18953,8 @@ export {
|
|
|
18946
18953
|
op as setPygmalionAppOrigin,
|
|
18947
18954
|
Od as setPygmalionPreviewConcurrency,
|
|
18948
18955
|
ip as setPygmalionPreviewRevision,
|
|
18949
|
-
|
|
18950
|
-
|
|
18956
|
+
Lr as setStoryboardBaselineEnvironment,
|
|
18957
|
+
Pn as setStoryboardGraph,
|
|
18951
18958
|
tb as setSurfaceClassifications,
|
|
18952
18959
|
px as setTokens,
|
|
18953
18960
|
By as setViewportPresets,
|