@flemo/core 2.2.2 → 2.3.0

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/index.mjs CHANGED
@@ -1,6 +1,6 @@
1
1
  import { createStore as e } from "zustand/vanilla";
2
2
  import { compile as t, match as n, parse as r, pathToRegexp as i } from "path-to-regexp";
3
- //#region src/core/TaskManger.ts
3
+ //#region src/core/TaskManager.ts
4
4
  var a = "browser-history", o = 1200, s = 2, c = new class {
5
5
  tasks = /* @__PURE__ */ new Map();
6
6
  instanceId = Date.now().toString();
@@ -523,7 +523,7 @@ function N(e) {
523
523
  }
524
524
  //#endregion
525
525
  //#region src/history/memoryHistoryDriver.ts
526
- function P(e) {
526
+ function te(e) {
527
527
  let t = [{
528
528
  state: e?.state ?? null,
529
529
  url: e?.url ?? "/"
@@ -566,12 +566,12 @@ function P(e) {
566
566
  }
567
567
  //#endregion
568
568
  //#region src/navigate/store.ts
569
- var F = [
569
+ var P = [
570
570
  "PUSHING",
571
571
  "POPPING",
572
572
  "REPLACING"
573
573
  ];
574
- function te() {
574
+ function ne() {
575
575
  return e((e) => ({
576
576
  status: "IDLE",
577
577
  transitionTaskId: null,
@@ -581,11 +581,11 @@ function te() {
581
581
  }
582
582
  //#endregion
583
583
  //#region src/navigate/createNavigationController.ts
584
- var I = (e, t, n) => {
584
+ var F = (e, t, n) => {
585
585
  let { regexp: r } = i(e);
586
586
  for (let e = t - 1; e >= 0; e--) if (r.test(n[e].pathname)) return t - e;
587
587
  return -1;
588
- }, ne = (e, t) => typeof e == "number" && Number.isFinite(e) ? Math.max(0, Math.trunc(e)) : t, L = async (e, t, n, r) => {
588
+ }, re = (e, t) => typeof e == "number" && Number.isFinite(e) ? Math.max(0, Math.trunc(e)) : t, I = async (e, t, n, r) => {
589
589
  let i, a = new Promise((t) => {
590
590
  i = e.subscribe(() => t(!0));
591
591
  }), o = new Promise((e) => setTimeout(() => e(!1), 200));
@@ -593,7 +593,7 @@ var I = (e, t, n) => {
593
593
  let s = await Promise.race([a, o]);
594
594
  i(), s && r();
595
595
  };
596
- function re(e) {
596
+ function L(e) {
597
597
  let { stores: t, buildPathname: n, driver: r = b(), markSelfInduced: i = C } = e, a = v(r), s = () => t.history.getState().bumpTruncationEpoch(), l = () => {
598
598
  let e = r.readState();
599
599
  if (!e?.id) return null;
@@ -618,10 +618,10 @@ function re(e) {
618
618
  }
619
619
  let o = l(), { index: c, histories: f, addHistory: p, popHistories: g } = t.history.getState(), _ = (() => {
620
620
  if (d?.until != null) {
621
- let e = I(d.until, c, f);
621
+ let e = F(d.until, c, f);
622
622
  return e < 0 ? 0 : e;
623
623
  }
624
- return Math.min(ne(d?.skip, 0), Math.max(0, c));
624
+ return Math.min(re(d?.skip, 0), Math.max(0, c));
625
625
  })(), { setStatus: v, setTransitionTaskId: y } = t.navigate.getState();
626
626
  v("PUSHING"), y(h);
627
627
  let { pathname: b, toPathname: x } = n(e, u ?? {}), S = {
@@ -646,7 +646,7 @@ function re(e) {
646
646
  return p({
647
647
  ...S,
648
648
  frameIndex: w + 1
649
- }), await L(r, i, _, () => {
649
+ }), await I(r, i, _, () => {
650
650
  s(), r.pushState({
651
651
  id: h,
652
652
  index: w + 1,
@@ -676,10 +676,10 @@ function re(e) {
676
676
  }
677
677
  let o = l(), { index: c, histories: f, addHistory: p, replaceHistory: g, popHistories: _ } = t.history.getState(), v = (() => {
678
678
  if (d?.until != null) {
679
- let e = I(d.until, c, f);
679
+ let e = F(d.until, c, f);
680
680
  return e < 0 ? 0 : e + 1;
681
681
  }
682
- return Math.min(ne(d?.skip, 0) + 1, c + 1);
682
+ return Math.min(re(d?.skip, 0) + 1, c + 1);
683
683
  })();
684
684
  if (v <= 0) {
685
685
  a.abort();
@@ -709,7 +709,7 @@ function re(e) {
709
709
  return _(v - 1), p({
710
710
  ...C,
711
711
  frameIndex: T
712
- }), v <= c ? await L(r, i, v, () => {
712
+ }), v <= c ? await I(r, i, v, () => {
713
713
  s(), r.pushState({
714
714
  id: h,
715
715
  index: T,
@@ -717,7 +717,7 @@ function re(e) {
717
717
  params: u,
718
718
  transitionName: m
719
719
  }, x);
720
- }) : await L(r, i, c, () => {
720
+ }) : await I(r, i, c, () => {
721
721
  s(), r.replaceState({
722
722
  id: h,
723
723
  index: T,
@@ -776,10 +776,10 @@ function re(e) {
776
776
  pop: async (e) => {
777
777
  await f((t, n) => {
778
778
  if (e?.until != null) {
779
- let r = I(e.until, t, n);
779
+ let r = F(e.until, t, n);
780
780
  return r < 0 ? 0 : r;
781
781
  }
782
- let r = ne(e?.skip, 1);
782
+ let r = re(e?.skip, 1);
783
783
  return r <= 0 ? 0 : Math.min(r, t);
784
784
  }, e?.transitionName);
785
785
  }
@@ -970,7 +970,7 @@ function W(e) {
970
970
  index: 0,
971
971
  histories: [d]
972
972
  }), e.hostedScope;
973
- let m = a ? P({
973
+ let m = a ? te({
974
974
  state: {
975
975
  id: d.id,
976
976
  index: 0,
@@ -981,7 +981,7 @@ function W(e) {
981
981
  url: d.pathname
982
982
  }) : o, h = x(), g = {
983
983
  history: l([d], 0),
984
- navigate: te(),
984
+ navigate: ne(),
985
985
  transition: V(i),
986
986
  screen: ae(),
987
987
  driver: m,
@@ -1640,18 +1640,18 @@ var Ue = [
1640
1640
  }, Qe = "data-flemo-", $e = "data-flemo-screen", et = "data-flemo-status", tt = "data-flemo-active", nt = "data-flemo-transition", rt = "data-flemo-router", it = "data-flemo-skip-animation", at = "data-flemo-bar", ot = "data-flemo-bar-active", st = "data-flemo-bar-status", ct = "data-flemo-bar-riding", lt = "data-flemo-bar-id", ut = "data-flemo-bar-id-type", dt = "data-flemo-bar-transition", ft = "data-flemo-bar-spacer", pt = "data-flemo-decorator", mt = "data-flemo-decorator-name", ht = "data-flemo-decorator-owner", gt = "data-flemo-layer-host", _t = "data-flemo-layer-slot", vt = "data-flemo-layer-owner", J = "data-flemo-part-name", yt = "data-flemo-part-layer", bt = "data-flemo-part-home", xt = "data-flemo-part-stand-in", St = "data-flemo-morph", Ct = {
1641
1641
  ENTER: "enter",
1642
1642
  EXIT: "exit"
1643
- }, wt = "data-flemo-morph-name", Tt = "data-flemo-morph-layer", Et = "data-flemo-morph-slot", Dt = "data-flemo-morph-stand-in", Ot = "data-flemo-morph-ghost", kt = "data-flemo-morph-camera", At = "data-flemo-morph-sheet", Y = "data-flemo-anim-hold", jt = {
1643
+ }, wt = "data-flemo-morph-name", Tt = "data-flemo-morph-id", Et = "data-flemo-morph-layer", Dt = "data-flemo-morph-slot", Ot = "data-flemo-morph-stand-in", kt = "data-flemo-morph-ghost", At = "data-flemo-morph-camera", jt = "data-flemo-morph-sheet", Y = "data-flemo-anim-hold", Mt = {
1644
1644
  HELD: "true",
1645
1645
  RELEASED: "false",
1646
1646
  PARK: "park",
1647
1647
  PARK_UNDER: "park-under",
1648
1648
  PARK_OVER: "park-over"
1649
- }, Mt = [
1650
- jt.HELD,
1651
- jt.PARK,
1652
- jt.PARK_UNDER,
1653
- jt.PARK_OVER
1654
- ], Nt = "data-flemo-held-arrival", Pt = "data-flemo-img-hold", Ft = "data-flemo-governed", It = "data-flemo-creep", Lt = "data-flemo-desk-head", Rt = "data-flemo-park-head", zt = "data-flemo-warm", Bt = "data-flemo-gpu-prewarm", Vt = "data-flemo-image-src", Ht = "data-flemo-devtools-panel", X = (e) => `[${e}]`, Z = (e, t) => `[${e}="${t}"]`, Ut = [
1649
+ }, Nt = [
1650
+ Mt.HELD,
1651
+ Mt.PARK,
1652
+ Mt.PARK_UNDER,
1653
+ Mt.PARK_OVER
1654
+ ], Pt = "data-flemo-held-arrival", Ft = "data-flemo-img-hold", It = "data-flemo-governed", Lt = "data-flemo-creep", Rt = "data-flemo-desk-head", zt = "data-flemo-park-head", Bt = "data-flemo-warm", Vt = "data-flemo-gpu-prewarm", Ht = "data-flemo-image-src", Ut = "data-flemo-devtools-panel", X = (e) => `[${e}]`, Z = (e, t) => `[${e}="${t}"]`, Wt = [
1655
1655
  $e,
1656
1656
  et,
1657
1657
  tt,
@@ -1677,15 +1677,15 @@ var Ue = [
1677
1677
  bt,
1678
1678
  xt,
1679
1679
  St,
1680
+ At,
1680
1681
  kt,
1681
- Ot,
1682
1682
  Tt,
1683
- wt,
1684
1683
  Et,
1684
+ wt,
1685
1685
  Dt,
1686
- At,
1686
+ Ot,
1687
+ jt,
1687
1688
  Y,
1688
- Nt,
1689
1689
  Pt,
1690
1690
  Ft,
1691
1691
  It,
@@ -1694,9 +1694,10 @@ var Ue = [
1694
1694
  zt,
1695
1695
  Bt,
1696
1696
  Vt,
1697
- Ht
1698
- ], Wt = (e, t) => t <= 0 || Math.abs(e - t) <= .5 ? 1 : e / t || 1, Gt = (e, t) => {
1699
- let n = t.getBoundingClientRect(), r = Wt(n.width, t.offsetWidth), i = Wt(n.height, t.offsetHeight);
1697
+ Ht,
1698
+ Ut
1699
+ ], Gt = (e, t) => t <= 0 || Math.abs(e - t) <= .5 ? 1 : e / t || 1, Kt = (e, t) => {
1700
+ let n = t.getBoundingClientRect(), r = Gt(n.width, t.offsetWidth), i = Gt(n.height, t.offsetHeight);
1700
1701
  return {
1701
1702
  x: (e.x - n.left) / r,
1702
1703
  y: (e.y - n.top) / i,
@@ -1704,47 +1705,47 @@ var Ue = [
1704
1705
  height: e.height / i
1705
1706
  };
1706
1707
  };
1707
- function Kt(e) {
1708
+ function qt(e) {
1708
1709
  let t = e.animationName;
1709
1710
  return typeof t == "string" && t.length > 0 ? t : null;
1710
1711
  }
1711
- function qt(e) {
1712
+ function Jt(e) {
1712
1713
  let t = e.effect?.target ?? null;
1713
1714
  return t instanceof Element ? t : null;
1714
1715
  }
1715
- function Jt(e) {
1716
+ function Yt(e) {
1716
1717
  let t = e.currentTime;
1717
1718
  return typeof t == "number" ? t : null;
1718
1719
  }
1719
- function Yt(e) {
1720
+ function Xt(e) {
1720
1721
  let t = /* @__PURE__ */ new Map();
1721
1722
  t.set(e, 0);
1722
1723
  let n = 1;
1723
1724
  for (let r of e.querySelectorAll("*")) t.set(r, n++);
1724
1725
  return t;
1725
1726
  }
1726
- function Xt(e, t) {
1727
+ function Zt(e, t) {
1727
1728
  let n = /* @__PURE__ */ new Map();
1728
1729
  if (typeof e.getAnimations != "function") return n;
1729
- let r = Yt(e);
1730
+ let r = Xt(e);
1730
1731
  for (let i of e.getAnimations({ subtree: !0 })) {
1731
- let a = qt(i);
1732
+ let a = Jt(i);
1732
1733
  if (!a || a === e && !t) continue;
1733
- let o = Kt(i), s = r.get(a);
1734
+ let o = qt(i), s = r.get(a);
1734
1735
  if (o === null || s === void 0) continue;
1735
- let c = Jt(i);
1736
+ let c = Yt(i);
1736
1737
  c !== null && n.set(`${s}|${o}`, { time: c });
1737
1738
  }
1738
1739
  return n;
1739
1740
  }
1740
- function Zt(e, t, n = {}) {
1741
- let r = n.includeRoot ?? !1, i = Xt(e, r);
1741
+ function Qt(e, t, n = {}) {
1742
+ let r = n.includeRoot ?? !1, i = Zt(e, r);
1742
1743
  if (t(), i.size === 0 || typeof e.getAnimations != "function") return i.size;
1743
- let a = Yt(e);
1744
+ let a = Xt(e);
1744
1745
  for (let t of e.getAnimations({ subtree: !0 })) {
1745
- let n = qt(t);
1746
+ let n = Jt(t);
1746
1747
  if (!n || n === e && !r) continue;
1747
- let o = Kt(t), s = a.get(n);
1748
+ let o = qt(t), s = a.get(n);
1748
1749
  if (o === null || s === void 0) continue;
1749
1750
  let c = i.get(`${s}|${o}`);
1750
1751
  if (c) try {
@@ -1755,7 +1756,7 @@ function Zt(e, t, n = {}) {
1755
1756
  }
1756
1757
  //#endregion
1757
1758
  //#region src/morph/morphClip.ts
1758
- var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
1759
+ var $t = (e) => e !== "" && e !== "visible", en = (e) => {
1759
1760
  if (!e || !e.isConnected) return null;
1760
1761
  let t = e.getBoundingClientRect();
1761
1762
  if (t.width <= 0 || t.height <= 0) return null;
@@ -1768,9 +1769,9 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
1768
1769
  } catch {
1769
1770
  return null;
1770
1771
  }
1771
- if (!Qt(e) && !Qt(o)) continue;
1772
+ if (!$t(e) && !$t(o)) continue;
1772
1773
  let s = t.getBoundingClientRect();
1773
- s.width <= 0 || s.height <= 0 || (Qt(o) && (n = Math.max(n, s.top), i = Math.min(i, s.bottom)), Qt(e) && (r = Math.max(r, s.left), a = Math.min(a, s.right)));
1774
+ s.width <= 0 || s.height <= 0 || ($t(o) && (n = Math.max(n, s.top), i = Math.min(i, s.bottom)), $t(e) && (r = Math.max(r, s.left), a = Math.min(a, s.right)));
1774
1775
  }
1775
1776
  let o = n - t.y, s = r - t.x, c = t.y + t.height - i, l = t.x + t.width - a;
1776
1777
  if (o < .5 && s < .5 && c < .5 && l < .5) return null;
@@ -1781,19 +1782,19 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
1781
1782
  bottom: u(c, t.height),
1782
1783
  left: u(s, t.width)
1783
1784
  };
1784
- }, en = {
1785
+ }, tn = {
1785
1786
  top: 0,
1786
1787
  right: 0,
1787
1788
  bottom: 0,
1788
1789
  left: 0
1789
- }, tn = (e, t) => e === null && t === null ? null : {
1790
- from: e ?? en,
1791
- to: t ?? en
1792
- }, nn = 1 / 64, rn = 256, an = /^\s*$/, on = (e, t) => {
1790
+ }, nn = (e, t) => e === null && t === null ? null : {
1791
+ from: e ?? tn,
1792
+ to: t ?? tn
1793
+ }, rn = 1 / 64, an = 256, on = /^\s*$/, sn = (e, t) => {
1793
1794
  let n = e.getBoundingClientRect(), r = (e) => [t.x === "right" ? n.right - e.right : e.left - n.left, t.y === "bottom" ? n.bottom - e.bottom : e.top - n.top], i = [], a = !1, o = (e) => {
1794
1795
  if (!a) {
1795
1796
  for (let t of e.children) {
1796
- if (i.length >= rn * 4) {
1797
+ if (i.length >= an * 4) {
1797
1798
  a = !0;
1798
1799
  return;
1799
1800
  }
@@ -1801,7 +1802,7 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
1801
1802
  i.push(...r(e), e.width, e.height), o(t);
1802
1803
  }
1803
1804
  for (let t of e.childNodes) {
1804
- if (t.nodeType !== 3 || an.test(t.data)) continue;
1805
+ if (t.nodeType !== 3 || on.test(t.data)) continue;
1805
1806
  let n = e.ownerDocument.createRange();
1806
1807
  if (typeof n.getClientRects != "function") {
1807
1808
  a = !0;
@@ -1815,22 +1816,22 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
1815
1816
  }
1816
1817
  };
1817
1818
  return o(e), a ? null : i;
1818
- }, sn = /* @__PURE__ */ new WeakMap(), cn = (e, t, n, r) => {
1819
+ }, cn = /* @__PURE__ */ new WeakMap(), ln = (e, t, n, r) => {
1819
1820
  let i = e.parentElement;
1820
- if (!i || !e.isConnected || Math.abs(t.width - n.width) < nn && Math.abs(t.height - n.height) < nn) return !1;
1821
- let a = `${t.width.toFixed(1)}x${t.height.toFixed(1)}>${n.width.toFixed(1)}x${n.height.toFixed(1)}|${r.x}${r.y}`, o = sn.get(e), s = o?.get(a);
1821
+ if (!i || !e.isConnected || Math.abs(t.width - n.width) < rn && Math.abs(t.height - n.height) < rn) return !1;
1822
+ let a = `${t.width.toFixed(1)}x${t.height.toFixed(1)}>${n.width.toFixed(1)}x${n.height.toFixed(1)}|${r.x}${r.y}`, o = cn.get(e), s = o?.get(a);
1822
1823
  if (s !== void 0) return s;
1823
1824
  let c = e.cloneNode(!0);
1824
1825
  c.setAttribute("aria-hidden", "true"), c.style.position = "absolute", c.style.left = "0", c.style.top = "0", c.style.margin = "0", c.style.visibility = "hidden", c.style.pointerEvents = "none", c.style.animation = "none", c.style.transition = "none", i.appendChild(c);
1825
- let l = (e) => (c.style.width = `${e.width}px`, c.style.height = `${e.height}px`, on(c, r)), u = null, d = null;
1826
+ let l = (e) => (c.style.width = `${e.width}px`, c.style.height = `${e.height}px`, sn(c, r)), u = null, d = null;
1826
1827
  try {
1827
1828
  u = l(t), d = l(n);
1828
1829
  } finally {
1829
1830
  c.remove();
1830
1831
  }
1831
- let f = u !== null && d !== null && u.length > 0 && u.length === d.length && u.every((e, t) => Math.abs(e - d[t]) <= nn), p = o ?? /* @__PURE__ */ new Map();
1832
- return p.set(a, f), sn.set(e, p), f;
1833
- }, ln = (e) => e === "normal" ? "0px" : e, un = [
1832
+ let f = u !== null && d !== null && u.length > 0 && u.length === d.length && u.every((e, t) => Math.abs(e - d[t]) <= rn), p = o ?? /* @__PURE__ */ new Map();
1833
+ return p.set(a, f), cn.set(e, p), f;
1834
+ }, un = (e) => e === "normal" ? "0px" : e, dn = [
1834
1835
  { property: "border-radius" },
1835
1836
  { property: "background-color" },
1836
1837
  { property: "background-size" },
@@ -1865,27 +1866,27 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
1865
1866
  { property: "mix-blend-mode" },
1866
1867
  {
1867
1868
  property: "row-gap",
1868
- normalize: ln
1869
+ normalize: un
1869
1870
  },
1870
1871
  {
1871
1872
  property: "column-gap",
1872
- normalize: ln
1873
+ normalize: un
1873
1874
  },
1874
1875
  { property: "object-position" },
1875
1876
  { property: "fill" },
1876
1877
  { property: "stroke" },
1877
1878
  { property: "stroke-width" }
1878
- ], dn = (e) => e.replace(/-([a-z])/g, (e, t) => t.toUpperCase()), fn = (e) => {
1879
+ ], fn = (e) => e.replace(/-([a-z])/g, (e, t) => t.toUpperCase()), pn = (e) => {
1879
1880
  let t = {};
1880
1881
  if (!e) return t;
1881
- for (let n of un) {
1882
- let r = n.sides ? n.sides.map((t) => e[t] ?? "").join(" ") : e[dn(n.property)] ?? "";
1882
+ for (let n of dn) {
1883
+ let r = n.sides ? n.sides.map((t) => e[t] ?? "").join(" ") : e[fn(n.property)] ?? "";
1883
1884
  r.trim().length > 0 && (t[n.property] = n.normalize ? n.normalize(r) : r);
1884
1885
  }
1885
1886
  return t;
1886
- }, pn = (e, t, n) => {
1887
+ }, mn = (e, t, n) => {
1887
1888
  let r = [];
1888
- for (let i of un) {
1889
+ for (let i of dn) {
1889
1890
  if (n?.has(i.property)) continue;
1890
1891
  let a = e[i.property], o = t[i.property];
1891
1892
  a !== void 0 && o !== void 0 && a !== o && r.push({
@@ -1901,7 +1902,7 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
1901
1902
  scaleX: 1,
1902
1903
  scaleY: 1,
1903
1904
  rotate: 0
1904
- }, mn = (e, t) => {
1905
+ }, hn = (e, t) => {
1905
1906
  if (e === void 0) return 0;
1906
1907
  if (typeof e == "number") return e;
1907
1908
  let n = e.trim();
@@ -1916,12 +1917,12 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
1916
1917
  }
1917
1918
  let r = Number.parseFloat(n);
1918
1919
  return n === String(r) && Number.isFinite(r) ? r : null;
1919
- }, hn = (e, t) => {
1920
+ }, gn = (e, t) => {
1920
1921
  if (e === void 0) return t;
1921
1922
  if (typeof e == "number") return e;
1922
1923
  let n = Number.parseFloat(e.trim());
1923
1924
  return Number.isFinite(n) ? n : null;
1924
- }, gn = (e) => {
1925
+ }, _n = (e) => {
1925
1926
  if (e === void 0) return 0;
1926
1927
  if (typeof e == "number") return e;
1927
1928
  let t = e.trim();
@@ -1931,15 +1932,15 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
1931
1932
  }
1932
1933
  let n = Number.parseFloat(t);
1933
1934
  return t === String(n) && Number.isFinite(n) ? n : null;
1934
- }, _n = (e, t) => {
1935
+ }, vn = (e, t) => {
1935
1936
  if (!e) return { ...Q };
1936
- let n = mn(e.x, t.width), r = mn(e.y, t.height);
1937
+ let n = hn(e.x, t.width), r = hn(e.y, t.height);
1937
1938
  if (n === null || r === null) return null;
1938
- let i = hn(e.scale, 1);
1939
+ let i = gn(e.scale, 1);
1939
1940
  if (i === null) return null;
1940
- let a = hn(e.scaleX, i), o = hn(e.scaleY, i);
1941
+ let a = gn(e.scaleX, i), o = gn(e.scaleY, i);
1941
1942
  if (a === null || o === null) return null;
1942
- let s = gn(e.rotate ?? e.rotateZ);
1943
+ let s = _n(e.rotate ?? e.rotateZ);
1943
1944
  return s === null ? null : {
1944
1945
  x: n,
1945
1946
  y: r,
@@ -1947,73 +1948,73 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
1947
1948
  scaleY: o,
1948
1949
  rotate: s
1949
1950
  };
1950
- }, vn = (e) => e.x === 0 && e.y === 0 && e.scaleX === 1 && e.scaleY === 1 && e.rotate === 0, yn = (e) => Math.round(e * 1e3) / 1e3, bn = (e) => {
1951
- if (vn(e)) return "none";
1951
+ }, yn = (e) => e.x === 0 && e.y === 0 && e.scaleX === 1 && e.scaleY === 1 && e.rotate === 0, bn = (e) => Math.round(e * 1e3) / 1e3, xn = (e) => {
1952
+ if (yn(e)) return "none";
1952
1953
  let t = [];
1953
- return (e.x !== 0 || e.y !== 0) && t.push(`translate3d(${yn(e.x)}px, ${yn(e.y)}px, 0)`), (e.scaleX !== 1 || e.scaleY !== 1) && t.push(`scale(${yn(e.scaleX)}, ${yn(e.scaleY)})`), e.rotate !== 0 && t.push(`rotate(${yn(e.rotate)}deg)`), t.join(" ");
1954
- }, xn = (e) => e.filter((e) => !vn(e)), Sn = (e) => {
1955
- let t = xn(e).map(bn);
1954
+ return (e.x !== 0 || e.y !== 0) && t.push(`translate3d(${bn(e.x)}px, ${bn(e.y)}px, 0)`), (e.scaleX !== 1 || e.scaleY !== 1) && t.push(`scale(${bn(e.scaleX)}, ${bn(e.scaleY)})`), e.rotate !== 0 && t.push(`rotate(${bn(e.rotate)}deg)`), t.join(" ");
1955
+ }, Sn = (e) => e.filter((e) => !yn(e)), Cn = (e) => {
1956
+ let t = Sn(e).map(xn);
1956
1957
  return t.length === 0 ? "none" : t.join(" ");
1957
- }, Cn = {
1958
+ }, wn = {
1958
1959
  x: "--flemo-pose-x",
1959
1960
  y: "--flemo-pose-y",
1960
1961
  scaleX: "--flemo-pose-sx",
1961
1962
  scaleY: "--flemo-pose-sy",
1962
1963
  rotate: "--flemo-pose-r"
1963
- }, wn = {
1964
+ }, Tn = {
1964
1965
  x: "--flemo-move-x",
1965
1966
  y: "--flemo-move-y",
1966
1967
  lift: "--flemo-lift-y"
1967
- }, Tn = {
1968
+ }, En = {
1968
1969
  w: "--flemo-box-w",
1969
1970
  h: "--flemo-box-h"
1970
- }, En = Tn.w, Dn = `var(${Tn.w})`, On = `var(${Tn.h})`, kn = 1 / 64, An = (e) => Math.round(e / kn) * kn, jn = (e) => An(e).toFixed(6).replace(/0+$/, "").replace(/\.$/, ""), Mn = (e, t, n = " ") => `${n}${Tn.w}: ${jn(e)}px;\n${n}${Tn.h}: ${jn(t)}px;`, Nn = {
1971
+ }, Dn = En.w, On = `var(${En.w})`, kn = `var(${En.h})`, An = 1 / 64, jn = (e) => Math.round(e / An) * An, Mn = (e) => jn(e).toFixed(6).replace(/0+$/, "").replace(/\.$/, ""), Nn = (e, t, n = " ") => `${n}${En.w}: ${Mn(e)}px;\n${n}${En.h}: ${Mn(t)}px;`, Pn = {
1971
1972
  authored: "--flemo-track",
1972
1973
  fix: "--flemo-track-fix"
1973
- }, Pn = `calc(var(${Nn.authored}) + var(${Nn.fix}))`, Fn = (e, t = " ") => `${t}${Nn.authored}: ${yn(e)}px;`, In = (e, t = " ") => `${t}${Nn.fix}: ${yn(e)}px;`, Ln = `var(${wn.x}) calc(var(${wn.y}) + var(${wn.lift}))`, Rn = (e, t, n = " ") => `${n}${wn.x}: ${yn(e)}px;\n${n}${wn.y}: ${yn(t)}px;`, zn = (e, t = " ") => `${t}${wn.lift}: ${yn(-e)}px;`, Bn = `translate3d(var(${Cn.x}), var(${Cn.y}), 0) scale(var(${Cn.scaleX}), var(${Cn.scaleY})) rotate(var(${Cn.rotate}))`, Vn = [
1974
+ }, Fn = `calc(var(${Pn.authored}) + var(${Pn.fix}))`, In = (e, t = " ") => `${t}${Pn.authored}: ${bn(e)}px;`, Ln = (e, t = " ") => `${t}${Pn.fix}: ${bn(e)}px;`, Rn = `var(${Tn.x}) calc(var(${Tn.y}) + var(${Tn.lift}))`, zn = (e, t, n = " ") => `${n}${Tn.x}: ${bn(e)}px;\n${n}${Tn.y}: ${bn(t)}px;`, Bn = (e, t = " ") => `${t}${Tn.lift}: ${bn(-e)}px;`, Vn = `translate3d(var(${wn.x}), var(${wn.y}), 0) scale(var(${wn.scaleX}), var(${wn.scaleY})) rotate(var(${wn.rotate}))`, Hn = [
1975
+ `@property ${Tn.x} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1976
+ `@property ${Tn.y} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1977
+ `@property ${Tn.lift} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1978
+ `@property ${En.w} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1979
+ `@property ${En.h} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1980
+ `@property ${Pn.authored} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1981
+ `@property ${Pn.fix} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1974
1982
  `@property ${wn.x} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1975
1983
  `@property ${wn.y} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1976
- `@property ${wn.lift} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1977
- `@property ${Tn.w} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1978
- `@property ${Tn.h} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1979
- `@property ${Nn.authored} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1980
- `@property ${Nn.fix} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1981
- `@property ${Cn.x} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1982
- `@property ${Cn.y} {\n syntax: "<length>";\n inherits: false;\n initial-value: 0px;\n}`,
1983
- `@property ${Cn.scaleX} {\n syntax: "<number>";\n inherits: false;\n initial-value: 1;\n}`,
1984
- `@property ${Cn.scaleY} {\n syntax: "<number>";\n inherits: false;\n initial-value: 1;\n}`,
1985
- `@property ${Cn.rotate} {\n syntax: "<angle>";\n inherits: false;\n initial-value: 0deg;\n}`
1986
- ], Hn = (e, t = " ") => [
1987
- `${t}${Cn.x}: ${yn(e.x)}px;`,
1988
- `${t}${Cn.y}: ${yn(e.y)}px;`,
1989
- `${t}${Cn.scaleX}: ${yn(e.scaleX)};`,
1990
- `${t}${Cn.scaleY}: ${yn(e.scaleY)};`,
1991
- `${t}${Cn.rotate}: ${yn(e.rotate)}deg;`
1992
- ].join("\n"), Un = (e) => ({
1984
+ `@property ${wn.scaleX} {\n syntax: "<number>";\n inherits: false;\n initial-value: 1;\n}`,
1985
+ `@property ${wn.scaleY} {\n syntax: "<number>";\n inherits: false;\n initial-value: 1;\n}`,
1986
+ `@property ${wn.rotate} {\n syntax: "<angle>";\n inherits: false;\n initial-value: 0deg;\n}`
1987
+ ], Un = (e, t = " ") => [
1988
+ `${t}${wn.x}: ${bn(e.x)}px;`,
1989
+ `${t}${wn.y}: ${bn(e.y)}px;`,
1990
+ `${t}${wn.scaleX}: ${bn(e.scaleX)};`,
1991
+ `${t}${wn.scaleY}: ${bn(e.scaleY)};`,
1992
+ `${t}${wn.rotate}: ${bn(e.rotate)}deg;`
1993
+ ].join("\n"), Wn = (e) => ({
1993
1994
  x: e.x + e.width / 2,
1994
1995
  y: e.y + e.height / 2
1995
- }), Wn = /^(-?[\d.]+)px$/, Gn = (e) => {
1996
+ }), Gn = /^(-?[\d.]+)px$/, Kn = (e) => {
1996
1997
  if (!e) return null;
1997
- let t = Wn.exec(e.trim());
1998
+ let t = Gn.exec(e.trim());
1998
1999
  if (!t) return null;
1999
2000
  let n = Number.parseFloat(t[1]);
2000
2001
  return Number.isFinite(n) ? n : null;
2001
- }, Kn = 1.35, qn = 1.6, Jn = (e, t, n) => {
2002
+ }, qn = 1.35, Jn = 1.6, Yn = (e, t, n) => {
2002
2003
  if (e <= 0) return !1;
2003
- let r = t ?? (n === null ? null : n * Kn);
2004
- return r === null || r <= 0 ? !1 : e <= r * qn;
2005
- }, Yn = /* @__PURE__ */ new Map(), Xn = () => typeof document > "u" ? "" : document.fonts?.status ?? "", Zn = (e) => [
2004
+ let r = t ?? (n === null ? null : n * qn);
2005
+ return r === null || r <= 0 ? !1 : e <= r * Jn;
2006
+ }, Xn = /* @__PURE__ */ new Map(), Zn = () => typeof document > "u" ? "" : document.fonts?.status ?? "", Qn = (e) => [
2006
2007
  e.fontFamily,
2007
2008
  e.fontSize,
2008
2009
  e.fontWeight,
2009
2010
  e.fontStyle,
2010
2011
  e.lineHeight,
2011
- Xn()
2012
- ].join("|"), Qn = (e, t, n) => {
2012
+ Zn()
2013
+ ].join("|"), $n = (e, t, n) => {
2013
2014
  if (!t || e.firstElementChild !== null) return null;
2014
2015
  let r = e.firstChild;
2015
2016
  if (!r || r.nodeType !== 3) return null;
2016
- let i = Zn(t), a = Yn.get(i);
2017
+ let i = Qn(t), a = Xn.get(i);
2017
2018
  if (a !== void 0) return a;
2018
2019
  /* v8 ignore next -- SSR; a jsdom host is covered through the range it does
2019
2020
  give, which carries no rects. */
@@ -2029,31 +2030,31 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2029
2030
  height: c.height,
2030
2031
  offset: c.top - n.y
2031
2032
  };
2032
- return Yn.set(i, u), u;
2033
- }, $n = (e, t, n, r) => e.firstElementChild === null && Jn(t.height, n, r), er = (e) => {
2034
- let t = e.getBoundingClientRect(), n = typeof getComputedStyle == "function" ? getComputedStyle(e) : null, r = n ? Number.parseFloat(n.fontSize) : NaN, i = n ? Number.parseFloat(n.fontWeight) : NaN, a = n?.aspectRatio, o = Gn(n?.lineHeight), s = {
2033
+ return Xn.set(i, u), u;
2034
+ }, er = (e, t, n, r) => e.firstElementChild === null && Yn(t.height, n, r), tr = (e) => {
2035
+ let t = e.getBoundingClientRect(), n = typeof getComputedStyle == "function" ? getComputedStyle(e) : null, r = n ? Number.parseFloat(n.fontSize) : NaN, i = n ? Number.parseFloat(n.fontWeight) : NaN, a = n?.aspectRatio, o = Kn(n?.lineHeight), s = {
2035
2036
  x: t.left,
2036
2037
  y: t.top,
2037
2038
  width: t.width,
2038
2039
  height: t.height
2039
- }, c = Qn(e, n, s), l = (e) => n ? `${n[`${e}Top`]} ${n[`${e}Right`]} ${n[`${e}Bottom`]} ${n[`${e}Left`]}` : "0px 0px 0px 0px";
2040
+ }, c = $n(e, n, s), l = (e) => n ? `${n[`${e}Top`]} ${n[`${e}Right`]} ${n[`${e}Bottom`]} ${n[`${e}Left`]}` : "0px 0px 0px 0px";
2040
2041
  return {
2041
2042
  rect: s,
2042
2043
  fontSize: Number.isFinite(r) ? r : null,
2043
2044
  fontWeight: Number.isFinite(i) ? i : null,
2044
- letterSpacing: Gn(n?.letterSpacing),
2045
- wordSpacing: Gn(n?.wordSpacing),
2045
+ letterSpacing: Kn(n?.letterSpacing),
2046
+ wordSpacing: Kn(n?.wordSpacing),
2046
2047
  lineHeight: o,
2047
2048
  aspectRatio: a && a !== "auto" ? a : null,
2048
2049
  padding: l("padding"),
2049
2050
  margin: l("margin"),
2050
- paint: fn(n),
2051
- singleLine: $n(e, s, o, Number.isFinite(r) ? r : null),
2051
+ paint: pn(n),
2052
+ singleLine: er(e, s, o, Number.isFinite(r) ? r : null),
2052
2053
  textHeight: c?.height ?? null,
2053
2054
  leadOffset: c?.offset ?? null
2054
2055
  };
2055
- }, tr = (e, t, n) => {
2056
- let r = t.scaleX === 0 ? 1 : t.scaleX, i = t.scaleY === 0 ? 1 : t.scaleY, a = Un(e), o = {
2056
+ }, nr = (e, t, n) => {
2057
+ let r = t.scaleX === 0 ? 1 : t.scaleX, i = t.scaleY === 0 ? 1 : t.scaleY, a = Wn(e), o = {
2057
2058
  x: n.x + (a.x - n.x - t.x) / r,
2058
2059
  y: n.y + (a.y - n.y - t.y) / i
2059
2060
  }, s = e.width / r, c = e.height / i;
@@ -2063,9 +2064,9 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2063
2064
  width: s,
2064
2065
  height: c
2065
2066
  };
2066
- }, nr = /^matrix\(([^)]+)\)$/, rr = /^translate(?:3d)?\(([^)]+)\)$/, ir = (e) => {
2067
+ }, rr = /^matrix\(([^)]+)\)$/, ir = /^translate(?:3d)?\(([^)]+)\)$/, ar = (e) => {
2067
2068
  if (typeof getComputedStyle != "function") return { ...Q };
2068
- let t = (getComputedStyle(e).transform ?? "").trim(), n = rr.exec(t);
2069
+ let t = (getComputedStyle(e).transform ?? "").trim(), n = ir.exec(t);
2069
2070
  if (n) {
2070
2071
  let [e, t] = n[1].split(",").map((e) => Number.parseFloat(e));
2071
2072
  return {
@@ -2076,7 +2077,7 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2076
2077
  rotate: 0
2077
2078
  };
2078
2079
  }
2079
- let r = nr.exec(t);
2080
+ let r = rr.exec(t);
2080
2081
  if (!r) return { ...Q };
2081
2082
  let i = r[1].split(",").map((e) => Number.parseFloat(e));
2082
2083
  return i.length < 6 || i.some((e) => !Number.isFinite(e)) ? { ...Q } : {
@@ -2086,15 +2087,15 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2086
2087
  scaleY: i[3],
2087
2088
  rotate: 0
2088
2089
  };
2089
- }, ar = (e, t) => {
2090
- let n = Un(e);
2090
+ }, or = (e, t) => {
2091
+ let n = Wn(e);
2091
2092
  return {
2092
2093
  x: n.x - t.x,
2093
2094
  y: n.y - t.y
2094
2095
  };
2095
- }, or = (e, t) => {
2096
+ }, sr = (e, t) => {
2096
2097
  if (t.width <= 0 || t.height <= 0) return { ...Q };
2097
- let n = Un(t), r = Un(e);
2098
+ let n = Wn(t), r = Wn(e);
2098
2099
  return {
2099
2100
  x: r.x - n.x,
2100
2101
  y: r.y - n.y,
@@ -2102,22 +2103,22 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2102
2103
  scaleY: e.height / t.height,
2103
2104
  rotate: 0
2104
2105
  };
2105
- }, sr = "--flemo-ride-y", cr = /^\s*(-?\d*\.?\d+)%\s*$/, lr = (e) => {
2106
+ }, cr = "--flemo-ride-y", lr = /^\s*(-?\d*\.?\d+)%\s*$/, ur = (e) => {
2106
2107
  if (typeof e != "string") return null;
2107
- let t = cr.exec(e);
2108
+ let t = lr.exec(e);
2108
2109
  if (!t) return null;
2109
2110
  let n = Number(t[1]) / 100;
2110
2111
  return Number.isFinite(n) ? n : null;
2111
- }, ur = (e) => {
2112
- let t = `var(${sr}, 100%)`;
2112
+ }, dr = (e) => {
2113
+ let t = `var(${cr}, 100%)`;
2113
2114
  return e === 1 ? t : e === -1 ? `calc(${t} * -1)` : `calc(${t} * ${e})`;
2114
- }, dr = (e, t) => {
2115
- let n = lr(e.y);
2115
+ }, fr = (e, t) => {
2116
+ let n = ur(e.y);
2116
2117
  return n === null || !(t > 0) ? e : {
2117
2118
  ...e,
2118
2119
  y: `${t * n}px`
2119
2120
  };
2120
- }, fr = je, pr = "translateZ(0.02px)", mr = "0.004", hr = (e) => e.replace(/[^a-zA-Z0-9_-]/g, "_"), gr = (e) => typeof e == "object" && !!e && !Array.isArray(e), _r = /* @__PURE__ */ new Set(/* @__PURE__ */ "opacity.scale.scaleX.scaleY.scaleZ.aspectRatio.columnCount.columns.flex.flexGrow.flexShrink.fontWeight.gridArea.gridColumn.gridColumnEnd.gridColumnStart.gridRow.gridRowEnd.gridRowStart.lineHeight.lineClamp.order.orphans.tabSize.widows.zIndex.zoom.fillOpacity.floodOpacity.stopOpacity.strokeOpacity.strokeDasharray.strokeDashoffset.strokeMiterlimit.strokeWidth".split(".")), vr = (e, t) => t.startsWith("--") || _r.has(t) ? `${e}` : t === "rotate" || t === "rotateX" || t === "rotateY" || t === "rotateZ" ? `${e}deg` : `${e}px`, yr = (e, t) => typeof t == "number" ? vr(t, e) : typeof t == "string" ? t : "", br = (e) => e.replace(/[A-Z]/g, (e) => `-${e.toLowerCase()}`), xr = /* @__PURE__ */ new Set([
2121
+ }, pr = je, mr = "translateZ(0.02px)", hr = "0.004", gr = (e) => e.replace(/[^a-zA-Z0-9_-]/g, "_"), _r = (e) => typeof e == "object" && !!e && !Array.isArray(e), vr = /* @__PURE__ */ new Set(/* @__PURE__ */ "opacity.scale.scaleX.scaleY.scaleZ.aspectRatio.columnCount.columns.flex.flexGrow.flexShrink.fontWeight.gridArea.gridColumn.gridColumnEnd.gridColumnStart.gridRow.gridRowEnd.gridRowStart.lineHeight.lineClamp.order.orphans.tabSize.widows.zIndex.zoom.fillOpacity.floodOpacity.stopOpacity.strokeOpacity.strokeDasharray.strokeDashoffset.strokeMiterlimit.strokeWidth".split(".")), yr = (e, t) => t.startsWith("--") || vr.has(t) ? `${e}` : t === "rotate" || t === "rotateX" || t === "rotateY" || t === "rotateZ" ? `${e}deg` : `${e}px`, br = (e, t) => typeof t == "number" ? yr(t, e) : typeof t == "string" ? t : "", xr = (e) => e.replace(/[A-Z]/g, (e) => `-${e.toLowerCase()}`), Sr = /* @__PURE__ */ new Set([
2121
2122
  "x",
2122
2123
  "y",
2123
2124
  "z",
@@ -2128,10 +2129,10 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2128
2129
  "rotateX",
2129
2130
  "rotateY",
2130
2131
  "rotateZ"
2131
- ]), Sr = /^-?0(\.0+)?(px|%|em|rem|vh|vw|vmin|vmax)?$/, Cr = /^-?0(\.0+)?(deg|rad|grad|turn)?$/, wr = /^1(\.0+)?$/, Tr = (e, t) => e === "scale" || e === "scaleX" || e === "scaleY" ? t === 1 || typeof t == "string" && wr.test(t.trim()) : e === "rotate" || e === "rotateX" || e === "rotateY" || e === "rotateZ" ? t === 0 || typeof t == "string" && Cr.test(t.trim()) : t === 0 || typeof t == "string" && Sr.test(t.trim()), Er = (e, t, n) => {
2132
+ ]), Cr = /^-?0(\.0+)?(px|%|em|rem|vh|vw|vmin|vmax)?$/, wr = /^-?0(\.0+)?(deg|rad|grad|turn)?$/, Tr = /^1(\.0+)?$/, Er = (e, t) => e === "scale" || e === "scaleX" || e === "scaleY" ? t === 1 || typeof t == "string" && Tr.test(t.trim()) : e === "rotate" || e === "rotateX" || e === "rotateY" || e === "rotateZ" ? t === 0 || typeof t == "string" && wr.test(t.trim()) : t === 0 || typeof t == "string" && Cr.test(t.trim()), Dr = (e, t, n) => {
2132
2133
  if (n && e === "y") {
2133
- let n = lr(t);
2134
- if (n !== null) return Er(e, ur(n), !1);
2134
+ let n = ur(t);
2135
+ if (n !== null) return Dr(e, dr(n), !1);
2135
2136
  }
2136
2137
  switch (e) {
2137
2138
  case "x": return `translate3d(${t}, 0, 0)`;
@@ -2146,17 +2147,17 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2146
2147
  case "rotateY": return `rotateY(${t})`;
2147
2148
  default: return "";
2148
2149
  }
2149
- }, Dr = (e) => {
2150
+ }, Or = (e) => {
2150
2151
  let t = /* @__PURE__ */ new Map(), n = !1, r = /* @__PURE__ */ new Set(), i = (e) => {
2151
- if (!gr(e)) return;
2152
+ if (!_r(e)) return;
2152
2153
  let n = [];
2153
2154
  for (let r of Object.keys(e)) {
2154
- let i = e[r], a = yr(r, i);
2155
+ let i = e[r], a = br(r, i);
2155
2156
  if (a !== "") {
2156
- if (xr.has(r)) n.push(`${r}:${a}`);
2157
+ if (Sr.has(r)) n.push(`${r}:${a}`);
2157
2158
  else {
2158
- let e = t.get(br(r)) ?? /* @__PURE__ */ new Set();
2159
- e.add(a), t.set(br(r), e);
2159
+ let e = t.get(xr(r)) ?? /* @__PURE__ */ new Set();
2160
+ e.add(a), t.set(xr(r), e);
2160
2161
  }
2161
2162
  }
2162
2163
  }
@@ -2167,13 +2168,13 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2167
2168
  n = r.size > 1;
2168
2169
  let a = Array.from(t.entries()).filter(([, e]) => e.size > 1).map(([e]) => e);
2169
2170
  return n && a.push("transform"), a;
2170
- }, Or = (e, t = !1) => {
2171
- if (!gr(e)) return [];
2171
+ }, kr = (e, t = !1) => {
2172
+ if (!_r(e)) return [];
2172
2173
  let n = [], r = !0, i = [];
2173
2174
  for (let a of Object.keys(e)) {
2174
- let o = e[a], s = yr(a, o);
2175
- s !== "" && (xr.has(a) ? (n.push(Er(a, s, t)), Tr(a, o) || (r = !1)) : i.push({
2176
- property: br(a),
2175
+ let o = e[a], s = br(a, o);
2176
+ s !== "" && (Sr.has(a) ? (n.push(Dr(a, s, t)), Er(a, o) || (r = !1)) : i.push({
2177
+ property: xr(a),
2177
2178
  value: s
2178
2179
  }));
2179
2180
  }
@@ -2181,11 +2182,11 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2181
2182
  property: "transform",
2182
2183
  value: r ? "none" : n.join(" ")
2183
2184
  }), i;
2184
- }, kr = (e) => e.map((e) => ` ${e.property}: ${e.value};`).join("\n"), Ar = (e, t) => {
2185
+ }, Ar = (e) => e.map((e) => ` ${e.property}: ${e.value};`).join("\n"), jr = (e, t) => {
2185
2186
  let n = new Map(e.map((e) => [e.property, e.value])), r = new Map(t.map((e) => [e.property, e.value]));
2186
2187
  for (let e of /* @__PURE__ */ new Set([...n.keys(), ...r.keys()])) if (n.get(e) !== r.get(e)) return !0;
2187
2188
  return !1;
2188
- }, jr = (e) => Array.isArray(e) ? e.length === 4 && e.every((e) => typeof e == "number") ? `cubic-bezier(${e.join(", ")})` : "linear" : typeof e == "string" ? {
2189
+ }, Mr = (e) => Array.isArray(e) ? e.length === 4 && e.every((e) => typeof e == "number") ? `cubic-bezier(${e.join(", ")})` : "linear" : typeof e == "string" ? {
2189
2190
  linear: "linear",
2190
2191
  easeIn: "ease-in",
2191
2192
  easeOut: "ease-out",
@@ -2195,22 +2196,22 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2195
2196
  backIn: "cubic-bezier(0.31, 0.01, 0.66, -0.59)",
2196
2197
  backOut: "cubic-bezier(0.33, 1.53, 0.69, 0.99)",
2197
2198
  anticipate: "cubic-bezier(0.36, 0, 0.66, -0.56)"
2198
- }[e] ?? "ease" : "ease", Mr = (e, t) => {
2199
+ }[e] ?? "ease" : "ease", Nr = (e, t) => {
2199
2200
  let [n, r] = t.split("-");
2200
2201
  return X($e) + Z(nt, e) + Z(et, n) + Z(tt, r);
2201
- }, Nr = (e, t, n) => {
2202
+ }, Pr = (e, t, n) => {
2202
2203
  let [r, i] = n.split("-");
2203
2204
  return X(pt) + Z(mt, t) + Z(nt, e) + Z(et, r) + Z(tt, i);
2204
- }, Pr = (e, t) => {
2205
+ }, Fr = (e, t) => {
2205
2206
  let [n, r] = t.split("-");
2206
2207
  return X(at) + Z(dt, e) + Z(st, n) + Z(ot, r) + Z(ct, "true");
2207
- }, Fr = (e, t, n) => {
2208
+ }, Ir = (e, t, n) => {
2208
2209
  let [r, i] = n.split("-");
2209
2210
  return X(e) + Z(nt, t) + Z(et, r) + Z(tt, i);
2210
- }, Ir = (e, t) => {
2211
+ }, Lr = (e, t) => {
2211
2212
  let [n, r] = t.split("-");
2212
2213
  return Z(J, e) + Z(et, n) + Z(tt, r);
2213
- }, Lr = (e, t, n) => Z(nt, e) + Ir(t, n), Rr = (e) => {
2214
+ }, Rr = (e, t, n) => Z(nt, e) + Lr(t, n), zr = (e) => {
2214
2215
  let t = /* @__PURE__ */ new Set(), n = "", r = 0;
2215
2216
  for (; r < e.length;) {
2216
2217
  let i = e.indexOf("@keyframes", r);
@@ -2236,26 +2237,26 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2236
2237
  n += e.slice(r, i), t.has(c) ? n = n.replace(/\n{2,}$/, "\n\n") : (t.add(c), n += c), r = s + 1;
2237
2238
  }
2238
2239
  return n;
2239
- }, zr = (e, t, n) => `flemo-${e}-${hr(t)}-${n}`, Br = (e, t, n) => zr("decorator", `${e}--${t}`, n), Vr = {
2240
+ }, Br = (e, t, n) => `flemo-${e}-${gr(t)}-${n}`, Vr = (e, t, n) => Br("decorator", `${e}--${t}`, n), Hr = {
2240
2241
  governed: "gov",
2241
2242
  desktop: "deskhead",
2242
2243
  creep: "govcreep",
2243
2244
  governedPark: "govpark",
2244
2245
  desktopPark: "deskpark"
2245
- }, Hr = Object.values(Vr).map((e) => `-${e}`), Ur = (e, t) => e === t || Hr.some((n) => e === `${t}${n}`), Wr = (e, t, n, r, i, a) => {
2246
- let o = Or(r), s = Or(i.value), c = new Set(o.filter((e) => s.some((t) => t.property === e.property && t.value === e.value)).map((e) => e.property)), l = o.filter((e) => c.has(e.property)), u = o.filter((e) => !c.has(e.property)), d = s.filter((e) => !c.has(e.property)), f = Me(i.options), p = Ne(i.options), m = jr(i.options?.ease), h = Or(r, !0), g = Or(i.value, !0), _ = h.filter((e) => !c.has(e.property)), v = g.filter((e) => !c.has(e.property)), y = (e, t) => kr(e) !== kr(t), b = e === "screen" && (y(h, o) || y(g, s)), x = a(t, n), S = Pr(t, n), C = e === "screen" ? [
2246
+ }, Ur = Object.values(Hr).map((e) => `-${e}`), Wr = (e, t) => e === t || Ur.some((n) => e === `${t}${n}`), Gr = (e, t, n, r, i, a) => {
2247
+ let o = kr(r), s = kr(i.value), c = new Set(o.filter((e) => s.some((t) => t.property === e.property && t.value === e.value)).map((e) => e.property)), l = o.filter((e) => c.has(e.property)), u = o.filter((e) => !c.has(e.property)), d = s.filter((e) => !c.has(e.property)), f = Me(i.options), p = Ne(i.options), m = Mr(i.options?.ease), h = kr(r, !0), g = kr(i.value, !0), _ = h.filter((e) => !c.has(e.property)), v = g.filter((e) => !c.has(e.property)), y = (e, t) => Ar(e) !== Ar(t), b = e === "screen" && (y(h, o) || y(g, s)), x = a(t, n), S = Fr(t, n), C = e === "screen" ? [
2247
2248
  x,
2248
2249
  ...b ? [] : [S],
2249
- Fr(gt, t, n),
2250
- Fr(_t, t, n)
2250
+ Ir(gt, t, n),
2251
+ Ir(_t, t, n)
2251
2252
  ].join(",\n") : x;
2252
2253
  if (s.length === 0 && o.length === 0) return "";
2253
- if (!Ar(o, s) || f <= 0 && p <= 0) {
2254
+ if (!jr(o, s) || f <= 0 && p <= 0) {
2254
2255
  if (s.length === 0) return "";
2255
- let e = `${C} {\n${kr(s)}\n animation: none;\n}`;
2256
- return b ? `${e}\n${S} {\n${kr(g)}\n animation: none;\n}` : e;
2256
+ let e = `${C} {\n${Ar(s)}\n animation: none;\n}`;
2257
+ return b ? `${e}\n${S} {\n${Ar(g)}\n animation: none;\n}` : e;
2257
2258
  }
2258
- let w = zr(e, t, n), T = {
2259
+ let w = Br(e, t, n), T = {
2259
2260
  selector: C,
2260
2261
  keyframe: w,
2261
2262
  fromDecls: u,
@@ -2268,10 +2269,10 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2268
2269
  }, D = (e) => [
2269
2270
  `@keyframes ${e.keyframe} {`,
2270
2271
  " from {",
2271
- kr(e.fromDecls).replace(/^/gm, " "),
2272
+ Ar(e.fromDecls).replace(/^/gm, " "),
2272
2273
  " }",
2273
2274
  " to {",
2274
- kr(e.toDecls).replace(/^/gm, " "),
2275
+ Ar(e.toDecls).replace(/^/gm, " "),
2275
2276
  " }",
2276
2277
  "}"
2277
2278
  ].join("\n"), O = D(T), k = (e) => [
@@ -2283,8 +2284,8 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2283
2284
  ].filter(Boolean).join(" "), A = (e) => e.startsWith("REPLACING") ? .18 : e.startsWith("PUSHING") ? .1 : e.startsWith("POPPING") ? .08 : 0, j = (e) => e.startsWith("REPLACING") || e.startsWith("PUSHING") ? .033 : e.startsWith("POPPING") ? .017 : 0, M = (e, t, n, r, i = T) => {
2284
2285
  if (n <= 0 || f <= 0 || o.length === 0 && s.length === 0) return "";
2285
2286
  let a = f + n, c = (n / a * 100).toFixed(3), l = `${i.keyframe}-${t}`, { fromDecls: u, toDecls: d } = i, m = i.selector.split(",\n").map((t) => `:root[${e}] ${t}`).join(",\n");
2286
- return `\n@keyframes ${l} {\n 0%, ${c}% {\n${kr(u).replace(/^/gm, " ")}\n }\n 100% {\n${kr(d).replace(/^/gm, " ")}\n }\n}\n${m} {\n animation-name: ${l};\n animation-duration: ${a.toFixed(3)}s;\n animation-delay: ${(r ? p + n : p).toFixed(3)}s;\n}`;
2287
- }, ee = n.startsWith("PUSHING") || n.startsWith("POPPING"), N = (e) => A(e), P = (t = T) => {
2287
+ return `\n@keyframes ${l} {\n 0%, ${c}% {\n${Ar(u).replace(/^/gm, " ")}\n }\n 100% {\n${Ar(d).replace(/^/gm, " ")}\n }\n}\n${m} {\n animation-name: ${l};\n animation-duration: ${a.toFixed(3)}s;\n animation-delay: ${(r ? p + n : p).toFixed(3)}s;\n}`;
2288
+ }, ee = n.startsWith("PUSHING") || n.startsWith("POPPING"), N = (e) => A(e), te = (t = T) => {
2288
2289
  /* v8 ignore next */
2289
2290
  if (e === "part") return "";
2290
2291
  let r = N(n);
@@ -2295,36 +2296,36 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2295
2296
  let e = t.fromDecls.find((e) => e.property === "transform");
2296
2297
  if (!e) return [...t.fromDecls, {
2297
2298
  property: "transform",
2298
- value: pr
2299
+ value: mr
2299
2300
  }];
2300
2301
  let n = e.value === "none" ? "" : `${e.value} `;
2301
2302
  return t.fromDecls.map((e) => e.property === "transform" ? {
2302
2303
  property: "transform",
2303
- value: `${n}${pr}`
2304
+ value: `${n}${mr}`
2304
2305
  } : e);
2305
- })(), a = f + r, c = (r / a * 100).toFixed(3), l = `${t.keyframe}-${Vr.creep}`, u = t.selector.split(",\n").map((e) => `:root${X(Ft)}${X(It)} ${e}`).join(",\n");
2306
- return `\n@keyframes ${l} {\n 0% {\n${kr(t.fromDecls).replace(/^/gm, " ")}\n }\n ${c}% {\n${kr(i).replace(/^/gm, " ")}\n }\n 100% {\n${kr(t.toDecls).replace(/^/gm, " ")}\n }\n}\n${u} {\n animation-name: ${l};\n animation-duration: ${a.toFixed(3)}s;\n animation-delay: ${(ee ? p + r : p).toFixed(3)}s;\n}`;
2307
- }, F = (e = T) => M(Ft, Vr.governed, N(n), ee, e) + P(e) + M(Lt, Vr.desktop, j(n), !1, e), te = new Map(u.map((e) => [e.property, e.value])), I = new Map(d.map((e) => [e.property, e.value])), ne = Array.from(/* @__PURE__ */ new Set([...te.keys(), ...I.keys()])).filter((e) => te.get(e) !== I.get(e)), L = e !== "part" && ne.length > 0 ? ` will-change: ${ne.join(", ")};\n` : "", re = n.split("-")[0], R = re === "PUSHING" || re === "REPLACING" ? " contain: layout;\n" : "", z = l.length > 0 ? `${kr(l)}\n` : "", ie = (e = T) => `${e.selector} {\n animation: ${k(e.keyframe)};\n${z}${L}${R}}`, B = e === "screen" && Gr(r) && s.length > 0, V = B && n.endsWith("-false"), H = B && n.endsWith("-true") && (re === "PUSHING" || re === "REPLACING"), U = V ? `\n${x}${Z(Y, jt.PARK)} {\n animation: none;\n${kr(s)}\n}` : "", ae = H ? `\n${x}${Z(Y, jt.PARK_UNDER)} {\n animation: none;\n${kr(s)}\n}` : "", oe = H ? `\n${x}${Z(Y, jt.PARK_OVER)} {\n animation: none;\n${kr(s)}\n opacity: ${mr};\n}` : "", W = (e, t, n, r) => {
2306
+ })(), a = f + r, c = (r / a * 100).toFixed(3), l = `${t.keyframe}-${Hr.creep}`, u = t.selector.split(",\n").map((e) => `:root${X(It)}${X(Lt)} ${e}`).join(",\n");
2307
+ return `\n@keyframes ${l} {\n 0% {\n${Ar(t.fromDecls).replace(/^/gm, " ")}\n }\n ${c}% {\n${Ar(i).replace(/^/gm, " ")}\n }\n 100% {\n${Ar(t.toDecls).replace(/^/gm, " ")}\n }\n}\n${u} {\n animation-name: ${l};\n animation-duration: ${a.toFixed(3)}s;\n animation-delay: ${(ee ? p + r : p).toFixed(3)}s;\n}`;
2308
+ }, P = (e = T) => M(It, Hr.governed, N(n), ee, e) + te(e) + M(Rt, Hr.desktop, j(n), !1, e), ne = new Map(u.map((e) => [e.property, e.value])), F = new Map(d.map((e) => [e.property, e.value])), re = Array.from(/* @__PURE__ */ new Set([...ne.keys(), ...F.keys()])).filter((e) => ne.get(e) !== F.get(e)), I = e !== "part" && re.length > 0 ? ` will-change: ${re.join(", ")};\n` : "", L = n.split("-")[0], R = L === "PUSHING" || L === "REPLACING" ? " contain: layout;\n" : "", z = l.length > 0 ? `${Ar(l)}\n` : "", ie = (e = T) => `${e.selector} {\n animation: ${k(e.keyframe)};\n${z}${I}${R}}`, B = e === "screen" && Kr(r) && s.length > 0, V = B && n.endsWith("-false"), H = B && n.endsWith("-true") && (L === "PUSHING" || L === "REPLACING"), U = V ? `\n${x}${Z(Y, Mt.PARK)} {\n animation: none;\n${Ar(s)}\n}` : "", ae = H ? `\n${x}${Z(Y, Mt.PARK_UNDER)} {\n animation: none;\n${Ar(s)}\n}` : "", oe = H ? `\n${x}${Z(Y, Mt.PARK_OVER)} {\n animation: none;\n${Ar(s)}\n opacity: ${hr};\n}` : "", W = (e, t, n, r) => {
2308
2309
  /* v8 ignore next -- every parking variant is a PUSHING/REPLACING/POPPING
2309
2310
  screen, so it has both a head and a duration; the guard mirrors
2310
2311
  headBlock's so a future caller cannot walk into a malformed keyframe. */
2311
2312
  if (!V && !H || n <= 0 || f <= 0) return "";
2312
- let i = f + n, a = n / i * 100, o = Math.min(.05, a / 4), s = `${w}-${t}`, c = H ? ` opacity: ${mr};` : "", l = [...u, ...d].some((e) => e.property === "opacity"), m = H && !l ? " opacity: 1;" : "", h = (e, t, n) => {
2313
- let r = n ? t.filter((e) => e.property !== "opacity") : t, i = [...r.length > 0 ? [kr(r).replace(/^/gm, " ")] : [], ...n ? [n] : []];
2313
+ let i = f + n, a = n / i * 100, o = Math.min(.05, a / 4), s = `${w}-${t}`, c = H ? ` opacity: ${hr};` : "", l = [...u, ...d].some((e) => e.property === "opacity"), m = H && !l ? " opacity: 1;" : "", h = (e, t, n) => {
2314
+ let r = n ? t.filter((e) => e.property !== "opacity") : t, i = [...r.length > 0 ? [Ar(r).replace(/^/gm, " ")] : [], ...n ? [n] : []];
2314
2315
  return ` ${e.toFixed(3)}% {\n${i.join("\n")}\n }`;
2315
2316
  };
2316
- return `\n@keyframes ${s} {\n${h(0, d, c)}\n${h(a - o, d, c)}\n${h(a, u, c)}\n` + (H ? `${h(a + o, u, m)}\n` : "") + `${h(100, d, m)}\n}\n:root${X(e)} ${x}${Z(Rt, "true")} {\n animation-name: ${s};\n animation-duration: ${i.toFixed(3)}s;\n animation-delay: ${(r ? p + n : p).toFixed(3)}s;\n` + (H ? ` will-change: ${[.../* @__PURE__ */ new Set([...ne, "opacity"])].join(", ")};\n` : "") + "}";
2317
- }, G = () => W(Ft, Vr.governedPark, A(n), ee) + W(Lt, Vr.desktopPark, j(n), !1), se = b ? `\n${D(E)}\n${ie(E)}${F(E)}` : "";
2318
- return `${O}\n${ie()}${F()}${G()}${U}${ae}${oe}${se}`;
2319
- }, Gr = (e) => {
2317
+ return `\n@keyframes ${s} {\n${h(0, d, c)}\n${h(a - o, d, c)}\n${h(a, u, c)}\n` + (H ? `${h(a + o, u, m)}\n` : "") + `${h(100, d, m)}\n}\n:root${X(e)} ${x}${Z(zt, "true")} {\n animation-name: ${s};\n animation-duration: ${i.toFixed(3)}s;\n animation-delay: ${(r ? p + n : p).toFixed(3)}s;\n` + (H ? ` will-change: ${[.../* @__PURE__ */ new Set([...re, "opacity"])].join(", ")};\n` : "") + "}";
2318
+ }, G = () => W(It, Hr.governedPark, A(n), ee) + W(Rt, Hr.desktopPark, j(n), !1), se = b ? `\n${D(E)}\n${ie(E)}${P(E)}` : "";
2319
+ return `${O}\n${ie()}${P()}${G()}${U}${ae}${oe}${se}`;
2320
+ }, Kr = (e) => {
2320
2321
  if (!e) return !1;
2321
2322
  if (e.opacity === 0) return !0;
2322
2323
  let t = (e) => typeof e == "string" && e.trim().endsWith("%") && Math.abs(parseFloat(e)) >= 100;
2323
2324
  return t(e.x) || t(e.y);
2324
- }, Kr = (e, t, n, r) => {
2325
- let i = Or(r.value);
2326
- return i.length === 0 ? "" : `${e(t, n)} {\n${kr(i)}\n}`;
2327
- }, qr = (e, t, n = []) => {
2325
+ }, qr = (e, t, n, r) => {
2326
+ let i = kr(r.value);
2327
+ return i.length === 0 ? "" : `${e(t, n)} {\n${Ar(i)}\n}`;
2328
+ }, Jr = (e, t, n = []) => {
2328
2329
  let r = [], i = [...e], a = /* @__PURE__ */ new Map();
2329
2330
  for (let e of t) a.set(e.name, e);
2330
2331
  for (let e of i) {
@@ -2332,92 +2333,92 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2332
2333
  for (let n of je) {
2333
2334
  let i = e.variants[n], a = Ae[n];
2334
2335
  if (a === "self") {
2335
- r.push(Kr(Mr, t, n, i));
2336
+ r.push(qr(Nr, t, n, i));
2336
2337
  continue;
2337
2338
  }
2338
2339
  let o = a === "initial" ? e.initial : e.variants[a].value;
2339
- r.push(Wr("screen", t, n, o, i, Mr));
2340
+ r.push(Gr("screen", t, n, o, i, Nr));
2340
2341
  }
2341
2342
  }
2342
2343
  for (let e of i) {
2343
2344
  if (!e.decoratorName) continue;
2344
2345
  let t = a.get(e.decoratorName);
2345
2346
  if (!t) continue;
2346
- let n = Fe(e, t), i = `${e.name}--${t.name}`, o = (n, r) => Nr(e.name, t.name, r);
2347
- for (let e of fr) {
2347
+ let n = Fe(e, t), i = `${e.name}--${t.name}`, o = (n, r) => Pr(e.name, t.name, r);
2348
+ for (let e of pr) {
2348
2349
  let t = n.variants[e], a = Ae[e];
2349
2350
  if (a === "self") {
2350
- r.push(Kr(o, i, e, t));
2351
+ r.push(qr(o, i, e, t));
2351
2352
  continue;
2352
2353
  }
2353
2354
  let s = a === "initial" ? n.initial : n.variants[a].value;
2354
- r.push(Wr("decorator", i, e, s, t, o));
2355
+ r.push(Gr("decorator", i, e, s, t, o));
2355
2356
  }
2356
2357
  }
2357
2358
  let o = [...n], s = /* @__PURE__ */ new Map();
2358
2359
  for (let e of o) {
2359
2360
  let t = e.name, n = Re(null, e);
2360
2361
  s.set(t, n);
2361
- for (let e of fr) {
2362
+ for (let e of pr) {
2362
2363
  let i = n.variants[e], a = Ae[e];
2363
2364
  if (a === "self") {
2364
- r.push(Kr(Ir, t, e, i));
2365
+ r.push(qr(Lr, t, e, i));
2365
2366
  continue;
2366
2367
  }
2367
2368
  let o = a === "initial" ? n.initial : n.variants[a].value;
2368
- r.push(Wr("part", t, e, o, i, Ir));
2369
+ r.push(Gr("part", t, e, o, i, Lr));
2369
2370
  }
2370
2371
  }
2371
2372
  for (let e of i) for (let t of o) {
2372
- let n = Re(e, t), i = s.get(t.name), a = (n, r) => Lr(e.name, t.name, r);
2373
- for (let e of fr) {
2373
+ let n = Re(e, t), i = s.get(t.name), a = (n, r) => Rr(e.name, t.name, r);
2374
+ for (let e of pr) {
2374
2375
  let o = n.variants[e], s = Ae[e], c = i?.variants[e];
2375
2376
  if (c && c.options?.duration === o.options?.duration && c.options?.delay === o.options?.delay) continue;
2376
2377
  if (s === "self") {
2377
- r.push(Kr(a, t.name, e, o));
2378
+ r.push(qr(a, t.name, e, o));
2378
2379
  continue;
2379
2380
  }
2380
2381
  let l = s === "initial" ? n.initial : n.variants[s].value;
2381
- r.push(Wr("part", t.name, e, l, o, a));
2382
+ r.push(Gr("part", t.name, e, l, o, a));
2382
2383
  }
2383
2384
  }
2384
- return Rr([
2385
+ return zr([
2385
2386
  ...r.filter((e) => e.length > 0),
2386
- Jr,
2387
- Yr
2387
+ Yr,
2388
+ Xr
2388
2389
  ].join("\n\n"));
2389
- }, Jr = [
2390
- [...Mt.map((e) => Z(Y, e)), ...Mt.flatMap((e) => [
2390
+ }, Yr = [
2391
+ [...Nt.map((e) => Z(Y, e)), ...Nt.flatMap((e) => [
2391
2392
  `${Z(Y, e)} ${X(J)}`,
2392
2393
  `${Z(Y, e)} ${X(St)}`,
2393
- `${Z(Y, e)} ${X(Ot)}`
2394
+ `${Z(Y, e)} ${X(kt)}`
2394
2395
  ])].join(",\n") + " {",
2395
2396
  " animation-play-state: paused !important;",
2396
2397
  "}"
2397
- ].join("\n"), Yr = [
2398
- `${X(Nt)} {`,
2398
+ ].join("\n"), Xr = [
2399
+ `${X(Pt)} {`,
2399
2400
  " display: none !important;",
2400
2401
  "}"
2401
- ].join("\n"), Xr = (e, t) => {
2402
+ ].join("\n"), Zr = (e, t) => {
2402
2403
  let n = Ae[t];
2403
2404
  if (n === "self") return !1;
2404
2405
  let r = e.variants[t], i = Me(r.options), a = Ne(r.options);
2405
- return i <= 0 && a <= 0 ? !1 : Ar(Or(n === "initial" ? e.initial : e.variants[n].value), Or(r.value));
2406
- }, Zr = {
2406
+ return i <= 0 && a <= 0 ? !1 : jr(kr(n === "initial" ? e.initial : e.variants[n].value), kr(r.value));
2407
+ }, Qr = {
2407
2408
  REPLACING: 33,
2408
2409
  PUSHING: 33,
2409
2410
  POPPING: 17
2410
- }, Qr = {
2411
+ }, $r = {
2411
2412
  REPLACING: 180,
2412
2413
  PUSHING: 100,
2413
2414
  POPPING: 80
2414
- }, $r = (e) => `${Math.round(e * 100) / 100}px`, ei = (e) => `${Number.parseFloat(e.toFixed(6)).toString()}px`, ti = (e) => `inset(${e.top.toFixed(2)}% ${e.right.toFixed(2)}% ${e.bottom.toFixed(2)}% ${e.left.toFixed(2)}%)`, ni = (e, t, n) => `${t ? "" : ` left: ${$r(e.x)};\n top: ${$r(e.y)};\n`}${n ? Mn(e.width, e.height) : ` width: ${$r(e.width)};\n height: ${$r(e.height)};`}`, ri = (e) => e.map((e) => ` ${e.property}: ${e.value};`).join("\n"), ii = (e) => Or(e ?? {}).filter((e) => e.property !== "transform"), ai = (e) => {
2415
- let { id: t, travel: n, fade: r, paint: i, box: a, fontSize: o, fontWeight: s, letterSpacing: c, wordSpacing: l, lineHeight: u, aspectRatio: d, padding: f, margin: p, size: m, clip: h, contentsHold: g = !1, radius: _, leading: v, leadStart: y, lift: b, track: x, pinned: S = !1, travelPinned: C = !1 } = e, w = [], T = [], E = jr(n.ease), D = Math.max(0, Math.min(n.head ?? 0, n.start)), O = n.duration + D, k = D > 0 ? D / O * 100 : 0, A = `${O.toFixed(3)}s`, j = (n.start - D).toFixed(3), M = (e) => D > 0 ? k + e / 100 * (n.duration / O) * 100 : e, ee = O > 0 ? Math.max(0, 100 - 1 / 60 * 100 / O) : 100, N = (e, t, n) => {
2415
+ }, ei = (e) => `${Math.round(e * 100) / 100}px`, ti = (e) => `${Number.parseFloat(e.toFixed(6)).toString()}px`, ni = (e) => `inset(${e.top.toFixed(2)}% ${e.right.toFixed(2)}% ${e.bottom.toFixed(2)}% ${e.left.toFixed(2)}%)`, ri = (e, t, n) => `${t ? "" : ` left: ${ei(e.x)};\n top: ${ei(e.y)};\n`}${n ? Nn(e.width, e.height) : ` width: ${ei(e.width)};\n height: ${ei(e.height)};`}`, ii = (e) => e.map((e) => ` ${e.property}: ${e.value};`).join("\n"), ai = (e) => kr(e ?? {}).filter((e) => e.property !== "transform"), oi = (e) => {
2416
+ let { id: t, travel: n, fade: r, paint: i, box: a, fontSize: o, fontWeight: s, letterSpacing: c, wordSpacing: l, lineHeight: u, aspectRatio: d, padding: f, margin: p, size: m, clip: h, contentsHold: g = !1, radius: _, leading: v, leadStart: y, lift: b, track: x, pinned: S = !1, travelPinned: C = !1 } = e, w = [], T = [], E = Mr(n.ease), D = Math.max(0, Math.min(n.head ?? 0, n.start)), O = n.duration + D, k = D > 0 ? D / O * 100 : 0, A = `${O.toFixed(3)}s`, j = (n.start - D).toFixed(3), M = (e) => D > 0 ? k + e / 100 * (n.duration / O) * 100 : e, ee = O > 0 ? Math.max(0, 100 - 1 / 60 * 100 / O) : 100, N = (e, t, n) => {
2416
2417
  let r = ee >= 99.999 ? ` 100% {\n${n}\n }` : ` ${ee.toFixed(3)}%, 100% {\n${n}\n }`;
2417
2418
  return D > 0 ? `@keyframes ${e} {\n 0%, ${k.toFixed(3)}% {\n${t}\n }\n${r}\n}` : `@keyframes ${e} {\n 0% {\n${t}\n }\n${r}\n}`;
2418
- }, P = `flemo-morph-${t}-travel`, F = [], te = [], I = v && v.length > 1 ? v : null, ne = !!(a || o || s || c || l || u || d || f || p || m || h), L = (e, t) => {
2419
- F.push(e), te.push(t);
2420
- }, re = null, R = xn([n.from, n.authoredFrom]), z = xn([n.to ?? Q, n.authoredTo]), ie = R.length <= 1 && z.length <= 1, B = C && ie, V = B && I && b && b.length > 1 ? b : null, H = C && x && x.length > 1 ? x : null, U = !!a && (B || !!H), ae = (e, t) => Math.abs(e - t) < .05, oe = !!(a && ie && !R[0] && !z[0] && ae(a.from.x + a.from.width, a.to.x + a.to.width) && !ae(a.from.x, a.to.x)), W = (e, t) => Math.abs(e - t) < .05, G = a && g && B && !h && !(W(a.from.width, a.to.width) && W(a.from.height, a.to.height)) ? (() => {
2419
+ }, te = `flemo-morph-${t}-travel`, P = [], ne = [], F = v && v.length > 1 ? v : null, re = !!(a || o || s || c || l || u || d || f || p || m || h), I = (e, t) => {
2420
+ P.push(e), ne.push(t);
2421
+ }, L = null, R = Sn([n.from, n.authoredFrom]), z = Sn([n.to ?? Q, n.authoredTo]), ie = R.length <= 1 && z.length <= 1, B = C && ie, V = B && F && b && b.length > 1 ? b : null, H = C && x && x.length > 1 ? x : null, U = !!a && (B || !!H), ae = (e, t) => Math.abs(e - t) < .05, oe = !!(a && ie && !R[0] && !z[0] && ae(a.from.x + a.from.width, a.to.x + a.to.width) && !ae(a.from.x, a.to.x)), W = (e, t) => Math.abs(e - t) < .05, G = a && g && B && !h && !(W(a.from.width, a.to.width) && W(a.from.height, a.to.height)) ? (() => {
2421
2422
  let e = Math.max(a.from.width, a.to.width), t = Math.max(a.from.height, a.to.height), n = (n) => {
2422
2423
  let r = ((e - n.width) / e * 100).toFixed(3), i = ((t - n.height) / t * 100).toFixed(3);
2423
2424
  return `0% ${oe ? "0.000" : r}% ${i}% ${oe ? r : "0.000"}%`;
@@ -2443,9 +2444,9 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2443
2444
  from: 0,
2444
2445
  to: 0
2445
2446
  };
2446
- I && y && (t.from += y);
2447
+ F && y && (t.from += y);
2447
2448
  let n = e("from", R, t.from), r = e("to", z, t.to);
2448
- F.push(Rn(n.x, n.y)), te.push(Rn(r.x, r.y));
2449
+ P.push(zn(n.x, n.y)), ne.push(zn(r.x, r.y));
2449
2450
  }
2450
2451
  if (a) {
2451
2452
  let e = G ? {
@@ -2453,64 +2454,64 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2453
2454
  width: G.width,
2454
2455
  height: G.height
2455
2456
  } : null;
2456
- F.push(ni(e ?? a.from, B, U)), te.push(ni(e ?? a.to, B, U));
2457
+ P.push(ri(e ?? a.from, B, U)), ne.push(ri(e ?? a.to, B, U));
2457
2458
  }
2458
- let se = S && !ne && ie, ce = (e) => B ? e.map((e) => ({
2459
+ let se = S && !re && ie, ce = (e) => B ? e.map((e) => ({
2459
2460
  ...e,
2460
2461
  x: 0,
2461
2462
  y: 0
2462
- })) : e, le = Sn(ce(R)), ue = Sn(ce(z)), de = null;
2463
- if ((le !== "none" || ue !== "none") && (se ? (de = Bn, F.push(Hn(ce(R)[0] ?? Q)), te.push(Hn(ce(z)[0] ?? Q))) : (F.push(` transform: ${le};`), te.push(` transform: ${ue};`))), o && L(` font-size: ${ei(o.from)};`, ` font-size: ${ei(o.to)};`), s && L(` font-weight: ${Math.round(s.from)};`, ` font-weight: ${Math.round(s.to)};`), H ? L(Fn(c ? c.from : 0), Fn(c ? c.to : 0)) : c && L(` letter-spacing: ${$r(c.from)};`, ` letter-spacing: ${$r(c.to)};`), l && L(` word-spacing: ${$r(l.from)};`, ` word-spacing: ${$r(l.to)};`), u && !I && L(` line-height: ${ei(u.from)};`, ` line-height: ${ei(u.to)};`), d && L(` aspect-ratio: ${d.from};`, ` aspect-ratio: ${d.to};`), f && L(` padding: ${f.from};`, ` padding: ${f.to};`), p && L(` margin: ${p.from};`, ` margin: ${p.to};`), m && (L(` width: ${$r(m.from.width)};`, ` width: ${$r(m.to.width)};`), L(` height: ${$r(m.from.height)};`, ` height: ${$r(m.to.height)};`)), h) L(` clip-path: ${ti(h.from)};`, ` clip-path: ${ti(h.to)};`);
2463
+ })) : e, le = Cn(ce(R)), ue = Cn(ce(z)), de = null;
2464
+ if ((le !== "none" || ue !== "none") && (se ? (de = Vn, P.push(Un(ce(R)[0] ?? Q)), ne.push(Un(ce(z)[0] ?? Q))) : (P.push(` transform: ${le};`), ne.push(` transform: ${ue};`))), o && I(` font-size: ${ti(o.from)};`, ` font-size: ${ti(o.to)};`), s && I(` font-weight: ${Math.round(s.from)};`, ` font-weight: ${Math.round(s.to)};`), H ? I(In(c ? c.from : 0), In(c ? c.to : 0)) : c && I(` letter-spacing: ${ei(c.from)};`, ` letter-spacing: ${ei(c.to)};`), l && I(` word-spacing: ${ei(l.from)};`, ` word-spacing: ${ei(l.to)};`), u && !F && I(` line-height: ${ti(u.from)};`, ` line-height: ${ti(u.to)};`), d && I(` aspect-ratio: ${d.from};`, ` aspect-ratio: ${d.to};`), f && I(` padding: ${f.from};`, ` padding: ${f.to};`), p && I(` margin: ${p.from};`, ` margin: ${p.to};`), m && (I(` width: ${ei(m.from.width)};`, ` width: ${ei(m.to.width)};`), I(` height: ${ei(m.from.height)};`, ` height: ${ei(m.to.height)};`)), h) I(` clip-path: ${ni(h.from)};`, ` clip-path: ${ni(h.to)};`);
2464
2465
  else if (G) {
2465
2466
  let e = _ && _ !== "0px" ? ` round ${_}` : "";
2466
- L(` clip-path: inset(${G.from}${e});`, ` clip-path: inset(${G.to}${e});`);
2467
+ I(` clip-path: inset(${G.from}${e});`, ` clip-path: inset(${G.to}${e});`);
2467
2468
  }
2468
- if (F.length > 0 && (w.push(N(P, F.join("\n"), te.join("\n"))), T.push(`${P} ${A} ${E} ${j}s both`), re = P), r && r.duration > 0) {
2469
- let e = ii(r.from), i = ii(r.to);
2469
+ if (P.length > 0 && (w.push(N(te, P.join("\n"), ne.join("\n"))), T.push(`${te} ${A} ${E} ${j}s both`), L = te), r && r.duration > 0) {
2470
+ let e = ai(r.from), i = ai(r.to);
2470
2471
  if (e.length > 0 || i.length > 0) {
2471
2472
  let a = `flemo-morph-${t}-fade`;
2472
- w.push(`@keyframes ${a} {\n from {\n${ri(e)}\n }\n to {\n${ri(i)}\n }\n}`);
2473
+ w.push(`@keyframes ${a} {\n from {\n${ii(e)}\n }\n to {\n${ii(i)}\n }\n}`);
2473
2474
  let o = (n.start + (r.delay ?? 0)).toFixed(3);
2474
2475
  T.push(`${a} ${r.duration.toFixed(3)}s ${r.easing ?? E} ${o}s both`);
2475
2476
  }
2476
2477
  }
2477
- if (I) {
2478
- let e = `flemo-morph-${t}-lead`, n = O > 0 ? Math.max(0, 100 - 1 / 60 * 100 / O) : 100, r = I.map((e, t) => t === I.length - 1 ? {
2478
+ if (F) {
2479
+ let e = `flemo-morph-${t}-lead`, n = O > 0 ? Math.max(0, 100 - 1 / 60 * 100 / O) : 100, r = F.map((e, t) => t === F.length - 1 ? {
2479
2480
  ...e,
2480
2481
  at: Math.min(M(e.at), n)
2481
2482
  } : {
2482
2483
  ...e,
2483
2484
  at: M(e.at)
2484
- }).map((e) => ` ${e.at.toFixed(4)}% {\n line-height: ${ei(e.lineHeight)};\n animation-timing-function: steps(1, end);\n }`).join("\n");
2485
+ }).map((e) => ` ${e.at.toFixed(4)}% {\n line-height: ${ti(e.lineHeight)};\n animation-timing-function: steps(1, end);\n }`).join("\n");
2485
2486
  w.push(`@keyframes ${e} {\n${r}\n}`), T.push(`${e} ${A} linear ${j}s both`);
2486
2487
  }
2487
2488
  if (V) {
2488
- let e = `flemo-morph-${t}-lift`, n = (k > 0 ? ` 0% {\n${zn(V[0].ascent)}\n animation-timing-function: steps(1, end);\n }\n` : "") + V.map((e, t) => ` ${(t === V.length - 1 ? Math.min(M(e.at), ee) : M(e.at)).toFixed(4)}% {\n${zn(e.ascent)}\n animation-timing-function: steps(1, end);\n }`).join("\n");
2489
+ let e = `flemo-morph-${t}-lift`, n = (k > 0 ? ` 0% {\n${Bn(V[0].ascent)}\n animation-timing-function: steps(1, end);\n }\n` : "") + V.map((e, t) => ` ${(t === V.length - 1 ? Math.min(M(e.at), ee) : M(e.at)).toFixed(4)}% {\n${Bn(e.ascent)}\n animation-timing-function: steps(1, end);\n }`).join("\n");
2489
2490
  w.push(`@keyframes ${e} {\n${n}\n}`), T.push(`${e} ${A} linear ${j}s both`);
2490
2491
  }
2491
2492
  if (H) {
2492
- let e = `flemo-morph-${t}-track`, n = H.map((e, t, n) => ` ${(t === n.length - 1 ? Math.min(M(e.at), ee) : M(e.at)).toFixed(4)}% {\n${In(e.fix)}\n }`).join("\n");
2493
+ let e = `flemo-morph-${t}-track`, n = H.map((e, t, n) => ` ${(t === n.length - 1 ? Math.min(M(e.at), ee) : M(e.at)).toFixed(4)}% {\n${Ln(e.fix)}\n }`).join("\n");
2493
2494
  w.push(`@keyframes ${e} {\n${n}\n}`), T.push(`${e} ${A} linear ${j}s both`);
2494
2495
  }
2495
2496
  if (i.length > 0) {
2496
2497
  let e = `flemo-morph-${t}-paint`, n = i.map((e) => ` ${e.property}: ${e.from};`).join("\n"), r = i.map((e) => ` ${e.property}: ${e.to};`).join("\n");
2497
- w.push(N(e, n, r)), T.push(`${e} ${A} ${E} ${j}s both`), re ??= e;
2498
+ w.push(N(e, n, r)), T.push(`${e} ${A} ${E} ${j}s both`), L ??= e;
2498
2499
  }
2499
2500
  return {
2500
2501
  rules: w,
2501
2502
  animation: T.join(", "),
2502
- geometryName: re ?? P,
2503
- geometryAccelerated: !ne && de === null,
2503
+ geometryName: L ?? te,
2504
+ geometryAccelerated: !re && de === null,
2504
2505
  transform: de,
2505
- translate: B ? Ln : null,
2506
+ translate: B ? Rn : null,
2506
2507
  size: U ? {
2507
- width: Dn,
2508
- height: On
2508
+ width: On,
2509
+ height: kn
2509
2510
  } : null,
2510
- heldEdge: B && oe && a ? An(a.to.x + a.to.width) : null,
2511
- letterSpacing: H ? Pn : null
2511
+ heldEdge: B && oe && a ? jn(a.to.x + a.to.width) : null,
2512
+ letterSpacing: H ? Fn : null
2512
2513
  };
2513
- }, oi = (e) => {
2514
+ }, si = (e) => {
2514
2515
  let { id: t, origin: n, small: r, big: i, settling: a, duration: o, start: s, ease: c, selector: l, accelerated: u } = e, d = Math.max(0, Math.min(e.head ?? 0, s)), f = o + d, p = d > 0 ? d / f * 100 : 0, m = s - d, h = r.width > 0 ? i.width / r.width : 1, g = (e) => ({
2515
2516
  x: e.x + e.width / 2,
2516
2517
  y: e.y + e.height / 2
@@ -2522,21 +2523,21 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2522
2523
  rotate: 0
2523
2524
  }, C = (e) => {
2524
2525
  let t = e ? Q : S;
2525
- return u ? ` transform: ${e ? "none" : `translate(${$r(t.x)}, ${$r(t.y)}) scale(${x})`};` : Hn(t);
2526
+ return u ? ` transform: ${e ? "none" : `translate(${ei(t.x)}, ${ei(t.y)}) scale(${x})`};` : Un(t);
2526
2527
  }, w = `flemo-morph-${t}-camera`, T = f > 0 ? Math.max(0, 100 - 1 / 60 * 100 / f) : 100, E = T >= 99.999 ? ` 100% {\n${C(a)}\n }` : ` ${T.toFixed(3)}%, 100% {\n${C(a)}\n }`;
2527
2528
  return {
2528
- rules: [d > 0 ? `@keyframes ${w} {\n 0%, ${p.toFixed(3)}% {\n${C(!a)}\n }\n${E}\n}` : `@keyframes ${w} {\n 0% {\n${C(!a)}\n }\n${E}\n}`, `${l} {\n${u ? "" : ` transform: ${Bn} !important;\n`} animation-name: ${w} !important;\n animation-duration: ${f.toFixed(3)}s !important;\n animation-timing-function: ${jr(c)} !important;\n animation-delay: ${m.toFixed(3)}s !important;\n animation-fill-mode: both !important;\n}`],
2529
+ rules: [d > 0 ? `@keyframes ${w} {\n 0%, ${p.toFixed(3)}% {\n${C(!a)}\n }\n${E}\n}` : `@keyframes ${w} {\n 0% {\n${C(!a)}\n }\n${E}\n}`, `${l} {\n${u ? "" : ` transform: ${Vn} !important;\n`} animation-name: ${w} !important;\n animation-duration: ${f.toFixed(3)}s !important;\n animation-timing-function: ${Mr(c)} !important;\n animation-delay: ${m.toFixed(3)}s !important;\n animation-fill-mode: both !important;\n}`],
2529
2530
  name: w
2530
2531
  };
2531
- }, si = /* @__PURE__ */ new WeakMap(), ci = (e, t) => {
2532
- t ? si.set(e, t) : si.delete(e);
2533
- }, li = (e) => {
2532
+ }, ci = /* @__PURE__ */ new WeakMap(), li = (e, t) => {
2533
+ t ? ci.set(e, t) : ci.delete(e);
2534
+ }, ui = (e) => {
2534
2535
  if (p()) return null;
2535
- let t = si.get(e);
2536
+ let t = ci.get(e);
2536
2537
  if (t?.isConnected) return t;
2537
- let n = document.body.querySelector(`:scope > [${Tt}]`);
2538
- return n || (n = document.createElement("div"), n.setAttribute(Tt, ""), document.body.appendChild(n)), n;
2539
- }, ui = (e, t, n, r) => {
2538
+ let n = document.body.querySelector(`:scope > [${Et}]`);
2539
+ return n || (n = document.createElement("div"), n.setAttribute(Et, ""), document.body.appendChild(n)), n;
2540
+ }, di = (e, t, n, r) => {
2540
2541
  let i = (t) => 3 * (1 - t) * (1 - t) * t * e + 3 * (1 - t) * t * t * n + t ** 3, a = (e) => 3 * (1 - e) * (1 - e) * e * t + 3 * (1 - e) * e * e * r + e ** 3;
2541
2542
  return (e) => {
2542
2543
  if (e <= 0) return 0;
@@ -2548,8 +2549,8 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2548
2549
  }
2549
2550
  return a((t + n) / 2);
2550
2551
  };
2551
- }, di = (e) => {
2552
- let t = mi(e);
2552
+ }, fi = (e) => {
2553
+ let t = hi(e);
2553
2554
  if (!t) return (e) => e;
2554
2555
  let [n, r, i, a] = t, o = (e) => 3 * (1 - e) * (1 - e) * e * n + 3 * (1 - e) * e * e * i + e ** 3, s = (e) => 3 * (1 - e) * (1 - e) * e * r + 3 * (1 - e) * e * e * a + e ** 3;
2555
2556
  return (e) => {
@@ -2562,7 +2563,7 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2562
2563
  }
2563
2564
  return o((t + n) / 2);
2564
2565
  };
2565
- }, fi = (e) => e, pi = {
2566
+ }, pi = (e) => e, mi = {
2566
2567
  ease: [
2567
2568
  .25,
2568
2569
  .1,
@@ -2617,47 +2618,47 @@ var Qt = (e) => e !== "" && e !== "visible", $t = (e) => {
2617
2618
  .66,
2618
2619
  -.56
2619
2620
  ]
2620
- }, mi = (e) => Array.isArray(e) ? e.length === 4 && e.every((e) => typeof e == "number") ? [...e] : null : typeof e == "string" ? e === "linear" ? null : [...pi[e] ?? pi.ease] : [...pi.ease], hi = (e) => {
2621
+ }, hi = (e) => Array.isArray(e) ? e.length === 4 && e.every((e) => typeof e == "number") ? [...e] : null : typeof e == "string" ? e === "linear" ? null : [...mi[e] ?? mi.ease] : [...mi.ease], gi = (e) => {
2621
2622
  if (Array.isArray(e)) {
2622
2623
  if (e.length === 4 && e.every((e) => typeof e == "number")) {
2623
2624
  let [t, n, r, i] = e;
2624
- return ui(t, n, r, i);
2625
+ return di(t, n, r, i);
2625
2626
  }
2626
- return fi;
2627
+ return pi;
2627
2628
  }
2628
- return typeof e == "string" ? e === "linear" ? fi : ui(...pi[e] ?? pi.ease) : ui(...pi.ease);
2629
- }, gi = 1e4, _i = {
2629
+ return typeof e == "string" ? e === "linear" ? pi : di(...mi[e] ?? mi.ease) : di(...mi.ease);
2630
+ }, _i = 1e4, vi = {
2630
2631
  low: .6,
2631
2632
  high: 2.5
2632
- }, vi = /* @__PURE__ */ new Map(), yi = () => typeof document > "u" ? "" : document.fonts?.status ?? "", bi = (e) => {
2633
- let t = `${e.style}|${e.weight}|${e.family}|${yi()}`, n = vi.get(t);
2633
+ }, yi = /* @__PURE__ */ new Map(), bi = () => typeof document > "u" ? "" : document.fonts?.status ?? "", xi = (e) => {
2634
+ let t = `${e.style}|${e.weight}|${e.family}|${bi()}`, n = yi.get(t);
2634
2635
  if (n !== void 0) return n;
2635
- let r = Ci(t, e);
2636
- return vi.set(t, r), r;
2637
- }, xi, Si = () => (xi === void 0 &&
2636
+ let r = wi(t, e);
2637
+ return yi.set(t, r), r;
2638
+ }, Si, Ci = () => (Si === void 0 &&
2638
2639
  /* v8 ignore next 3 -- SSR, and a host with no canvas: neither has a line
2639
2640
  box to correct in the first place. */
2640
- (xi = typeof document > "u" || typeof document.createElement != "function" ? null : document.createElement("canvas")), xi ? xi.getContext("2d") : null), Ci = (e, t) => {
2641
- let n = Si();
2641
+ (Si = typeof document > "u" || typeof document.createElement != "function" ? null : document.createElement("canvas")), Si ? Si.getContext("2d") : null), wi = (e, t) => {
2642
+ let n = Ci();
2642
2643
  if (!n) return null;
2643
2644
  try {
2644
- n.font = `${t.style} ${t.weight} ${gi}px ${t.family}`;
2645
+ n.font = `${t.style} ${t.weight} ${_i}px ${t.family}`;
2645
2646
  let e = n.measureText(""), r = e.fontBoundingBoxAscent, i = e.fontBoundingBoxDescent;
2646
2647
  if (typeof r != "number" || typeof i != "number" || !(r > 0) || !(i >= 0)) return null;
2647
2648
  let a = {
2648
- ascent: r / gi,
2649
- descent: i / gi
2649
+ ascent: r / _i,
2650
+ descent: i / _i
2650
2651
  }, o = a.ascent + a.descent;
2651
- return o < _i.low || o > _i.high ? null : a;
2652
+ return o < vi.low || o > vi.high ? null : a;
2652
2653
  } catch {
2653
- return vi.set(e, null), null;
2654
+ return yi.set(e, null), null;
2654
2655
  }
2655
- }, wi = () => {
2656
+ }, Ti = () => {
2656
2657
  /* v8 ignore next -- SSR: nothing is rendered, so nothing is on a grid. */
2657
2658
  let e = typeof window > "u" ? 1 : window.devicePixelRatio;
2658
2659
  return typeof e == "number" && e > 1 ? [1, e] : [1];
2659
- }, Ti = (e, t, n) => {
2660
- let r = Si();
2660
+ }, Ei = (e, t, n) => {
2661
+ let r = Ci();
2661
2662
  if (!r) return null;
2662
2663
  try {
2663
2664
  r.font = `${t.style} ${t.weight} ${e * n}px ${t.family}`;
@@ -2669,8 +2670,8 @@ box to correct in the first place. */
2669
2670
  } catch {
2670
2671
  return null;
2671
2672
  }
2672
- }, Ei = (e, t, n) => {
2673
- let r = Si();
2673
+ }, Di = (e, t, n) => {
2674
+ let r = Ci();
2674
2675
  if (!r) return null;
2675
2676
  try {
2676
2677
  r.font = `${n.style} ${n.weight} ${t}px ${n.family}`;
@@ -2679,44 +2680,44 @@ box to correct in the first place. */
2679
2680
  } catch {
2680
2681
  return null;
2681
2682
  }
2682
- }, Di = (e, t) => Oi(e, t), Oi = (e, t) => e.ascent === t.ascent && e.descent === t.descent, ki = {
2683
+ }, Oi = (e, t) => ki(e, t), ki = (e, t) => e.ascent === t.ascent && e.descent === t.descent, Ai = {
2683
2684
  whiteSpace: "nowrap",
2684
2685
  overflow: "hidden",
2685
2686
  textOverflow: "ellipsis"
2686
- }, Ai = (e) => {
2687
- e.style.whiteSpace = ki.whiteSpace, e.style.overflow = ki.overflow, e.style.textOverflow = ki.textOverflow;
2688
- }, ji = (e, t) => e && t, Mi = () => {
2687
+ }, ji = (e) => {
2688
+ e.style.whiteSpace = Ai.whiteSpace, e.style.overflow = Ai.overflow, e.style.textOverflow = Ai.textOverflow;
2689
+ }, Mi = (e, t) => e && t, Ni = () => {
2689
2690
  /* v8 ignore next -- SSR: nothing is rendered, so nothing is on a grid. */
2690
2691
  let e = typeof window > "u" ? 1 : window.devicePixelRatio, t = typeof e == "number" && e > 0 ? 1 / e : 1;
2691
2692
  return t === 1 ? [1] : [1, t];
2692
- }, Ni = (e, t) => Math.floor(e / t + 1e-6) * t, Pi = .001, Fi = (e, t, n) => {
2693
+ }, Pi = (e, t) => Math.floor(e / t + 1e-6) * t, Fi = .001, Ii = (e, t, n) => {
2693
2694
  if (n === null || e.lineHeight === null || e.textHeight === null) return 0;
2694
2695
  let r = (e.lineHeight - e.textHeight) / 2, i = (n[0].lineHeight - e.textHeight) / 2;
2695
2696
  if (e.leadOffset === null || t.leadOffset === null || t.lineHeight === null || t.textHeight === null) return r - i;
2696
- let a = Mi().find((n) => Math.abs(Ni(r, n) - e.leadOffset) < Pi && Math.abs(Ni((t.lineHeight - t.textHeight) / 2, n) - t.leadOffset) < Pi);
2697
- return a === void 0 ? r - i : Ni(r, a) - Ni(i, a);
2698
- }, Ii = (e, t) => {
2697
+ let a = Ni().find((n) => Math.abs(Pi(r, n) - e.leadOffset) < Fi && Math.abs(Pi((t.lineHeight - t.textHeight) / 2, n) - t.leadOffset) < Fi);
2698
+ return a === void 0 ? r - i : Pi(r, a) - Pi(i, a);
2699
+ }, Li = (e, t) => {
2699
2700
  let n = (e) => e.lineHeight === null || e.textHeight === null ? null : (e.lineHeight - e.textHeight) / 2, r = [n(e), n(t)];
2700
2701
  if (r[0] === null || r[1] === null || e.leadOffset === null || t.leadOffset === null) return 0;
2701
- let i = Mi().find((n) => Math.abs(Ni(r[0], n) - e.leadOffset) < Pi && Math.abs(Ni(r[1], n) - t.leadOffset) < Pi);
2702
+ let i = Ni().find((n) => Math.abs(Pi(r[0], n) - e.leadOffset) < Fi && Math.abs(Pi(r[1], n) - t.leadOffset) < Fi);
2702
2703
  if (i === void 0) return 0;
2703
2704
  let a = Math.min(r[0], r[1]), o = Math.max(r[0], r[1]);
2704
2705
  return o - a >= i ? 0 : (t.leadOffset + i / 2 - (a + o) / 2) * 2;
2705
- }, Li = 1e-6, Ri = .001, zi = /* @__PURE__ */ new Map(), Bi = /* @__PURE__ */ new Map(), Vi = (e, t) => {
2706
- if (Bi.has(e)) return Bi.get(e);
2706
+ }, Ri = 1e-6, zi = .001, Bi = /* @__PURE__ */ new Map(), Vi = /* @__PURE__ */ new Map(), Hi = (e, t) => {
2707
+ if (Vi.has(e)) return Vi.get(e);
2707
2708
  let n = t();
2708
- return Bi.size > 512 && Bi.clear(), Bi.set(e, n), n;
2709
- }, Hi = (e) => e ? `${e.family}|${e.weight}|${e.style}` : "none", Ui = (e, t, n, r) => !n || e.fontSize === null || t.fontSize === null || e.lineHeight === null || t.lineHeight === null || e.textHeight === null || t.textHeight === null || Math.abs(e.fontSize - t.fontSize) < Li ? null : Vi(`lead|${Hi(n)}|${e.fontSize},${e.lineHeight},${e.textHeight}>${t.fontSize},${t.lineHeight},${t.textHeight}|${String(r)}`, () => Wi(e, t, n, r)), Wi = (e, t, n, r) => {
2710
- let i = `${n.style}|${n.weight}|${n.family}|${e.fontSize}|${t.fontSize}|${e.lineHeight}|${t.lineHeight}|${e.textHeight}|${t.textHeight}|${JSON.stringify(r ?? null)}`, a = zi.get(i);
2709
+ return Vi.size > 512 && Vi.clear(), Vi.set(e, n), n;
2710
+ }, Ui = (e) => e ? `${e.family}|${e.weight}|${e.style}` : "none", Wi = (e, t, n, r) => !n || e.fontSize === null || t.fontSize === null || e.lineHeight === null || t.lineHeight === null || e.textHeight === null || t.textHeight === null || Math.abs(e.fontSize - t.fontSize) < Ri ? null : Hi(`lead|${Ui(n)}|${e.fontSize},${e.lineHeight},${e.textHeight}>${t.fontSize},${t.lineHeight},${t.textHeight}|${String(r)}`, () => Gi(e, t, n, r)), Gi = (e, t, n, r) => {
2711
+ let i = `${n.style}|${n.weight}|${n.family}|${e.fontSize}|${t.fontSize}|${e.lineHeight}|${t.lineHeight}|${e.textHeight}|${t.textHeight}|${JSON.stringify(r ?? null)}`, a = Bi.get(i);
2711
2712
  if (a !== void 0) return a;
2712
- let o = Gi(e, t, n, r);
2713
- return zi.set(i, o), o;
2714
- }, Gi = (e, t, n, r) => {
2715
- if (!bi(n)) return null;
2713
+ let o = Ki(e, t, n, r);
2714
+ return Bi.set(i, o), o;
2715
+ }, Ki = (e, t, n, r) => {
2716
+ if (!xi(n)) return null;
2716
2717
  let i = null;
2717
- for (let r of wi()) {
2718
- let a = Ti(e.fontSize, n, r), o = Ti(t.fontSize, n, r);
2719
- if (a !== null && o !== null && !(!Ki(a, e.textHeight) || !Ki(o, t.textHeight))) {
2718
+ for (let r of Ti()) {
2719
+ let a = Ei(e.fontSize, n, r), o = Ei(t.fontSize, n, r);
2720
+ if (a !== null && o !== null && !(!qi(a, e.textHeight) || !qi(o, t.textHeight))) {
2720
2721
  i = {
2721
2722
  scale: r,
2722
2723
  ends: [a, o]
@@ -2725,13 +2726,13 @@ box to correct in the first place. */
2725
2726
  }
2726
2727
  }
2727
2728
  if (i === null) return null;
2728
- let { scale: a, ends: o } = i, s = t.lineHeight - t.textHeight, c = hi(r), l = t.fontSize - e.fontSize, u = (t) => Ti(e.fontSize + l * c(t), n, a), d = [{
2729
+ let { scale: a, ends: o } = i, s = t.lineHeight - t.textHeight, c = gi(r), l = t.fontSize - e.fontSize, u = (t) => Ei(e.fontSize + l * c(t), n, a), d = [{
2729
2730
  at: 0,
2730
2731
  lineHeight: e.textHeight + s,
2731
2732
  ascent: o[0].ascent
2732
2733
  }], f = (e, t, n, r) => {
2733
- if (Di(n, r)) return;
2734
- if (t - e <= Ri) {
2734
+ if (Oi(n, r)) return;
2735
+ if (t - e <= zi) {
2735
2736
  d.push({
2736
2737
  at: t * 100,
2737
2738
  lineHeight: r.ascent + r.descent + s,
@@ -2754,20 +2755,20 @@ box to correct in the first place. */
2754
2755
  lineHeight: t.lineHeight,
2755
2756
  ascent: o[1].ascent
2756
2757
  }), m.length > 2 ? m : null;
2757
- }, Ki = (e, t) => Math.abs(e.ascent + e.descent - t) < Li, qi = 16, Ji = .5, Yi = (e, t, n, r, i) => !r || t.fontSize === null || n.fontSize === null ? null : Vi(`track|${Hi(r)}|${e.length}:${e.slice(0, 24)}|${t.fontSize}>${n.fontSize}|${String(i)}`, () => Xi(e, t, n, r, i)), Xi = (e, t, n, r, i) => {
2758
- if (t.fontSize === null || n.fontSize === null || Math.abs(t.fontSize - n.fontSize) < Li) return null;
2758
+ }, qi = (e, t) => Math.abs(e.ascent + e.descent - t) < Ri, Ji = 16, Yi = .5, Xi = (e, t, n, r, i) => !r || t.fontSize === null || n.fontSize === null ? null : Hi(`track|${Ui(r)}|${e.length}:${e.slice(0, 24)}|${t.fontSize}>${n.fontSize}|${String(i)}`, () => Zi(e, t, n, r, i)), Zi = (e, t, n, r, i) => {
2759
+ if (t.fontSize === null || n.fontSize === null || Math.abs(t.fontSize - n.fontSize) < Ri) return null;
2759
2760
  let a = [...e].length - 1;
2760
2761
  if (a < 1) return null;
2761
- let o = `${r.style}|${r.weight}|${r.family}|${t.fontSize}|${n.fontSize}|${e}|${JSON.stringify(i ?? null)}`, s = Zi.get(o);
2762
+ let o = `${r.style}|${r.weight}|${r.family}|${t.fontSize}|${n.fontSize}|${e}|${JSON.stringify(i ?? null)}`, s = Qi.get(o);
2762
2763
  if (s !== void 0) return s;
2763
- let c = Qi(e, t.fontSize, n.fontSize, a, r, i);
2764
- return Zi.set(o, c), c;
2765
- }, Zi = /* @__PURE__ */ new Map(), Qi = (e, t, n, r, i, a) => {
2766
- let o = [Ei(e, t, i), Ei(e, n, i)];
2764
+ let c = $i(e, t.fontSize, n.fontSize, a, r, i);
2765
+ return Qi.set(o, c), c;
2766
+ }, Qi = /* @__PURE__ */ new Map(), $i = (e, t, n, r, i, a) => {
2767
+ let o = [Di(e, t, i), Di(e, n, i)];
2767
2768
  if (o[0] === null || o[1] === null) return null;
2768
- let s = di(a), c = n - t, l = [];
2769
- for (let n = 0; n <= qi; n += 1) {
2770
- let a = n / qi, u = Ei(e, t + c * a, i);
2769
+ let s = fi(a), c = n - t, l = [];
2770
+ for (let n = 0; n <= Ji; n += 1) {
2771
+ let a = n / Ji, u = Di(e, t + c * a, i);
2771
2772
  /* v8 ignore next -- the ends above already refused a face with no metrics. */
2772
2773
  if (u === null) return null;
2773
2774
  let d = o[0] + (o[1] - o[0]) * a;
@@ -2776,13 +2777,13 @@ box to correct in the first place. */
2776
2777
  fix: (d - u) / r
2777
2778
  });
2778
2779
  }
2779
- return Math.max(...l.map((e) => Math.abs(e.fix))) * r < Ji ? null : l;
2780
- }, $i = () => {
2780
+ return Math.max(...l.map((e) => Math.abs(e.fix))) * r < Yi ? null : l;
2781
+ }, ea = () => {
2781
2782
  if (p()) return null;
2782
- let e = document.head.querySelector(`style[${At}]`);
2783
- return e || (e = document.createElement("style"), e.setAttribute(At, ""), document.head.appendChild(e)), e.sheet;
2784
- }, ea = (e) => {
2785
- let t = $i();
2783
+ let e = document.head.querySelector(`style[${jt}]`);
2784
+ return e || (e = document.createElement("style"), e.setAttribute(jt, ""), document.head.appendChild(e)), e.sheet;
2785
+ }, ta = (e) => {
2786
+ let t = ea();
2786
2787
  if (!t) return () => {};
2787
2788
  let n = [];
2788
2789
  for (let r of e) try {
@@ -2796,87 +2797,87 @@ box to correct in the first place. */
2796
2797
  }
2797
2798
  n.length = 0;
2798
2799
  };
2799
- }, ta = /* @__PURE__ */ new WeakMap(), na = () => {
2800
- let e = $i();
2800
+ }, na = /* @__PURE__ */ new WeakMap(), ra = () => {
2801
+ let e = ea();
2801
2802
  /* v8 ignore next -- no document to register into. */
2802
2803
  if (!e) return !1;
2803
- let t = ta.get(e);
2804
+ let t = na.get(e);
2804
2805
  if (t !== void 0) return t;
2805
2806
  let n = !0;
2806
- for (let t of Vn) try {
2807
+ for (let t of Hn) try {
2807
2808
  e.insertRule(t, e.cssRules.length);
2808
2809
  } catch {
2809
2810
  n = !1;
2810
2811
  }
2811
- return ta.set(e, n), n;
2812
- }, ra = 1e3 / 60, ia = 1e3 / 600, aa = 42, oa = ra, sa = () => oa, ca = (e) => {
2813
- Number.isFinite(e) && (e < ia || e > aa || (oa = Math.min(ra, Math.max(ia, e))));
2814
- }, la = () => {
2812
+ return na.set(e, n), n;
2813
+ }, ia = 1e3 / 60, aa = 1e3 / 600, oa = 42, sa = ia, ca = () => sa, la = (e) => {
2814
+ Number.isFinite(e) && (e < aa || e > oa || (sa = Math.min(ia, Math.max(aa, e))));
2815
+ }, ua = () => {
2815
2816
  if (typeof navigator > "u") return !1;
2816
2817
  let e = navigator.userAgentData?.brands;
2817
2818
  if (Array.isArray(e)) return e.some((e) => /chromium/i.test(e?.brand ?? ""));
2818
2819
  let t = navigator.userAgent ?? "";
2819
2820
  return /Android/i.test(t) && !/Firefox|FxiOS/i.test(t);
2820
- }, ua = 90, da = () => {
2821
+ }, da = 90, fa = () => {
2821
2822
  if (typeof navigator > "u") return !1;
2822
2823
  let e = navigator.userAgentData?.brands;
2823
2824
  if (Array.isArray(e)) return !1;
2824
2825
  let t = navigator.userAgent ?? "";
2825
- return !/Android/i.test(t) || /Firefox|FxiOS/i.test(t) || (navigator.maxTouchPoints ?? 0) <= 0 ? !1 : Number(/Chrom(?:e|ium)\/(\d+)/i.exec(t)?.[1] ?? 0) < ua;
2826
- }, fa = () => typeof navigator > "u" ? !1 : !la() && navigator.maxTouchPoints === 0 && /Mac/.test(navigator.platform), pa = () => la() && typeof navigator < "u" && navigator.maxTouchPoints === 0, ma = 14, ha = 22, ga = 2, _a = 1.5, va = !1, ya = 0, ba = () => typeof navigator > "u" || (navigator.maxTouchPoints ?? 0) === 0, xa = (e, t) => {
2827
- if (!(!Number.isFinite(e) || e <= 0) && ba()) {
2828
- if (e < 12) {
2826
+ return !/Android/i.test(t) || /Firefox|FxiOS/i.test(t) || (navigator.maxTouchPoints ?? 0) <= 0 ? !1 : Number(/Chrom(?:e|ium)\/(\d+)/i.exec(t)?.[1] ?? 0) < da;
2827
+ }, pa = () => typeof navigator > "u" ? !1 : !ua() && navigator.maxTouchPoints === 0 && /Mac/.test(navigator.platform), ma = () => ua() && typeof navigator < "u" && navigator.maxTouchPoints === 0, ha = 12, ga = 14, _a = 22, va = 2, ya = 1.5, ba = !1, xa = 0, Sa = () => typeof navigator > "u" || (navigator.maxTouchPoints ?? 0) === 0, Ca = (e, t) => {
2828
+ if (!(!Number.isFinite(e) || e <= 0) && Sa()) {
2829
+ if (e < ha) {
2829
2830
  if (t !== void 0 && t > 24) return;
2830
- va = !0, ya = 0;
2831
+ ba = !0, xa = 0;
2831
2832
  return;
2832
2833
  }
2833
- if (e >= ma && e <= ha) {
2834
- ya = Math.min(ga, ya + 1);
2834
+ if (e >= ga && e <= _a) {
2835
+ xa = Math.min(va, xa + 1);
2835
2836
  return;
2836
2837
  }
2837
- e < ma && (ya = 0);
2838
+ e < ga && (xa = 0);
2838
2839
  }
2839
- }, Sa = () => !va && ya >= ga, Ca = () => Sa() && la() && typeof navigator < "u" && navigator.maxTouchPoints === 0 && typeof window < "u" && window.devicePixelRatio >= _a, wa = () => {}, Ta = null, Ea = () => {
2840
+ }, wa = () => !ba && xa >= va, Ta = () => wa() && ua() && typeof navigator < "u" && navigator.maxTouchPoints === 0 && typeof window < "u" && window.devicePixelRatio >= ya, Ea = () => {}, Da = null, Oa = () => {
2840
2841
  /* v8 ignore next 2 -- the loop only runs where rAF existed to start it; the
2841
2842
  re-check covers an environment that removes it mid-session. */
2842
- Ta = typeof requestAnimationFrame == "function" ? requestAnimationFrame(Ea) : null;
2843
- }, Da = () => (Ta === null && typeof requestAnimationFrame == "function" && (Ta = requestAnimationFrame(Ea)), wa), Oa = !1, ka = 0, Aa = () => {
2844
- Oa &&= (ka += 1, !1);
2845
- }, ja = 2, Ma = 8, Na = () => {
2846
- if (Oa || typeof requestAnimationFrame != "function") return;
2847
- Oa = !0;
2848
- let e = ++ka, t = [], n = ja, r = null, i = (a) => {
2849
- if (e !== ka) return;
2850
- if (r !== null && (n > 0 ? --n : t.push(a - r)), r = a, t.length < Ma) {
2843
+ Da = typeof requestAnimationFrame == "function" ? requestAnimationFrame(Oa) : null;
2844
+ }, ka = () => (Da === null && typeof requestAnimationFrame == "function" && (Da = requestAnimationFrame(Oa)), Ea), Aa = !1, ja = 0, Ma = () => {
2845
+ Aa &&= (ja += 1, !1);
2846
+ }, Na = 2, Pa = 8, Fa = () => {
2847
+ if (Aa || typeof requestAnimationFrame != "function") return;
2848
+ Aa = !0;
2849
+ let e = ++ja, t = [], n = Na, r = null, i = (a) => {
2850
+ if (e !== ja) return;
2851
+ if (r !== null && (n > 0 ? --n : t.push(a - r)), r = a, t.length < Pa) {
2851
2852
  requestAnimationFrame(i);
2852
2853
  return;
2853
2854
  }
2854
- Oa = !1;
2855
+ Aa = !1;
2855
2856
  let o = [...t].sort((e, t) => e - t), s = o[Math.floor(o.length / 2)];
2856
- ca(s), xa(s, o[o.length - 1]);
2857
+ la(s), Ca(s, o[o.length - 1]);
2857
2858
  };
2858
2859
  requestAnimationFrame(i);
2859
- }, Pa = () => !la() && typeof navigator < "u" && navigator.maxTouchPoints > 0, Fa = () => la() && navigator.maxTouchPoints > 0, Ia = () => Pa() || Ca() || Fa() || fa(), La = (e = {}) => {
2860
- let t = !la(), n = Pa();
2860
+ }, Ia = () => !ua() && typeof navigator < "u" && navigator.maxTouchPoints > 0, La = () => ua() && navigator.maxTouchPoints > 0, Ra = () => Ia() || Ta() || La() || pa(), za = (e = {}) => {
2861
+ let t = !ua(), n = Ia();
2861
2862
  return {
2862
2863
  mainThreadPresented: t,
2863
- atomicReleaseFlip: t && (e.authoredNativeDriver === !0 || n || fa()),
2864
+ atomicReleaseFlip: t && (e.authoredNativeDriver === !0 || n || pa()),
2864
2865
  deferReleaseCommit: n,
2865
- renderSettleGate: Ia(),
2866
+ renderSettleGate: Ra(),
2866
2867
  parkOver: n,
2867
2868
  imageDecodeOffload: typeof navigator < "u"
2868
2869
  };
2869
- }, Ra = () => typeof navigator < "u" && navigator.maxTouchPoints > 0, za = (e) => {
2870
- let t = la(), n = Ra(), r = !t && n && Pa(), i = t && n && da(), a = !t && n && (e === "POPPING" || e === "PUSHING" && Ia()), o = r || i || a, s = fa();
2870
+ }, Ba = () => typeof navigator < "u" && navigator.maxTouchPoints > 0, Va = (e) => {
2871
+ let t = ua(), n = Ba(), r = !t && n && Ia(), i = t && n && fa(), a = !t && n && (e === "POPPING" || e === "PUSHING" && Ra()), o = r || i || a, s = pa();
2871
2872
  return {
2872
2873
  touchGoverned: r,
2873
2874
  forceCompiled: a,
2874
2875
  governedHead: o,
2875
2876
  desktopHead: s,
2876
- headMs: o ? Qr[e] ?? 0 : s ? Zr[e] ?? 0 : 0
2877
+ headMs: o ? $r[e] ?? 0 : s ? Qr[e] ?? 0 : 0
2877
2878
  };
2878
- }, Ba = (e) => {
2879
- let { status: t, transition: n, skipAnimation: r, hasActiveMotion: i, hasAnimation: a } = e, o = la(), { touchGoverned: s, forceCompiled: c, governedHead: l, desktopHead: u, headMs: d } = za(t);
2879
+ }, Ha = (e) => {
2880
+ let { status: t, transition: n, skipAnimation: r, hasActiveMotion: i, hasAnimation: a } = e, o = ua(), { touchGoverned: s, forceCompiled: c, governedHead: l, desktopHead: u, headMs: d } = Va(t);
2880
2881
  return {
2881
2882
  hasDrivableMotion: !r && i,
2882
2883
  nativeSurgeryAllowed: n.driver === "native" && !o,
@@ -2886,36 +2887,36 @@ box to correct in the first place. */
2886
2887
  desktopHead: u,
2887
2888
  birthHoldMs: d,
2888
2889
  governedSlide: s && (t === "PUSHING" || t === "POPPING"),
2889
- framePacingKeepalive: a && o && (typeof navigator < "u" && navigator.maxTouchPoints === 0 || sa() < 12),
2890
- creepHead: l && Pa()
2890
+ framePacingKeepalive: a && o && (typeof navigator < "u" && navigator.maxTouchPoints === 0 || ca() < 12),
2891
+ creepHead: l && Ia()
2891
2892
  };
2892
- }, Va = [
2893
+ }, Ua = [
2893
2894
  "x",
2894
2895
  "y",
2895
2896
  "scale",
2896
2897
  "scaleX",
2897
2898
  "scaleY",
2898
2899
  "rotate"
2899
- ], Ha = (e) => !!e && Va.some((t) => e[t] !== void 0 && e[t] !== 0), Ua = (e) => {
2900
+ ], Wa = (e) => !!e && Ua.some((t) => e[t] !== void 0 && e[t] !== 0), Ga = (e) => {
2900
2901
  if (p()) return 0;
2901
- let { governedHead: t, headMs: n } = za(e);
2902
+ let { governedHead: t, headMs: n } = Va(e);
2902
2903
  return t && (e === "PUSHING" || e === "POPPING") ? n * 2 / 1e3 : n / 1e3;
2903
- }, Wa = (e, t) => {
2904
+ }, Ka = (e, t) => {
2904
2905
  let n = e;
2905
2906
  for (let e = t.parentElement; e && e !== document.documentElement; e = e.parentElement) {
2906
- let t = ir(e);
2907
+ let t = ar(e);
2907
2908
  if (t.x === 0 && t.y === 0 && t.scaleX === 1 && t.scaleY === 1) continue;
2908
- let r = e.getBoundingClientRect(), i = ar({
2909
+ let r = e.getBoundingClientRect(), i = or({
2909
2910
  x: r.left,
2910
2911
  y: r.top,
2911
2912
  width: r.width,
2912
2913
  height: r.height
2913
2914
  }, t);
2914
- n = tr(n, t, i);
2915
+ n = nr(n, t, i);
2915
2916
  }
2916
2917
  return n;
2917
- }, Ga = (e, t, n) => {
2918
- let r = er(e), i = Wa(r.rect, e), a = {
2918
+ }, qa = (e, t, n) => {
2919
+ let r = tr(e), i = Ka(r.rect, e), a = {
2919
2920
  rect: i,
2920
2921
  fontSize: r.fontSize,
2921
2922
  fontWeight: r.fontWeight,
@@ -2949,11 +2950,11 @@ box to correct in the first place. */
2949
2950
  singleLine: r.singleLine,
2950
2951
  textHeight: r.textHeight,
2951
2952
  leadOffset: r.leadOffset,
2952
- screenMoves: Ha(c.from) || Ha(c.to),
2953
+ screenMoves: Wa(c.from) || Wa(c.to),
2953
2954
  screenDuration: c.duration,
2954
2955
  screenEase: c.ease
2955
2956
  } : a;
2956
- }, Ka = (e) => {
2957
+ }, Ja = (e) => {
2957
2958
  let t = [];
2958
2959
  for (let n of e.querySelectorAll(`[${J}]`)) {
2959
2960
  let { width: e } = n.getBoundingClientRect();
@@ -2966,7 +2967,7 @@ box to correct in the first place. */
2966
2967
  return () => {
2967
2968
  for (let e of t) e();
2968
2969
  };
2969
- }, qa = /* @__PURE__ */ new WeakMap(), Ja = 0, Ya = X($e), Xa = [
2970
+ }, Ya = /* @__PURE__ */ new WeakMap(), Xa = 0, Za = X($e), Qa = [
2970
2971
  "color",
2971
2972
  "font",
2972
2973
  "letterSpacing",
@@ -2975,34 +2976,34 @@ box to correct in the first place. */
2975
2976
  "textTransform",
2976
2977
  "whiteSpace",
2977
2978
  "direction"
2978
- ], Za = (e, t) => {
2979
+ ], $a = (e, t) => {
2979
2980
  if (t !== "lineHeight") return e[t];
2980
2981
  let n = e.lineHeight ?? "", r = Number.parseFloat(n), i = Number.parseFloat(e.fontSize ?? "");
2981
2982
  return !n.endsWith("px") || !Number.isFinite(r) || !Number.isFinite(i) || i <= 0 ? n : String(Math.round(r / i * 1e4) / 1e4);
2982
- }, Qa = (e) => F.includes(e), $a = (e) => e.closest(Ya), eo = (e) => e.hasAttribute("data-flemo-status") && e.hasAttribute("data-flemo-active") ? e : $a(e), to = (e) => {
2983
- let t = $a(e);
2983
+ }, eo = (e) => P.includes(e), to = (e) => e.closest(Za), no = (e) => e.hasAttribute("data-flemo-status") && e.hasAttribute("data-flemo-active") ? e : to(e), ro = (e) => {
2984
+ let t = to(e);
2984
2985
  if (!t) return null;
2985
2986
  let n = e.getAttribute(rt);
2986
2987
  return n === null || n === t.getAttribute("data-flemo-router") ? t : null;
2987
- }, no = (e) => e === "POPPING" ? "false" : "true", ro = (e, t) => e.getAttribute(tt) === no(t), io = (e) => e === "POPPING" ? {
2988
+ }, io = (e) => e === "POPPING" ? "false" : "true", ao = (e, t) => e.getAttribute(tt) === io(t), oo = (e) => e === "POPPING" ? {
2988
2989
  enter: "POPPING-false",
2989
2990
  exit: "POPPING-true"
2990
2991
  } : {
2991
2992
  enter: `${e}-true`,
2992
2993
  exit: `${e}-false`
2993
- }, ao = (e) => e < 0 ? 0 : e > 1 ? 1 : e, oo = (e, t, n) => e !== null && t !== null && Math.abs(e - t) >= n ? {
2994
+ }, so = (e) => e < 0 ? 0 : e > 1 ? 1 : e, co = (e, t, n) => e !== null && t !== null && Math.abs(e - t) >= n ? {
2994
2995
  from: e,
2995
2996
  to: t
2996
- } : null, so = (e, t, n, r, i) => {
2997
- let a = oo(e.fontSize, t.fontSize, .5), o = oo(e.lineHeight, t.lineHeight, .25), s = a ? Ui(e, t, n, r) : null, c = a && i ? Yi(i, e, t, n, r) : null, l = s === null && (a || o) ? Ii(e, t) : 0;
2997
+ } : null, lo = (e, t, n, r, i) => {
2998
+ let a = co(e.fontSize, t.fontSize, .5), o = co(e.lineHeight, t.lineHeight, .25), s = a ? Wi(e, t, n, r) : null, c = a && i ? Xi(i, e, t, n, r) : null, l = s === null && (a || o) ? Li(e, t) : 0;
2998
2999
  return {
2999
3000
  fontSize: a,
3000
3001
  leading: s,
3001
- leadStart: Fi(e, t, s),
3002
+ leadStart: Ii(e, t, s),
3002
3003
  track: c,
3003
- fontWeight: oo(e.fontWeight, t.fontWeight, 1),
3004
- letterSpacing: oo(e.letterSpacing, t.letterSpacing, .01),
3005
- wordSpacing: oo(e.wordSpacing, t.wordSpacing, .01),
3004
+ fontWeight: co(e.fontWeight, t.fontWeight, 1),
3005
+ letterSpacing: co(e.letterSpacing, t.letterSpacing, .01),
3006
+ wordSpacing: co(e.wordSpacing, t.wordSpacing, .01),
3006
3007
  lift: s,
3007
3008
  lineHeight: o ? {
3008
3009
  from: o.from + l,
@@ -3015,11 +3016,11 @@ box to correct in the first place. */
3015
3016
  to: t.lineHeight
3016
3017
  } : null
3017
3018
  };
3018
- }, co = 1 / 60, lo = "steps(1, start)", uo = .006, fo = .4, po = (e) => {
3019
+ }, uo = 1 / 60, fo = "steps(1, start)", po = .006, mo = .4, ho = (e) => {
3019
3020
  let t = 0, n = e;
3020
3021
  for (; n;) n.hasAttribute("data-flemo-morph") && (t += 1), n = n.parentElement;
3021
3022
  return t;
3022
- }, mo = (e, t) => {
3023
+ }, go = (e, t) => {
3023
3024
  let n = Ze[t];
3024
3025
  if (n === "self") return null;
3025
3026
  let r = e.variants[t];
@@ -3028,41 +3029,41 @@ box to correct in the first place. */
3028
3029
  to: r.value,
3029
3030
  options: r.options
3030
3031
  };
3031
- }, ho = (e) => {
3032
+ }, _o = (e) => {
3032
3033
  e.style.pointerEvents = "none", e.style.zIndex = "2147483000";
3033
- }, go = {
3034
+ }, vo = {
3034
3035
  left: 0,
3035
3036
  top: 0,
3036
3037
  center: .5,
3037
3038
  right: 1,
3038
3039
  bottom: 1
3039
- }, _o = (e, t) => {
3040
+ }, yo = (e, t) => {
3040
3041
  if (!e) return t / 2;
3041
- let n = go[e];
3042
+ let n = vo[e];
3042
3043
  if (n !== void 0) return n * t;
3043
3044
  let r = Number.parseFloat(e);
3044
3045
  return Number.isFinite(r) ? e.endsWith("%") ? r / 100 * t : r : t / 2;
3045
- }, vo = (e, t) => {
3046
+ }, bo = (e, t) => {
3046
3047
  let n = e.getBoundingClientRect(), r = {
3047
3048
  x: n.left,
3048
3049
  y: n.top,
3049
3050
  width: n.width,
3050
3051
  height: n.height
3051
- }, i = ir(e), a = Gt(tr(r, i, ar(r, i)), t), o = ((typeof getComputedStyle == "function" ? getComputedStyle(e) : null)?.transformOrigin ?? "").trim().split(/\s+/);
3052
+ }, i = ar(e), a = Kt(nr(r, i, or(r, i)), t), o = ((typeof getComputedStyle == "function" ? getComputedStyle(e) : null)?.transformOrigin ?? "").trim().split(/\s+/);
3052
3053
  return {
3053
- x: a.x + _o(o[0], a.width),
3054
- y: a.y + _o(o[1], a.height)
3054
+ x: a.x + yo(o[0], a.width),
3055
+ y: a.y + yo(o[1], a.height)
3055
3056
  };
3056
- }, yo = (e, t) => {
3057
+ }, xo = (e, t) => {
3057
3058
  t.translate && (e.style.translate = t.translate), t.transform && (e.style.transform = t.transform), t.letterSpacing && (e.style.letterSpacing = t.letterSpacing), t.size && (e.style.width = t.size.width, e.style.height = t.size.height);
3058
- }, bo = (e, t, n, r, i, a, o, s) => {
3059
+ }, So = (e, t, n, r, i, a, o, s) => {
3059
3060
  let c = Ye.get(t.name) ?? Ye.get("shared");
3060
3061
  if (!c) return;
3061
- let { enter: l, exit: u } = io(r), d = mo(c, l);
3062
+ let { enter: l, exit: u } = oo(r), d = go(c, l);
3062
3063
  if (!d) return;
3063
3064
  e.residue.get(t.element)?.(), e.residue.get(n.element)?.();
3064
3065
  let f = s ? (() => {
3065
- let e = er(t.element);
3066
+ let e = tr(t.element);
3066
3067
  return {
3067
3068
  rect: e.rect,
3068
3069
  fontSize: e.fontSize,
@@ -3081,30 +3082,30 @@ box to correct in the first place. */
3081
3082
  screenDuration: s.duration,
3082
3083
  screenEase: s.ease
3083
3084
  };
3084
- })() : Ga(t.element, i, l);
3085
+ })() : qa(t.element, i, l);
3085
3086
  if (f.rect.width <= 0 || f.rect.height <= 0 || n.snapshot.rect.width <= 0 || n.snapshot.rect.height <= 0) return;
3086
- let p = li(o), m = t.element.parentElement;
3087
+ let p = ui(o), m = t.element.parentElement;
3087
3088
  /* v8 ignore next 4 -- neither is reachable from a browser: the layer falls
3088
3089
  back to a document-level element when a binding publishes none, and a
3089
3090
  registered element that reached the pairing is in the tree. The guard is
3090
3091
  for SSR and for a binding that registers a detached node. */
3091
3092
  if (!p || !m) return;
3092
- let h = d.options.duration ?? f.screenDuration, g = s ? s.duration : h > 0 ? h : fo, _ = f.screenMoves && f.screenEase ? f.screenEase : d.options.ease ?? f.screenEase, v = s ? s.head : Ua(r), y = s ? s.start : (d.options.delay ?? 0) + v;
3093
- ho(p);
3094
- let b = Gt(f.rect, p), x = Gt(n.snapshot.rect, p), S = {
3093
+ let h = d.options.duration ?? f.screenDuration, g = s ? s.duration : h > 0 ? h : mo, _ = f.screenMoves && f.screenEase ? f.screenEase : d.options.ease ?? f.screenEase, v = s ? s.head : Ga(r), y = s ? s.start : (d.options.delay ?? 0) + v;
3094
+ _o(p);
3095
+ let b = Kt(f.rect, p), x = Kt(n.snapshot.rect, p), S = {
3095
3096
  width: b.width,
3096
3097
  height: b.height
3097
- }, C = t.element.firstElementChild === null && t.restSize ? Jn(t.restSize.height, f.lineHeight, f.fontSize) : f.singleLine, w = ao(c.crossFade ?? .55), T = Math.abs(x.width - b.width) >= .05 ? Ka(t.element) : null, E = typeof getComputedStyle == "function" ? getComputedStyle(t.element) : null, D = E ? {
3098
+ }, C = t.element.firstElementChild === null && t.restSize ? Yn(t.restSize.height, f.lineHeight, f.fontSize) : f.singleLine, w = so(c.crossFade ?? .55), T = Math.abs(x.width - b.width) >= .05 ? Ja(t.element) : null, E = typeof getComputedStyle == "function" ? getComputedStyle(t.element) : null, D = E ? {
3098
3099
  fontFamily: E.fontFamily,
3099
3100
  fontWeight: E.fontWeight,
3100
3101
  fontStyle: E.fontStyle,
3101
3102
  borderRadius: E.borderRadius,
3102
- inherited: Xa.map((e) => [e, Za(E, e)])
3103
+ inherited: Qa.map((e) => [e, $a(E, e)])
3103
3104
  } : null, O = D?.fontFamily ? {
3104
3105
  family: D.fontFamily,
3105
3106
  weight: D.fontWeight,
3106
3107
  style: D.fontStyle
3107
- } : null, k = t.element.firstElementChild === null ? Array.from(t.element.childNodes, (e) => e instanceof Text ? e.data : "").join("").trim() : "", A = so(n.snapshot, f, O, _, k || null), j = pn(n.snapshot.paint, f.paint, c.radius === !1 ? /* @__PURE__ */ new Set(["border-radius"]) : void 0), M = j.find((e) => e.property === "border-radius");
3108
+ } : null, k = t.element.firstElementChild === null ? Array.from(t.element.childNodes, (e) => e instanceof Text ? e.data : "").join("").trim() : "", A = lo(n.snapshot, f, O, _, k || null), j = mn(n.snapshot.paint, f.paint, c.radius === !1 ? /* @__PURE__ */ new Set(["border-radius"]) : void 0), M = j.find((e) => e.property === "border-radius");
3108
3109
  if (M) {
3109
3110
  let e = (e) => {
3110
3111
  if (e.includes("/")) return null;
@@ -3121,15 +3122,15 @@ box to correct in the first place. */
3121
3122
  M.from = e(r, n.snapshot.rect.width), M.to = e(i, f.rect.width);
3122
3123
  }
3123
3124
  }
3124
- let ee = tn($t(n.element), $t(t.element)), N = `${Ja += 1}`, P = na(), F = !s && n.element.isConnected && n.element !== t.element, te = cn(t.element, x, b, {
3125
+ let ee = nn(en(n.element), en(t.element)), N = `${Xa += 1}`, te = ra(), P = !s && n.element.isConnected && n.element !== t.element, ne = ln(t.element, x, b, {
3125
3126
  x: Math.abs(x.x + x.width - (b.x + b.width)) < .05 && Math.abs(x.x - b.x) >= .05 ? "right" : "left",
3126
3127
  y: "top"
3127
- }), I = ai({
3128
+ }), F = oi({
3128
3129
  id: `${N}i`,
3129
3130
  travel: {
3130
3131
  from: Q,
3131
- authoredFrom: _n(d.from, S) ?? Q,
3132
- authoredTo: _n(d.to, S) ?? Q,
3132
+ authoredFrom: vn(d.from, S) ?? Q,
3133
+ authoredTo: vn(d.to, S) ?? Q,
3133
3134
  duration: g,
3134
3135
  start: y,
3135
3136
  head: v,
@@ -3139,7 +3140,7 @@ box to correct in the first place. */
3139
3140
  from: x,
3140
3141
  to: b
3141
3142
  },
3142
- contentsHold: te,
3143
+ contentsHold: ne,
3143
3144
  clip: ee,
3144
3145
  radius: D?.borderRadius || null,
3145
3146
  padding: n.snapshot.padding === f.padding ? null : {
@@ -3155,19 +3156,19 @@ box to correct in the first place. */
3155
3156
  leadStart: A.leadStart,
3156
3157
  lift: A.lift,
3157
3158
  track: A.track,
3158
- travelPinned: P,
3159
- fade: ii(d.from).length > 0 ? {
3159
+ travelPinned: te,
3160
+ fade: ai(d.from).length > 0 ? {
3160
3161
  from: d.from,
3161
3162
  to: d.to,
3162
3163
  duration: g * w
3163
- } : F && v > 0 && w === 0 ? {
3164
- from: { opacity: uo },
3164
+ } : P && v > 0 && w === 0 ? {
3165
+ from: { opacity: po },
3165
3166
  to: { opacity: 1 },
3166
- duration: co,
3167
- easing: lo
3167
+ duration: uo,
3168
+ easing: fo
3168
3169
  } : null,
3169
3170
  paint: j
3170
- }), ne = !I.geometryAccelerated && na(), L = n.element, re = mo(c, u), R = L.isConnected && L !== t.element && re ? ai({
3171
+ }), re = !F.geometryAccelerated && ra(), I = n.element, L = go(c, u), R = I.isConnected && I !== t.element && L ? oi({
3171
3172
  id: `${N}o`,
3172
3173
  travel: {
3173
3174
  from: Q,
@@ -3178,9 +3179,9 @@ box to correct in the first place. */
3178
3179
  ease: _
3179
3180
  },
3180
3181
  fade: {
3181
- from: re.to,
3182
- to: re.to,
3183
- duration: co,
3182
+ from: L.to,
3183
+ to: L.to,
3184
+ duration: uo,
3184
3185
  delay: 0
3185
3186
  },
3186
3187
  paint: []
@@ -3191,7 +3192,7 @@ box to correct in the first place. */
3191
3192
  height: f.rect.height
3192
3193
  }, s = n.snapshot.rect.width - o.width, c = n.snapshot.rect.height - o.height, l = A.fontSize === null && (Math.abs(s) >= 1 || Math.abs(c) >= 1), u = A.fontSize !== null || A.fontWeight !== null || A.letterSpacing !== null || A.wordSpacing !== null || A.lineHeight !== null, d = n.snapshot.aspectRatio !== null && f.aspectRatio !== null && n.snapshot.aspectRatio !== f.aspectRatio, p = n.snapshot.padding !== f.padding || n.snapshot.margin !== f.margin;
3193
3194
  if (!u && !d && !p && !a && !l && j.length === 0) return;
3194
- let m = ai({
3195
+ let m = oi({
3195
3196
  id: `${N}n`,
3196
3197
  travel: {
3197
3198
  from: a ? {
@@ -3214,7 +3215,7 @@ box to correct in the first place. */
3214
3215
  leadStart: A.leadStart,
3215
3216
  lift: A.lift,
3216
3217
  track: A.track,
3217
- travelPinned: P,
3218
+ travelPinned: te,
3218
3219
  aspectRatio: d ? {
3219
3220
  from: n.snapshot.aspectRatio,
3220
3221
  to: f.aspectRatio
@@ -3236,9 +3237,9 @@ box to correct in the first place. */
3236
3237
  } : null,
3237
3238
  fade: null,
3238
3239
  paint: j,
3239
- pinned: ne
3240
- }), h = ea(m.rules), b = t.element.getAttribute("style");
3241
- t.element.style.animation = m.animation, yo(t.element, m), ji(n.snapshot.singleLine, C) && Ai(t.element), t.element.setAttribute(St, Ct.ENTER);
3240
+ pinned: re
3241
+ }), h = ta(m.rules), b = t.element.getAttribute("style");
3242
+ t.element.style.animation = m.animation, xo(t.element, m), Mi(n.snapshot.singleLine, C) && ji(t.element), t.element.setAttribute(St, Ct.ENTER);
3242
3243
  let x = !1, S = () => {
3243
3244
  x || (x = !0, t.element.removeEventListener("animationend", w), clearTimeout(E), b === null ? t.element.removeAttribute("style") : t.element.setAttribute("style", b), t.element.setAttribute(St, ""), typeof requestAnimationFrame == "function" ? requestAnimationFrame(() => h()) : h(), e.flights.delete(t.layoutId));
3244
3245
  };
@@ -3262,11 +3263,11 @@ box to correct in the first place. */
3262
3263
  });
3263
3264
  return;
3264
3265
  }
3265
- let z = F && (w > 0 || v > 0) ? L.cloneNode(!0) : null, ie = z && typeof getComputedStyle == "function" ? getComputedStyle(L) : null, B = ie ? Xa.map((e) => [e, ie[e]]) : [], V = z ? ai({
3266
+ let z = P && (w > 0 || v > 0) ? I.cloneNode(!0) : null, ie = z && typeof getComputedStyle == "function" ? getComputedStyle(I) : null, B = ie ? Qa.map((e) => [e, ie[e]]) : [], V = z ? oi({
3266
3267
  id: `${N}g`,
3267
3268
  travel: {
3268
3269
  from: Q,
3269
- to: or(b, x),
3270
+ to: sr(b, x),
3270
3271
  authoredFrom: Q,
3271
3272
  authoredTo: Q,
3272
3273
  duration: g,
@@ -3282,14 +3283,14 @@ box to correct in the first place. */
3282
3283
  } : {
3283
3284
  from: { opacity: 1 },
3284
3285
  to: { opacity: 0 },
3285
- duration: co,
3286
- easing: lo
3286
+ duration: uo,
3287
+ easing: fo
3287
3288
  },
3288
3289
  paint: [],
3289
- pinned: ne
3290
- }) : null, H = b.width * b.height < x.width * x.height, U = c.carry === "screen" && !s ? H ? a : to(L) : null, ae = U && x.width > 0 && b.width > 0 ? oi({
3290
+ pinned: re
3291
+ }) : null, H = b.width * b.height < x.width * x.height, U = c.carry === "screen" && !s ? H ? a : ro(I) : null, ae = U && x.width > 0 && b.width > 0 ? si({
3291
3292
  id: `${N}c`,
3292
- origin: vo(U, p),
3293
+ origin: bo(U, p),
3293
3294
  small: H ? b : x,
3294
3295
  big: H ? x : b,
3295
3296
  settling: H,
@@ -3297,41 +3298,41 @@ box to correct in the first place. */
3297
3298
  start: y,
3298
3299
  head: v,
3299
3300
  ease: _,
3300
- selector: Z(kt, `${N}c`),
3301
- accelerated: !ne
3302
- }) : null, oe = ea([
3303
- ...I.rules,
3301
+ selector: Z(At, `${N}c`),
3302
+ accelerated: !re
3303
+ }) : null, oe = ta([
3304
+ ...F.rules,
3304
3305
  ...R?.rules ?? [],
3305
3306
  ...V?.rules ?? [],
3306
3307
  ...ae?.rules ?? []
3307
3308
  ]);
3308
- U && ae && (e.residue.get(U)?.(), U.setAttribute(kt, `${N}c`));
3309
+ U && ae && (e.residue.get(U)?.(), U.setAttribute(At, `${N}c`));
3309
3310
  let W = t.element.cloneNode(!0);
3310
- for (let e of [W, ...W.querySelectorAll("*")]) e.removeAttribute(St), e.removeAttribute(wt), e.removeAttribute(Et), e.removeAttribute(J), e.removeAttribute("id"), e.removeAttribute("name"), e.removeAttribute("data-testid"), e.style.removeProperty("animation");
3311
- W.setAttribute(Dt, ""), W.setAttribute("aria-hidden", "true"), W.inert = !0, W.style.visibility = "hidden", W.style.pointerEvents = "none", m.insertBefore(W, t.element);
3312
- let G = t.element.getAttribute("style"), se = D?.inherited ?? [], ce = Zt(t.element, () => p.appendChild(t.element));
3311
+ for (let e of [W, ...W.querySelectorAll("*")]) e.removeAttribute(St), e.removeAttribute(Tt), e.removeAttribute(wt), e.removeAttribute(Dt), e.removeAttribute(J), e.removeAttribute("id"), e.removeAttribute("name"), e.removeAttribute("data-testid"), e.style.removeProperty("animation");
3312
+ W.setAttribute(Ot, ""), W.setAttribute("aria-hidden", "true"), W.inert = !0, W.style.visibility = "hidden", W.style.pointerEvents = "none", m.insertBefore(W, t.element);
3313
+ let G = t.element.getAttribute("style"), se = D?.inherited ?? [], ce = Qt(t.element, () => p.appendChild(t.element));
3313
3314
  for (let [e, n] of se) t.element.style[e] = n;
3314
3315
  t.element.style.position = "absolute";
3315
- let le = I.translate ? b : x;
3316
- if (t.element.style.left = I.heldEdge === null ? `${le.x}px` : `calc(${I.heldEdge}px - var(${En}))`, t.element.style.top = `${le.y}px`, t.element.style.margin = "0", t.element.style.minWidth = "0", t.element.style.minHeight = "0", t.element.style.maxWidth = "none", t.element.style.maxHeight = "none", t.element.style.contain = "layout", t.element.style.willChange = "left, top, width, height", t.element.style.zIndex = `${po(m) + 1}`, t.element.style.animation = I.animation, yo(t.element, I), ji(n.snapshot.singleLine, C) && Ai(t.element), t.element.setAttribute(St, Ct.ENTER), z && V) {
3317
- for (let e of [z, ...z.querySelectorAll("*")]) e !== z && e.hasAttribute("data-flemo-morph") && (e.style.opacity = "0"), e.removeAttribute(St), e.removeAttribute(wt), e.removeAttribute(J), e.removeAttribute("id"), e.removeAttribute("name"), e.removeAttribute("data-testid");
3318
- z.setAttribute(Ot, ""), z.setAttribute("aria-hidden", "true"), z.inert = !0, w > 0 && (z.style.background = "none", z.style.boxShadow = "none", z.style.borderColor = "transparent");
3316
+ let le = F.translate ? b : x;
3317
+ if (t.element.style.left = F.heldEdge === null ? `${le.x}px` : `calc(${F.heldEdge}px - var(${Dn}))`, t.element.style.top = `${le.y}px`, t.element.style.margin = "0", t.element.style.minWidth = "0", t.element.style.minHeight = "0", t.element.style.maxWidth = "none", t.element.style.maxHeight = "none", t.element.style.contain = "layout", t.element.style.willChange = "left, top, width, height", t.element.style.zIndex = `${ho(m) + 1}`, t.element.style.animation = F.animation, xo(t.element, F), Mi(n.snapshot.singleLine, C) && ji(t.element), t.element.setAttribute(St, Ct.ENTER), z && V) {
3318
+ for (let e of [z, ...z.querySelectorAll("*")]) e !== z && e.hasAttribute("data-flemo-morph") && (e.style.opacity = "0"), e.removeAttribute(St), e.removeAttribute(Tt), e.removeAttribute(wt), e.removeAttribute(J), e.removeAttribute("id"), e.removeAttribute("name"), e.removeAttribute("data-testid");
3319
+ z.setAttribute(kt, ""), z.setAttribute("aria-hidden", "true"), z.inert = !0, w > 0 && (z.style.background = "none", z.style.boxShadow = "none", z.style.borderColor = "transparent");
3319
3320
  for (let [e, t] of B) z.style[e] = t;
3320
- z.style.position = "absolute", z.style.left = `${x.x}px`, z.style.top = `${x.y}px`, z.style.width = `${x.width}px`, z.style.height = `${x.height}px`, z.style.margin = "0", z.style.minWidth = "0", z.style.minHeight = "0", z.style.maxWidth = "none", z.style.maxHeight = "none", z.style.pointerEvents = "none", z.style.willChange = "left, top, width, height", z.style.contain = "layout", z.style.zIndex = `${po(m) + 2}`, z.style.animation = V.animation, yo(z, V), p.appendChild(z);
3321
+ z.style.position = "absolute", z.style.left = `${x.x}px`, z.style.top = `${x.y}px`, z.style.width = `${x.width}px`, z.style.height = `${x.height}px`, z.style.margin = "0", z.style.minWidth = "0", z.style.minHeight = "0", z.style.maxWidth = "none", z.style.maxHeight = "none", z.style.pointerEvents = "none", z.style.willChange = "left, top, width, height", z.style.contain = "layout", z.style.zIndex = `${ho(m) + 2}`, z.style.animation = V.animation, xo(z, V), p.appendChild(z);
3321
3322
  }
3322
3323
  /* v8 ignore next -- as above: `departing` exists for every paired flight. */
3323
- R && (L.style.setProperty("animation", R.animation), L.setAttribute(St, Ct.EXIT));
3324
+ R && (I.style.setProperty("animation", R.animation), I.setAttribute(St, Ct.EXIT));
3324
3325
  let ue = null, de = !1, fe = () => {
3325
3326
  de || (de = !0, typeof requestAnimationFrame == "function" ? requestAnimationFrame(() => oe()) : oe());
3326
3327
  }, K = () => {
3327
- ue?.(), ue = null, e.residue.get(L) === K && e.residue.delete(L), R && (L.style.removeProperty("animation"), L.setAttribute(St, "")), U && (e.residue.get(U) === K && e.residue.delete(U), U.getAttribute("data-flemo-morph-camera") === `${N}c` && U.removeAttribute(kt)), fe();
3328
+ ue?.(), ue = null, e.residue.get(I) === K && e.residue.delete(I), R && (I.style.removeProperty("animation"), I.setAttribute(St, "")), U && (e.residue.get(U) === K && e.residue.delete(U), U.getAttribute("data-flemo-morph-camera") === `${N}c` && U.removeAttribute(At)), fe();
3328
3329
  }, pe = () => {
3329
- if (!L.isConnected || !Qa(o.getState().status)) {
3330
+ if (!I.isConnected || !eo(o.getState().status)) {
3330
3331
  K();
3331
3332
  return;
3332
3333
  }
3333
- R && e.residue.set(L, K), U && ae && e.residue.set(U, K), ue = o.subscribe((e) => {
3334
- Qa(e.status) || K();
3334
+ R && e.residue.set(I, K), U && ae && e.residue.set(U, K), ue = o.subscribe((e) => {
3335
+ eo(e.status) || K();
3335
3336
  });
3336
3337
  let t = setTimeout(K, (y + g) * 1e3 + 1e3), n = ue;
3337
3338
  ue = () => {
@@ -3340,10 +3341,10 @@ box to correct in the first place. */
3340
3341
  }, me = [
3341
3342
  i,
3342
3343
  a,
3343
- eo(L)
3344
+ no(I)
3344
3345
  ].map((e) => e?.closest(X("data-flemo-anim-hold")) ?? null).filter((e, t, n) => e !== null && e !== p && !p.contains(e) && n.indexOf(e) === t), he = () => {
3345
- let e = me.map((e) => e.getAttribute(Y)).find((e) => e !== null && e !== jt.RELEASED);
3346
- p.setAttribute(Y, e ?? jt.RELEASED);
3346
+ let e = me.map((e) => e.getAttribute(Y)).find((e) => e !== null && e !== Mt.RELEASED);
3347
+ p.setAttribute(Y, e ?? Mt.RELEASED);
3347
3348
  };
3348
3349
  he();
3349
3350
  let ge = typeof MutationObserver == "function" ? new MutationObserver(he) : null;
@@ -3352,10 +3353,10 @@ box to correct in the first place. */
3352
3353
  attributeFilter: [Y]
3353
3354
  });
3354
3355
  let _e = !1, ve = () => {
3355
- _e || (_e = !0, t.element.removeEventListener("animationend", ye), clearTimeout(xe), ge?.disconnect(), p.removeAttribute(Y), T?.(), G === null ? t.element.removeAttribute("style") : t.element.setAttribute("style", G), m.isConnected ? ce > 0 ? Zt(t.element, () => W.replaceWith(t.element)) : W.replaceWith(t.element) : t.element.remove(), W.remove(), t.element.setAttribute(St, ""), z?.remove(), R || U ? pe() : fe(), e.flights.delete(t.layoutId));
3356
+ _e || (_e = !0, t.element.removeEventListener("animationend", ye), clearTimeout(xe), ge?.disconnect(), p.removeAttribute(Y), T?.(), G === null ? t.element.removeAttribute("style") : t.element.setAttribute("style", G), m.isConnected ? ce > 0 ? Qt(t.element, () => W.replaceWith(t.element)) : W.replaceWith(t.element) : t.element.remove(), W.remove(), t.element.setAttribute(St, ""), z?.remove(), R || U ? pe() : fe(), e.flights.delete(t.layoutId));
3356
3357
  };
3357
3358
  function ye(e) {
3358
- e.animationName === I.geometryName && (g > 0 && e.elapsedTime === 0 || ve());
3359
+ e.animationName === F.geometryName && (g > 0 && e.elapsedTime === 0 || ve());
3359
3360
  }
3360
3361
  let be = (e) => setTimeout(() => {
3361
3362
  ve();
@@ -3372,19 +3373,19 @@ box to correct in the first place. */
3372
3373
  clearTimeout(xe), xe = be(e);
3373
3374
  }
3374
3375
  });
3375
- }, xo = (e, t, n, r = !1, i = !1) => {
3376
+ }, Co = (e, t, n, r = !1, i = !1) => {
3376
3377
  if (!e.isConnected) return !1;
3377
3378
  if (e.getAttribute("data-flemo-morph")) {
3378
3379
  if (e.closest(X("data-flemo-morph-layer")) === null) return !0;
3379
3380
  for (let t of n.flights.values()) if (t.element === e) return !0;
3380
3381
  return !1;
3381
3382
  }
3382
- let a = eo(e);
3383
- return a ? !r && !i && !Qa(a.getAttribute("data-flemo-status")) ? !1 : a.getAttribute(tt) !== no(t) : !0;
3384
- }, So = (e, t, n, r = !1) => {
3383
+ let a = no(e);
3384
+ return a ? !r && !i && !eo(a.getAttribute("data-flemo-status")) ? !1 : a.getAttribute(tt) !== io(t) : !0;
3385
+ }, wo = (e, t, n, r = !1) => {
3385
3386
  for (let i of e.entries.values()) {
3386
- if (i.element === t.element || i.layoutId !== t.layoutId || !xo(i.element, n, e, r)) continue;
3387
- let a = eo(i.element), o = Ga(i.element, a, io(n).exit);
3387
+ if (i.element === t.element || i.layoutId !== t.layoutId || !Co(i.element, n, e, r)) continue;
3388
+ let a = no(i.element), o = qa(i.element, a, oo(n).exit);
3388
3389
  return {
3389
3390
  snapshot: {
3390
3391
  rect: o.rect,
@@ -3405,54 +3406,54 @@ box to correct in the first place. */
3405
3406
  };
3406
3407
  }
3407
3408
  return null;
3408
- }, Co = X(St), wo = (e, t, n, r = !1, i) => {
3409
+ }, To = X(St), Eo = (e, t, n, r = !1, i) => {
3409
3410
  let a = i ?? t.getState().status;
3410
- if (!i && !Qa(a)) return;
3411
+ if (!i && !eo(a)) return;
3411
3412
  if (e.flights.has(n.layoutId)) {
3412
3413
  e.delivered.delete(n.layoutId);
3413
3414
  return;
3414
3415
  }
3415
- let o = n.element.parentElement?.closest(Co) ?? null, s = null;
3416
+ let o = n.element.parentElement?.closest(To) ?? null, s = null;
3416
3417
  if (o) {
3417
3418
  if (!r) {
3418
- queueMicrotask(() => wo(e, t, n, !0, i));
3419
+ queueMicrotask(() => Eo(e, t, n, !0, i));
3419
3420
  return;
3420
3421
  }
3421
3422
  s = [...e.flights.values()].find((e) => e.element === o) ?? null;
3422
3423
  }
3423
- let c = s ? null : eo(n.element), l = s ? null : to(n.element);
3424
- if (!s && (!c || !ro(c, a)) || e.delivered.delete(n.layoutId)) return;
3425
- let u = e.snapshots.get(n.layoutId), d = i !== void 0, f = u && u.element !== n.element && xo(u.element, a, e, d, !0) ? u : So(e, n, a, d);
3426
- f && bo(e, n, f, a, c, l, t, s);
3427
- }, To = (e, t) => {
3424
+ let c = s ? null : no(n.element), l = s ? null : ro(n.element);
3425
+ if (!s && (!c || !ao(c, a)) || e.delivered.delete(n.layoutId)) return;
3426
+ let u = e.snapshots.get(n.layoutId), d = i !== void 0, f = u && u.element !== n.element && Co(u.element, a, e, d, !0) ? u : wo(e, n, a, d);
3427
+ f && So(e, n, f, a, c, l, t, s);
3428
+ }, Do = (e, t) => {
3428
3429
  /* v8 ignore next -- both callers pass `resolveMorphLayer`, which yields null
3429
3430
  only under SSR; in a browser it always resolves or creates a layer. */
3430
3431
  if (!t) return;
3431
3432
  let n = new Set([...e.flights.values()].map((e) => e.element));
3432
- for (let r of t.querySelectorAll(Co)) !r.getAttribute("data-flemo-morph") || n.has(r) || (e.residue.get(r)?.(), e.residue.delete(r), r.remove());
3433
- }, Eo = (e, t) => {
3434
- To(e, t);
3433
+ for (let r of t.querySelectorAll(To)) !r.getAttribute("data-flemo-morph") || n.has(r) || (e.residue.get(r)?.(), e.residue.delete(r), r.remove());
3434
+ }, Oo = (e, t) => {
3435
+ Do(e, t);
3435
3436
  for (let [t, n] of e.snapshots) n.element.isConnected || e.snapshots.delete(t);
3436
3437
  for (let t of e.entries.values()) {
3437
3438
  if (!t.element.isConnected) continue;
3438
- let n = e.snapshots.get(t.layoutId), r = eo(t.element);
3439
+ let n = e.snapshots.get(t.layoutId), r = no(t.element);
3439
3440
  n && r && r.getAttribute("data-flemo-active") !== "true" || e.snapshots.set(t.layoutId, {
3440
- snapshot: er(t.element),
3441
+ snapshot: tr(t.element),
3441
3442
  element: t.element
3442
3443
  });
3443
3444
  }
3444
- }, Do = (e, t) => {
3445
- let n = jo(e);
3446
- Eo(n, li(e));
3447
- for (let r of [...n.entries.values()]) r.element.isConnected && wo(n, e, r, !1, t);
3445
+ }, ko = (e, t) => {
3446
+ let n = No(e);
3447
+ Oo(n, ui(e));
3448
+ for (let r of [...n.entries.values()]) r.element.isConnected && Eo(n, e, r, !1, t);
3448
3449
  return [...n.flights.values()];
3449
- }, Oo = (e) => {
3450
- jo(e).delivered.clear();
3451
- }, ko = (e) => {
3452
- let t = jo(e);
3450
+ }, Ao = (e) => {
3451
+ No(e).delivered.clear();
3452
+ }, jo = (e) => {
3453
+ let t = No(e);
3453
3454
  for (let e of t.flights.keys()) t.delivered.add(e);
3454
- }, Ao = (e) => [...jo(e).flights.values()], jo = (e) => {
3455
- let t = qa.get(e);
3455
+ }, Mo = (e) => [...No(e).flights.values()], No = (e) => {
3456
+ let t = Ya.get(e);
3456
3457
  if (t) return t;
3457
3458
  let n = {
3458
3459
  entries: /* @__PURE__ */ new Map(),
@@ -3465,14 +3466,14 @@ box to correct in the first place. */
3465
3466
  unsubscribe: () => {}
3466
3467
  };
3467
3468
  return n.unsubscribe = e.subscribe((t, r) => {
3468
- if (t.status !== r.status && Qa(t.status)) {
3469
- Eo(n, li(e));
3469
+ if (t.status !== r.status && eo(t.status)) {
3470
+ Oo(n, ui(e));
3470
3471
  for (let e of [...n.flights.values()]) e.finish();
3471
3472
  }
3472
- }), qa.set(e, n), n;
3473
+ }), Ya.set(e, n), n;
3473
3474
  };
3474
- function Mo(e, t) {
3475
- let { layoutId: n, navigateStore: r } = t, i = t.name ?? "shared", a = jo(r), o = e.parentElement?.closest(Co) ?? null, s = e.closest(`[${Tt}]`) !== null, c = a.entries.get(e)?.restSize ?? null, l = o && !s ? e.getBoundingClientRect() : null, u = {
3475
+ function Po(e, t) {
3476
+ let { layoutId: n, navigateStore: r } = t, i = t.name ?? "shared", a = No(r), o = e.parentElement?.closest(To) ?? null, s = e.closest(`[${Et}]`) !== null, c = a.entries.get(e)?.restSize ?? null, l = o && !s ? e.getBoundingClientRect() : null, u = {
3476
3477
  element: e,
3477
3478
  layoutId: String(n),
3478
3479
  name: i,
@@ -3481,44 +3482,46 @@ function Mo(e, t) {
3481
3482
  height: l.height
3482
3483
  } : c
3483
3484
  };
3484
- a.entries.set(e, u), e.hasAttribute("data-flemo-morph") || e.setAttribute(St, ""), e.setAttribute(wt, String(i));
3485
- let d = $a(e), f = e.getAttribute(rt);
3486
- return d === null || f !== null && f !== d.getAttribute("data-flemo-router") ? t.ownership && (e.setAttribute(et, t.ownership.status), e.setAttribute(tt, t.ownership.active ? "true" : "false")) : e.hasAttribute("data-flemo-status") && (e.removeAttribute(et), e.removeAttribute(tt)), wo(a, r, u), () => {
3485
+ a.entries.set(e, u), e.hasAttribute("data-flemo-morph") || e.setAttribute(St, "");
3486
+ let d = String(i);
3487
+ e.getAttribute("data-flemo-morph-name") !== d && e.setAttribute(wt, d), e.getAttribute("data-flemo-morph-id") !== u.layoutId && e.setAttribute(Tt, u.layoutId);
3488
+ let f = to(e), p = e.getAttribute(rt);
3489
+ return f === null || p !== null && p !== f.getAttribute("data-flemo-router") ? t.ownership && (e.setAttribute(et, t.ownership.status), e.setAttribute(tt, t.ownership.active ? "true" : "false")) : e.hasAttribute("data-flemo-status") && (e.removeAttribute(et), e.removeAttribute(tt)), Eo(a, r, u), () => {
3487
3490
  a.entries.get(e) === u && a.entries.delete(e);
3488
3491
  };
3489
3492
  }
3490
3493
  //#endregion
3491
3494
  //#region src/screen/partLayer.ts
3492
- var No = /* @__PURE__ */ new WeakMap(), Po = (e, t) => {
3493
- t ? No.set(e, t) : No.delete(e);
3494
- }, Fo = (e) => {
3495
+ var Fo = /* @__PURE__ */ new WeakMap(), Io = (e, t) => {
3496
+ t ? Fo.set(e, t) : Fo.delete(e);
3497
+ }, Lo = (e) => {
3495
3498
  if (p()) return null;
3496
- let t = No.get(e);
3499
+ let t = Fo.get(e);
3497
3500
  if (t?.isConnected) return t;
3498
3501
  let n = document.body.querySelector(`:scope > [${yt}]`);
3499
3502
  return n || (n = document.createElement("div"), n.setAttribute(yt, ""), document.body.appendChild(n)), n;
3500
- }, Io = (e) => {
3503
+ }, Ro = (e) => {
3501
3504
  let t = e?.currentTime ?? null;
3502
3505
  if (t === null) return null;
3503
3506
  if (typeof t == "number") return t;
3504
3507
  let n = t;
3505
3508
  return typeof n.value == "number" ? n.value : null;
3506
- }, Lo = (e, t) => {
3509
+ }, zo = (e, t) => {
3507
3510
  for (let n of e) {
3508
3511
  n.pause();
3509
3512
  try {
3510
3513
  n.currentTime = t * 1e3;
3511
3514
  } catch {}
3512
3515
  }
3513
- }, Ro = (e, t, n) => {
3516
+ }, Bo = (e, t, n) => {
3514
3517
  let r = n < 0 ? 0 : n > 1 ? 1 : n;
3515
- Lo(e, t.start + di(t.ease)(r) * t.duration);
3516
- }, zo = (e, t, n, r, i) => {
3517
- let a = Math.max(r, 1 / 60), o = (Io(e[0] ?? null) ?? 0) / 1e3, s = t.start + t.duration, c = Math.max(n ? s - o : o, 0), l = c > 0 ? c / a : 1;
3518
+ zo(e, t.start + fi(t.ease)(r) * t.duration);
3519
+ }, Vo = (e, t, n, r, i) => {
3520
+ let a = Math.max(r, 1 / 60), o = (Ro(e[0] ?? null) ?? 0) / 1e3, s = t.start + t.duration, c = Math.max(n ? s - o : o, 0), l = c > 0 ? c / a : 1;
3518
3521
  for (let t of e) {
3519
- let e = Io(t) ?? 0, r = n ? l : -l;
3522
+ let e = Ro(t) ?? 0, r = n ? l : -l;
3520
3523
  t.playbackRate = r, !n && i && t.addEventListener("finish", i, { once: !0 });
3521
- let a = Io(t.timeline);
3524
+ let a = Ro(t.timeline);
3522
3525
  if (a === null) {
3523
3526
  t.play();
3524
3527
  continue;
@@ -3529,18 +3532,18 @@ var No = /* @__PURE__ */ new WeakMap(), Po = (e, t) => {
3529
3532
  t.play();
3530
3533
  }
3531
3534
  }
3532
- }, Bo = "flemo-morph-", Vo = (e) => {
3535
+ }, Ho = "flemo-morph-", Uo = (e) => {
3533
3536
  let t = e.animationName;
3534
- return typeof t == "string" && t.startsWith(Bo);
3535
- }, Ho = () => typeof document > "u" || typeof document.getAnimations != "function" ? [] : document.getAnimations().filter(Vo), Uo = (e, t = "POPPING") => {
3537
+ return typeof t == "string" && t.startsWith(Ho);
3538
+ }, Wo = () => typeof document > "u" || typeof document.getAnimations != "function" ? [] : document.getAnimations().filter(Uo), Go = (e, t = "POPPING") => {
3536
3539
  let n = !1;
3537
- Oo(e), Do(e, t), Ao(e).length === 0 && requestAnimationFrame(() => {
3538
- n || Ao(e).length > 0 || (Do(e, t), a(0));
3540
+ Ao(e), ko(e, t), Mo(e).length === 0 && requestAnimationFrame(() => {
3541
+ n || Mo(e).length > 0 || (ko(e, t), a(0));
3539
3542
  });
3540
- let r = () => Ao(e)[0] ?? null, i = () => {
3541
- for (let t of Ao(e)) t.suspendBackstop();
3543
+ let r = () => Mo(e)[0] ?? null, i = () => {
3544
+ for (let t of Mo(e)) t.suspendBackstop();
3542
3545
  }, a = (e) => {
3543
- i(), Lo(Ho(), e);
3546
+ i(), zo(Wo(), e);
3544
3547
  };
3545
3548
  return a(0), queueMicrotask(() => a(0)), {
3546
3549
  get active() {
@@ -3549,69 +3552,69 @@ var No = /* @__PURE__ */ new WeakMap(), Po = (e, t) => {
3549
3552
  scrub: (e) => {
3550
3553
  if (n) return;
3551
3554
  let t = r();
3552
- t && (i(), Ro(Ho(), t, e));
3555
+ t && (i(), Bo(Wo(), t, e));
3553
3556
  },
3554
3557
  settle: (t, i) => {
3555
3558
  if (n) return;
3556
3559
  n = !0;
3557
3560
  let a = r();
3558
3561
  if (!a) return;
3559
- let o = Ho(), s = Math.max(i, 1 / 60);
3560
- t && ko(e);
3561
- for (let t of Ao(e)) t.armBackstop(s);
3562
- zo(o, a, t, i, () => {
3563
- for (let t of Ao(e)) t.finish();
3562
+ let o = Wo(), s = Math.max(i, 1 / 60);
3563
+ t && jo(e);
3564
+ for (let t of Mo(e)) t.armBackstop(s);
3565
+ Vo(o, a, t, i, () => {
3566
+ for (let t of Mo(e)) t.finish();
3564
3567
  });
3565
3568
  }
3566
3569
  };
3567
- }, Wo = "data-flemo", Go = /* @__PURE__ */ new WeakMap(), Ko = 0, qo = (e) => {
3568
- let t = Go.get(e);
3569
- return t === void 0 ? (Ko += 1, Go.set(e, Ko), Ko) : t;
3570
- }, Jo = () => [
3570
+ }, Ko = "data-flemo", qo = /* @__PURE__ */ new WeakMap(), Jo = 0, Yo = (e) => {
3571
+ let t = qo.get(e);
3572
+ return t === void 0 ? (Jo += 1, qo.set(e, Jo), Jo) : t;
3573
+ }, Xo = () => [
3571
3574
  Ce,
3572
3575
  ke,
3573
3576
  ze
3574
- ].map((e) => [...e.entries()].map(([e, t]) => `${e}:${qo(t)}`).join(",")).join("|"), Yo = 4, Xo = /* @__PURE__ */ new Map(), Zo = (e) => {
3575
- let t = Xo.get(e);
3577
+ ].map((e) => [...e.entries()].map(([e, t]) => `${e}:${Yo(t)}`).join(",")).join("|"), Zo = 4, Qo = /* @__PURE__ */ new Map(), $o = (e) => {
3578
+ let t = Qo.get(e);
3576
3579
  if (t !== void 0) return t;
3577
- let n = qr(Ce.values(), ke.values(), ze.values());
3578
- if (Xo.size >= Yo) {
3579
- let e = Xo.keys().next();
3580
+ let n = Jr(Ce.values(), ke.values(), ze.values());
3581
+ if (Qo.size >= Zo) {
3582
+ let e = Qo.keys().next();
3580
3583
  /* v8 ignore next -- the size check above is what guarantees a first key. */
3581
- e.done || Xo.delete(e.value);
3584
+ e.done || Qo.delete(e.value);
3582
3585
  }
3583
- return Xo.set(e, n), n;
3586
+ return Qo.set(e, n), n;
3584
3587
  };
3585
- function Qo() {
3588
+ function es() {
3586
3589
  /* v8 ignore next -- there is no document to write the sheet into. */
3587
3590
  if (p()) return;
3588
- let e = Zo(Jo()), t = document.head.querySelector(`style[${Wo}]`);
3589
- t || (t = document.createElement("style"), t.setAttribute(Wo, ""), document.head.appendChild(t)), t.textContent !== e && (t.textContent = e);
3591
+ let e = $o(Xo()), t = document.head.querySelector(`style[${Ko}]`);
3592
+ t || (t = document.createElement("style"), t.setAttribute(Ko, ""), document.head.appendChild(t)), t.textContent !== e && (t.textContent = e);
3590
3593
  }
3591
3594
  //#endregion
3592
3595
  //#region src/transition/registerTransitionDefinitions.ts
3593
- var $o = /* @__PURE__ */ new Map(), es = /* @__PURE__ */ new Map(), ts = /* @__PURE__ */ new Map(), ns = /* @__PURE__ */ new Map(), rs = (e, t) => {
3596
+ var ts = /* @__PURE__ */ new Map(), ns = /* @__PURE__ */ new Map(), rs = /* @__PURE__ */ new Map(), is = /* @__PURE__ */ new Map(), as = (e, t) => {
3594
3597
  e.set(t, (e.get(t) ?? 0) + 1);
3595
- }, is = (e, t) => {
3598
+ }, os = (e, t) => {
3596
3599
  let n = (e.get(t) ?? 1) - 1;
3597
3600
  return n <= 0 ? (e.delete(t), !0) : (e.set(t, n), !1);
3598
3601
  };
3599
- function as(e, t, n = [], r = []) {
3600
- for (let t of e) Ce.set(t.name, t), rs($o, t.name);
3601
- for (let e of t) ke.set(e.name, e), rs(es, e.name);
3602
- for (let e of n) ze.set(e.name, e), rs(ts, e.name);
3603
- for (let e of r) Ye.set(e.name, e), rs(ns, e.name);
3604
- return Qo(), () => {
3605
- for (let t of e) is($o, t.name) && Ce.delete(t.name);
3606
- for (let e of t) is(es, e.name) && ke.delete(e.name);
3607
- for (let e of n) is(ts, e.name) && ze.delete(e.name);
3608
- for (let e of r) is(ns, e.name) && Ye.delete(e.name);
3609
- Qo();
3602
+ function ss(e, t, n = [], r = []) {
3603
+ for (let t of e) Ce.set(t.name, t), as(ts, t.name);
3604
+ for (let e of t) ke.set(e.name, e), as(ns, e.name);
3605
+ for (let e of n) ze.set(e.name, e), as(rs, e.name);
3606
+ for (let e of r) Ye.set(e.name, e), as(is, e.name);
3607
+ return es(), () => {
3608
+ for (let t of e) os(ts, t.name) && Ce.delete(t.name);
3609
+ for (let e of t) os(ns, e.name) && ke.delete(e.name);
3610
+ for (let e of n) os(rs, e.name) && ze.delete(e.name);
3611
+ for (let e of r) os(is, e.name) && Ye.delete(e.name);
3612
+ es();
3610
3613
  };
3611
3614
  }
3612
3615
  //#endregion
3613
3616
  //#region src/transition/enteringInitialStyle.ts
3614
- function os(e) {
3617
+ function cs(e) {
3615
3618
  let { initial: t, isActive: n, status: r } = e;
3616
3619
  if (!n || r !== "PUSHING" && r !== "REPLACING") return {};
3617
3620
  let i = {};
@@ -3619,19 +3622,19 @@ function os(e) {
3619
3622
  }
3620
3623
  //#endregion
3621
3624
  //#region src/transition/animateInline.ts
3622
- var ss = (e) => typeof HTMLElement < "u" && e instanceof HTMLElement, cs = /* @__PURE__ */ new WeakMap(), ls = Symbol("flemo-inline-writer"), us = /* @__PURE__ */ new WeakMap(), ds = (e, t, n = ls) => {
3623
- let r = cs.get(e);
3624
- r || (r = /* @__PURE__ */ new Map(), cs.set(e, r));
3625
+ var ls = (e) => typeof HTMLElement < "u" && e instanceof HTMLElement, us = /* @__PURE__ */ new WeakMap(), ds = Symbol("flemo-inline-writer"), fs = /* @__PURE__ */ new WeakMap(), ps = (e, t, n = ds) => {
3626
+ let r = us.get(e);
3627
+ r || (r = /* @__PURE__ */ new Map(), us.set(e, r));
3625
3628
  let i = r.get(t);
3626
3629
  i || (i = {
3627
3630
  original: e.style.getPropertyValue(t),
3628
3631
  owners: /* @__PURE__ */ new Set()
3629
3632
  }, r.set(t, i)), i.owners.add(n);
3630
- }, fs = (e, t) => {
3631
- ss(e) && (ds(e, "transition", t), e.style.transition = "none", us.set(e, t));
3633
+ }, ms = (e, t) => {
3634
+ ls(e) && (ps(e, "transition", t), e.style.transition = "none", fs.set(e, t));
3632
3635
  }, $ = (e, t, n) => {
3633
- let r = cs.get(e);
3634
- (!n || us.get(e) === n) && (e.style.transition = "", us.delete(e));
3636
+ let r = us.get(e);
3637
+ (!n || fs.get(e) === n) && (e.style.transition = "", fs.delete(e));
3635
3638
  let i = (t) => {
3636
3639
  let i = r?.get(t);
3637
3640
  if (!i) {
@@ -3649,19 +3652,19 @@ var ss = (e) => typeof HTMLElement < "u" && e instanceof HTMLElement, cs = /* @_
3649
3652
  return;
3650
3653
  }
3651
3654
  n || (e.style.removeProperty("transform"), e.style.removeProperty("opacity"));
3652
- }, ps = (e, t, n = {}, r) => {
3653
- if (!ss(e)) return Promise.resolve();
3654
- let i = e, a = Or(t);
3655
+ }, hs = (e, t, n = {}, r) => {
3656
+ if (!ls(e)) return Promise.resolve();
3657
+ let i = e, a = kr(t);
3655
3658
  if (a.length === 0) return Promise.resolve();
3656
- let o = typeof n.duration == "number" ? n.duration : 0, s = typeof n.delay == "number" && n.delay > 0 ? n.delay : 0, c = jr(n.ease);
3659
+ let o = typeof n.duration == "number" ? n.duration : 0, s = typeof n.delay == "number" && n.delay > 0 ? n.delay : 0, c = Mr(n.ease);
3657
3660
  if (o <= 0 && s <= 0) {
3658
- i.style.transition = "none", us.set(i, r);
3659
- for (let e of a) ds(i, e.property, r), i.style.setProperty(e.property, e.value);
3661
+ i.style.transition = "none", fs.set(i, r);
3662
+ for (let e of a) ps(i, e.property, r), i.style.setProperty(e.property, e.value);
3660
3663
  return Promise.resolve();
3661
3664
  }
3662
3665
  let l = a.map((e) => `${e.property} ${o}s ${c} ${s}s`).join(", ");
3663
- i.style.transition = l, us.set(i, r), i.offsetWidth;
3664
- for (let e of a) ds(i, e.property, r), i.style.setProperty(e.property, e.value);
3666
+ i.style.transition = l, fs.set(i, r), i.offsetWidth;
3667
+ for (let e of a) ps(i, e.property, r), i.style.setProperty(e.property, e.value);
3665
3668
  return new Promise((e) => {
3666
3669
  let t = !1, n = () => {
3667
3670
  t || (t = !0, i.removeEventListener("transitionend", r), e());
@@ -3670,15 +3673,15 @@ var ss = (e) => typeof HTMLElement < "u" && e instanceof HTMLElement, cs = /* @_
3670
3673
  };
3671
3674
  i.addEventListener("transitionend", r), setTimeout(n, (o + s) * 1e3 + 60);
3672
3675
  });
3673
- }, ms = (e) => `${Math.round(e * 1e3) / 1e3}s`, hs = /* @__PURE__ */ new WeakSet(), gs = (e) => {
3674
- hs.add(e);
3675
- }, _s = (e) => {
3676
+ }, gs = (e) => `${Math.round(e * 1e3) / 1e3}s`, _s = /* @__PURE__ */ new WeakSet(), vs = (e) => {
3677
+ _s.add(e);
3678
+ }, ys = (e) => {
3676
3679
  let { element: t, expectedName: n, motion: r } = e, i = !1, a = !1, o = (n) => {
3677
- i = !0, t.style.animation = "none", t.offsetWidth, t.style.removeProperty("animation"), n.mode === "clear" ? (t.style.removeProperty("animation-delay"), a = !1) : n.mode === "set" && (ds(t, "animation-delay", e.writer), t.style.animationDelay = ms(n.seconds), a = !0), i = !1;
3680
+ i = !0, t.style.animation = "none", t.offsetWidth, t.style.removeProperty("animation"), n.mode === "clear" ? (t.style.removeProperty("animation-delay"), a = !1) : n.mode === "set" && (ps(t, "animation-delay", e.writer), t.style.animationDelay = gs(n.seconds), a = !0), i = !1;
3678
3681
  }, s = (a) => {
3679
- if (i || a.target !== t || !Ur(a.animationName, n)) return;
3680
- if (hs.has(t)) {
3681
- hs.delete(t);
3682
+ if (i || a.target !== t || !Wr(a.animationName, n)) return;
3683
+ if (_s.has(t)) {
3684
+ _s.delete(t);
3682
3685
  return;
3683
3686
  }
3684
3687
  if (!e.isLive() || e.budgetUsed() >= 4) {
@@ -3710,51 +3713,51 @@ var ss = (e) => typeof HTMLElement < "u" && e instanceof HTMLElement, cs = /* @_
3710
3713
  o({ mode: "clear" });
3711
3714
  }
3712
3715
  };
3713
- }, vs = 2147482e3, ys = /* @__PURE__ */ new WeakMap(), bs = (e, t, n) => {
3716
+ }, bs = 2147482e3, xs = /* @__PURE__ */ new WeakMap(), Ss = (e, t, n) => {
3714
3717
  let r = e.ownerDocument.createElement("div");
3715
3718
  r.setAttribute(xt, ""), r.setAttribute("aria-hidden", "true"), r.style.width = `${t}px`, r.style.height = `${n}px`, r.style.flex = "0 0 auto", r.style.pointerEvents = "none", r.style.visibility = "hidden";
3716
3719
  let i = e.ownerDocument.defaultView?.getComputedStyle(e);
3717
3720
  return i && (r.style.marginTop = i.marginTop, r.style.marginRight = i.marginRight, r.style.marginBottom = i.marginBottom, r.style.marginLeft = i.marginLeft), r;
3718
- }, xs = (e) => {
3719
- e.style.pointerEvents = "none", e.style.zIndex = String(vs);
3720
- }, Ss = (e) => {
3721
+ }, Cs = (e) => {
3722
+ e.style.pointerEvents = "none", e.style.zIndex = String(bs);
3723
+ }, ws = (e) => {
3721
3724
  let t = e.getAttribute(rt), n = e.getAttribute(at), r = e.getAttribute(lt), i = e.getAttribute(ut);
3722
3725
  for (let a of document.querySelectorAll(X(at))) if (a !== e && a.getAttribute("data-flemo-router") === t && a.getAttribute("data-flemo-bar") === n && a.getAttribute("data-flemo-bar-id") === r && a.getAttribute("data-flemo-bar-id-type") === i) return !0;
3723
3726
  return !1;
3724
- }, Cs = (e) => {
3727
+ }, Ts = (e) => {
3725
3728
  let t = [];
3726
- for (let n of e) n && (n.getAttribute("data-flemo-bar-riding") !== "false" && !Ss(n) || t.push(...n.querySelectorAll(X(J))));
3729
+ for (let n of e) n && (n.getAttribute("data-flemo-bar-riding") !== "false" && !ws(n) || t.push(...n.querySelectorAll(X(J))));
3727
3730
  return t;
3728
- }, ws = (e) => {
3731
+ }, Es = (e) => {
3729
3732
  let { scope: t, bars: n, layer: r, strandedMs: i } = e;
3730
3733
  if (!r) return null;
3731
3734
  let a = t.getAttribute($e);
3732
3735
  if (a === null) return null;
3733
- let o = Cs(n);
3736
+ let o = Ts(n);
3734
3737
  if (o.length === 0) return null;
3735
- xs(r);
3738
+ Cs(r);
3736
3739
  let s = [];
3737
3740
  for (let e of o) {
3738
3741
  let t = e.parentNode, n = e.offsetWidth, i = e.offsetHeight;
3739
3742
  if (n <= 0 || i <= 0) continue;
3740
- let o = bs(e, n, i), c = {
3743
+ let o = Ss(e, n, i), c = {
3741
3744
  element: e,
3742
3745
  parent: t,
3743
3746
  nextSibling: e.nextSibling,
3744
3747
  inlineStyle: e.getAttribute("style"),
3745
3748
  standIn: o
3746
3749
  };
3747
- t.insertBefore(o, e), gs(e), Zt(e, () => r.appendChild(e), { includeRoot: !0 });
3748
- let l = Gt(o.getBoundingClientRect(), r);
3750
+ t.insertBefore(o, e), vs(e), Qt(e, () => r.appendChild(e), { includeRoot: !0 });
3751
+ let l = Kt(o.getBoundingClientRect(), r);
3749
3752
  e.setAttribute(bt, a), e.style.position = "absolute", e.style.left = `${l.x}px`, e.style.top = `${l.y}px`, e.style.width = `${l.width}px`, e.style.height = `${l.height}px`, e.style.boxSizing = "border-box", e.style.margin = "0", s.push(c);
3750
3753
  }
3751
3754
  if (s.length === 0) return null;
3752
3755
  let c = () => {
3753
- r.setAttribute(Y, t.getAttribute("data-flemo-anim-hold") ?? jt.RELEASED);
3756
+ r.setAttribute(Y, t.getAttribute("data-flemo-anim-hold") ?? Mt.RELEASED);
3754
3757
  };
3755
3758
  c();
3756
3759
  let l = Symbol("bar-part-staging");
3757
- ys.set(r, l);
3760
+ xs.set(r, l);
3758
3761
  let u = typeof MutationObserver == "function" ? new MutationObserver(c) : null;
3759
3762
  u?.observe(t, {
3760
3763
  attributes: !0,
@@ -3762,74 +3765,74 @@ var ss = (e) => typeof HTMLElement < "u" && e instanceof HTMLElement, cs = /* @_
3762
3765
  });
3763
3766
  let d = !1, f = () => {
3764
3767
  if (!d) {
3765
- d = !0, clearTimeout(p), u?.disconnect(), ys.get(r) === l && (ys.delete(r), r.removeAttribute(Y));
3768
+ d = !0, clearTimeout(p), u?.disconnect(), xs.get(r) === l && (xs.delete(r), r.removeAttribute(Y));
3766
3769
  for (let e of s) {
3767
3770
  if (e.element.removeAttribute(bt), e.inlineStyle === null ? e.element.removeAttribute("style") : e.element.setAttribute("style", e.inlineStyle), !e.parent.isConnected) {
3768
3771
  e.element.remove(), e.standIn.remove();
3769
3772
  continue;
3770
3773
  }
3771
- gs(e.element), Zt(e.element, () => {
3774
+ vs(e.element), Qt(e.element, () => {
3772
3775
  e.standIn.isConnected ? e.standIn.replaceWith(e.element) : e.parent.insertBefore(e.element, e.nextSibling);
3773
3776
  }, { includeRoot: !0 }), e.standIn.remove();
3774
3777
  }
3775
3778
  }
3776
3779
  }, p = setTimeout(f, i);
3777
3780
  return { release: f };
3778
- }, Ts = (e) => {
3781
+ }, Ds = (e) => {
3779
3782
  if (typeof e.querySelectorAll == "function") {
3780
3783
  e.tagName === "IMG" && !e.hasAttribute("decoding") && e.setAttribute("decoding", "async");
3781
3784
  for (let t of Array.from(e.querySelectorAll("img:not([decoding])"))) t.setAttribute("decoding", "async");
3782
3785
  }
3783
- }, Es = 0, Ds = [], Os = [];
3784
- function ks() {
3785
- let e = Es === 0;
3786
- if (Es += 1, e) for (let e of Os) e();
3786
+ }, Os = 0, ks = [], As = [];
3787
+ function js() {
3788
+ let e = Os === 0;
3789
+ if (Os += 1, e) for (let e of As) e();
3787
3790
  let t = !1;
3788
3791
  return () => {
3789
- if (t || (t = !0, --Es, Es > 0)) return;
3790
- let e = Ds;
3791
- Ds = [];
3792
+ if (t || (t = !0, --Os, Os > 0)) return;
3793
+ let e = ks;
3794
+ ks = [];
3792
3795
  for (let t of e) t();
3793
3796
  };
3794
3797
  }
3795
- var As = () => Es > 0;
3796
- function js(e) {
3797
- return Os.push(e), () => {
3798
- Os = Os.filter((t) => t !== e);
3798
+ var Ms = () => Os > 0;
3799
+ function Ns(e) {
3800
+ return As.push(e), () => {
3801
+ As = As.filter((t) => t !== e);
3799
3802
  };
3800
3803
  }
3801
- function Ms(e) {
3802
- Es === 0 ? e() : Ds.push(e);
3804
+ function Ps(e) {
3805
+ Os === 0 ? e() : ks.push(e);
3803
3806
  }
3804
3807
  //#endregion
3805
3808
  //#region src/core/engine/imageDecodeOffloader.ts
3806
- var Ns = 8, Ps = 2, Fs = 96, Is = 15e3, Ls = 3e3, Rs = "data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7", zs = "flemo-image-scale-v1", Bs = new Set(F), Vs = (e) => {
3809
+ var Fs = 8, Is = 2, Ls = 96, Rs = 15e3, zs = 3e3, Bs = "data:image/gif;base64,R0lGODlhAQABAIAAAAAAAP///yH5BAEAAAAALAAAAAABAAEAAAIBRAA7", Vs = "flemo-image-scale-v1", Hs = new Set(P), Us = (e) => {
3807
3810
  let t = e.closest(X($e));
3808
- return !!t && Bs.has(t.getAttribute("data-flemo-status") ?? "");
3809
- }, Hs = (e) => {
3811
+ return !!t && Hs.has(t.getAttribute("data-flemo-status") ?? "");
3812
+ }, Ws = (e) => {
3810
3813
  if (e.naturalWidth <= 0 || e.naturalHeight <= 0 || e.boxWidth <= 0 || e.boxHeight <= 0) return !1;
3811
3814
  let t = e.boxWidth * e.boxHeight * e.devicePixelRatio * e.devicePixelRatio;
3812
3815
  return e.naturalWidth * e.naturalHeight > t * 8;
3813
- }, Us = "onmessage = async (e) => {\n const { url, targetWidth, neededArea, ratio } = e.data;\n try {\n const response = await fetch(url);\n if (!response.ok) throw new Error(\"http \" + response.status);\n const blob = await response.blob();\n const full = await createImageBitmap(blob);\n if (full.width * full.height <= neededArea * ratio) {\n full.close();\n postMessage({ url, skip: true });\n return;\n }\n const scale = targetWidth / full.width;\n const canvas = new OffscreenCanvas(targetWidth, Math.max(1, Math.round(full.height * scale)));\n const context = canvas.getContext(\"2d\");\n context.imageSmoothingQuality = \"high\";\n context.drawImage(full, 0, 0, canvas.width, canvas.height);\n full.close();\n const out = await canvas.convertToBlob({ type: \"image/jpeg\", quality: 0.85 });\n postMessage({ url, blob: out });\n } catch (error) {\n postMessage({ url, error: String(error) });\n }\n};", Ws = () => typeof Worker < "u" && typeof OffscreenCanvas < "u" && typeof createImageBitmap == "function" && typeof MutationObserver < "u" && typeof URL < "u" && typeof URL.createObjectURL == "function", Gs = async (e, t) => {
3816
+ }, Gs = "onmessage = async (e) => {\n const { url, targetWidth, neededArea, ratio } = e.data;\n try {\n const response = await fetch(url);\n if (!response.ok) throw new Error(\"http \" + response.status);\n const blob = await response.blob();\n const full = await createImageBitmap(blob);\n if (full.width * full.height <= neededArea * ratio) {\n full.close();\n postMessage({ url, skip: true });\n return;\n }\n const scale = targetWidth / full.width;\n const canvas = new OffscreenCanvas(targetWidth, Math.max(1, Math.round(full.height * scale)));\n const context = canvas.getContext(\"2d\");\n context.imageSmoothingQuality = \"high\";\n context.drawImage(full, 0, 0, canvas.width, canvas.height);\n full.close();\n const out = await canvas.convertToBlob({ type: \"image/jpeg\", quality: 0.85 });\n postMessage({ url, blob: out });\n } catch (error) {\n postMessage({ url, error: String(error) });\n }\n};", Ks = () => typeof Worker < "u" && typeof OffscreenCanvas < "u" && typeof createImageBitmap == "function" && typeof MutationObserver < "u" && typeof URL < "u" && typeof URL.createObjectURL == "function", qs = async (e, t) => {
3814
3817
  try {
3815
3818
  if (typeof caches > "u") return;
3816
- await (await caches.open(zs)).put(e, new Response(t, { headers: { "content-type": t.type } }));
3819
+ await (await caches.open(Vs)).put(e, new Response(t, { headers: { "content-type": t.type } }));
3817
3820
  } catch {}
3818
- }, Ks = async (e) => {
3821
+ }, Js = async (e) => {
3819
3822
  try {
3820
3823
  if (typeof caches > "u") return null;
3821
- let t = await (await caches.open(zs)).match(e);
3824
+ let t = await (await caches.open(Vs)).match(e);
3822
3825
  return t ? await t.blob() : null;
3823
3826
  } catch {
3824
3827
  return null;
3825
3828
  }
3826
3829
  };
3827
- function qs(e) {
3828
- if (!Ws()) return () => {};
3830
+ function Ys(e) {
3831
+ if (!Ks()) return () => {};
3829
3832
  let t = null, n = !1, r = /* @__PURE__ */ new Map(), i = (e) => !!e && e !== "skip" && e !== "opaque", a = /* @__PURE__ */ new Set(), o = /* @__PURE__ */ new Set(), s = /* @__PURE__ */ new Map(), c = /* @__PURE__ */ new WeakSet(), l = /* @__PURE__ */ new Set(), u = () => typeof devicePixelRatio == "number" ? devicePixelRatio : 1, d = () => {
3830
3833
  if (t) return t;
3831
3834
  try {
3832
- t = new Worker(URL.createObjectURL(new Blob([Us])));
3835
+ t = new Worker(URL.createObjectURL(new Blob([Gs])));
3833
3836
  } catch {
3834
3837
  return null;
3835
3838
  }
@@ -3844,7 +3847,7 @@ function qs(e) {
3844
3847
  return;
3845
3848
  }
3846
3849
  let a = URL.createObjectURL(n);
3847
- l.add(a), Gs(t, n), f(t, a);
3850
+ l.add(a), qs(t, n), f(t, a);
3848
3851
  }, t;
3849
3852
  }, f = (e, t) => {
3850
3853
  r.has(e) || r.set(e, t);
@@ -3853,21 +3856,21 @@ function qs(e) {
3853
3856
  let n = () => {
3854
3857
  t ? e.style.visibility = t : e.style.removeProperty("visibility");
3855
3858
  };
3856
- if (!As()) {
3859
+ if (!Ms()) {
3857
3860
  n();
3858
3861
  return;
3859
3862
  }
3860
3863
  let r = !1, i = () => {
3861
3864
  r || (r = !0, clearTimeout(o), a.delete(i), n());
3862
- }, o = setTimeout(i, Ls);
3863
- a.add(i), Ms(i);
3865
+ }, o = setTimeout(i, zs);
3866
+ a.add(i), Ps(i);
3864
3867
  }, m = (e, t) => {
3865
3868
  let n = () => {
3866
- if (As()) {
3867
- Ms(t);
3869
+ if (Ms()) {
3870
+ Ps(t);
3868
3871
  return;
3869
3872
  }
3870
- if (!Vs(e) || typeof requestAnimationFrame != "function") {
3873
+ if (!Us(e) || typeof requestAnimationFrame != "function") {
3871
3874
  t();
3872
3875
  return;
3873
3876
  }
@@ -3879,10 +3882,10 @@ function qs(e) {
3879
3882
  e.style.visibility = "hidden";
3880
3883
  let r = !1, i = () => {
3881
3884
  r || (r = !0, clearTimeout(o), a.delete(i), t(), n ? e.style.visibility = n : e.style.removeProperty("visibility"));
3882
- }, o = setTimeout(i, Ls);
3885
+ }, o = setTimeout(i, zs);
3883
3886
  a.add(i), m(e, i);
3884
- }, g = (e, t) => !As() && !Vs(e) ? !1 : (e.setAttribute(Vt, t), h(e, () => {}), !0), _ = (e, t, a) => {
3885
- e.setAttribute(Vt, t), e.src = a, h(e, () => {
3887
+ }, g = (e, t) => !Ms() && !Us(e) ? !1 : (e.setAttribute(Ht, t), h(e, () => {}), !0), _ = (e, t, a) => {
3888
+ e.setAttribute(Ht, t), e.src = a, h(e, () => {
3886
3889
  /* v8 ignore next -- disposal runs pending reveals; nothing to repair. */
3887
3890
  if (n) return;
3888
3891
  let a = r.get(t);
@@ -3893,12 +3896,12 @@ function qs(e) {
3893
3896
  if (n) {
3894
3897
  if (s.delete(e), clearTimeout(n.timeout), n.detachListeners?.(), n.responsive) {
3895
3898
  if (i(t)) {
3896
- e.setAttribute(Vt, n.url), e.removeAttribute("srcset"), e.removeAttribute("sizes");
3899
+ e.setAttribute(Ht, n.url), e.removeAttribute("srcset"), e.removeAttribute("sizes");
3897
3900
  let r = e.closest("picture");
3898
3901
  if (r) for (let e of Array.from(r.querySelectorAll("source"))) e.removeAttribute("srcset");
3899
3902
  e.src = t;
3900
3903
  }
3901
- } else e.getAttribute("src") === Rs && (i(t) ? e.src = t : (e.removeAttribute(Vt), e.src = n.url));
3904
+ } else e.getAttribute("src") === Bs && (i(t) ? e.src = t : (e.removeAttribute(Ht), e.src = n.url));
3902
3905
  p(e, n.previousVisibility);
3903
3906
  }
3904
3907
  }, y = /* @__PURE__ */ new Map(), b = !1, x = () => {
@@ -3907,14 +3910,14 @@ function qs(e) {
3907
3910
  y.clear();
3908
3911
  for (let [t, n] of e) C(t, n.boxWidth, n.boxHeight);
3909
3912
  }, S = () => {
3910
- b || (b = !0, Ms(() => {
3913
+ b || (b = !0, Ps(() => {
3911
3914
  if (n) return;
3912
3915
  let e = globalThis.requestIdleCallback;
3913
3916
  typeof e == "function" ? e(() => x()) : typeof setTimeout == "function" ? setTimeout(x, 400) : x();
3914
3917
  }));
3915
3918
  }, C = (e, t, n) => {
3916
3919
  if (r.has(e) || o.has(e)) return;
3917
- if (As() && la()) {
3920
+ if (Ms() && ua()) {
3918
3921
  y.has(e) || y.set(e, {
3919
3922
  boxWidth: t,
3920
3923
  boxHeight: n
@@ -3924,28 +3927,28 @@ function qs(e) {
3924
3927
  let i = d();
3925
3928
  if (!i) return;
3926
3929
  o.add(e);
3927
- let a = Math.round(Math.max(Fs, t * u()) * Ps), s = Math.max(t * n, 9216) * u() ** 2;
3930
+ let a = Math.round(Math.max(Ls, t * u()) * Is), s = Math.max(t * n, 9216) * u() ** 2;
3928
3931
  i.postMessage({
3929
3932
  url: e,
3930
3933
  targetWidth: a,
3931
3934
  neededArea: s,
3932
3935
  ratio: 8
3933
3936
  });
3934
- }, w = js(() => {
3935
- if (la() && !(!t || o.size === 0)) {
3937
+ }, w = Ns(() => {
3938
+ if (ua() && !(!t || o.size === 0)) {
3936
3939
  t.terminate(), t = null;
3937
3940
  for (let e of o) {
3938
3941
  if (y.has(e)) continue;
3939
3942
  let t = {
3940
- boxWidth: Fs,
3941
- boxHeight: Fs
3943
+ boxWidth: Ls,
3944
+ boxHeight: Ls
3942
3945
  };
3943
3946
  for (let [n, r] of s) {
3944
3947
  if (r.url !== e) continue;
3945
3948
  let i = n.getBoundingClientRect();
3946
3949
  t = {
3947
- boxWidth: i.width || Fs,
3948
- boxHeight: i.height || Fs
3950
+ boxWidth: i.width || Ls,
3951
+ boxHeight: i.height || Ls
3949
3952
  };
3950
3953
  break;
3951
3954
  }
@@ -3959,17 +3962,17 @@ function qs(e) {
3959
3962
  let a = {
3960
3963
  url: "",
3961
3964
  previousVisibility: e.style.visibility,
3962
- timeout: setTimeout(() => v(e, null), Is),
3965
+ timeout: setTimeout(() => v(e, null), Rs),
3963
3966
  responsive: !0
3964
3967
  }, o = () => {
3965
3968
  /* v8 ignore next -- consider() only routes elements with an https src
3966
3969
  here, so the final fallback arm is unreachable. */
3967
3970
  let t = e.currentSrc || e.getAttribute("src") || "", i = e.getBoundingClientRect();
3968
- if (!(/^https?:/.test(t) && Hs({
3971
+ if (!(/^https?:/.test(t) && Ws({
3969
3972
  naturalWidth: e.naturalWidth,
3970
3973
  naturalHeight: e.naturalHeight,
3971
- boxWidth: i.width || Fs,
3972
- boxHeight: i.height || Fs,
3974
+ boxWidth: i.width || Ls,
3975
+ boxHeight: i.height || Ls,
3973
3976
  devicePixelRatio: u()
3974
3977
  }))) {
3975
3978
  v(e, null);
@@ -3981,7 +3984,7 @@ function qs(e) {
3981
3984
  v(e, o);
3982
3985
  return;
3983
3986
  }
3984
- Ks(t).then((a) => {
3987
+ Js(t).then((a) => {
3985
3988
  if (!(n || !s.has(e))) {
3986
3989
  /* v8 ignore start -- a verdict can only appear via settle(), which
3987
3990
  releases every held element of the url first, so a still-held
@@ -3997,7 +4000,7 @@ function qs(e) {
3997
4000
  l.add(e), f(t, e);
3998
4001
  return;
3999
4002
  }
4000
- C(t, i.width || Fs, i.height || Fs);
4003
+ C(t, i.width || Ls, i.height || Ls);
4001
4004
  }
4002
4005
  });
4003
4006
  };
@@ -4020,20 +4023,20 @@ function qs(e) {
4020
4023
  if (c.add(e), e.complete && e.naturalWidth > 0) {
4021
4024
  if (!t) {
4022
4025
  let t = e.getBoundingClientRect();
4023
- C(a, t.width || Fs, t.height || Fs);
4026
+ C(a, t.width || Ls, t.height || Ls);
4024
4027
  return;
4025
4028
  }
4026
4029
  let n = e.getBoundingClientRect();
4027
- if (!Hs({
4030
+ if (!Ws({
4028
4031
  naturalWidth: e.naturalWidth,
4029
4032
  naturalHeight: e.naturalHeight,
4030
- boxWidth: n.width || Fs,
4031
- boxHeight: n.height || Fs,
4033
+ boxWidth: n.width || Ls,
4034
+ boxHeight: n.height || Ls,
4032
4035
  devicePixelRatio: u()
4033
4036
  })) return;
4034
4037
  let o = r.get(a);
4035
4038
  if (i(o)) {
4036
- As() || Vs(e) ? _(e, a, o) : (e.setAttribute(Vt, a), e.src = o);
4039
+ Ms() || Us(e) ? _(e, a, o) : (e.setAttribute(Ht, a), e.src = o);
4037
4040
  return;
4038
4041
  }
4039
4042
  if (o === "opaque") {
@@ -4049,14 +4052,14 @@ function qs(e) {
4049
4052
  return;
4050
4053
  }
4051
4054
  if (o) {
4052
- As() || Vs(e) ? _(e, a, o) : (e.setAttribute(Vt, a), e.src = o);
4055
+ Ms() || Us(e) ? _(e, a, o) : (e.setAttribute(Ht, a), e.src = o);
4053
4056
  return;
4054
4057
  }
4055
4058
  s.set(e, {
4056
4059
  url: a,
4057
4060
  previousVisibility: e.style.visibility,
4058
- timeout: setTimeout(() => v(e, null), Is)
4059
- }), e.style.visibility = "hidden", e.setAttribute(Vt, a), e.src = Rs, Ks(a).then((t) => {
4061
+ timeout: setTimeout(() => v(e, null), Rs)
4062
+ }), e.style.visibility = "hidden", e.setAttribute(Ht, a), e.src = Bs, Js(a).then((t) => {
4060
4063
  if (n || r.has(a)) return;
4061
4064
  if (t) {
4062
4065
  let e = URL.createObjectURL(t);
@@ -4066,7 +4069,7 @@ function qs(e) {
4066
4069
  let i = () => {
4067
4070
  if (n) return;
4068
4071
  let t = e.getBoundingClientRect();
4069
- C(a, t.width || Fs, t.height || Fs);
4072
+ C(a, t.width || Ls, t.height || Ls);
4070
4073
  };
4071
4074
  typeof requestAnimationFrame == "function" ? requestAnimationFrame(i) : i();
4072
4075
  });
@@ -4083,23 +4086,23 @@ function qs(e) {
4083
4086
  let k = (e) => {
4084
4087
  let t = e.getAttribute("src") ?? "", n = s.get(e);
4085
4088
  if (n && !n.responsive) {
4086
- t === n.url && (e.src = Rs);
4089
+ t === n.url && (e.src = Bs);
4087
4090
  return;
4088
4091
  }
4089
- let a = e.getAttribute(Vt);
4092
+ let a = e.getAttribute(Ht);
4090
4093
  if (a) {
4091
4094
  if (t === a) {
4092
4095
  let t = r.get(a);
4093
4096
  i(t) && (e.src = t);
4094
- } else t !== Rs && !t.startsWith("blob:") && e.removeAttribute(Vt);
4097
+ } else t !== Bs && !t.startsWith("blob:") && e.removeAttribute(Ht);
4095
4098
  }
4096
4099
  }, A = !1, j = new MutationObserver((t) => {
4097
4100
  if (!n) {
4098
- if (As()) {
4101
+ if (Ms()) {
4099
4102
  if (A) return;
4100
- A = !0, Ms(() => {
4103
+ A = !0, Ps(() => {
4101
4104
  if (A = !1, !n) {
4102
- for (let t of Array.from(e.querySelectorAll(`img[${Vt}]`))) k(t);
4105
+ for (let t of Array.from(e.querySelectorAll(`img[${Ht}]`))) k(t);
4103
4106
  for (let e of [...s.keys()]) k(e);
4104
4107
  }
4105
4108
  });
@@ -4121,29 +4124,29 @@ function qs(e) {
4121
4124
  l.clear();
4122
4125
  };
4123
4126
  }
4124
- var Js = null;
4125
- function Ys() {
4126
- return typeof document > "u" || !document.body ? () => {} : (Js ? Js.count += 1 : Js = {
4127
- dispose: qs(document.body),
4127
+ var Xs = null;
4128
+ function Zs() {
4129
+ return typeof document > "u" || !document.body ? () => {} : (Xs ? Xs.count += 1 : Xs = {
4130
+ dispose: Ys(document.body),
4128
4131
  count: 1
4129
4132
  }, () => {
4130
- Js && (--Js.count, Js.count <= 0 && (Js.dispose(), Js = null));
4133
+ Xs && (--Xs.count, Xs.count <= 0 && (Xs.dispose(), Xs = null));
4131
4134
  });
4132
4135
  }
4133
4136
  //#endregion
4134
4137
  //#region src/core/engine/arrivalHold.ts
4135
- var Xs = [
4138
+ var Qs = [
4136
4139
  X(J),
4137
4140
  X(St),
4138
- X(Et),
4139
- X(Nt),
4140
- X(Vt)
4141
+ X(Dt),
4142
+ X(Pt),
4143
+ X(Ht)
4141
4144
  ].join(", ");
4142
- function Zs(e) {
4145
+ function $s(e) {
4143
4146
  if (typeof MutationObserver > "u") return () => {};
4144
4147
  let t = /* @__PURE__ */ new Set(), n = /* @__PURE__ */ new Set(), r = /* @__PURE__ */ new Set(), i = /* @__PURE__ */ new Map(), a = /* @__PURE__ */ new Map(), o = (t) => {
4145
4148
  let n = t instanceof Element ? t : t.parentElement;
4146
- return !n || n === e || n.closest(Xs) !== null;
4149
+ return !n || n === e || n.closest(Qs) !== null;
4147
4150
  }, s = (e, t, n, r) => e ? n === e.glass ? (e.pendingEcho ? e.pendingEcho = !1 : e.latest = n, e) : (e.latest = n, r(e.glass), e.pendingEcho = !0, e) : n === t ? null : (r(t), {
4148
4151
  glass: t,
4149
4152
  latest: n,
@@ -4173,12 +4176,12 @@ function Zs(e) {
4173
4176
  if (i.type === "childList") {
4174
4177
  for (let e of Array.from(i.removedNodes)) if (!n.has(e)) {
4175
4178
  if (e instanceof Element && t.delete(e)) {
4176
- e.removeAttribute(Nt);
4179
+ e.removeAttribute(Pt);
4177
4180
  continue;
4178
4181
  }
4179
4182
  (e instanceof Element || e.nodeType === Node.TEXT_NODE) && l(i.target).removed.push(e);
4180
4183
  }
4181
- for (let e of Array.from(i.addedNodes)) r.delete(e) || e instanceof Element && (e.closest(Xs) || (e.setAttribute(Nt, ""), t.add(e), l(i.target).added.push(e)));
4184
+ for (let e of Array.from(i.addedNodes)) r.delete(e) || e instanceof Element && (e.closest(Qs) || (e.setAttribute(Pt, ""), t.add(e), l(i.target).added.push(e)));
4182
4185
  }
4183
4186
  }
4184
4187
  for (let [e, t] of u) {
@@ -4213,7 +4216,7 @@ function Zs(e) {
4213
4216
  c.disconnect();
4214
4217
  for (let e of n) e.parentNode?.removeChild(e);
4215
4218
  n.clear();
4216
- for (let e of t) e instanceof HTMLElement && Ts(e), e.removeAttribute(Nt);
4219
+ for (let e of t) e instanceof HTMLElement && Ds(e), e.removeAttribute(Pt);
4217
4220
  t.clear();
4218
4221
  for (let [e, t] of i) e.isConnected && (e.nodeValue = t.latest);
4219
4222
  i.clear();
@@ -4223,41 +4226,41 @@ function Zs(e) {
4223
4226
  }
4224
4227
  //#endregion
4225
4228
  //#region src/core/engine/compositorWarmUp.ts
4226
- var Qs = 3e3, $s = [{ backgroundPosition: "0px 0px" }, { backgroundPosition: "48px 0px" }], ec = {
4229
+ var ec = 3e3, tc = [{ backgroundPosition: "0px 0px" }, { backgroundPosition: "48px 0px" }], nc = {
4227
4230
  duration: 500,
4228
4231
  iterations: Infinity,
4229
4232
  direction: "alternate",
4230
4233
  easing: "linear"
4231
- }, tc = "position:fixed;top:0;left:0;width:48px;height:48px;pointer-events:none;opacity:0.006;background-image:linear-gradient(90deg,#808080 0 24px,#909090 24px 48px);background-repeat:repeat;background-size:48px 48px;", nc = null, rc = null, ic = 0, ac = () => {
4232
- ic = 0, rc?.pause(), nc?.setAttribute(zt, "idle");
4234
+ }, rc = "position:fixed;top:0;left:0;width:48px;height:48px;pointer-events:none;opacity:0.006;background-image:linear-gradient(90deg,#808080 0 24px,#909090 24px 48px);background-repeat:repeat;background-size:48px 48px;", ic = null, ac = null, oc = 0, sc = () => {
4235
+ oc = 0, ac?.pause(), ic?.setAttribute(Bt, "idle");
4233
4236
  };
4234
- function oc() {
4237
+ function cc() {
4235
4238
  if (typeof document > "u" || !document.body || typeof Element > "u" || typeof Element.prototype.animate != "function") return () => {};
4236
- if (ic += 1, nc && !nc.isConnected && (rc?.cancel(), rc = null, nc = null), nc) ic === 1 && (nc.setAttribute(zt, "on"), rc?.play());
4239
+ if (oc += 1, ic && !ic.isConnected && (ac?.cancel(), ac = null, ic = null), ic) oc === 1 && (ic.setAttribute(Bt, "on"), ac?.play());
4237
4240
  else {
4238
- nc = document.createElement("div"), nc.setAttribute(zt, "on"), nc.setAttribute("aria-hidden", "true"), nc.setAttribute("style", tc), document.body.appendChild(nc);
4241
+ ic = document.createElement("div"), ic.setAttribute(Bt, "on"), ic.setAttribute("aria-hidden", "true"), ic.setAttribute("style", rc), document.body.appendChild(ic);
4239
4242
  try {
4240
- rc = nc.animate($s, ec);
4243
+ ac = ic.animate(tc, nc);
4241
4244
  } catch {
4242
- rc = null;
4245
+ ac = null;
4243
4246
  }
4244
4247
  }
4245
4248
  let e = !1, t = setTimeout(() => {
4246
- e || (e = !0, --ic, ic <= 0 && ac());
4247
- }, Qs);
4249
+ e || (e = !0, --oc, oc <= 0 && sc());
4250
+ }, ec);
4248
4251
  return () => {
4249
- e || (e = !0, clearTimeout(t), --ic, ic <= 0 && ac());
4252
+ e || (e = !0, clearTimeout(t), --oc, oc <= 0 && sc());
4250
4253
  };
4251
4254
  }
4252
4255
  //#endregion
4253
4256
  //#region src/core/engine/emulationNotice.ts
4254
- var sc = () => {
4257
+ var lc = () => {
4255
4258
  if (typeof navigator > "u") return !1;
4256
4259
  let e = navigator.platform ?? "";
4257
4260
  return /Mac/i.test(e) ? (navigator.maxTouchPoints ?? 0) > 0 : !1;
4258
- }, cc = !1, lc = () => {
4259
- cc || !la() || !sc() || (cc = !0, console.warn("[flemo] DevTools device emulation detected. The emulated view is composited through an extra scaling pass, so transitions can show text shimmer and settle flashes that do NOT exist in a plain window or on a real device. Judge motion quality outside device emulation."));
4260
- }, uc = (e) => {
4261
+ }, uc = !1, dc = () => {
4262
+ uc || !ua() || !lc() || (uc = !0, console.warn("[flemo] DevTools device emulation detected. The emulated view is composited through an extra scaling pass, so transitions can show text shimmer and settle flashes that do NOT exist in a plain window or on a real device. Judge motion quality outside device emulation."));
4263
+ }, fc = (e) => {
4261
4264
  let t = e.parentElement ?? e, n = Array.from(t.querySelectorAll(`[${J}]`)).filter((n) => {
4262
4265
  let r = n.closest(X($e));
4263
4266
  return !r || r === e || !t.contains(r);
@@ -4265,17 +4268,17 @@ var sc = () => {
4265
4268
  if (r === null) return n;
4266
4269
  let i = Array.from(e.ownerDocument.querySelectorAll(Z(bt, r)));
4267
4270
  return i.length === 0 ? n : [...n, ...i];
4268
- }, dc = (e, t) => {
4271
+ }, pc = (e, t) => {
4269
4272
  let [n, r] = t.split("-");
4270
- return uc(e).filter((e) => e.getAttribute("data-flemo-status") === n && e.getAttribute("data-flemo-active") === r);
4271
- }, fc = (e, t) => {
4273
+ return fc(e).filter((e) => e.getAttribute("data-flemo-status") === n && e.getAttribute("data-flemo-active") === r);
4274
+ }, mc = (e, t) => {
4272
4275
  let n = e.closest(X("data-flemo-router"))?.getAttribute("data-flemo-router") ?? null;
4273
4276
  return Array.from(e.ownerDocument.querySelectorAll(`${X(J)}${Z(et, t)}`)).filter((e) => {
4274
4277
  if (n === null) return !0;
4275
4278
  let t = e.closest(X(rt));
4276
4279
  return !t || t.getAttribute(rt) === n;
4277
4280
  });
4278
- }, pc = (e, t) => fc(e, t).filter((e) => e.parentElement?.closest(`[${Y}]`) == null), mc = (e) => {
4281
+ }, hc = (e, t) => mc(e, t).filter((e) => e.parentElement?.closest(`[${Y}]`) == null), gc = (e) => {
4279
4282
  let t = e.closest(X("data-flemo-router"))?.getAttribute("data-flemo-router") ?? null;
4280
4283
  return Array.from(e.ownerDocument.querySelectorAll(`[${J}][${Y}]`)).filter((e) => {
4281
4284
  /* v8 ignore next -- a part reached by a document query always has a parent;
@@ -4285,16 +4288,16 @@ var sc = () => {
4285
4288
  let n = e.closest(X(rt));
4286
4289
  return !n || n.getAttribute("data-flemo-router") === t;
4287
4290
  });
4288
- }, hc = (e, t, n) => {
4291
+ }, _c = (e, t, n) => {
4289
4292
  let r = 0;
4290
4293
  for (let e of [`${n}-true`, `${n}-false`]) {
4291
- if (!Xr(t, e)) continue;
4294
+ if (!Zr(t, e)) continue;
4292
4295
  let n = q(t, e);
4293
4296
  r = Math.max(r, (n.delay + n.duration) * 1e3);
4294
4297
  }
4295
- for (let i of fc(e, n)) {
4298
+ for (let i of mc(e, n)) {
4296
4299
  let e = Be(i.getAttribute(J), t), a = `${n}-${i.getAttribute(tt)}`;
4297
- if (!e || !Xr(e, a)) continue;
4300
+ if (!e || !Zr(e, a)) continue;
4298
4301
  let o = q(e, a);
4299
4302
  r = Math.max(r, (o.delay + o.duration) * 1e3);
4300
4303
  }
@@ -4302,31 +4305,31 @@ var sc = () => {
4302
4305
  if (i) {
4303
4306
  let e = Fe(t, i);
4304
4307
  for (let t of [`${n}-true`, `${n}-false`]) {
4305
- if (!Xr(e, t)) continue;
4308
+ if (!Zr(e, t)) continue;
4306
4309
  let n = q(e, t);
4307
4310
  r = Math.max(r, (n.delay + n.duration) * 1e3);
4308
4311
  }
4309
4312
  }
4310
4313
  return r;
4311
- }, gc = () => {}, _c = .004, vc = (e, t) => {
4314
+ }, vc = () => {}, yc = .004, bc = (e, t) => {
4312
4315
  let n = e.ownerDocument?.defaultView;
4313
4316
  if (!n) return !1;
4314
4317
  let r = e;
4315
4318
  for (; r;) {
4316
- if (Number(n.getComputedStyle(r).opacity) <= _c) return !0;
4319
+ if (Number(n.getComputedStyle(r).opacity) <= yc) return !0;
4317
4320
  if (r === t) break;
4318
4321
  r = r.parentElement;
4319
4322
  }
4320
4323
  return !1;
4321
4324
  };
4322
- function yc(e) {
4323
- if (typeof e.getAnimations != "function") return gc;
4325
+ function xc(e) {
4326
+ if (typeof e.getAnimations != "function") return vc;
4324
4327
  let t = /* @__PURE__ */ new Set(), n = () => {
4325
4328
  for (let n of e.getAnimations({ subtree: !0 })) {
4326
4329
  if (t.size >= 128) return;
4327
4330
  if (t.has(n) || (n.animationName ?? "").startsWith("flemo-") || n.playState !== "running") continue;
4328
4331
  let r = n.effect?.target;
4329
- if (r instanceof Element && vc(r, e)) try {
4332
+ if (r instanceof Element && bc(r, e)) try {
4330
4333
  n.pause(), t.add(n);
4331
4334
  } catch {}
4332
4335
  }
@@ -4355,41 +4358,41 @@ function yc(e) {
4355
4358
  }
4356
4359
  //#endregion
4357
4360
  //#region src/core/engine/responseHold.ts
4358
- var bc = !1, xc = 0, Sc = [], Cc = () => {
4359
- let e = Sc;
4360
- Sc = [];
4361
+ var Sc = !1, Cc = 0, wc = [], Tc = () => {
4362
+ let e = wc;
4363
+ wc = [];
4361
4364
  for (let t of e) t();
4362
- }, wc = (e) => /event-stream/i.test(e.headers.get("content-type") ?? ""), Tc = () => {
4363
- if (bc || typeof window > "u" || typeof window.fetch != "function") return;
4364
- bc = !0;
4365
+ }, Ec = (e) => /event-stream/i.test(e.headers.get("content-type") ?? ""), Dc = () => {
4366
+ if (Sc || typeof window > "u" || typeof window.fetch != "function") return;
4367
+ Sc = !0;
4365
4368
  let e = window.fetch.bind(window);
4366
- window.fetch = (...t) => e(...t).then((e) => xc <= 0 || wc(e) ? e : new Promise((t) => {
4367
- Sc.push(() => t(e));
4369
+ window.fetch = (...t) => e(...t).then((e) => Cc <= 0 || Ec(e) ? e : new Promise((t) => {
4370
+ wc.push(() => t(e));
4368
4371
  }), (e) => {
4369
- if (xc <= 0) throw e;
4372
+ if (Cc <= 0) throw e;
4370
4373
  return new Promise((t, n) => {
4371
- Sc.push(() => n(e));
4374
+ wc.push(() => n(e));
4372
4375
  });
4373
4376
  });
4374
- }, Ec = 2e3;
4375
- function Dc(e = Ec) {
4377
+ }, Oc = 2e3;
4378
+ function kc(e = Oc) {
4376
4379
  /* v8 ignore next -- SSR guard: without fetch there is nothing to hold. */
4377
- if (Tc(), !bc) return () => {};
4378
- xc += 1;
4380
+ if (Dc(), !Sc) return () => {};
4381
+ Cc += 1;
4379
4382
  let t = !1, n = null, r = () => {
4380
- t || (t = !0, n !== null && clearTimeout(n), xc = Math.max(0, xc - 1), xc === 0 && Cc());
4383
+ t || (t = !0, n !== null && clearTimeout(n), Cc = Math.max(0, Cc - 1), Cc === 0 && Tc());
4381
4384
  };
4382
- return typeof setTimeout == "function" && (n = setTimeout(r, Math.max(Ec, e))), r;
4385
+ return typeof setTimeout == "function" && (n = setTimeout(r, Math.max(Oc, e))), r;
4383
4386
  }
4384
- Tc();
4387
+ Dc();
4385
4388
  //#endregion
4386
4389
  //#region src/core/engine/flightHolds.ts
4387
- var Oc = 1500, kc = 400, Ac = (e) => {
4390
+ var Ac = 1500, jc = 400, Mc = (e) => {
4388
4391
  let t = null, n = null, r = null;
4389
4392
  return { sync: ({ isTransitional: i, isActive: a, status: o, transitionName: s, getScope: c }) => {
4390
- i && (lc(), r &&= (clearTimeout(r), null), n ||= oc()), !i && n && !r && (typeof setTimeout == "function" ? r = setTimeout(() => {
4393
+ i && (dc(), r &&= (clearTimeout(r), null), n ||= cc()), !i && n && !r && (typeof setTimeout == "function" ? r = setTimeout(() => {
4391
4394
  r = null, n?.(), n = null;
4392
- }, kc) : (n(), n = null));
4395
+ }, jc) : (n(), n = null));
4393
4396
  let l = i && (a ? o === "PUSHING" || o === "REPLACING" : o === "POPPING");
4394
4397
  if (!l && t) {
4395
4398
  let n = t;
@@ -4399,35 +4402,35 @@ var Oc = 1500, kc = 400, Ac = (e) => {
4399
4402
  e.landNow();
4400
4403
  let n = c();
4401
4404
  if (n) {
4402
- fs(n);
4403
- let e = Zs(n), r = yc(n), i = Dc(hc(n, we(s), o) + Oc), a = ks();
4405
+ ms(n);
4406
+ let e = $s(n), r = xc(n), i = kc(_c(n, we(s), o) + Ac), a = js();
4404
4407
  t = () => {
4405
4408
  i(), r(), e(), a();
4406
4409
  };
4407
4410
  }
4408
4411
  }
4409
4412
  } };
4410
- }, jc = (e, t) => {
4413
+ }, Nc = (e, t) => {
4411
4414
  for (let n of Array.from(e.children)) {
4412
4415
  let e = n;
4413
4416
  if (e.matches(t)) return e;
4414
4417
  }
4415
4418
  return null;
4416
- }, Mc = (e) => {
4419
+ }, Pc = (e) => {
4417
4420
  if (!e) return [];
4418
- let t = jc(e, X(gt));
4421
+ let t = Nc(e, X(gt));
4419
4422
  if (t) return [t];
4420
- let n = jc(e, X($e))?.getAttribute($e);
4423
+ let n = Nc(e, X($e))?.getAttribute($e);
4421
4424
  return n ? Array.from(document.querySelectorAll(X(_t) + Z(vt, n))) : [];
4422
- }, Nc = (e) => e ? e.getAttribute("data-flemo-bar-riding") === "true" || e.hasAttribute("data-flemo-layer-host") || e.hasAttribute("data-flemo-layer-slot") : !1, Pc = 1e3 / 60 * 2, Fc = "flemo-", Ic = /* @__PURE__ */ new WeakMap(), Lc = (e, t, n) => {
4425
+ }, Fc = (e) => e ? e.getAttribute("data-flemo-bar-riding") === "true" || e.hasAttribute("data-flemo-layer-host") || e.hasAttribute("data-flemo-layer-slot") : !1, Ic = 1e3 / 60 * 2, Lc = "flemo-", Rc = /* @__PURE__ */ new WeakMap(), zc = (e, t, n) => {
4423
4426
  if (typeof e.getAnimations == "function") for (let r of e.getAnimations({ subtree: !0 })) {
4424
4427
  let e = r.animationName;
4425
- if (typeof e != "string" || !e.startsWith(Fc) || r.playState !== "running" || Ic.get(r) === n) continue;
4428
+ if (typeof e != "string" || !e.startsWith(Lc) || r.playState !== "running" || Rc.get(r) === n) continue;
4426
4429
  let i = r.startTime;
4427
- typeof i == "number" && (r.startTime = i + t, Ic.set(r, n));
4430
+ typeof i == "number" && (r.startTime = i + t, Rc.set(r, n));
4428
4431
  }
4429
- }, Rc = /* @__PURE__ */ new WeakSet(), zc = 1e3, Bc = 3e3;
4430
- function Vc(e, t, n) {
4432
+ }, Bc = /* @__PURE__ */ new WeakSet(), Vc = 1e3, Hc = 3e3;
4433
+ function Uc(e, t, n) {
4431
4434
  if (typeof MutationObserver > "u" || typeof requestAnimationFrame != "function") return () => {};
4432
4435
  let r = 0, i = !1, a = !1, o = !1, s = null, c = [], l = null, u = () => {
4433
4436
  s !== null && (clearTimeout(s), s = null);
@@ -4441,7 +4444,7 @@ function Vc(e, t, n) {
4441
4444
  i = !0, m.disconnect();
4442
4445
  for (let e of t()) if (!(!e || typeof e.getAnimations != "function")) for (let t of e.getAnimations({ subtree: !0 })) {
4443
4446
  let e = t.animationName;
4444
- if (typeof e != "string" || !e.startsWith(Fc) || t.playState !== "running" || Rc.has(t)) continue;
4447
+ if (typeof e != "string" || !e.startsWith(Lc) || t.playState !== "running" || Bc.has(t)) continue;
4445
4448
  let n = t.currentTime;
4446
4449
  if (!(typeof n == "number" && n > 33.333333333333336)) {
4447
4450
  try {
@@ -4449,18 +4452,18 @@ function Vc(e, t, n) {
4449
4452
  } catch {
4450
4453
  continue;
4451
4454
  }
4452
- Rc.add(t), c.push(t);
4455
+ Bc.add(t), c.push(t);
4453
4456
  }
4454
4457
  }
4455
4458
  if (c.length === 0) return;
4456
- r = requestAnimationFrame(f), typeof setTimeout == "function" && (s = setTimeout(f, zc));
4457
- let e = Kc(t, () => {
4459
+ r = requestAnimationFrame(f), typeof setTimeout == "function" && (s = setTimeout(f, Vc));
4460
+ let e = Jc(t, () => {
4458
4461
  a || n?.();
4459
4462
  });
4460
4463
  if (l = e, typeof setTimeout == "function") {
4461
4464
  let t = setTimeout(() => {
4462
4465
  l === e && (l = null), e();
4463
- }, Bc), n = e;
4466
+ }, Hc), n = e;
4464
4467
  l = () => {
4465
4468
  clearTimeout(t), n();
4466
4469
  };
@@ -4475,16 +4478,16 @@ function Vc(e, t, n) {
4475
4478
  a = !0, m.disconnect(), r &&= (cancelAnimationFrame(r), 0), u(), l?.(), l = null, i && !o && d();
4476
4479
  };
4477
4480
  }
4478
- var Hc = 150, Uc = 4e3, Wc = 400;
4479
- function Gc(e, t, n = !0, r = !1) {
4481
+ var Wc = 150, Gc = 4e3, Kc = 400;
4482
+ function qc(e, t, n = !0, r = !1) {
4480
4483
  /* v8 ignore next -- same rAF guard as the watcher below. */
4481
4484
  if (typeof requestAnimationFrame != "function") return () => {};
4482
4485
  let i = [], a = /* @__PURE__ */ new Map();
4483
4486
  for (let t of e()) if (!(!t || typeof t.getAnimations != "function")) for (let e of t.getAnimations({ subtree: !0 })) {
4484
4487
  let t = e.animationName;
4485
- if (typeof t != "string" || !t.startsWith(Fc) || e.playState !== "running" || Rc.has(e)) continue;
4488
+ if (typeof t != "string" || !t.startsWith(Lc) || e.playState !== "running" || Bc.has(e)) continue;
4486
4489
  let n = e.currentTime;
4487
- typeof n == "number" && n > 33.333333333333336 || (n === null || typeof n == "number") && (Rc.add(e), i.push(e), a.set(e, typeof n == "number" ? n : 0));
4490
+ typeof n == "number" && n > 33.333333333333336 || (n === null || typeof n == "number") && (Bc.add(e), i.push(e), a.set(e, typeof n == "number" ? n : 0));
4488
4491
  }
4489
4492
  if (i.length === 0) return () => {};
4490
4493
  let o = 0, s = null, c = !1, l = !1, u = !1, d = null, f = null, p = 0, m = (e) => {
@@ -4497,7 +4500,7 @@ function Gc(e, t, n = !0, r = !1) {
4497
4500
  if (typeof r != "number" || typeof i != "number") continue;
4498
4501
  let o = (a.get(n) ?? 0) + e;
4499
4502
  n.startTime = i + (r - o), a.set(n, o);
4500
- let s = r + Uc;
4503
+ let s = r + Gc;
4501
4504
  t = Math.max(t, s - o);
4502
4505
  }
4503
4506
  return t;
@@ -4505,7 +4508,7 @@ function Gc(e, t, n = !0, r = !1) {
4505
4508
  if (c) return;
4506
4509
  if (d === null && (d = e), f !== null) {
4507
4510
  let t = e - f;
4508
- p += Math.min(Math.max(0, t), Pc);
4511
+ p += Math.min(Math.max(0, t), Ic);
4509
4512
  }
4510
4513
  if (f = e, !l) {
4511
4514
  if (l = !0, r) {
@@ -4517,7 +4520,7 @@ function Gc(e, t, n = !0, r = !1) {
4517
4520
  if (typeof n != "number" || typeof r != "number") continue;
4518
4521
  let i = a.get(t) ?? 0;
4519
4522
  if (n <= i + 33.333333333333336) continue;
4520
- let o = n - (i + Pc);
4523
+ let o = n - (i + Ic);
4521
4524
  t.startTime = r + o, e = Math.max(e, o);
4522
4525
  }
4523
4526
  e > 0 && t?.(e);
@@ -4531,13 +4534,13 @@ function Gc(e, t, n = !0, r = !1) {
4531
4534
  if (e.playState !== "running") continue;
4532
4535
  let t = e.startTime;
4533
4536
  if (typeof t == "number") {
4534
- e.startTime = t + Uc;
4537
+ e.startTime = t + Gc;
4535
4538
  continue;
4536
4539
  }
4537
4540
  let n = e.timeline?.currentTime;
4538
- typeof n == "number" && (e.startTime = n + Uc);
4541
+ typeof n == "number" && (e.startTime = n + Gc);
4539
4542
  }
4540
- typeof setTimeout == "function" && (s = setTimeout(() => m(p + Pc), Wc)), o = requestAnimationFrame(h);
4543
+ typeof setTimeout == "function" && (s = setTimeout(() => m(p + Ic), Kc)), o = requestAnimationFrame(h);
4541
4544
  return;
4542
4545
  }
4543
4546
  if (!u) {
@@ -4560,13 +4563,13 @@ function Gc(e, t, n = !0, r = !1) {
4560
4563
  t?.(g);
4561
4564
  return;
4562
4565
  }
4563
- e - d < Hc && (o = requestAnimationFrame(h));
4566
+ e - d < Wc && (o = requestAnimationFrame(h));
4564
4567
  };
4565
4568
  return o = requestAnimationFrame(h), () => {
4566
- c = !0, cancelAnimationFrame(o), s !== null && clearTimeout(s), l && !u && m(p + Pc);
4569
+ c = !0, cancelAnimationFrame(o), s !== null && clearTimeout(s), l && !u && m(p + Ic);
4567
4570
  };
4568
4571
  }
4569
- function Kc(e, t) {
4572
+ function Jc(e, t) {
4570
4573
  /* v8 ignore next -- every runtime under test has rAF; the guard shields
4571
4574
  exotic embedders. */
4572
4575
  if (typeof requestAnimationFrame != "function") return () => {};
@@ -4575,8 +4578,8 @@ function Kc(e, t) {
4575
4578
  if (r !== null) {
4576
4579
  let n = o - r;
4577
4580
  if (n > 33.333333333333336) {
4578
- let r = n - Pc;
4579
- for (let t of e()) t && Lc(t, r, o);
4581
+ let r = n - Ic;
4582
+ for (let t of e()) t && zc(t, r, o);
4580
4583
  t?.(r);
4581
4584
  }
4582
4585
  }
@@ -4587,29 +4590,29 @@ function Kc(e, t) {
4587
4590
  i = !0, cancelAnimationFrame(n);
4588
4591
  };
4589
4592
  }
4590
- var qc = /* @__PURE__ */ new WeakMap();
4591
- function Jc(e, t, n, r = !0, i = !1) {
4593
+ var Yc = /* @__PURE__ */ new WeakMap();
4594
+ function Xc(e, t, n, r = !0, i = !1) {
4592
4595
  if (typeof MutationObserver > "u" || typeof requestAnimationFrame != "function") return () => {};
4593
- let a = qc.get(e);
4594
- if (a) return a.refs += 1, a.pendingDrop !== null && (clearTimeout(a.pendingDrop), a.pendingDrop = null), () => Yc(e);
4596
+ let a = Yc.get(e);
4597
+ if (a) return a.refs += 1, a.pendingDrop !== null && (clearTimeout(a.pendingDrop), a.pendingDrop = null), () => Zc(e);
4595
4598
  let o = null, s = !1, c = !1, l = () => {
4596
- s || c || (s = !0, u.disconnect(), o = Gc(t, n, r, i));
4599
+ s || c || (s = !0, u.disconnect(), o = qc(t, n, r, i));
4597
4600
  }, u = new MutationObserver(() => {
4598
4601
  e.getAttribute("data-flemo-anim-hold") === "false" && l();
4599
4602
  });
4600
4603
  return e.getAttribute("data-flemo-anim-hold") === "false" ? l() : u.observe(e, {
4601
4604
  attributes: !0,
4602
4605
  attributeFilter: [Y]
4603
- }), qc.set(e, {
4606
+ }), Yc.set(e, {
4604
4607
  refs: 1,
4605
4608
  pendingDrop: null,
4606
4609
  dispose: () => {
4607
- c = !0, u.disconnect(), o?.(), qc.delete(e);
4610
+ c = !0, u.disconnect(), o?.(), Yc.delete(e);
4608
4611
  }
4609
- }), () => Yc(e);
4612
+ }), () => Zc(e);
4610
4613
  }
4611
- var Yc = (e) => {
4612
- let t = qc.get(e);
4614
+ var Zc = (e) => {
4615
+ let t = Yc.get(e);
4613
4616
  if (t && (--t.refs, !(t.refs > 0))) {
4614
4617
  /* v8 ignore next 4 -- setTimeout exists in every runtime under test. */
4615
4618
  if (typeof setTimeout != "function") {
@@ -4618,11 +4621,11 @@ var Yc = (e) => {
4618
4621
  }
4619
4622
  t.pendingDrop !== null && clearTimeout(t.pendingDrop), t.pendingDrop = setTimeout(t.dispose, 0);
4620
4623
  }
4621
- }, Xc = 1 / 255, Zc = 400, Qc = 24, $c = /* @__PURE__ */ new Set([
4624
+ }, Qc = 1 / 255, $c = 400, el = 24, tl = /* @__PURE__ */ new Set([
4622
4625
  "x",
4623
4626
  "y",
4624
4627
  "opacity"
4625
- ]), el = (e, t, n) => {
4628
+ ]), nl = (e, t, n) => {
4626
4629
  if (!e || typeof e != "object") return;
4627
4630
  let r = e[t];
4628
4631
  if (r === void 0) return;
@@ -4640,7 +4643,7 @@ var Yc = (e) => {
4640
4643
  return Number.isNaN(e) ? null : e;
4641
4644
  }
4642
4645
  return null;
4643
- }, tl = (e, t, n) => {
4646
+ }, rl = (e, t, n) => {
4644
4647
  let r = /* @__PURE__ */ new Set();
4645
4648
  for (let t of [e.from, e.to]) if (!(!t || typeof t != "object")) for (let e of Object.keys(t)) r.add(e);
4646
4649
  if (r.size === 0) return null;
@@ -4648,25 +4651,25 @@ var Yc = (e) => {
4648
4651
  for (let a of r) {
4649
4652
  let r = e.from && typeof e.from == "object" ? e.from[a] : void 0, o = e.to && typeof e.to == "object" ? e.to[a] : void 0;
4650
4653
  if (r !== void 0 && r === o) continue;
4651
- if (!$c.has(a)) return null;
4652
- let s = el(e.from, a, t), c = el(e.to, a, t);
4654
+ if (!tl.has(a)) return null;
4655
+ let s = nl(e.from, a, t), c = nl(e.to, a, t);
4653
4656
  if (s === null || c === null || s === void 0 || c === void 0) return null;
4654
4657
  let l = Math.abs(c - s);
4655
4658
  if (l === 0) continue;
4656
- let u = a === "opacity" ? Xc : 1 / Math.max(1, n);
4659
+ let u = a === "opacity" ? Qc : 1 / Math.max(1, n);
4657
4660
  i = Math.min(i, u / l);
4658
4661
  }
4659
4662
  return !Number.isFinite(i) || i <= 0 || i >= 1 ? null : i;
4660
- }, nl = (e, t, n) => {
4663
+ }, il = (e, t, n) => {
4661
4664
  if (e.duration <= 0) return null;
4662
- let r = tl(e, t, n);
4665
+ let r = rl(e, t, n);
4663
4666
  if (r === null) return null;
4664
- let i = hi(e.ease), a = Zc;
4665
- for (let e = Zc; e >= 0 && !(Math.abs(1 - i(e / Zc)) > r); --e) a = e;
4667
+ let i = gi(e.ease), a = $c;
4668
+ for (let e = $c; e >= 0 && !(Math.abs(1 - i(e / $c)) > r); --e) a = e;
4666
4669
  if (a === 0) return null;
4667
- let o = (e.delay + e.duration * (a / Zc)) * 1e3;
4668
- return (e.delay + e.duration) * 1e3 - o < Qc ? null : o;
4669
- }, rl = 400, il = 4, al = (e) => +e.toFixed(5) + 0, ol = 12, sl = (e, t, n, r) => {
4670
+ let o = (e.delay + e.duration * (a / $c)) * 1e3;
4671
+ return (e.delay + e.duration) * 1e3 - o < el ? null : o;
4672
+ }, al = 400, ol = 4, sl = (e) => +e.toFixed(5) + 0, cl = 12, ll = (e, t, n, r) => {
4670
4673
  if (e.duration <= 0 || !Number.isFinite(r) || r <= 0) return null;
4671
4674
  let i = Number.isFinite(n) && n > 0 ? n : 1, a = /* @__PURE__ */ new Set();
4672
4675
  for (let t of [e.from, e.to]) if (!(!t || typeof t != "object")) for (let e of Object.keys(t)) a.add(e);
@@ -4675,20 +4678,20 @@ var Yc = (e) => {
4675
4678
  let r = e.from && typeof e.from == "object" ? e.from[n] : void 0, a = e.to && typeof e.to == "object" ? e.to[n] : void 0;
4676
4679
  if (r !== void 0 && r === a) continue;
4677
4680
  if (n !== "x" && n !== "y") return null;
4678
- let s = el(e.from, n, t), c = el(e.to, n, t);
4681
+ let s = nl(e.from, n, t), c = nl(e.to, n, t);
4679
4682
  if (s === null || c === null || s === void 0 || c === void 0) return null;
4680
4683
  o = Math.max(o, Math.abs(c - s) * i);
4681
4684
  }
4682
- if (o < ol) return null;
4683
- let s = hi(e.ease), c = Array(401);
4684
- for (let e = 0; e <= rl; e += 1) c[e] = s(e / rl);
4685
- let l = e.duration * 1e3, u = l / rl, d = 1 / o * (u / r), f = rl, p = 0;
4685
+ if (o < cl) return null;
4686
+ let s = gi(e.ease), c = Array(401);
4687
+ for (let e = 0; e <= al; e += 1) c[e] = s(e / al);
4688
+ let l = e.duration * 1e3, u = l / al, d = 1 / o * (u / r), f = al, p = 0;
4686
4689
  for (let e = 399; e >= 0 && (p = Math.max(p, Math.abs(c[e + 1] - c[e])), !(p > d)); --e) f = e;
4687
- if (f === 0 || f >= rl) return null;
4688
- for (let e = f; e < rl; e += 1) if (c[e + 1] < c[e] || c[e] > 1) return null;
4690
+ if (f === 0 || f >= al) return null;
4691
+ for (let e = f; e < al; e += 1) if (c[e + 1] < c[e] || c[e] > 1) return null;
4689
4692
  let m = (1 - c[f]) * o;
4690
- if (m <= 1 || m > ol) return null;
4691
- let h = f / rl * 100, g = m * r / l * 100;
4693
+ if (m <= 1 || m > cl) return null;
4694
+ let h = f / al * 100, g = m * r / l * 100;
4692
4695
  /* v8 ignore next 2 -- unreachable for a decelerating cubic bezier, and kept
4693
4696
  anyway. The sprint's share of the timeline works out to roughly (samples
4694
4697
  of travel remaining at the engagement velocity) / 4 percent, independent
@@ -4701,14 +4704,14 @@ var Yc = (e) => {
4701
4704
  that keeps one from emitting a curve that lands past its own end. */
4702
4705
  if (h + g >= 100) return null;
4703
4706
  let _ = [];
4704
- for (let e = 0; e <= f; e += il) _.push(`${al(c[e])} ${al(e / rl * 100)}%`);
4705
- return _.push(`${al(c[f])} ${al(h)}%`), _.push(`1 ${al(h + g)}%`, "1 100%"), `linear(${_.join(", ")})`;
4706
- }, cl = /* @__PURE__ */ new WeakMap(), ll = Symbol("flemo-layer-owner"), ul = (e, t) => {
4707
+ for (let e = 0; e <= f; e += ol) _.push(`${sl(c[e])} ${sl(e / al * 100)}%`);
4708
+ return _.push(`${sl(c[f])} ${sl(h)}%`), _.push(`1 ${sl(h + g)}%`, "1 100%"), `linear(${_.join(", ")})`;
4709
+ }, ul = /* @__PURE__ */ new WeakMap(), dl = Symbol("flemo-layer-owner"), fl = (e, t) => {
4707
4710
  t.willChange ? e.style.willChange = t.willChange : e.style.removeProperty("will-change"), t.contain ? e.style.contain = t.contain : e.style.removeProperty("contain");
4708
- }, dl = (e, t) => {
4711
+ }, pl = (e, t) => {
4709
4712
  let n = e.trim() === "none" ? "" : e.trim();
4710
4713
  return t ? n ? /\b(layout|strict|content)\b/.test(n) ? n : `${n} layout` : "layout" : n;
4711
- }, fl = (e, t) => {
4714
+ }, ml = (e, t) => {
4712
4715
  let n = /* @__PURE__ */ new Set(), r = !1;
4713
4716
  for (let e of t.willChange.split(",")) {
4714
4717
  let t = e.trim();
@@ -4719,13 +4722,13 @@ var Yc = (e) => {
4719
4722
  e.containment && (r = !0);
4720
4723
  }
4721
4724
  e.style.willChange = [...n].join(", ");
4722
- let i = dl(t.contain, r);
4725
+ let i = pl(t.contain, r);
4723
4726
  i ? e.style.contain = i : e.style.removeProperty("contain");
4724
- }, pl = (e, t, n = !1, r = ll) => {
4725
- let i = Dr(t), a = cl.get(e);
4727
+ }, hl = (e, t, n = !1, r = dl) => {
4728
+ let i = Or(t), a = ul.get(e);
4726
4729
  if (i.length === 0) {
4727
4730
  if (!a) return;
4728
- a.owners.has(r) ? (a.owners.delete(r), a.owners.size === 0 ? (a.pending != null && clearTimeout(a.pending), ul(e, a), cl.delete(e)) : fl(e, a)) : r === a.settleOwner && a.owners.size === 0 && (a.pending != null && clearTimeout(a.pending), ul(e, a), cl.delete(e));
4731
+ a.owners.has(r) ? (a.owners.delete(r), a.owners.size === 0 ? (a.pending != null && clearTimeout(a.pending), fl(e, a), ul.delete(e)) : ml(e, a)) : r === a.settleOwner && a.owners.size === 0 && (a.pending != null && clearTimeout(a.pending), fl(e, a), ul.delete(e));
4729
4732
  return;
4730
4733
  }
4731
4734
  a?.pending != null && (clearTimeout(a.pending), a.pending = null), a || (a = {
@@ -4734,66 +4737,66 @@ var Yc = (e) => {
4734
4737
  willChange: e.style.willChange,
4735
4738
  contain: e.style.contain,
4736
4739
  pending: null
4737
- }, cl.set(e, a)), a.owners.set(r, {
4740
+ }, ul.set(e, a)), a.owners.set(r, {
4738
4741
  properties: i,
4739
4742
  containment: n
4740
- }), a.settleOwner = null, fl(e, a);
4741
- }, ml = (e, t = ll) => {
4742
- let n = cl.get(e);
4743
+ }), a.settleOwner = null, ml(e, a);
4744
+ }, gl = (e, t = dl) => {
4745
+ let n = ul.get(e);
4743
4746
  if (!(!n || !n.owners.has(t))) {
4744
4747
  if (n.owners.delete(t), n.owners.size > 0) {
4745
- fl(e, n);
4748
+ ml(e, n);
4746
4749
  return;
4747
4750
  }
4748
4751
  /* v8 ignore next 5 -- setTimeout exists in every runtime under test; the
4749
4752
  guard shields exotic embedders, where an immediate demotion is simply
4750
4753
  the pre-hold behavior. */
4751
4754
  if (n.settleOwner = t, n.pending != null && clearTimeout(n.pending), typeof setTimeout != "function") {
4752
- ul(e, n), cl.delete(e);
4755
+ fl(e, n), ul.delete(e);
4753
4756
  return;
4754
4757
  }
4755
- hl(e, n);
4758
+ _l(e, n);
4756
4759
  }
4757
- }, hl = (e, t) => {
4760
+ }, _l = (e, t) => {
4758
4761
  t.pending = setTimeout(() => {
4759
- if (t.pending = null, As()) {
4760
- Ms(() => {
4761
- cl.get(e) === t && t.owners.size === 0 && t.settleOwner !== null && t.pending === null && hl(e, t);
4762
+ if (t.pending = null, Ms()) {
4763
+ Ps(() => {
4764
+ ul.get(e) === t && t.owners.size === 0 && t.settleOwner !== null && t.pending === null && _l(e, t);
4762
4765
  });
4763
4766
  return;
4764
4767
  }
4765
- ul(e, t), cl.delete(e);
4768
+ fl(e, t), ul.delete(e);
4766
4769
  }, 300);
4767
- }, gl = (e, t, n, r) => {
4768
- let { scope: i, decorator: a, bars: o } = e, s = n.split("-")[0], c = s === "PUSHING" || s === "REPLACING", l = la() && typeof navigator < "u" && navigator.maxTouchPoints > 0 && sa() < 12, u = l && typeof window < "u" && window.devicePixelRatio || 1, d = (e, t) => !e || !l ? null : sl(e, t, u, sa());
4769
- if (Xr(t, n)) {
4770
- pl(i, t, c, r);
4770
+ }, vl = (e, t, n, r) => {
4771
+ let { scope: i, decorator: a, bars: o } = e, s = n.split("-")[0], c = s === "PUSHING" || s === "REPLACING", l = ua() && typeof navigator < "u" && navigator.maxTouchPoints > 0 && ca() < 12, u = l && typeof window < "u" && window.devicePixelRatio || 1, d = (e, t) => !e || !l ? null : ll(e, t, u, ca());
4772
+ if (Zr(t, n)) {
4773
+ hl(i, t, c, r);
4771
4774
  let e = d(q(t, n), i);
4772
- e && (ds(i, "animation-timing-function", r), i.style.animationTimingFunction = e);
4773
- for (let n of o ?? []) Nc(n) && (pl(n, t, c, r), e && (ds(n, "animation-timing-function", r), n.style.animationTimingFunction = e));
4775
+ e && (ps(i, "animation-timing-function", r), i.style.animationTimingFunction = e);
4776
+ for (let n of o ?? []) Fc(n) && (hl(n, t, c, r), e && (ps(n, "animation-timing-function", r), n.style.animationTimingFunction = e));
4774
4777
  }
4775
4778
  if (a && t.decoratorName) {
4776
4779
  let e = ke.get(t.decoratorName), i = e ? Fe(t, e) : null;
4777
- i && Xr(i, n) && pl(a, i, c, r);
4780
+ i && Zr(i, n) && hl(a, i, c, r);
4778
4781
  }
4779
- for (let e of dc(i, n)) {
4782
+ for (let e of pc(i, n)) {
4780
4783
  let i = Be(e.getAttribute(J), t);
4781
- if (i && Xr(i, n)) {
4784
+ if (i && Zr(i, n)) {
4782
4785
  let t = d(q(i, n), e);
4783
- t && (ds(e, "animation-timing-function", r), e.style.animationTimingFunction = t);
4786
+ t && (ps(e, "animation-timing-function", r), e.style.animationTimingFunction = t);
4784
4787
  }
4785
4788
  }
4786
- }, _l = (e, t) => {
4789
+ }, yl = (e, t) => {
4787
4790
  let { scope: n, decorator: r, bars: i } = e;
4788
4791
  if (n) {
4789
- ml(n, t);
4790
- for (let e of uc(n)) ml(e, t);
4792
+ gl(n, t);
4793
+ for (let e of fc(n)) gl(e, t);
4791
4794
  }
4792
- r && ml(r, t);
4793
- for (let e of i ?? []) e && ml(e, t);
4794
- }, vl = () => {}, yl = 4, bl = 100, xl = 1500, Sl = /* @__PURE__ */ new WeakMap();
4795
- function Cl(e) {
4796
- let t = Symbol("flemo-engine-layer"), n = /* @__PURE__ */ new Map(), r = Ac({
4795
+ r && gl(r, t);
4796
+ for (let e of i ?? []) e && gl(e, t);
4797
+ }, bl = () => {}, xl = 4, Sl = 100, Cl = 1500, wl = /* @__PURE__ */ new WeakMap();
4798
+ function Tl(e) {
4799
+ let t = Symbol("flemo-engine-layer"), n = /* @__PURE__ */ new Map(), r = Mc({
4797
4800
  landNow: () => a(),
4798
4801
  scheduleLanding: (e) => o(e)
4799
4802
  }), i = null, a = () => {
@@ -4821,15 +4824,15 @@ function Cl(e) {
4821
4824
  if (!p && s && (s.release(), s = null), d) {
4822
4825
  let { scope: e } = a();
4823
4826
  if (e) {
4824
- if (p && !f) for (let t of pc(e, u)) t.setAttribute(Y, "true");
4825
- else for (let t of mc(e)) t.removeAttribute(Y);
4827
+ if (p && !f) for (let t of hc(e, u)) t.setAttribute(Y, "true");
4828
+ else for (let t of gc(e)) t.removeAttribute(Y);
4826
4829
  }
4827
4830
  }
4828
4831
  if (p) {
4829
- let { scope: e, bars: n, screenContainer: r } = a(), i = [...n ?? [], ...Mc(r ?? null)];
4832
+ let { scope: e, bars: n, screenContainer: r } = a(), i = [...n ?? [], ...Pc(r ?? null)];
4830
4833
  if (e) {
4831
- Ts(e), $(e, ["animation-timing-function", "animation-duration"], t);
4832
- for (let n of uc(e)) $(n, ["animation-timing-function", "animation-duration"], t);
4834
+ Ds(e), $(e, ["animation-timing-function", "animation-duration"], t);
4835
+ for (let n of fc(e)) $(n, ["animation-timing-function", "animation-duration"], t);
4833
4836
  for (let e of i) e && $(e, ["animation-timing-function", "animation-duration"], t);
4834
4837
  }
4835
4838
  }
@@ -4841,12 +4844,12 @@ function Cl(e) {
4841
4844
  getScope: () => a().scope
4842
4845
  });
4843
4846
  let m = () => {
4844
- if (!la()) return;
4847
+ if (!ua()) return;
4845
4848
  let t = e.getTransitionTaskId();
4846
- t && (c.pendingTaskIds.some((e) => e !== t) || Na());
4849
+ t && (c.pendingTaskIds.some((e) => e !== t) || Fa());
4847
4850
  }, h = (e, n) => {
4848
- let r = [], { decorator: i, bars: s, screenContainer: c } = a(), l = [...s ?? [], ...Mc(c ?? null)], u = we(o), d = (e, n, i) => {
4849
- let a = 0, o = _s({
4851
+ let r = [], { decorator: i, bars: s, screenContainer: c } = a(), l = [...s ?? [], ...Pc(c ?? null)], u = we(o), d = (e, n, i) => {
4852
+ let a = 0, o = ys({
4850
4853
  element: e,
4851
4854
  expectedName: n,
4852
4855
  motion: i,
@@ -4856,49 +4859,49 @@ function Cl(e) {
4856
4859
  spendBudget: () => {
4857
4860
  a += 1;
4858
4861
  },
4859
- onTerminal: vl
4862
+ onTerminal: bl
4860
4863
  });
4861
4864
  o.attach(), r.push(o.detach);
4862
- }, f = zr("screen", o, n), p = q(u, n);
4863
- if (p) for (let e of l) Nc(e) && d(e, f, p);
4865
+ }, f = Br("screen", o, n), p = q(u, n);
4866
+ if (p) for (let e of l) Fc(e) && d(e, f, p);
4864
4867
  if (i && u.decoratorName) {
4865
4868
  let e = ke.get(u.decoratorName), t = e ? q(Fe(u, e), n) : null;
4866
- t && d(i, Br(u.name, u.decoratorName, n), t);
4869
+ t && d(i, Vr(u.name, u.decoratorName, n), t);
4867
4870
  }
4868
- for (let t of dc(e, n)) {
4871
+ for (let t of pc(e, n)) {
4869
4872
  let e = t.getAttribute(J), r = Be(e, we(o)), i = r ? q(r, n) : null;
4870
- i && d(t, zr("part", e, n), i);
4873
+ i && d(t, Br("part", e, n), i);
4871
4874
  }
4872
4875
  return r;
4873
4876
  };
4874
4877
  if (!d) {
4875
4878
  if (u === "COMPLETED") {
4876
- let { scope: e, decorator: n, bars: r, screenContainer: i } = a(), o = [...r ?? [], ...Mc(i ?? null)];
4879
+ let { scope: e, decorator: n, bars: r, screenContainer: i } = a(), o = [...r ?? [], ...Pc(i ?? null)];
4877
4880
  if (e) {
4878
4881
  $(e);
4879
- for (let t of uc(e)) $(t);
4882
+ for (let t of fc(e)) $(t);
4880
4883
  }
4881
4884
  n && $(n);
4882
4885
  for (let e of o) e && $(e, void 0, t);
4883
- return _l({
4886
+ return yl({
4884
4887
  scope: e,
4885
4888
  decorator: n,
4886
4889
  bars: o
4887
- }, t), vl;
4890
+ }, t), bl;
4888
4891
  }
4889
4892
  if (u === "REPLACING" && l !== o && e.setReplaceTransitionStatus("PENDING"), p) {
4890
- let { scope: e, decorator: n, bars: r, screenContainer: i, partLayer: c } = a(), l = [...r ?? [], ...Mc(i ?? null)];
4893
+ let { scope: e, decorator: n, bars: r, screenContainer: i, partLayer: c } = a(), l = [...r ?? [], ...Pc(i ?? null)];
4891
4894
  if (e) {
4892
4895
  let i = we(o);
4893
- gl({
4896
+ vl({
4894
4897
  scope: e,
4895
4898
  decorator: n,
4896
4899
  bars: l
4897
- }, i, `${u}-false`, t), s ??= ws({
4900
+ }, i, `${u}-false`, t), s ??= Es({
4898
4901
  scope: e,
4899
4902
  bars: r ?? [],
4900
4903
  layer: c ?? null,
4901
- strandedMs: hc(e, i, u) + 1500
4904
+ strandedMs: _c(e, i, u) + 1500
4902
4905
  });
4903
4906
  }
4904
4907
  }
@@ -4908,10 +4911,10 @@ function Cl(e) {
4908
4911
  let { scope: n } = a();
4909
4912
  if (n) {
4910
4913
  let r = we(o), i = [];
4911
- if (Xr(r, e)) {
4912
- let a = q(r, e), s = 0, c = _s({
4914
+ if (Zr(r, e)) {
4915
+ let a = q(r, e), s = 0, c = ys({
4913
4916
  element: n,
4914
- expectedName: zr("screen", o, e),
4917
+ expectedName: Br("screen", o, e),
4915
4918
  motion: a,
4916
4919
  writer: t,
4917
4920
  isLive: () => n.isConnected && n.getAttribute("data-flemo-skip-animation") !== "true",
@@ -4919,47 +4922,47 @@ function Cl(e) {
4919
4922
  spendBudget: () => {
4920
4923
  s += 1;
4921
4924
  },
4922
- onTerminal: vl
4925
+ onTerminal: bl
4923
4926
  });
4924
4927
  c.attach(), i.push(c.detach);
4925
4928
  }
4926
4929
  if (i.push(...h(n, e)), i.length > 0) return () => i.forEach((e) => e());
4927
4930
  }
4928
4931
  }
4929
- return vl;
4932
+ return bl;
4930
4933
  }
4931
4934
  if (u === "COMPLETED") {
4932
- Aa(), e.setDragStatus("IDLE"), e.setReplaceTransitionStatus("IDLE");
4933
- let { scope: n, decorator: r, bars: i, screenContainer: o } = a(), s = [...i ?? [], ...Mc(o ?? null)];
4935
+ Ma(), e.setDragStatus("IDLE"), e.setReplaceTransitionStatus("IDLE");
4936
+ let { scope: n, decorator: r, bars: i, screenContainer: o } = a(), s = [...i ?? [], ...Pc(o ?? null)];
4934
4937
  if (n) {
4935
4938
  $(n), $(n, ["transform", "opacity"]), n.removeAttribute(it);
4936
- for (let e of uc(n)) $(e), e.removeAttribute(it);
4939
+ for (let e of fc(n)) $(e), e.removeAttribute(it);
4937
4940
  }
4938
4941
  r && ($(r), r.removeAttribute(it));
4939
4942
  for (let e of s) e && $(e, void 0, t);
4940
- return _l({
4943
+ return yl({
4941
4944
  scope: n,
4942
4945
  decorator: r,
4943
4946
  bars: s
4944
- }, t), vl;
4947
+ }, t), bl;
4945
4948
  }
4946
- if (u === "IDLE") return vl;
4949
+ if (u === "IDLE") return bl;
4947
4950
  let { scope: g } = a();
4948
- if (!g) return vl;
4949
- let _ = e.getTransitionTaskId(), v = vl, y = () => {
4951
+ if (!g) return bl;
4952
+ let _ = e.getTransitionTaskId(), v = bl, y = () => {
4950
4953
  v(), _ && (c.resolveTask(_), n.delete(_));
4951
- }, b = we(o), x = `${u}-true`, S = g.getAttribute(it) === "true", C = !S && Xr(b, x);
4954
+ }, b = we(o), x = `${u}-true`, S = g.getAttribute(it) === "true", C = !S && Zr(b, x);
4952
4955
  if (!S) {
4953
4956
  let { decorator: e, bars: n, screenContainer: r } = a();
4954
- gl({
4957
+ vl({
4955
4958
  scope: g,
4956
4959
  decorator: e,
4957
- bars: [...n ?? [], ...Mc(r ?? null)]
4960
+ bars: [...n ?? [], ...Pc(r ?? null)]
4958
4961
  }, b, x, t);
4959
4962
  }
4960
- let w = `${u}-false`, T = Xr(b, w) ? q(b, w) : null, E = [];
4961
- for (let e of fc(g, u)) {
4962
- let t = Be(e.getAttribute(J), b), n = `${u}-${e.getAttribute(tt)}`, r = t && Xr(t, n) ? q(t, n) : null;
4963
+ let w = `${u}-false`, T = Zr(b, w) ? q(b, w) : null, E = [];
4964
+ for (let e of mc(g, u)) {
4965
+ let t = Be(e.getAttribute(J), b), n = `${u}-${e.getAttribute(tt)}`, r = t && Zr(t, n) ? q(t, n) : null;
4963
4966
  r && E.push({
4964
4967
  element: e,
4965
4968
  motion: r
@@ -4973,7 +4976,7 @@ function Cl(e) {
4973
4976
  if (e) {
4974
4977
  let t = Fe(b, e);
4975
4978
  for (let e of [`${u}-true`, `${u}-false`]) {
4976
- if (!Xr(t, e)) continue;
4979
+ if (!Zr(t, e)) continue;
4977
4980
  let n = q(t, e);
4978
4981
  n && (O.push(n), D = Math.max(D, (n.delay + n.duration) * 1e3));
4979
4982
  }
@@ -4988,39 +4991,39 @@ function Cl(e) {
4988
4991
  t = Math.max(t, (Number(n?.delay) || 0) + (Number(n?.duration) || 0));
4989
4992
  }
4990
4993
  if (D = Math.max(D, t), D > 0) {
4991
- if (!f) return _ && c.markGateHeld(_), vl;
4994
+ if (!f) return _ && c.markGateHeld(_), bl;
4992
4995
  let e = D + 50;
4993
- _ && c.anchorGate(_, e + xl);
4996
+ _ && c.anchorGate(_, e + Cl);
4994
4997
  let t = setTimeout(y, e);
4995
4998
  return () => clearTimeout(t);
4996
4999
  }
4997
5000
  }
4998
- return queueMicrotask(y), vl;
5001
+ return queueMicrotask(y), bl;
4999
5002
  }
5000
5003
  let k = q(b, x);
5001
5004
  if (_) {
5002
5005
  if (f) {
5003
5006
  let e = (k.delay + k.duration) * 1e3;
5004
- c.anchorGate(_, Math.max(e, D) + xl);
5007
+ c.anchorGate(_, Math.max(e, D) + Cl);
5005
5008
  } else c.markGateHeld(_);
5006
5009
  }
5007
- let A = Ba({
5010
+ let A = Ha({
5008
5011
  status: u,
5009
5012
  transition: b,
5010
5013
  skipAnimation: S,
5011
5014
  hasActiveMotion: !!k,
5012
5015
  hasAnimation: C
5013
- }), { hasDrivableMotion: j, nativeSurgeryAllowed: M, touchGoverned: ee, forceCompiled: N, governedHead: P, desktopHead: F, governedSlide: te, birthHoldMs: I } = A;
5014
- A.framePacingKeepalive && (v = Da());
5015
- let ne = null;
5016
- j && !la() && !M && !ee && !N && !F && (ne = Jc(g, () => [g.ownerDocument.documentElement], () => Sl.get(g)?.(), !1));
5016
+ }), { hasDrivableMotion: j, nativeSurgeryAllowed: M, touchGoverned: ee, forceCompiled: N, governedHead: te, desktopHead: P, governedSlide: ne, birthHoldMs: F } = A;
5017
+ A.framePacingKeepalive && (v = ka());
5018
+ let re = null;
5019
+ j && !ua() && !M && !ee && !N && !P && (re = Xc(g, () => [g.ownerDocument.documentElement], () => wl.get(g)?.(), !1));
5017
5020
  {
5018
5021
  let e = g.ownerDocument.documentElement;
5019
- A.creepHead ? e.setAttribute(It, "true") : e.removeAttribute(It), P ? e.setAttribute(Ft, "true") : e.removeAttribute(Ft), F ? e.setAttribute(Lt, "true") : e.removeAttribute(Lt);
5022
+ A.creepHead ? e.setAttribute(Lt, "true") : e.removeAttribute(Lt), te ? e.setAttribute(It, "true") : e.removeAttribute(It), P ? e.setAttribute(Rt, "true") : e.removeAttribute(Rt);
5020
5023
  }
5021
- let L = null;
5022
- j && M && (L = Vc(g, () => [g.ownerDocument.documentElement], () => Sl.get(g)?.()));
5023
- let re = zr("screen", o, x), R, z = () => {
5024
+ let I = null;
5025
+ j && M && (I = Uc(g, () => [g.ownerDocument.documentElement], () => wl.get(g)?.()));
5026
+ let L = Br("screen", o, x), R, z = () => {
5024
5027
  R !== void 0 && (clearTimeout(R), R = void 0);
5025
5028
  }, ie = 0, B, V = [], H, U = () => {
5026
5029
  V.forEach((e) => cancelAnimationFrame(e)), V = [], H !== void 0 && clearTimeout(H), H = void 0;
@@ -5033,7 +5036,7 @@ function Cl(e) {
5033
5036
  }
5034
5037
  H = setTimeout(() => {
5035
5038
  U(), y();
5036
- }, bl);
5039
+ }, Sl);
5037
5040
  let e = (t) => {
5038
5041
  if (t <= 0) {
5039
5042
  U(), y();
@@ -5041,22 +5044,22 @@ function Cl(e) {
5041
5044
  }
5042
5045
  V.push(requestAnimationFrame(() => e(t - 1)));
5043
5046
  };
5044
- e(yl);
5047
+ e(xl);
5045
5048
  }, oe = () => {
5046
5049
  if (ie <= 0) {
5047
5050
  ae();
5048
5051
  return;
5049
5052
  }
5050
5053
  B = setTimeout(ae, ie);
5051
- }, W = vl, G = vl, se = (e) => {
5052
- e.target === g && Ur(e.animationName, re) && (k && e.elapsedTime === 0 || (g.removeEventListener("animationend", se), z(), W(), oe()));
5054
+ }, W = bl, G = bl, se = (e) => {
5055
+ e.target === g && Wr(e.animationName, L) && (k && e.elapsedTime === 0 || (g.removeEventListener("animationend", se), z(), W(), oe()));
5053
5056
  };
5054
5057
  g.addEventListener("animationend", se), j && f && m();
5055
5058
  let ce = (k.delay + k.duration) * 1e3, le = Math.max(ce, D) + 1500, ue = _ ? setTimeout(() => void c.resolveTask(_), le) : void 0;
5056
5059
  ie = Math.max(0, D - ce);
5057
- let de = ce + I + 250, fe = () => _ !== null && e.getTransitionTaskId() === _ && g.isConnected && g.getAttribute("data-flemo-skip-animation") !== "true" && Xr(b, x), K = _s({
5060
+ let de = ce + F + 250, fe = () => _ !== null && e.getTransitionTaskId() === _ && g.isConnected && g.getAttribute("data-flemo-skip-animation") !== "true" && Zr(b, x), K = ys({
5058
5061
  element: g,
5059
- expectedName: re,
5062
+ expectedName: L,
5060
5063
  motion: k,
5061
5064
  writer: t,
5062
5065
  isLive: fe,
@@ -5076,18 +5079,18 @@ function Cl(e) {
5076
5079
  }
5077
5080
  y();
5078
5081
  }, ge = f, _e = ge ? h(g, x) : [];
5079
- ge && (K.attach(), _ && me()), ge && (M || ee) && Sl.set(g, () => {
5082
+ ge && (K.attach(), _ && me()), ge && (M || ee) && wl.set(g, () => {
5080
5083
  G(), _ && R !== void 0 && me();
5081
5084
  });
5082
- let ve = ge && M ? Kc(() => [g.ownerDocument.documentElement], () => {
5085
+ let ve = ge && M ? Jc(() => [g.ownerDocument.documentElement], () => {
5083
5086
  G(), _ && R !== void 0 && me();
5084
5087
  }) : null, ye, be = () => {
5085
5088
  ye !== void 0 && (clearTimeout(ye), ye = void 0);
5086
5089
  };
5087
- if (G = be, ge && _ && !te && !N) {
5088
- let e = typeof window < "u" && window.devicePixelRatio || 1, t = nl(k, g, e), n = T ? nl(T, g, e) : 0, r = 0;
5090
+ if (G = be, ge && _ && !ne && !N) {
5091
+ let e = typeof window < "u" && window.devicePixelRatio || 1, t = il(k, g, e), n = T ? il(T, g, e) : 0, r = 0;
5089
5092
  for (let { element: t, motion: n } of E) {
5090
- let i = nl(n, t, e);
5093
+ let i = il(n, t, e);
5091
5094
  if (i === null) {
5092
5095
  r = null;
5093
5096
  break;
@@ -5098,7 +5101,7 @@ function Cl(e) {
5098
5101
  if (O.length > 0) {
5099
5102
  let t = a().decorator;
5100
5103
  if (t) for (let n of O) {
5101
- let r = nl(n, t, e);
5104
+ let r = il(n, t, e);
5102
5105
  if (r === null) {
5103
5106
  i = null;
5104
5107
  break;
@@ -5109,10 +5112,10 @@ function Cl(e) {
5109
5112
  let o = t !== null && n !== null && r !== null && i !== null ? Math.max(t, n, r, i) : null;
5110
5113
  o !== null && o + 17 < ce + ie && (ye = setTimeout(() => {
5111
5114
  ye = void 0, fe() && (g.removeEventListener("animationend", se), z(), W(), ae());
5112
- }, o + 17 + I));
5115
+ }, o + 17 + F));
5113
5116
  }
5114
5117
  return () => {
5115
- if (v(), ue !== void 0 && clearTimeout(ue), B !== void 0 && clearTimeout(B), U(), L?.(), ne?.(), ve?.(), be(), g.removeEventListener("animationend", se), ge) {
5118
+ if (v(), ue !== void 0 && clearTimeout(ue), B !== void 0 && clearTimeout(B), U(), I?.(), re?.(), ve?.(), be(), g.removeEventListener("animationend", se), ge) {
5116
5119
  K.detach();
5117
5120
  for (let e of _e) e();
5118
5121
  }
@@ -5124,14 +5127,14 @@ function Cl(e) {
5124
5127
  }
5125
5128
  //#endregion
5126
5129
  //#region src/core/engine/gpuPipelinePrewarm.ts
5127
- var wl = () => {}, Tl = 2e3, El = 1200, Dl = 120, Ol = 3, kl = "position:fixed;top:0;left:0;pointer-events:none;opacity:0.02;", Al = "width:64px;height:64px;background:#888;color:#000;font-size:10px;will-change:transform;transform:translate3d(1px,0,0);", jl = "width:64px;height:64px;background:#000;will-change:opacity;opacity:0.5;", Ml = "cold", Nl = 0, Pl = null;
5128
- function Fl() {
5129
- if (typeof document > "u" || !document.body || typeof Element > "u" || typeof Element.prototype.animate != "function" || !la()) return wl;
5130
- if (Nl += 1, Ml === "cold") {
5131
- Ml = "scheduled";
5132
- let e = () => document.querySelector(F.map((e) => Z(et, e)).join(",")) !== null, t = () => {
5133
- let e = typeof requestIdleCallback == "function" ? requestIdleCallback(n, { timeout: Tl }) : null, t = e === null ? setTimeout(n, El) : null;
5134
- Pl = () => {
5130
+ var El = () => {}, Dl = 2e3, Ol = 1200, kl = 120, Al = 3, jl = "position:fixed;top:0;left:0;pointer-events:none;opacity:0.02;", Ml = "width:64px;height:64px;background:#888;color:#000;font-size:10px;will-change:transform;transform:translate3d(1px,0,0);", Nl = "width:64px;height:64px;background:#000;will-change:opacity;opacity:0.5;", Pl = "cold", Fl = 0, Il = null;
5131
+ function Ll() {
5132
+ if (typeof document > "u" || !document.body || typeof Element > "u" || typeof Element.prototype.animate != "function" || !ua()) return El;
5133
+ if (Fl += 1, Pl === "cold") {
5134
+ Pl = "scheduled";
5135
+ let e = () => document.querySelector(P.map((e) => Z(et, e)).join(",")) !== null, t = () => {
5136
+ let e = typeof requestIdleCallback == "function" ? requestIdleCallback(n, { timeout: Dl }) : null, t = e === null ? setTimeout(n, Ol) : null;
5137
+ Il = () => {
5135
5138
  e !== null && typeof cancelIdleCallback == "function" && cancelIdleCallback(e), t !== null && clearTimeout(t);
5136
5139
  };
5137
5140
  }, n = () => {
@@ -5139,13 +5142,13 @@ function Fl() {
5139
5142
  t();
5140
5143
  return;
5141
5144
  }
5142
- Pl = null, Ml = "done";
5145
+ Il = null, Pl = "done";
5143
5146
  let n = document.createElement("div");
5144
- n.setAttribute(Bt, ""), n.setAttribute("aria-hidden", "true"), n.setAttribute("style", kl);
5147
+ n.setAttribute(Vt, ""), n.setAttribute("aria-hidden", "true"), n.setAttribute("style", jl);
5145
5148
  let r = document.createElement("div");
5146
- r.setAttribute("style", Al), r.textContent = "flemo";
5149
+ r.setAttribute("style", Ml), r.textContent = "flemo";
5147
5150
  let i = document.createElement("div");
5148
- i.setAttribute("style", jl);
5151
+ i.setAttribute("style", Nl);
5149
5152
  let a = document.createElement("div");
5150
5153
  a.setAttribute("style", "width:96px;font-size:11px;color:#123;will-change:transform;transform:translate3d(0,0,0);");
5151
5154
  let o = document.createElement("div");
@@ -5166,14 +5169,14 @@ function Fl() {
5166
5169
  c.setAttribute("style", "border-top:1px solid #ccd;padding:2px 0;"), c.textContent = "의원 기록 표결 발의 가나다라", a.append(o, s, c), n.append(r, i, a), document.body.appendChild(n);
5167
5170
  try {
5168
5171
  r.animate([{ transform: "translate3d(0,0,0)" }, { transform: "translate3d(2px,0,0)" }], {
5169
- duration: Dl,
5170
- iterations: Ol
5172
+ duration: kl,
5173
+ iterations: Al
5171
5174
  }), i.animate([{ opacity: .4 }, { opacity: .6 }], {
5172
- duration: Dl,
5173
- iterations: Ol
5175
+ duration: kl,
5176
+ iterations: Al
5174
5177
  }), a.animate([{ transform: "translate3d(0,0,0)" }, { transform: "translate3d(2px,0,0)" }], {
5175
- duration: Dl,
5176
- iterations: Ol
5178
+ duration: kl,
5179
+ iterations: Al
5177
5180
  });
5178
5181
  } catch {}
5179
5182
  setTimeout(() => n.remove(), 450);
@@ -5182,62 +5185,62 @@ function Fl() {
5182
5185
  }
5183
5186
  let e = !1;
5184
5187
  return () => {
5185
- e || (e = !0, Nl = Math.max(0, Nl - 1), Nl === 0 && Ml === "scheduled" && (Pl?.(), Pl = null, Ml = "cold"));
5188
+ e || (e = !0, Fl = Math.max(0, Fl - 1), Fl === 0 && Pl === "scheduled" && (Il?.(), Il = null, Pl = "cold"));
5186
5189
  };
5187
5190
  }
5188
5191
  //#endregion
5189
5192
  //#region src/runtime/flemoRuntime.ts
5190
- var Il = 500, Ll = 3e3, Rl = [
5193
+ var Rl = 500, zl = 3e3, Bl = [
5191
5194
  "pointerdown",
5192
5195
  "pointermove",
5193
5196
  "wheel",
5194
5197
  "touchstart",
5195
5198
  "keydown"
5196
- ], zl = () => {
5199
+ ], Vl = () => {
5197
5200
  if (typeof document > "u") return () => {};
5198
5201
  let e = null, t = null, n = 0, r = () => {
5199
5202
  let r = Date.now();
5200
- if (r - n < Il) return;
5203
+ if (r - n < Rl) return;
5201
5204
  n = r, t && clearTimeout(t);
5202
5205
  let i = e;
5203
- e = oc(), i?.(), t = setTimeout(() => {
5206
+ e = cc(), i?.(), t = setTimeout(() => {
5204
5207
  t = null, e?.(), e = null;
5205
- }, Ll);
5208
+ }, zl);
5206
5209
  };
5207
- for (let e of Rl) document.addEventListener(e, r, { passive: !0 });
5210
+ for (let e of Bl) document.addEventListener(e, r, { passive: !0 });
5208
5211
  return () => {
5209
- for (let e of Rl) document.removeEventListener(e, r);
5212
+ for (let e of Bl) document.removeEventListener(e, r);
5210
5213
  t && clearTimeout(t), e?.();
5211
5214
  };
5212
- }, Bl = 0, Vl = null, Hl = () => {
5213
- let e = [zl(), Fl()];
5214
- return La().imageDecodeOffload && e.push(Ys()), () => {
5215
+ }, Hl = 0, Ul = null, Wl = () => {
5216
+ let e = [Vl(), Ll()];
5217
+ return za().imageDecodeOffload && e.push(Zs()), () => {
5215
5218
  for (let t of e) t();
5216
5219
  };
5217
- }, Ul = () => {
5218
- Bl === 0 && (Vl = Hl()), Bl += 1;
5220
+ }, Gl = () => {
5221
+ Hl === 0 && (Ul = Wl()), Hl += 1;
5219
5222
  let e = !1;
5220
5223
  return () => {
5221
- e || (e = !0, --Bl, !(Bl > 0) && (Vl?.(), Vl = null));
5224
+ e || (e = !0, --Hl, !(Hl > 0) && (Ul?.(), Ul = null));
5222
5225
  };
5223
- }, Wl = "auto", Gl = 1e5, Kl = [
5226
+ }, Kl = "auto", ql = 1e5, Jl = [
5224
5227
  {
5225
5228
  role: "content",
5226
- level: Wl
5229
+ level: Kl
5227
5230
  },
5228
5231
  {
5229
5232
  role: "chrome",
5230
- level: Wl
5233
+ level: Kl
5231
5234
  },
5232
5235
  {
5233
5236
  role: "decorator",
5234
- level: Wl
5237
+ level: Kl
5235
5238
  },
5236
5239
  {
5237
5240
  role: "overlay",
5238
- level: Gl
5241
+ level: ql
5239
5242
  }
5240
- ], ql = .12, Jl = 1.6, Yl = .5, Xl = .28, Zl = (e, t, n) => {
5243
+ ], Yl = .12, Xl = 1.6, Zl = .5, Ql = .28, $l = (e, t, n) => {
5241
5244
  if (!(e > 0)) return t;
5242
5245
  if (e >= 1) return 0;
5243
5246
  let [r, i, a, o] = n, s = (e) => 3 * (1 - e) ** 2 * e * r + 3 * (1 - e) * e * e * a + e ** 3, c = (e) => 3 * (1 - e) ** 2 * e * i + 3 * (1 - e) * e * e * o + e ** 3, l = 0, u = 1;
@@ -5247,17 +5250,17 @@ var Il = 500, Ll = 3e3, Rl = [
5247
5250
  }
5248
5251
  let d = s((l + u) / 2);
5249
5252
  return t * Math.min(1, Math.max(0, 1 - d));
5250
- }, Ql = ({ remainingPx: e, spanPx: t, velocityPxPerSecond: n, authoredSeconds: r, authoredEase: i, reversing: a = !1, minSeconds: o = a ? Xl : ql }) => {
5253
+ }, eu = ({ remainingPx: e, spanPx: t, velocityPxPerSecond: n, authoredSeconds: r, authoredEase: i, reversing: a = !1, minSeconds: o = a ? Ql : Yl }) => {
5251
5254
  let s = Math.abs(e);
5252
5255
  if (s <= .5) return 0;
5253
- let c = Math.abs(t), l = c > 0 ? Math.min(1, s / c) : 1, u = i && !a ? Zl(1 - l, r, i) : r * l, d = Math.abs(n), f = !a && d > 0 ? Jl * s / d : Infinity;
5254
- return Math.min(r, Math.max(o, Math.min(u, f)));
5255
- }, $l = ({ remainingPx: e, velocityPxPerSecond: t, seconds: n, authoredSlope: r, reversing: i = !1 }) => {
5256
+ let c = Math.abs(t), l = c > 0 ? Math.min(1, s / c) : 1, u = i && !a ? $l(1 - l, r, i) : r * l, d = Math.abs(n), f = !a && d > 0 ? Xl * s / d : Infinity, p = Math.min(u, f), m = r * l / 3;
5257
+ return Math.min(r, Math.max(Math.max(o, m), p));
5258
+ }, tu = ({ remainingPx: e, velocityPxPerSecond: t, seconds: n, authoredSlope: r, reversing: i = !1 }) => {
5256
5259
  let a = Math.abs(e);
5257
5260
  if (!Number.isFinite(a) || a <= .5 || !Number.isFinite(n) || n <= 0 || !i && !Number.isFinite(t)) return null;
5258
5261
  let o = i ? 0 : Math.abs(t) * n / a;
5259
- return Math.min(Jl, Math.max(typeof r == "number" && r >= 0 ? Math.min(Yl, r) : Yl, o));
5260
- }, eu = (e, t) => {
5262
+ return Math.min(Xl, Math.max(typeof r == "number" && r >= 0 ? Math.min(Zl, r) : Zl, o));
5263
+ }, nu = (e, t) => {
5261
5264
  let [n, r, i, a] = e;
5262
5265
  if (!Number.isFinite(t) || n <= 0 || t <= 0) return [
5263
5266
  n,
@@ -5275,20 +5278,20 @@ var Il = 500, Ll = 3e3, Rl = [
5275
5278
  };
5276
5279
  //#endregion
5277
5280
  //#region src/utils/findScrollable.ts
5278
- function tu(e, t) {
5279
- let { direction: n = "x", markerSelector: r = "[data-swipe-at-edge]", depthLimit: i = 24, verifyByScroll: a = !1 } = t ?? {}, o = nu(e);
5281
+ function ru(e, t) {
5282
+ let { direction: n = "x", markerSelector: r = "[data-swipe-at-edge]", depthLimit: i = 24, verifyByScroll: a = !1 } = t ?? {}, o = iu(e);
5280
5283
  if (!o) return {
5281
5284
  element: null,
5282
5285
  hasMarker: !1
5283
5286
  };
5284
5287
  let s = o.closest?.(r);
5285
- if (s instanceof HTMLElement && ru(s, n) && (!a || iu(s, n))) return {
5288
+ if (s instanceof HTMLElement && au(s, n) && (!a || ou(s, n))) return {
5286
5289
  element: s,
5287
5290
  hasMarker: !0
5288
5291
  };
5289
5292
  let c = o, l = 0;
5290
5293
  for (; c && l < i;) {
5291
- if (ru(c, n) && (!a || iu(c, n))) return {
5294
+ if (au(c, n) && (!a || ou(c, n))) return {
5292
5295
  element: c,
5293
5296
  hasMarker: !1
5294
5297
  };
@@ -5299,7 +5302,7 @@ function tu(e, t) {
5299
5302
  hasMarker: !1
5300
5303
  };
5301
5304
  }
5302
- function nu(e) {
5305
+ function iu(e) {
5303
5306
  if (!e) return null;
5304
5307
  let t = e, n = typeof t.composedPath == "function" ? t.composedPath() : void 0;
5305
5308
  if (n && n.length) {
@@ -5307,33 +5310,33 @@ function nu(e) {
5307
5310
  }
5308
5311
  return e instanceof HTMLElement ? e : null;
5309
5312
  }
5310
- function ru(e, t) {
5313
+ function au(e, t) {
5311
5314
  return t === "y" ? e.scrollHeight - e.clientHeight > 1 : e.scrollWidth - e.clientWidth > 1;
5312
5315
  }
5313
- function iu(e, t) {
5314
- if (!ru(e, t) || typeof window > "u") return !1;
5316
+ function ou(e, t) {
5317
+ if (!au(e, t) || typeof window > "u") return !1;
5315
5318
  let n = window.getComputedStyle(e), r = t === "y" ? n.overflowY : n.overflowX;
5316
5319
  return r === "auto" || r === "scroll" || r === "overlay";
5317
5320
  }
5318
5321
  //#endregion
5319
5322
  //#region src/core/engine/riderSwipe.ts
5320
- var au = (e) => {
5323
+ var su = (e) => {
5321
5324
  let t = {};
5322
- for (let n of Or(e)) {
5325
+ for (let n of kr(e)) {
5323
5326
  let e = n.property.replace(/-([a-z])/g, (e, t) => t.toUpperCase());
5324
5327
  t[e] = n.value;
5325
5328
  }
5326
5329
  return t;
5327
- }, ou = (e) => {
5330
+ }, cu = (e) => {
5328
5331
  let t = [];
5329
5332
  for (let { element: n, motion: r } of e) {
5330
5333
  /* v8 ignore next -- jsdom implements Element.animate; the guard is for a
5331
5334
  host that does not, where a drag simply moves nothing. */
5332
5335
  if (r.duration <= 0 || typeof n.animate != "function") continue;
5333
- let e = n.animate([au(r.from), au(r.to)], {
5336
+ let e = n.animate([su(r.from), su(r.to)], {
5334
5337
  duration: r.duration * 1e3,
5335
5338
  delay: r.delay * 1e3,
5336
- easing: jr(r.ease),
5339
+ easing: Mr(r.ease),
5337
5340
  fill: "both"
5338
5341
  });
5339
5342
  t.push({
@@ -5347,44 +5350,44 @@ var au = (e) => {
5347
5350
  });
5348
5351
  }
5349
5352
  if (t.length === 0) return null;
5350
- for (let e of t) Lo([e.animation], 0);
5353
+ for (let e of t) zo([e.animation], 0);
5351
5354
  let n = !1;
5352
5355
  return {
5353
5356
  get active() {
5354
5357
  return !n;
5355
5358
  },
5356
5359
  scrub: (e) => {
5357
- if (!n) for (let n of t) Ro([n.animation], n.clock, e);
5360
+ if (!n) for (let n of t) Bo([n.animation], n.clock, e);
5358
5361
  },
5359
5362
  settle: (e, r) => {
5360
5363
  if (!n) {
5361
5364
  n = !0;
5362
5365
  for (let n of t) e && n.element.setAttribute(it, "true"), n.animation.addEventListener("finish", () => {
5363
5366
  n.animation.cancel(), n.element.removeAttribute(it);
5364
- }, { once: !0 }), zo([n.animation], n.clock, e, r);
5367
+ }, { once: !0 }), Vo([n.animation], n.clock, e, r);
5365
5368
  }
5366
5369
  }
5367
5370
  };
5368
5371
  };
5369
5372
  //#endregion
5370
5373
  //#region src/screen/computeBarRiding.ts
5371
- function su(e, t) {
5374
+ function lu(e, t) {
5372
5375
  return !!e && !!t && e.id === t.id;
5373
5376
  }
5374
- function cu(e) {
5377
+ function uu(e) {
5375
5378
  if (e.status !== "PUSHING" && e.status !== "POPPING" && e.status !== "REPLACING" || !e.isTopOrTopPrev) return {
5376
5379
  app: !1,
5377
5380
  nav: !1
5378
5381
  };
5379
5382
  let t = e.hasTopBar ? { id: e.topBarId } : void 0, n = e.hasNavBar ? { id: e.bottomBarId } : void 0, r = e.partnerMetadata?.topBar ?? (e.partnerBars?.topBar ? {} : void 0), i = e.partnerMetadata?.bottomBar ?? (e.partnerBars?.bottomBar ? {} : void 0);
5380
5383
  return {
5381
- app: e.hasTopBar && !su(t, r),
5382
- nav: e.hasNavBar && !su(n, i)
5384
+ app: e.hasTopBar && !lu(t, r),
5385
+ nav: e.hasNavBar && !lu(n, i)
5383
5386
  };
5384
5387
  }
5385
5388
  //#endregion
5386
5389
  //#region src/core/engine/createSwipeController.ts
5387
- function lu(e) {
5390
+ function du(e) {
5388
5391
  let t = Symbol("flemo-swipe-layer"), n = null, r = null, i = null, a = null, o = null, s = null, c = {
5389
5392
  current: [],
5390
5393
  prev: []
@@ -5410,7 +5413,7 @@ function lu(e) {
5410
5413
  }, D = {
5411
5414
  element: null,
5412
5415
  hasMarker: !1
5413
- }, O = 0, k = 0, A = (e) => ({
5416
+ }, O = 0, k = 0, A = (e, t) => Math.min(t, Math.max(0, e)), j = (e) => ({
5414
5417
  point: {
5415
5418
  x: e.clientX,
5416
5419
  y: e.clientY
@@ -5424,10 +5427,10 @@ function lu(e) {
5424
5427
  y: e.clientY - S.y
5425
5428
  },
5426
5429
  velocity: w
5427
- }), j = 0, M = (t) => {
5430
+ }), M = 0, ee = (t) => {
5428
5431
  let { scope: n } = e.getElements();
5429
5432
  n?.hasPointerCapture(t.pointerId) && n.releasePointerCapture(t.pointerId);
5430
- }, ee = (e) => {
5433
+ }, N = (e) => {
5431
5434
  let t = e.timeStamp;
5432
5435
  for (T.push({
5433
5436
  t,
@@ -5441,9 +5444,9 @@ function lu(e) {
5441
5444
  }, S = {
5442
5445
  x: e.clientX,
5443
5446
  y: e.clientY
5444
- }, C = t, j = Math.max(j, Math.abs(e.clientX - x.x), Math.abs(e.clientY - x.y));
5445
- }, N = (r, i, a) => {
5446
- let o = ps(r, i, a, t), s = (e) => ps(e, l.has(e) ? dr(i, u) : i, a, t);
5447
+ }, C = t, M = Math.max(M, Math.abs(e.clientX - x.x), Math.abs(e.clientY - x.y));
5448
+ }, te = (r, i, a) => {
5449
+ let o = hs(r, i, a, t), s = (e) => hs(e, l.has(e) ? fr(i, u) : i, a, t);
5447
5450
  if (r === e.getElements().scope) for (let e of c.current) s(e);
5448
5451
  else if (r === n) for (let e of c.prev) s(e);
5449
5452
  return o;
@@ -5454,50 +5457,50 @@ function lu(e) {
5454
5457
  if (typeof e.matches == "function" && e.matches(t)) return e;
5455
5458
  }
5456
5459
  return null;
5457
- }, F = (n, r) => {
5460
+ }, ne = (n, r) => {
5458
5461
  let i = e.getPartnerBars(), a = e.getPartnerBarMetadata?.(), o = P(n, Z(at, "app")), s = P(n, Z(at, "nav")), d = (e) => {
5459
5462
  if (!e) return;
5460
5463
  let t = e.getAttribute(lt);
5461
5464
  return t === null ? {} : { id: e.getAttribute("data-flemo-bar-id-type") === "number" ? Number(t) : t };
5462
5465
  }, f = e.hasSharedTopBar() ? { id: e.getSharedTopBarId?.() } : void 0, p = e.hasSharedBottomBar() ? { id: e.getSharedBottomBarId?.() } : void 0, m = a?.topBar ?? (i?.topBar ? {} : d(o)), h = a?.bottomBar ?? (i?.bottomBar ? {} : d(s)), g = [], { sharedTopBar: _, sharedBottomBar: v } = e.getElements();
5463
- _ && f && !su(f, m) && g.push(_), v && p && !su(p, h) && g.push(v);
5466
+ _ && f && !lu(f, m) && g.push(_), v && p && !lu(p, h) && g.push(v);
5464
5467
  let y = [];
5465
- n && (o && m && !su(m, f) && y.push(o), s && h && !su(h, p) && y.push(s)), l = /* @__PURE__ */ new Set([...g, ...y]), u = r.getBoundingClientRect().height, g.push(...Mc(e.getElements().screenContainer)), y.push(...Mc(n)), c = {
5468
+ n && (o && m && !lu(m, f) && y.push(o), s && h && !lu(h, p) && y.push(s)), l = /* @__PURE__ */ new Set([...g, ...y]), u = r.getBoundingClientRect().height, g.push(...Pc(e.getElements().screenContainer)), y.push(...Pc(n)), c = {
5466
5469
  current: g,
5467
5470
  prev: y
5468
5471
  };
5469
- for (let n of g) pl(n, e.getTransition(), !1, t);
5470
- for (let n of y) pl(n, e.getTransition(), !1, t);
5471
- }, te = () => {
5472
+ for (let n of g) hl(n, e.getTransition(), !1, t);
5473
+ for (let n of y) hl(n, e.getTransition(), !1, t);
5474
+ }, F = () => {
5472
5475
  let { scope: i, decorator: a } = e.getElements(), o = e.getTransition();
5473
- i && pl(i, o, !1, t), n && pl(n, o, !1, t);
5476
+ i && hl(i, o, !1, t), n && hl(n, o, !1, t);
5474
5477
  let s = e.getDecorator();
5475
5478
  if (s) {
5476
5479
  let e = Fe(o, s);
5477
- a && pl(a, e, !1, t), r && pl(r, e, !1, t);
5480
+ a && hl(a, e, !1, t), r && hl(r, e, !1, t);
5478
5481
  }
5479
- }, I = () => {
5482
+ }, re = () => {
5480
5483
  let { scope: i, decorator: a } = e.getElements();
5481
- i && ml(i, t), n && ml(n, t), a && ml(a, t), r && ml(r, t);
5482
- }, ne = () => {
5483
- for (let e of c.current) $(e, void 0, t), ml(e, t);
5484
- for (let e of c.prev) $(e, void 0, t), ml(e, t);
5484
+ i && gl(i, t), n && gl(n, t), a && gl(a, t), r && gl(r, t);
5485
+ }, I = () => {
5486
+ for (let e of c.current) $(e, void 0, t), gl(e, t);
5487
+ for (let e of c.prev) $(e, void 0, t), gl(e, t);
5485
5488
  c = {
5486
5489
  current: [],
5487
5490
  prev: []
5488
5491
  };
5489
5492
  }, L = () => {
5490
- a || !n || !i || (a = ws({
5493
+ a || !n || !i || (a = Es({
5491
5494
  scope: n,
5492
5495
  bars: [P(i, Z(at, "app")), P(i, Z(at, "nav"))],
5493
5496
  layer: e.getPartLayer?.() ?? null,
5494
5497
  strandedMs: 6e4
5495
5498
  }));
5496
- }, re = () => {
5497
- a?.release(), a = null;
5498
5499
  }, R = () => {
5499
- m && (s ||= ou(B()), !a && (L(), a && (o = ou(z()))));
5500
+ a?.release(), a = null;
5500
5501
  }, z = () => {
5502
+ m && (s ||= cu(V()), !a && (L(), a && (o = cu(ie()))));
5503
+ }, ie = () => {
5501
5504
  let t = e.getTransition(), n = [], r = (e, r) => {
5502
5505
  let i = ze.get(e.getAttribute(J));
5503
5506
  if (!i || i.onSwipe || i.onSwipeStart || i.onSwipeEnd) return;
@@ -5510,10 +5513,10 @@ function lu(e) {
5510
5513
  for (let e of d.current) r(e, !0);
5511
5514
  for (let e of d.prev) r(e, !1);
5512
5515
  return n;
5513
- }, ie = (e) => {
5516
+ }, B = (e) => {
5514
5517
  let t = e?.getAttribute($e);
5515
5518
  return t ? Array.from(document.querySelectorAll(X(pt) + Z(ht, t))) : [];
5516
- }, B = () => {
5519
+ }, V = () => {
5517
5520
  let t = e.getTransition(), i = e.getDecorator();
5518
5521
  if (!i || i.onSwipe || i.onSwipeStart) return [];
5519
5522
  let a = Fe(t, i), o = [], s = (e, t) => {
@@ -5524,8 +5527,8 @@ function lu(e) {
5524
5527
  motion: n
5525
5528
  });
5526
5529
  }, { scope: c, decorator: l } = e.getElements();
5527
- return s(l ?? ie(c)[0] ?? null, !0), s(r ?? ie(n)[0] ?? null, !1), o;
5528
- }, V = (t) => {
5530
+ return s(l ?? B(c)[0] ?? null, !0), s(r ?? B(n)[0] ?? null, !1), o;
5531
+ }, H = (t) => {
5529
5532
  let { screenContainer: n } = e.getElements(), r = (e) => {
5530
5533
  let t = P(e, X($e)), n = Array.from(e.querySelectorAll(X(J))).filter((e) => {
5531
5534
  let n = e.closest(X($e));
@@ -5539,12 +5542,12 @@ function lu(e) {
5539
5542
  current: r(n),
5540
5543
  prev: r(t)
5541
5544
  };
5542
- }, H = (e, n, r, i) => {
5545
+ }, U = (e, n, r, i) => {
5543
5546
  let a = (a, o) => {
5544
5547
  let s = ze.get(a.getAttribute(J));
5545
5548
  if (!s) return;
5546
5549
  let c = {
5547
- animate: i ?? ((e, n, r) => ps(e, n, r, t)),
5550
+ animate: i ?? ((e, n, r) => hs(e, n, r, t)),
5548
5551
  element: a,
5549
5552
  active: o
5550
5553
  };
@@ -5552,13 +5555,13 @@ function lu(e) {
5552
5555
  };
5553
5556
  for (let e of d.current) a(e, !0);
5554
5557
  for (let e of d.prev) a(e, !1);
5555
- }, U = () => {
5558
+ }, ae = () => {
5556
5559
  for (let e of [...d.current, ...d.prev]) $(e, void 0, t);
5557
5560
  d = {
5558
5561
  current: [],
5559
5562
  prev: []
5560
5563
  };
5561
- }, ae = async (t) => {
5564
+ }, oe = async (t) => {
5562
5565
  let a = e.getTransition();
5563
5566
  if (!a.swipeDirection || e.getViewportScrollHeight() > 10) {
5564
5567
  p = !1;
@@ -5570,11 +5573,11 @@ function lu(e) {
5570
5573
  return;
5571
5574
  }
5572
5575
  let d = l?.previousElementSibling ?? null;
5573
- if (i = d, n = P(d, X($e)), r = P(d, X("data-flemo-decorator")) ?? ie(n)[0] ?? null, !n) {
5576
+ if (i = d, n = P(d, X($e)), r = P(d, X("data-flemo-decorator")) ?? B(n)[0] ?? null, !n) {
5574
5577
  p = !1;
5575
5578
  return;
5576
5579
  }
5577
- m = !0, g(), le = ue(), de = 0, ce = (typeof performance > "u" ? Date.now() : performance.now()) + se, j = 0, x = {
5580
+ m = !0, g(), ue = de(), fe = 0, le = (typeof performance > "u" ? Date.now() : performance.now()) + ce, M = 0, x = {
5578
5581
  x: t.clientX,
5579
5582
  y: t.clientY
5580
5583
  }, S = {
@@ -5587,71 +5590,71 @@ function lu(e) {
5587
5590
  t: t.timeStamp,
5588
5591
  x: t.clientX,
5589
5592
  y: t.clientY
5590
- }], c.setPointerCapture(t.pointerId), F(d, c), V(d), te();
5591
- let f = e.getDecorator(), h = await a.onSwipeStart(t, A(t), {
5592
- animate: N,
5593
+ }], c.setPointerCapture(t.pointerId), ne(d, c), H(d), F();
5594
+ let f = e.getDecorator(), h = await a.onSwipeStart(t, j(t), {
5595
+ animate: te,
5593
5596
  currentScreen: c,
5594
5597
  prevScreen: n,
5595
5598
  onStart: (e) => {
5596
5599
  f?.onSwipeStart?.(e, {
5597
- animate: ps,
5600
+ animate: hs,
5598
5601
  currentDecorator: u,
5599
5602
  prevDecorator: r
5600
- }), H("start", e, 0);
5603
+ }), U("start", e, 0);
5601
5604
  }
5602
5605
  });
5603
- h && !b ? (e.setDragStatus("PENDING"), typeof requestAnimationFrame == "function" ? requestAnimationFrame(R) : R(), e.onDragStart?.()) : h || (e.setDragStatus("IDLE"), m = !1, p = !1, _(), M(t), ne(), I(), U(), re(), o?.settle(!1, 0), o = null, s?.settle(!1, 0), s = null);
5604
- }, oe = (e) => {
5605
- let t = ae(e);
5606
+ h && !b ? (e.setDragStatus("PENDING"), typeof requestAnimationFrame == "function" ? requestAnimationFrame(z) : z(), e.onDragStart?.()) : h || (e.setDragStatus("IDLE"), m = !1, p = !1, _(), ee(t), I(), re(), ae(), R(), o?.settle(!1, 0), o = null, s?.settle(!1, 0), s = null);
5607
+ }, W = (e) => {
5608
+ let t = oe(e);
5606
5609
  y = t, t.finally(() => {
5607
5610
  y = null;
5608
5611
  });
5609
- }, W = null, G = 0, se = 200, ce = 0, le = !0, ue = () => {
5612
+ }, G = null, se = 0, ce = 200, le = 0, ue = !0, de = () => {
5610
5613
  let e = n?.parentElement;
5611
5614
  return !e || !e.isConnected || typeof getComputedStyle != "function" || getComputedStyle(e).display !== "none";
5612
- }, de = 0, fe = (e) => le ? !0 : e >= ce ? (le = !0, !0) : ue() ? de ? (le = !0, !0) : (de = e, !1) : (de = 0, !1), K = () => {
5613
- G && typeof cancelAnimationFrame == "function" && cancelAnimationFrame(G), G = 0, le = !0;
5614
- let e = W;
5615
- W = null, e && he(e);
5616
- }, pe = (e = typeof performance > "u" ? Date.now() : performance.now()) => {
5617
- if (G = 0, !fe(e)) {
5618
- W && typeof requestAnimationFrame == "function" && (G = requestAnimationFrame(pe));
5615
+ }, fe = 0, K = (e) => ue ? !0 : e >= le ? (ue = !0, !0) : de() ? fe ? (ue = !0, !0) : (fe = e, !1) : (fe = 0, !1), pe = () => {
5616
+ se && typeof cancelAnimationFrame == "function" && cancelAnimationFrame(se), se = 0, ue = !0;
5617
+ let e = G;
5618
+ G = null, e && ge(e);
5619
+ }, me = (e = typeof performance > "u" ? Date.now() : performance.now()) => {
5620
+ if (se = 0, !K(e)) {
5621
+ G && typeof requestAnimationFrame == "function" && (se = requestAnimationFrame(me));
5619
5622
  return;
5620
5623
  }
5621
- let t = W;
5622
- W = null, t && he(t);
5623
- }, me = (e) => {
5624
- if (W = e, !G) {
5624
+ let t = G;
5625
+ G = null, t && ge(t);
5626
+ }, he = (e) => {
5627
+ if (G = e, !se) {
5625
5628
  if (typeof requestAnimationFrame != "function") {
5626
- pe();
5629
+ me();
5627
5630
  return;
5628
5631
  }
5629
- G = requestAnimationFrame(pe);
5632
+ se = requestAnimationFrame(me);
5630
5633
  }
5631
- }, he = (t) => {
5634
+ }, ge = (t) => {
5632
5635
  let i = e.getTransition();
5633
5636
  if (!i.swipeDirection || !m || y || e.getViewportScrollHeight() > 10) return;
5634
- let { scope: a, decorator: c } = e.getElements(), l = e.getDecorator(), u = A(t), d = i.swipeDirection, f = a?.getBoundingClientRect(), p = (d === "y" ? f?.height : f?.width) || (typeof window > "u" ? 0 : d === "y" ? window.innerHeight : window.innerWidth), h = Math.abs(d === "y" ? u.offset.y : u.offset.x), g = p > 0 ? Math.max(0, Math.min(100, h / p * 100)) : 0;
5637
+ let { scope: a, decorator: c } = e.getElements(), l = e.getDecorator(), u = j(t), d = i.swipeDirection, f = a?.getBoundingClientRect(), p = (d === "y" ? f?.height : f?.width) || (typeof window > "u" ? 0 : d === "y" ? window.innerHeight : window.innerWidth), h = A(d === "y" ? u.offset.y : u.offset.x, p), g = p > 0 ? Math.max(0, Math.min(100, h / p * 100)) : 0;
5635
5638
  i.onSwipe(t, u, {
5636
- animate: N,
5639
+ animate: te,
5637
5640
  currentScreen: a,
5638
5641
  prevScreen: n,
5639
5642
  onProgress: (e) => {
5640
5643
  l?.onSwipe?.(e, g, {
5641
- animate: ps,
5644
+ animate: hs,
5642
5645
  currentDecorator: c,
5643
5646
  prevDecorator: r
5644
- }), H("swipe", e, g), R(), o?.scrub(g / 100), s?.scrub(g / 100);
5647
+ }), U("swipe", e, g), z(), o?.scrub(g / 100), s?.scrub(g / 100);
5645
5648
  }
5646
5649
  }), e.onDragProgress?.(g / 100);
5647
- }, ge = async (i, a = !1) => {
5650
+ }, _e = async (i, a = !1) => {
5648
5651
  y && await y;
5649
5652
  let l = e.getTransition();
5650
5653
  if (!l.swipeDirection || !m) return;
5651
- K(), m = !1, _();
5654
+ pe(), a || N(i), m = !1, _();
5652
5655
  let { scope: u, decorator: f } = e.getElements();
5653
- M(i);
5654
- let p = e.getDecorator(), h = j < 6, g = a ? {
5656
+ ee(i);
5657
+ let p = e.getDecorator(), h = M < 6, g = a ? {
5655
5658
  point: {
5656
5659
  x: i.clientX,
5657
5660
  y: i.clientY
@@ -5668,12 +5671,12 @@ function lu(e) {
5668
5671
  x: 0,
5669
5672
  y: 0
5670
5673
  }
5671
- } : A(i), v = a ? A(i).offset : g.offset, b = l.swipeDirection, x = u?.getBoundingClientRect(), S = (b === "y" ? x?.height : x?.width) || (typeof window > "u" ? 0 : b === "y" ? window.innerHeight : window.innerWidth), C = b === "y" ? v.y : v.x, w = b === "y" ? g.velocity.y : g.velocity.x, T = Math.abs(C), E = Math.abs(w), D = Math.sign(C), O = D !== 0 && Math.sign(w) === -D && E >= 300, k = !1, ee = null, P = !1, F = (t, n) => {
5674
+ } : j(i), v = a ? j(i).offset : g.offset, b = l.swipeDirection, x = u?.getBoundingClientRect(), S = (b === "y" ? x?.height : x?.width) || (typeof window > "u" ? 0 : b === "y" ? window.innerHeight : window.innerWidth), C = b === "y" ? v.y : v.x, w = b === "y" ? g.velocity.y : g.velocity.x, T = A(C, S), E = Math.abs(w), D = T > 0 && w < 0 && E >= 300, O = !1, k = null, P = !1, ne = (t, n) => {
5672
5675
  P || (P = !0, e.onDragSettle?.(t, n), o?.settle(t, n), o = null, s?.settle(t, n), s = null);
5673
- }, te = (e, t) => ((r, i, a) => {
5676
+ }, F = (e, t) => ((r, i, a) => {
5674
5677
  let o = r === u || r === n, s = typeof a?.duration == "number" ? a.duration : 0;
5675
5678
  if (s <= 0) return e(r, i, a);
5676
- let c = t?.seconds ?? s, l = k ? S - T : T, d = !k && !O, f = mi(a?.ease), p = t ? t.ease : f, m = Ql({
5679
+ let c = t?.seconds ?? s, l = O ? S - T : T, d = !O && !D, f = hi(a?.ease), p = t ? t.ease : f, m = eu({
5677
5680
  remainingPx: l,
5678
5681
  spanPx: S,
5679
5682
  velocityPxPerSecond: E,
@@ -5681,8 +5684,8 @@ function lu(e) {
5681
5684
  authoredEase: p,
5682
5685
  reversing: d
5683
5686
  });
5684
- ee === null && (ee = m), o && F(k, m);
5685
- let h = f ? $l({
5687
+ k === null && (k = m), o && ne(O, m);
5688
+ let h = f ? tu({
5686
5689
  remainingPx: l,
5687
5690
  velocityPxPerSecond: E,
5688
5691
  seconds: m,
@@ -5692,57 +5695,57 @@ function lu(e) {
5692
5695
  return e(r, i, {
5693
5696
  ...a,
5694
5697
  duration: m,
5695
- ...f && h !== null ? { ease: eu(f, h) } : {}
5698
+ ...f && h !== null ? { ease: nu(f, h) } : {}
5696
5699
  });
5697
- }), L = q(l, "POPPING-true"), R = L ? {
5700
+ }), L = q(l, "POPPING-true"), z = L ? {
5698
5701
  seconds: L.duration,
5699
- ease: mi(L.ease)
5700
- } : void 0, z = h ? (e, t, n) => N(e, t, {
5702
+ ease: hi(L.ease)
5703
+ } : void 0, ie = h ? (e, t, n) => te(e, t, {
5701
5704
  ...n,
5702
5705
  duration: 0
5703
- }) : te(N), ie = h ? (e, t, n) => ps(e, t, {
5706
+ }) : F(te), B = h ? (e, t, n) => hs(e, t, {
5704
5707
  ...n,
5705
5708
  duration: 0
5706
- }) : te(ps, R), B = h ? (e, n, r) => ps(e, n, {
5709
+ }) : F(hs, z), V = h ? (e, n, r) => hs(e, n, {
5707
5710
  ...r,
5708
5711
  duration: 0
5709
- }, t) : te((e, n, r) => ps(e, n, r, t)), V = await l.onSwipeEnd(i, g, {
5710
- animate: z,
5712
+ }, t) : F((e, n, r) => hs(e, n, r, t)), H = await l.onSwipeEnd(i, g, {
5713
+ animate: ie,
5711
5714
  currentScreen: u,
5712
5715
  prevScreen: n,
5713
5716
  onStart: (e) => {
5714
5717
  let t = !a && e;
5715
- k = t, p?.onSwipeEnd?.(t, {
5716
- animate: ie,
5718
+ O = t, p?.onSwipeEnd?.(t, {
5719
+ animate: B,
5717
5720
  currentDecorator: f,
5718
5721
  prevDecorator: r
5719
- }), H("end", t, 0, B);
5722
+ }), U("end", t, 0, V);
5720
5723
  }
5721
- }), ae = !a && V;
5722
- if (F(ae, h ? 0 : ee ?? 0), ae) {
5724
+ }), oe = !a && H;
5725
+ if (ne(oe, h ? 0 : k ?? 0), oe) {
5723
5726
  u?.setAttribute(it, "true"), f?.setAttribute(it, "true");
5724
- for (let e of c.current) ml(e, t);
5725
- for (let e of c.prev) $(e, void 0, t), ml(e, t);
5727
+ for (let e of c.current) gl(e, t);
5728
+ for (let e of c.prev) $(e, void 0, t), gl(e, t);
5726
5729
  c = {
5727
5730
  current: [],
5728
5731
  prev: []
5729
5732
  }, d = {
5730
5733
  current: [],
5731
5734
  prev: []
5732
- }, re(), e.back(), I();
5733
- } else u && $(u, void 0, t), n && $(n, void 0, t), f && $(f), r && $(r), ne(), I(), U(), re(), e.setDragStatus("IDLE");
5734
- }, _e = (t) => {
5735
- t.isPrimary === !1 || t.pointerType === "mouse" && t.button !== 0 || ((m || v !== null) && Se(), e.isReadyForDrag() && (v = t.pointerId, b = !1, f = !0, p = !1, E = tu(t.target, {
5735
+ }, R(), e.back(), re();
5736
+ } else u && $(u, void 0, t), n && $(n, void 0, t), f && $(f), r && $(r), I(), re(), ae(), R(), e.setDragStatus("IDLE");
5737
+ }, ve = (t) => {
5738
+ t.isPrimary === !1 || t.pointerType === "mouse" && t.button !== 0 || ((m || v !== null) && Ce(), e.isReadyForDrag() && (v = t.pointerId, b = !1, f = !0, p = !1, E = ru(t.target, {
5736
5739
  direction: "x",
5737
5740
  verifyByScroll: !0
5738
- }), D = tu(t.target, {
5741
+ }), D = ru(t.target, {
5739
5742
  direction: "y",
5740
5743
  verifyByScroll: !0
5741
5744
  }), O = t.clientX, k = t.clientY));
5742
- }, ve = (t) => {
5745
+ }, ye = (t) => {
5743
5746
  if (t.pointerId !== v || e.getViewportScrollHeight() > 10) return;
5744
5747
  if (m) {
5745
- ee(t), me(t);
5748
+ N(t), he(t);
5746
5749
  return;
5747
5750
  }
5748
5751
  if (!f) return;
@@ -5757,22 +5760,22 @@ function lu(e) {
5757
5760
  }
5758
5761
  let r = !E.element && !D.element, i = t.clientX - O, a = t.clientY - k, o = n === "x" ? i : a, s = n === "x" ? a : i;
5759
5762
  if (!(Math.max(Math.abs(o), Math.abs(s)) < 8) && (f = !1, !(o <= 0 || Math.abs(o) <= Math.abs(s) * 3))) {
5760
- if (r) p = !0, oe(t);
5763
+ if (r) p = !0, W(t);
5761
5764
  else {
5762
5765
  let e = D.element && D.element.scrollTop <= 0, r = E.element && E.element.scrollLeft <= 0 && E.hasMarker;
5763
- (n === "y" && (e || E.element) || n === "x" && (r || D.element)) && (p = !0, oe(t));
5766
+ (n === "y" && (e || E.element) || n === "x" && (r || D.element)) && (p = !0, W(t));
5764
5767
  }
5765
5768
  }
5766
- }, ye = (e) => {
5767
- e.pointerId === v && (f = !1, p = !1, _(), v = null, m && ge(e));
5768
5769
  }, be = (e) => {
5769
- e.pointerId === v && (f = !1, p = !1, _(), v = null, b = !0, m && ge(e, !0));
5770
- }, xe = (t) => {
5771
- t.pointerId !== v || !m || t.target === e.getElements().scope && be(t);
5770
+ e.pointerId === v && (f = !1, p = !1, _(), v = null, m && _e(e));
5771
+ }, xe = (e) => {
5772
+ e.pointerId === v && (f = !1, p = !1, _(), v = null, b = !0, m && _e(e, !0));
5773
+ }, Se = (t) => {
5774
+ t.pointerId !== v || !m || t.target === e.getElements().scope && xe(t);
5772
5775
  };
5773
- function Se() {
5776
+ function Ce() {
5774
5777
  let e = v;
5775
- f = !1, p = !1, _(), e !== null && (be({
5778
+ f = !1, p = !1, _(), e !== null && (xe({
5776
5779
  pointerId: e,
5777
5780
  clientX: S.x,
5778
5781
  clientY: S.y,
@@ -5780,42 +5783,42 @@ function lu(e) {
5780
5783
  }), v = null);
5781
5784
  }
5782
5785
  return {
5783
- pointerDown: _e,
5784
- pointerMove: ve,
5785
- pointerUp: ye,
5786
- pointerCancel: be,
5787
- lostPointerCapture: xe,
5788
- abandon: Se,
5786
+ pointerDown: ve,
5787
+ pointerMove: ye,
5788
+ pointerUp: be,
5789
+ pointerCancel: xe,
5790
+ lostPointerCapture: Se,
5791
+ abandon: Ce,
5789
5792
  shouldPreventTouch: () => p
5790
5793
  };
5791
5794
  }
5792
5795
  //#endregion
5793
5796
  //#region src/screen/pendingNetwork.ts
5794
- var uu = 0, du = !1, fu = () => {
5795
- uu = Math.max(0, uu - 1);
5796
- }, pu = () => {
5797
- if (!(du || typeof window > "u")) {
5798
- if (du = !0, typeof window.fetch == "function") {
5797
+ var fu = 0, pu = !1, mu = () => {
5798
+ fu = Math.max(0, fu - 1);
5799
+ }, hu = () => {
5800
+ if (!(pu || typeof window > "u")) {
5801
+ if (pu = !0, typeof window.fetch == "function") {
5799
5802
  let e = window.fetch.bind(window);
5800
5803
  window.fetch = (...t) => {
5801
- uu += 1;
5804
+ fu += 1;
5802
5805
  let n;
5803
5806
  try {
5804
5807
  n = e(...t);
5805
5808
  } catch (e) {
5806
- throw fu(), e;
5809
+ throw mu(), e;
5807
5810
  }
5808
- return n.then((e) => (fu(), e), (e) => {
5809
- throw fu(), e;
5811
+ return n.then((e) => (mu(), e), (e) => {
5812
+ throw mu(), e;
5810
5813
  });
5811
5814
  };
5812
5815
  }
5813
5816
  if (typeof XMLHttpRequest == "function") {
5814
5817
  let e = XMLHttpRequest.prototype.send;
5815
5818
  XMLHttpRequest.prototype.send = function(...t) {
5816
- uu += 1;
5819
+ fu += 1;
5817
5820
  let n = !1, r = () => {
5818
- n || (n = !0, fu());
5821
+ n || (n = !0, mu());
5819
5822
  };
5820
5823
  this.addEventListener("loadend", r);
5821
5824
  try {
@@ -5826,28 +5829,28 @@ var uu = 0, du = !1, fu = () => {
5826
5829
  };
5827
5830
  }
5828
5831
  }
5829
- }, mu = () => (pu(), uu > 0);
5832
+ }, gu = () => (hu(), fu > 0);
5830
5833
  //#endregion
5831
5834
  //#region src/screen/animStartAnchor.ts
5832
- function hu(e) {
5835
+ function _u(e) {
5833
5836
  return e.status !== "PUSHING" && e.status !== "POPPING" && e.status !== "REPLACING" || !e.isTopOrTopPrev ? null : `${e.status}:${e.transitionName}`;
5834
5837
  }
5835
- var gu = 300, _u = 20;
5836
- function vu(e) {
5837
- return Array.from(e.querySelectorAll("img")).filter((e) => e.complete && typeof e.decode == "function").slice(0, _u);
5838
+ var vu = 300, yu = 150, bu = 20;
5839
+ function xu(e) {
5840
+ return Array.from(e.querySelectorAll("img")).filter((e) => e.complete && typeof e.decode == "function").slice(0, bu);
5838
5841
  }
5839
- function yu(e) {
5840
- if (!(!e || typeof e.querySelectorAll != "function")) for (let t of vu(e)) t.decode().catch(() => {});
5842
+ function Su(e) {
5843
+ if (!(!e || typeof e.querySelectorAll != "function")) for (let t of xu(e)) t.decode().catch(() => {});
5841
5844
  }
5842
- var bu = 3, xu = 40, Su = (e) => {
5845
+ var Cu = 3, wu = 40, Tu = (e) => {
5843
5846
  if (typeof e.querySelectorAll != "function") return !1;
5844
5847
  let t = Math.max(1, e.querySelectorAll("*").length);
5845
5848
  /* v8 ignore stop */
5846
- return ((e.textContent ?? "").trim().length + e.querySelectorAll("img").length * xu) / t < bu;
5847
- }, Cu = (e) => typeof e.getAnimations == "function" && e.getAnimations({ subtree: !0 }).some((e) => {
5849
+ return ((e.textContent ?? "").trim().length + e.querySelectorAll("img").length * wu) / t < Cu;
5850
+ }, Eu = (e) => typeof e.getAnimations == "function" && e.getAnimations({ subtree: !0 }).some((e) => {
5848
5851
  let t = e.animationName;
5849
5852
  return typeof t != "string" || !t.startsWith("flemo-");
5850
- }), wu = (e) => {
5853
+ }), Du = (e) => {
5851
5854
  /* v8 ignore next -- the settle gate only runs a scope past looksLikeShell,
5852
5855
  which already requires querySelectorAll. */
5853
5856
  if (typeof e.querySelectorAll != "function") return !1;
@@ -5855,12 +5858,12 @@ var bu = 3, xu = 40, Su = (e) => {
5855
5858
  the guard shields exotic embedders. */
5856
5859
  let t = typeof e.getBoundingClientRect == "function" ? e.getBoundingClientRect() : null, n = t && t.height > 0 ? t : null, r = 0;
5857
5860
  for (let t of Array.from(e.querySelectorAll("img"))) {
5858
- if (r >= _u) break;
5861
+ if (r >= bu) break;
5859
5862
  if (!(t.loading === "lazy" && !t.currentSrc) && !(n && t.getBoundingClientRect().top - n.top >= n.height) && (r += 1, !t.complete)) return !0;
5860
5863
  }
5861
5864
  return !1;
5862
5865
  };
5863
- function Tu(e, t = {}) {
5866
+ function Ou(e, t = {}) {
5864
5867
  let n = !1, r = 0, i = [], a = [], o = () => {
5865
5868
  if (n) return;
5866
5869
  let r = t.scope;
@@ -5868,13 +5871,13 @@ function Tu(e, t = {}) {
5868
5871
  e();
5869
5872
  return;
5870
5873
  }
5871
- let i = vu(r);
5874
+ let i = xu(r);
5872
5875
  if (i.length === 0) {
5873
5876
  e();
5874
5877
  return;
5875
5878
  }
5876
5879
  let a = Promise.allSettled(i.map((e) => e.decode())), o = new Promise((e) => {
5877
- setTimeout(e, 150);
5880
+ setTimeout(e, yu);
5878
5881
  });
5879
5882
  Promise.race([a, o]).then(() => {
5880
5883
  n || e();
@@ -5883,12 +5886,12 @@ function Tu(e, t = {}) {
5883
5886
  let n = t.contentSettle, r = t.scope;
5884
5887
  if (!n || !r || typeof MutationObserver > "u") return e(), () => {};
5885
5888
  let i = () => !n.renderSettleOnly && (h() || m());
5886
- if (!n.renderSettleOnly && !Su(r)) return e(), () => {};
5889
+ if (!n.renderSettleOnly && !Tu(r)) return e(), () => {};
5887
5890
  /* v8 ignore start -- performance exists in every runtime under test;
5888
5891
  the fallback only shields exotic embedders. */
5889
- let o = typeof performance < "u" ? performance.now() : 0, s = () => (typeof performance < "u" ? performance.now() : 0) - o, c = [], l = !1, u = !1, d, f, p, m = () => Su(r) && Cu(r), h = () => mu() || wu(r), g = () => {
5892
+ let o = typeof performance < "u" ? performance.now() : 0, s = () => (typeof performance < "u" ? performance.now() : 0) - o, c = [], l = !1, u = !1, d, f, p, m = () => Tu(r) && Eu(r), h = () => gu() || Du(r), g = () => {
5890
5893
  u || (u = !0, x.disconnect(), clearTimeout(d), clearTimeout(f), clearTimeout(p), c.forEach((e) => cancelAnimationFrame(e)), c = [], e());
5891
- }, _ = () => n.renderSettleOnly ? 6 : !Su(r) && !i() ? 2 : 6, v = !1, y = () => {
5894
+ }, _ = () => n.renderSettleOnly ? 6 : !Tu(r) && !i() ? 2 : 6, v = !1, y = () => {
5892
5895
  if (!n.renderSettleOnly) {
5893
5896
  g();
5894
5897
  return;
@@ -5971,14 +5974,14 @@ function Tu(e, t = {}) {
5971
5974
  n = !0, cancelAnimationFrame(p), r && cancelAnimationFrame(r), i.forEach((e) => cancelAnimationFrame(e)), a.forEach((e) => e());
5972
5975
  };
5973
5976
  }
5974
- function Eu(e, t = {}) {
5975
- let n = Tu(e, t), r = t.contentSettle?.capMs ?? 0, i = setTimeout(e, 300 + r);
5977
+ function ku(e, t = {}) {
5978
+ let n = Ou(e, t), r = t.contentSettle?.capMs ?? 0, i = setTimeout(e, 300 + r);
5976
5979
  return () => {
5977
5980
  n(), clearTimeout(i);
5978
5981
  };
5979
5982
  }
5980
- var Du = (e) => 300 + (e?.contentSettle?.capMs ?? 0);
5981
- function Ou() {
5983
+ var Au = (e) => 300 + (e?.contentSettle?.capMs ?? 0);
5984
+ function ju() {
5982
5985
  let e = /* @__PURE__ */ new Map(), t = (t, n) => {
5983
5986
  clearTimeout(n.backstop), e.delete(t);
5984
5987
  let r = [...n.members];
@@ -5988,14 +5991,14 @@ function Ou() {
5988
5991
  return { join: (r, i, a) => {
5989
5992
  let o = e.get(r);
5990
5993
  if (o) {
5991
- let e = Du(a);
5994
+ let e = Au(a);
5992
5995
  if (e > o.backstopMs) {
5993
5996
  clearTimeout(o.backstop);
5994
5997
  let n = o;
5995
5998
  n.backstopMs = e, n.backstop = setTimeout(() => t(r, n), e);
5996
5999
  }
5997
6000
  } else {
5998
- let n = Du(a), i = {
6001
+ let n = Au(a), i = {
5999
6002
  members: /* @__PURE__ */ new Set(),
6000
6003
  backstop: setTimeout(() => t(r, i), n),
6001
6004
  backstopMs: n
@@ -6005,7 +6008,7 @@ function Ou() {
6005
6008
  let s = o, c = {
6006
6009
  release: i,
6007
6010
  ready: !1,
6008
- cancelReadiness: Tu(() => {
6011
+ cancelReadiness: Ou(() => {
6009
6012
  c.ready = !0, n(s) && t(r, s);
6010
6013
  }, a)
6011
6014
  };
@@ -6022,7 +6025,7 @@ function Ou() {
6022
6025
  }
6023
6026
  //#endregion
6024
6027
  //#region src/screen/observeBarHeight.ts
6025
- function ku(e, t) {
6028
+ function Mu(e, t) {
6026
6029
  e.offsetHeight > 0 && t(e.offsetHeight);
6027
6030
  let n = new ResizeObserver(([e]) => {
6028
6031
  e.contentRect.height > 0 && t(e.contentRect.height);
@@ -6033,9 +6036,9 @@ function ku(e, t) {
6033
6036
  }
6034
6037
  //#endregion
6035
6038
  //#region src/screen/publishRideBox.ts
6036
- function Au(e) {
6039
+ function Nu(e) {
6037
6040
  let t = (t) => {
6038
- t > 0 && e.style.setProperty(sr, `${t}px`);
6041
+ t > 0 && e.style.setProperty(cr, `${t}px`);
6039
6042
  };
6040
6043
  t(e.offsetHeight);
6041
6044
  let n = new ResizeObserver(([e]) => {
@@ -6044,29 +6047,29 @@ function Au(e) {
6044
6047
  t(typeof n == "number" ? n : e.contentRect.height);
6045
6048
  });
6046
6049
  return n.observe(e), () => {
6047
- n.disconnect(), e.style.removeProperty(sr);
6050
+ n.disconnect(), e.style.removeProperty(cr);
6048
6051
  };
6049
6052
  }
6050
6053
  //#endregion
6051
6054
  //#region src/screen/observeViewportScrollHeight.ts
6052
- var ju = 0, Mu = 0, Nu = 0, Pu = !1, Fu = /* @__PURE__ */ new Set(), Iu = 0, Lu = () => {
6055
+ var Pu = 0, Fu = 0, Iu = 0, Lu = !1, Ru = /* @__PURE__ */ new Set(), zu = 0, Bu = () => {
6053
6056
  let e = document.documentElement.scrollHeight - (window.visualViewport?.height || 0);
6054
6057
  e = e < 0 ? 0 : e;
6055
- let t = e - ju;
6056
- t = t < 0 ? 0 : t, ju ||= e, Mu = e, Nu = t, Pu = !0;
6057
- for (let n of [...Fu]) n(e, t);
6058
- }, Ru = () => {
6059
- cancelAnimationFrame(Iu), Iu = requestAnimationFrame(Lu);
6058
+ let t = e - Pu;
6059
+ t = t < 0 ? 0 : t, Pu ||= e, Fu = e, Iu = t, Lu = !0;
6060
+ for (let n of [...Ru]) n(e, t);
6061
+ }, Vu = () => {
6062
+ cancelAnimationFrame(zu), zu = requestAnimationFrame(Bu);
6060
6063
  };
6061
- function zu(e) {
6062
- let t = Fu.size === 0;
6063
- return Fu.add(e), t && (window.visualViewport?.addEventListener("resize", Ru), window.visualViewport?.addEventListener("scroll", Ru)), Pu && (e(Mu, Nu), t && Ru()), () => {
6064
- Fu.delete(e), !(Fu.size > 0) && (cancelAnimationFrame(Iu), window.visualViewport?.removeEventListener("resize", Ru), window.visualViewport?.removeEventListener("scroll", Ru));
6064
+ function Hu(e) {
6065
+ let t = Ru.size === 0;
6066
+ return Ru.add(e), t && (window.visualViewport?.addEventListener("resize", Vu), window.visualViewport?.addEventListener("scroll", Vu)), Lu && (e(Fu, Iu), t && Vu()), () => {
6067
+ Ru.delete(e), !(Ru.size > 0) && (cancelAnimationFrame(zu), window.visualViewport?.removeEventListener("resize", Vu), window.visualViewport?.removeEventListener("scroll", Vu));
6065
6068
  };
6066
6069
  }
6067
6070
  //#endregion
6068
6071
  //#region src/utils/isOpaqueColor.ts
6069
- function Bu(e) {
6072
+ function Uu(e) {
6070
6073
  let t = e.trim().toLowerCase();
6071
6074
  if (t === "transparent" || t === "") return !1;
6072
6075
  if (t.match(/^rgb\(\s*\d+[\s,]+\d+[\s,]+\d+\s*\)$/)) return !0;
@@ -6077,7 +6080,7 @@ function Bu(e) {
6077
6080
  }
6078
6081
  //#endregion
6079
6082
  //#region src/utils/buildRoutePath.ts
6080
- function Vu(e, n) {
6083
+ function Wu(e, n) {
6081
6084
  let i = n ?? {}, a = t(e)(Object.fromEntries(Object.entries(i).map(([e, t]) => [e, String(t)]))), o = (typeof e == "string" ? r(e) : e).tokens.filter((e) => e.type === "param").map((e) => e.name), s = Object.fromEntries(Object.entries(i).filter(([e]) => !o.includes(e))), c = new URLSearchParams(s).toString();
6082
6085
  return {
6083
6086
  pathname: `${a}${c ? `?${c}` : ""}`,
@@ -6085,4 +6088,4 @@ function Vu(e, n) {
6085
6088
  };
6086
6089
  }
6087
6090
  //#endregion
6088
- export { tt as ACTIVE_ATTR, jt as ANIM_HOLD, Y as ANIM_HOLD_ATTR, Mt as ANIM_HOLD_PAUSED_VALUES, gu as ANIM_HOLD_RELEASE_BACKSTOP_MS, ot as BAR_ACTIVE_ATTR, at as BAR_ATTR, lt as BAR_ID_ATTR, ut as BAR_ID_TYPE_ATTR, ct as BAR_RIDING_ATTR, ft as BAR_SPACER_ATTR, st as BAR_STATUS_ATTR, dt as BAR_TRANSITION_ATTR, It as CREEP_ATTR, pt as DECORATOR_ATTR, mt as DECORATOR_NAME_ATTR, Xe as DEFAULT_MORPH_TRANSITION_NAME, Lt as DESK_HEAD_ATTR, Ht as DEVTOOLS_PANEL_ATTR, Ut as FLEMO_ATTRIBUTES, Qe as FLEMO_ATTR_PREFIX, Ft as GOVERNED_ATTR, Bt as GPU_PREWARM_ATTR, Nt as HELD_ARRIVAL_ATTR, Pt as IMAGE_HOLD_ATTR, gt as LAYER_HOST_ATTR, vt as LAYER_OWNER_ATTR, _t as LAYER_SLOT_ATTR, ql as MIN_SETTLE_SECONDS, St as MORPH_ATTR, Tt as MORPH_LAYER_ATTR, wt as MORPH_NAME_ATTR, Ct as MORPH_ROLE, At as MORPH_SHEET_ATTR, Et as MORPH_SLOT_ATTR, Vt as OFFLOADED_SRC_ATTR, Gl as OVERLAY_LEVEL, Ns as OVERSIZE_AREA_RATIO, Rt as PARK_HEAD_ATTR, bt as PART_HOME_ATTR, yt as PART_LAYER_ATTR, J as PART_NAME_ATTR, sr as RIDE_HEIGHT_VAR, rt as ROUTER_ATTR, $e as SCREEN_ATTR, Kl as SCREEN_STACKING_ORDER, it as SKIP_ANIMATION_ATTR, et as STATUS_ATTR, F as TRANSITIONAL_STATUS_VALUES, nt as TRANSITION_ATTR, c as TaskManager, c as TaskManger, Wl as UNNUMBERED_LEVEL, zt as WARM_ATTR, hu as animHoldKey, ps as animateInline, zr as animationName, z as appendParamsQuery, Qo as applyTransitionStyles, Mo as attachMorph, X as attrSelector, Z as attrValueSelector, Uo as beginMorphSwipe, Vu as buildRoutePath, iu as canProgrammaticallyScroll, $ as clearInlineAnimation, Dr as collectAnimatedProperties, qr as compileTransitionStyles, cu as computeBarRiding, ce as computeScreenFreeze, se as computeScreenFreezeMode, w as consumeSelfInducedPop, Ou as createAnimHoldCoordinator, b as createBrowserHistoryDriver, Te as createDecorator, l as createHistoryStore, T as createHistorySync, qs as createImageDecodeOffloader, P as createMemoryHistoryDriver, Ve as createMorphTransition, te as createNavigateStore, re as createNavigationController, Ie as createPartTransition, Ee as createRawDecorator, He as createRawMorphTransition, Le as createRawPartTransition, ue as createRawTransition, W as createRouterScope, G as createScreenSelector, ae as createScreenStore, x as createSelfPopGuard, ie as createStepController, lu as createSwipeController, le as createTransition, Cl as createTransitionEngine, V as createTransitionStore, ge as cupertino, ke as decoratorMap, la as detectBlinkEngine, yu as eagerlyDecodeImages, jr as easingToCss, Fl as ensureGpuPipelinePrewarm, Ys as ensureImageDecodeOffloader, ee as ensureScopeHistorySync, m as ensureWindowHistoryState, os as enteringInitialStyle, tu as findScrollable, u as getMatchedPathPattern, d as getParams, Pa as governedCompiledActive, oc as holdCompositorWarm, pa as isDesktopBlink, da as isLegacyAndroidBlink, Bu as isOpaqueColor, p as isServer, be as layout, C as markSelfInducedPop, H as matchesPathname, xe as material, Ye as morphTransitionMap, Se as none, ku as observeBarHeight, zu as observeViewportScrollHeight, ru as overflowsAxis, Oe as overlay, ze as partTransitionMap, lr as percentRatio, Au as publishRideBox, R as readStepParams, ci as registerMorphLayer, Po as registerPartLayer, as as registerTransitionDefinitions, N as releaseScopeHistorySync, Fe as resolveDecoratorClock, Fo as resolvePartLayer, La as resolvePlatformProfile, dr as resolveRideTarget, we as resolveTransition, ur as rideLength, Eu as scheduleAnimHoldRelease, f as seedInitialHistory, h as seedRouterEntry, We as shared, su as sharedBarsMatch, Hs as shouldOffloadImage, Ul as startFlemoRuntime, Ca as steadySixtyDesktopProfile, B as subscribeStepParamsRestore, Ql as swipeSettleSeconds, Or as targetToDecls, Ke as textMorph, Ce as transitionMap, Xr as variantHasAnimation, Je as zoomMorph };
6091
+ export { tt as ACTIVE_ATTR, Mt as ANIM_HOLD, Y as ANIM_HOLD_ATTR, Nt as ANIM_HOLD_PAUSED_VALUES, vu as ANIM_HOLD_RELEASE_BACKSTOP_MS, ot as BAR_ACTIVE_ATTR, at as BAR_ATTR, lt as BAR_ID_ATTR, ut as BAR_ID_TYPE_ATTR, ct as BAR_RIDING_ATTR, ft as BAR_SPACER_ATTR, st as BAR_STATUS_ATTR, dt as BAR_TRANSITION_ATTR, Lt as CREEP_ATTR, pt as DECORATOR_ATTR, mt as DECORATOR_NAME_ATTR, Xe as DEFAULT_MORPH_TRANSITION_NAME, Rt as DESK_HEAD_ATTR, Ut as DEVTOOLS_PANEL_ATTR, Wt as FLEMO_ATTRIBUTES, Qe as FLEMO_ATTR_PREFIX, It as GOVERNED_ATTR, Vt as GPU_PREWARM_ATTR, Pt as HELD_ARRIVAL_ATTR, Ft as IMAGE_HOLD_ATTR, gt as LAYER_HOST_ATTR, vt as LAYER_OWNER_ATTR, _t as LAYER_SLOT_ATTR, Yl as MIN_SETTLE_SECONDS, St as MORPH_ATTR, At as MORPH_CAMERA_ATTR, kt as MORPH_GHOST_ATTR, Tt as MORPH_ID_ATTR, Et as MORPH_LAYER_ATTR, wt as MORPH_NAME_ATTR, Ct as MORPH_ROLE, jt as MORPH_SHEET_ATTR, Dt as MORPH_SLOT_ATTR, Ot as MORPH_STAND_IN_ATTR, Ht as OFFLOADED_SRC_ATTR, ql as OVERLAY_LEVEL, Fs as OVERSIZE_AREA_RATIO, zt as PARK_HEAD_ATTR, bt as PART_HOME_ATTR, yt as PART_LAYER_ATTR, J as PART_NAME_ATTR, cr as RIDE_HEIGHT_VAR, rt as ROUTER_ATTR, $e as SCREEN_ATTR, Jl as SCREEN_STACKING_ORDER, it as SKIP_ANIMATION_ATTR, et as STATUS_ATTR, P as TRANSITIONAL_STATUS_VALUES, nt as TRANSITION_ATTR, c as TaskManager, c as TaskManger, Kl as UNNUMBERED_LEVEL, Bt as WARM_ATTR, _u as animHoldKey, hs as animateInline, Br as animationName, z as appendParamsQuery, es as applyTransitionStyles, Po as attachMorph, X as attrSelector, Z as attrValueSelector, Go as beginMorphSwipe, Wu as buildRoutePath, ou as canProgrammaticallyScroll, $ as clearInlineAnimation, Or as collectAnimatedProperties, Jr as compileTransitionStyles, uu as computeBarRiding, ce as computeScreenFreeze, se as computeScreenFreezeMode, w as consumeSelfInducedPop, ju as createAnimHoldCoordinator, b as createBrowserHistoryDriver, Te as createDecorator, l as createHistoryStore, T as createHistorySync, Ys as createImageDecodeOffloader, te as createMemoryHistoryDriver, Ve as createMorphTransition, ne as createNavigateStore, L as createNavigationController, Ie as createPartTransition, Ee as createRawDecorator, He as createRawMorphTransition, Le as createRawPartTransition, ue as createRawTransition, W as createRouterScope, G as createScreenSelector, ae as createScreenStore, x as createSelfPopGuard, ie as createStepController, du as createSwipeController, le as createTransition, Tl as createTransitionEngine, V as createTransitionStore, ge as cupertino, ke as decoratorMap, ua as detectBlinkEngine, Su as eagerlyDecodeImages, Mr as easingToCss, Ll as ensureGpuPipelinePrewarm, Zs as ensureImageDecodeOffloader, ee as ensureScopeHistorySync, m as ensureWindowHistoryState, cs as enteringInitialStyle, ru as findScrollable, u as getMatchedPathPattern, d as getParams, Ia as governedCompiledActive, cc as holdCompositorWarm, ma as isDesktopBlink, fa as isLegacyAndroidBlink, Uu as isOpaqueColor, p as isServer, be as layout, C as markSelfInducedPop, H as matchesPathname, xe as material, Ye as morphTransitionMap, Se as none, Mu as observeBarHeight, Hu as observeViewportScrollHeight, au as overflowsAxis, Oe as overlay, ze as partTransitionMap, ur as percentRatio, Nu as publishRideBox, R as readStepParams, li as registerMorphLayer, Io as registerPartLayer, ss as registerTransitionDefinitions, N as releaseScopeHistorySync, Fe as resolveDecoratorClock, Lo as resolvePartLayer, za as resolvePlatformProfile, fr as resolveRideTarget, we as resolveTransition, dr as rideLength, ku as scheduleAnimHoldRelease, f as seedInitialHistory, h as seedRouterEntry, We as shared, lu as sharedBarsMatch, Ws as shouldOffloadImage, Gl as startFlemoRuntime, Ta as steadySixtyDesktopProfile, B as subscribeStepParamsRestore, eu as swipeSettleSeconds, kr as targetToDecls, Ke as textMorph, Ce as transitionMap, Zr as variantHasAnimation, Je as zoomMorph };