@protonradio/proton-ui 0.7.5-beta8 → 0.7.5-beta9

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.es.js CHANGED
@@ -1,9 +1,9 @@
1
1
  import A, { useRef as I, useCallback as X, useState as z, useContext as Y, useEffect as L, createContext as Q, useMemo as V, useLayoutEffect as Mc, createElement as gi, isValidElement as Ic, forwardRef as dt, cloneElement as Fc } from "react";
2
- import Sn, { flushSync as _c, createPortal as yi } from "react-dom";
2
+ import Cn, { flushSync as _c, createPortal as yi } from "react-dom";
3
3
  import { e as W, i as Lr, h as $i, a as Rc, D as Un } from "./utils-KedSkjS1.mjs";
4
4
  import { THEMES as Pt, BREAKPOINTS as xi } from "./constants.es.js";
5
5
  import { transparentize as Gn, parseToRgba as Nc } from "color2k";
6
- import { G as ke, S as en, W as tn, D as nn } from "./colors-Dwh4VIMR.mjs";
6
+ import { G as ke, S as tn, W as nn, D as rn } from "./colors-Dwh4VIMR.mjs";
7
7
  import { c as h4 } from "./colors-Dwh4VIMR.mjs";
8
8
  var dr = { exports: {} }, Mt = {};
9
9
  /**
@@ -290,7 +290,7 @@ function Oc() {
290
290
  var K = h.prototype;
291
291
  return !!(K && K.isReactComponent);
292
292
  }
293
- function Jt(h, K, R) {
293
+ function Qt(h, K, R) {
294
294
  if (h == null)
295
295
  return "";
296
296
  if (typeof h == "function")
@@ -308,11 +308,11 @@ function Oc() {
308
308
  case u:
309
309
  return Ln(h.render);
310
310
  case d:
311
- return Jt(h.type, K, R);
311
+ return Qt(h.type, K, R);
312
312
  case f: {
313
313
  var j = h, Z = j._payload, ee = j._init;
314
314
  try {
315
- return Jt(ee(Z), K, R);
315
+ return Qt(ee(Z), K, R);
316
316
  } catch {
317
317
  }
318
318
  }
@@ -320,9 +320,9 @@ function Oc() {
320
320
  return "";
321
321
  }
322
322
  var Bt = Object.prototype.hasOwnProperty, dl = {}, fl = E.ReactDebugCurrentFrame;
323
- function Qt(h) {
323
+ function en(h) {
324
324
  if (h) {
325
- var K = h._owner, R = Jt(h.type, h._source, K ? K.type : null);
325
+ var K = h._owner, R = Qt(h.type, h._source, K ? K.type : null);
326
326
  fl.setExtraStackFrame(R);
327
327
  } else
328
328
  fl.setExtraStackFrame(null);
@@ -342,7 +342,7 @@ function Oc() {
342
342
  } catch (le) {
343
343
  G = le;
344
344
  }
345
- G && !(G instanceof Error) && (Qt(Z), S("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", j || "React class", R, q, typeof G), Qt(null)), G instanceof Error && !(G.message in dl) && (dl[G.message] = !0, Qt(Z), S("Failed %s type: %s", R, G.message), Qt(null));
345
+ G && !(G instanceof Error) && (en(Z), S("%s: type specification of %s `%s` is invalid; the type checker function must return `null` or an `Error` but returned a %s. You may have forgotten to pass an argument to the type checker creator (arrayOf, instanceOf, objectOf, oneOf, oneOfType, and shape all require an argument).", j || "React class", R, q, typeof G), en(null)), G instanceof Error && !(G.message in dl) && (dl[G.message] = !0, en(Z), S("Failed %s type: %s", R, G.message), en(null));
346
346
  }
347
347
  }
348
348
  }
@@ -471,7 +471,7 @@ function Oc() {
471
471
  var jn = E.ReactCurrentOwner, bl = E.ReactDebugCurrentFrame;
472
472
  function bt(h) {
473
473
  if (h) {
474
- var K = h._owner, R = Jt(h.type, h._source, K ? K.type : null);
474
+ var K = h._owner, R = Qt(h.type, h._source, K ? K.type : null);
475
475
  bl.setExtraStackFrame(R);
476
476
  } else
477
477
  bl.setExtraStackFrame(null);
@@ -669,10 +669,10 @@ function zc(t) {
669
669
  i
670
670
  ];
671
671
  }
672
- const fn = {
672
+ const pn = {
673
673
  prefix: String(Math.round(Math.random() * 1e10)),
674
674
  current: 0
675
- }, Ei = /* @__PURE__ */ A.createContext(fn), jc = /* @__PURE__ */ A.createContext(!1);
675
+ }, Ei = /* @__PURE__ */ A.createContext(pn), jc = /* @__PURE__ */ A.createContext(!1);
676
676
  let Vc = !!(typeof window < "u" && window.document && window.document.createElement), Yn = /* @__PURE__ */ new WeakMap();
677
677
  function Hc(t = !1) {
678
678
  let e = Y(Ei), n = I(null);
@@ -692,12 +692,12 @@ function Hc(t = !1) {
692
692
  }
693
693
  function Wc(t) {
694
694
  let e = Y(Ei);
695
- e === fn && !Vc && console.warn("When server rendering, you must wrap your application in an <SSRProvider> to ensure consistent ids are generated between the client and server.");
696
- let n = Hc(!!t), r = e === fn && process.env.NODE_ENV === "test" ? "react-aria" : `react-aria${e.prefix}`;
695
+ e === pn && !Vc && console.warn("When server rendering, you must wrap your application in an <SSRProvider> to ensure consistent ids are generated between the client and server.");
696
+ let n = Hc(!!t), r = e === pn && process.env.NODE_ENV === "test" ? "react-aria" : `react-aria${e.prefix}`;
697
697
  return t || `${r}-${n}`;
698
698
  }
699
699
  function Uc(t) {
700
- let e = A.useId(), [n] = z(nt()), r = n || process.env.NODE_ENV === "test" ? "react-aria" : `react-aria${fn.prefix}`;
700
+ let e = A.useId(), [n] = z(nt()), r = n || process.env.NODE_ENV === "test" ? "react-aria" : `react-aria${pn.prefix}`;
701
701
  return t || `${r}-${e}`;
702
702
  }
703
703
  const Gc = typeof A.useId == "function" ? Uc : Wc;
@@ -833,20 +833,20 @@ function Le(t) {
833
833
  t.focus(), ad(e);
834
834
  }
835
835
  }
836
- let rn = null;
836
+ let ln = null;
837
837
  function id() {
838
- if (rn == null) {
839
- rn = !1;
838
+ if (ln == null) {
839
+ ln = !1;
840
840
  try {
841
841
  document.createElement("div").focus({
842
842
  get preventScroll() {
843
- return rn = !0, !0;
843
+ return ln = !0, !0;
844
844
  }
845
845
  });
846
846
  } catch {
847
847
  }
848
848
  }
849
- return rn;
849
+ return ln;
850
850
  }
851
851
  function od(t) {
852
852
  let e = t.parentNode, n = [], r = document.scrollingElement || document.documentElement;
@@ -866,7 +866,7 @@ function ad(t) {
866
866
  for (let { element: e, scrollTop: n, scrollLeft: r } of t)
867
867
  e.scrollTop = n, e.scrollLeft = r;
868
868
  }
869
- function Cn(t) {
869
+ function wn(t) {
870
870
  var e;
871
871
  return typeof window > "u" || window.navigator == null ? !1 : ((e = window.navigator.userAgentData) === null || e === void 0 ? void 0 : e.brands.some((n) => t.test(n.brand))) || t.test(window.navigator.userAgent);
872
872
  }
@@ -885,18 +885,18 @@ const tt = Ve(function() {
885
885
  }), Ci = Ve(function() {
886
886
  return Or(/^iPad/i) || // iPadOS 13 lies and says it's a Mac, but we can distinguish by detecting touch support.
887
887
  tt() && navigator.maxTouchPoints > 1;
888
- }), wn = Ve(function() {
888
+ }), Pn = Ve(function() {
889
889
  return ud() || Ci();
890
890
  }), sd = Ve(function() {
891
- return tt() || wn();
891
+ return tt() || Pn();
892
892
  }), zr = Ve(function() {
893
- return Cn(/AppleWebKit/i) && !cd();
893
+ return wn(/AppleWebKit/i) && !cd();
894
894
  }), cd = Ve(function() {
895
- return Cn(/Chrome/i);
896
- }), pn = Ve(function() {
897
- return Cn(/Android/i);
895
+ return wn(/Chrome/i);
896
+ }), vn = Ve(function() {
897
+ return wn(/Android/i);
898
898
  }), dd = Ve(function() {
899
- return Cn(/Firefox/i);
899
+ return wn(/Firefox/i);
900
900
  }), fd = /* @__PURE__ */ Q({
901
901
  isNative: !0,
902
902
  open: vd,
@@ -1033,7 +1033,7 @@ function ki(t, e) {
1033
1033
  "aria-labelledby": l
1034
1034
  };
1035
1035
  }
1036
- function Pn(t) {
1036
+ function Dn(t) {
1037
1037
  const e = I(null);
1038
1038
  return V(() => ({
1039
1039
  get current() {
@@ -1106,7 +1106,7 @@ function bd(t, e) {
1106
1106
  }
1107
1107
  let gd = 0;
1108
1108
  const qn = /* @__PURE__ */ new Map();
1109
- function Dn(t) {
1109
+ function kn(t) {
1110
1110
  let [e, n] = z();
1111
1111
  return J(() => {
1112
1112
  if (!t) return;
@@ -1189,12 +1189,12 @@ function Ze(t, e) {
1189
1189
  }
1190
1190
  }
1191
1191
  function vr(t) {
1192
- return t.mozInputSource === 0 && t.isTrusted ? !0 : pn() && t.pointerType ? t.type === "click" && t.buttons === 1 : t.detail === 0 && !t.pointerType;
1192
+ return t.mozInputSource === 0 && t.isTrusted ? !0 : vn() && t.pointerType ? t.type === "click" && t.buttons === 1 : t.detail === 0 && !t.pointerType;
1193
1193
  }
1194
1194
  function yd(t) {
1195
- return !pn() && t.width === 0 && t.height === 0 || t.width === 1 && t.height === 1 && t.pressure === 0 && t.detail === 0 && t.pointerType === "mouse";
1195
+ return !vn() && t.width === 0 && t.height === 0 || t.width === 1 && t.height === 1 && t.pressure === 0 && t.detail === 0 && t.pointerType === "mouse";
1196
1196
  }
1197
- function kn(t, e, n) {
1197
+ function Tn(t, e, n) {
1198
1198
  let r = I(e), l = oe(() => {
1199
1199
  n && n(r.current);
1200
1200
  });
@@ -1238,18 +1238,18 @@ function rt(t, e, n) {
1238
1238
  function hr(t, e = -1 / 0, n = 1 / 0) {
1239
1239
  return Math.min(Math.max(t, e), n);
1240
1240
  }
1241
- let Ct = "default", mr = "", dn = /* @__PURE__ */ new WeakMap();
1241
+ let Ct = "default", mr = "", fn = /* @__PURE__ */ new WeakMap();
1242
1242
  function Tl(t) {
1243
- if (wn()) {
1243
+ if (Pn()) {
1244
1244
  if (Ct === "default") {
1245
1245
  const e = ne(t);
1246
1246
  mr = e.documentElement.style.webkitUserSelect, e.documentElement.style.webkitUserSelect = "none";
1247
1247
  }
1248
1248
  Ct = "disabled";
1249
- } else (t instanceof HTMLElement || t instanceof SVGElement) && (dn.set(t, t.style.userSelect), t.style.userSelect = "none");
1249
+ } else (t instanceof HTMLElement || t instanceof SVGElement) && (fn.set(t, t.style.userSelect), t.style.userSelect = "none");
1250
1250
  }
1251
- function ln(t) {
1252
- if (wn()) {
1251
+ function on(t) {
1252
+ if (Pn()) {
1253
1253
  if (Ct !== "disabled") return;
1254
1254
  Ct = "restoring", setTimeout(() => {
1255
1255
  Pi(() => {
@@ -1259,9 +1259,9 @@ function ln(t) {
1259
1259
  }
1260
1260
  });
1261
1261
  }, 300);
1262
- } else if ((t instanceof HTMLElement || t instanceof SVGElement) && t && dn.has(t)) {
1263
- let e = dn.get(t);
1264
- t.style.userSelect === "none" && (t.style.userSelect = e), t.getAttribute("style") === "" && t.removeAttribute("style"), dn.delete(t);
1262
+ } else if ((t instanceof HTMLElement || t instanceof SVGElement) && t && fn.has(t)) {
1263
+ let e = fn.get(t);
1264
+ t.style.userSelect === "none" && (t.style.userSelect = e), t.getAttribute("style") === "" && t.removeAttribute("style"), fn.delete(t);
1265
1265
  }
1266
1266
  }
1267
1267
  const Vt = A.createContext({
@@ -1307,19 +1307,19 @@ function wd(t) {
1307
1307
  }
1308
1308
  return jr(e, t.ref), t;
1309
1309
  }
1310
- var on = /* @__PURE__ */ new WeakMap();
1311
- class an {
1310
+ var an = /* @__PURE__ */ new WeakMap();
1311
+ class un {
1312
1312
  continuePropagation() {
1313
- Al(this, on, !1);
1313
+ Al(this, an, !1);
1314
1314
  }
1315
1315
  get shouldStopPropagation() {
1316
- return xd(this, on);
1316
+ return xd(this, an);
1317
1317
  }
1318
1318
  constructor(e, n, r, l) {
1319
- Sd(this, on, {
1319
+ Sd(this, an, {
1320
1320
  writable: !0,
1321
1321
  value: void 0
1322
- }), Al(this, on, !0);
1322
+ }), Al(this, an, !0);
1323
1323
  var i;
1324
1324
  let o = (i = l == null ? void 0 : l.target) !== null && i !== void 0 ? i : r.currentTarget;
1325
1325
  const a = o == null ? void 0 : o.getBoundingClientRect();
@@ -1358,7 +1358,7 @@ function ze(t) {
1358
1358
  if (o || P.didFirePressStart) return !1;
1359
1359
  let w = !0;
1360
1360
  if (P.isTriggeringEvent = !0, r) {
1361
- let M = new an("pressstart", B, v);
1361
+ let M = new un("pressstart", B, v);
1362
1362
  r(M), w = M.shouldStopPropagation;
1363
1363
  }
1364
1364
  return n && n(!0), P.isTriggeringEvent = !1, P.didFirePressStart = !0, m(!0), w;
@@ -1368,11 +1368,11 @@ function ze(t) {
1368
1368
  w.ignoreClickAfterPress = !0, w.didFirePressStart = !1, w.isTriggeringEvent = !0;
1369
1369
  let M = !0;
1370
1370
  if (l) {
1371
- let $ = new an("pressend", B, v);
1371
+ let $ = new un("pressend", B, v);
1372
1372
  l($), M = $.shouldStopPropagation;
1373
1373
  }
1374
1374
  if (n && n(!1), m(!1), e && P && !o) {
1375
- let $ = new an("press", B, v);
1375
+ let $ = new un("press", B, v);
1376
1376
  e($), M && (M = $.shouldStopPropagation);
1377
1377
  }
1378
1378
  return w.isTriggeringEvent = !1, M;
@@ -1381,13 +1381,13 @@ function ze(t) {
1381
1381
  if (o) return !1;
1382
1382
  if (i) {
1383
1383
  P.isTriggeringEvent = !0;
1384
- let w = new an("pressup", B, v);
1384
+ let w = new un("pressup", B, v);
1385
1385
  return i(w), P.isTriggeringEvent = !1, w.shouldStopPropagation;
1386
1386
  }
1387
1387
  return !0;
1388
1388
  }), C = oe((v) => {
1389
1389
  let B = y.current;
1390
- B.isPressed && B.target && (B.isOverTarget && B.pointerType != null && x(Fe(B.target, v), B.pointerType, !1), B.isPressed = !1, B.isOverTarget = !1, B.activePointerId = null, B.pointerType = null, E(), s || ln(B.target));
1390
+ B.isPressed && B.target && (B.isOverTarget && B.pointerType != null && x(Fe(B.target, v), B.pointerType, !1), B.isPressed = !1, B.isOverTarget = !1, B.activePointerId = null, B.pointerType = null, E(), s || on(B.target));
1391
1391
  }), D = oe((v) => {
1392
1392
  c && C(v);
1393
1393
  }), _ = V(() => {
@@ -1450,7 +1450,7 @@ function ze(t) {
1450
1450
  let w = (T) => {
1451
1451
  T.pointerId === v.activePointerId && (v.target && yt(T, v.target) ? !v.isOverTarget && v.pointerType != null && (v.isOverTarget = !0, S(Fe(v.target, T), v.pointerType)) : v.target && v.isOverTarget && v.pointerType != null && (v.isOverTarget = !1, x(Fe(v.target, T), v.pointerType, !1), D(T)));
1452
1452
  }, M = (T) => {
1453
- T.pointerId === v.activePointerId && v.isPressed && T.button === 0 && v.target && (yt(T, v.target) && v.pointerType != null ? x(Fe(v.target, T), v.pointerType) : v.isOverTarget && v.pointerType != null && x(Fe(v.target, T), v.pointerType, !1), v.isPressed = !1, v.isOverTarget = !1, v.activePointerId = null, v.pointerType = null, E(), s || ln(v.target), "ontouchend" in v.target && T.pointerType !== "mouse" && g(v.target, "touchend", $, {
1453
+ T.pointerId === v.activePointerId && v.isPressed && T.button === 0 && v.target && (yt(T, v.target) && v.pointerType != null ? x(Fe(v.target, T), v.pointerType) : v.isOverTarget && v.pointerType != null && x(Fe(v.target, T), v.pointerType, !1), v.isPressed = !1, v.isOverTarget = !1, v.activePointerId = null, v.pointerType = null, E(), s || on(v.target), "ontouchend" in v.target && T.pointerType !== "mouse" && g(v.target, "touchend", $, {
1454
1454
  once: !0
1455
1455
  }));
1456
1456
  }, $ = (T) => {
@@ -1509,7 +1509,7 @@ function ze(t) {
1509
1509
  return;
1510
1510
  }
1511
1511
  let F = Kl($.nativeEvent, v.activePointerId), T = !0;
1512
- F && yt(F, $.currentTarget) && v.pointerType != null ? (k(Ye(v.target, $), v.pointerType), T = x(Ye(v.target, $), v.pointerType)) : v.isOverTarget && v.pointerType != null && (T = x(Ye(v.target, $), v.pointerType, !1)), T && $.stopPropagation(), v.isPressed = !1, v.activePointerId = null, v.isOverTarget = !1, v.ignoreEmulatedMouseEvents = !0, v.target && !s && ln(v.target), E();
1512
+ F && yt(F, $.currentTarget) && v.pointerType != null ? (k(Ye(v.target, $), v.pointerType), T = x(Ye(v.target, $), v.pointerType)) : v.isOverTarget && v.pointerType != null && (T = x(Ye(v.target, $), v.pointerType, !1)), T && $.stopPropagation(), v.isPressed = !1, v.activePointerId = null, v.isOverTarget = !1, v.ignoreEmulatedMouseEvents = !0, v.target && !s && on(v.target), E();
1513
1513
  }, B.onTouchCancel = ($) => {
1514
1514
  $.currentTarget.contains($.target) && ($.stopPropagation(), v.isPressed && C(Ye(v.target, $)));
1515
1515
  };
@@ -1541,7 +1541,7 @@ function ze(t) {
1541
1541
  ]);
1542
1542
  return L(() => () => {
1543
1543
  var v;
1544
- s || ln((v = y.current.target) !== null && v !== void 0 ? v : void 0);
1544
+ s || on((v = y.current.target) !== null && v !== void 0 ? v : void 0);
1545
1545
  }, [
1546
1546
  s
1547
1547
  ]), {
@@ -1634,7 +1634,7 @@ function Mi(t, e) {
1634
1634
  }
1635
1635
  const Ad = /* @__PURE__ */ A.forwardRef(({ children: t, ...e }, n) => {
1636
1636
  let r = I(!1), l = Y(Vt);
1637
- n = Pn(n || (l == null ? void 0 : l.ref));
1637
+ n = Dn(n || (l == null ? void 0 : l.ref));
1638
1638
  let i = H(l || {}, {
1639
1639
  ...e,
1640
1640
  ref: n,
@@ -1721,7 +1721,7 @@ function Ii(t) {
1721
1721
  n
1722
1722
  ]);
1723
1723
  }
1724
- function Tn(t) {
1724
+ function An(t) {
1725
1725
  let { isDisabled: e, onFocus: n, onBlur: r, onFocusChange: l } = t;
1726
1726
  const i = X((u) => {
1727
1727
  if (u.target === u.currentTarget)
@@ -1749,34 +1749,34 @@ const Md = {
1749
1749
  Tab: !0,
1750
1750
  Escape: !0
1751
1751
  };
1752
- function An(t, e) {
1752
+ function Bn(t, e) {
1753
1753
  for (let n of Ht) n(t, e);
1754
1754
  }
1755
1755
  function Id(t) {
1756
1756
  return !(t.metaKey || !tt() && t.altKey || t.ctrlKey || t.key === "Control" || t.key === "Shift" || t.key === "Meta");
1757
1757
  }
1758
- function vn(t) {
1759
- st = !0, Id(t) && (je = "keyboard", An("keyboard", t));
1758
+ function hn(t) {
1759
+ st = !0, Id(t) && (je = "keyboard", Bn("keyboard", t));
1760
1760
  }
1761
1761
  function we(t) {
1762
- je = "pointer", (t.type === "mousedown" || t.type === "pointerdown") && (st = !0, An("pointer", t));
1762
+ je = "pointer", (t.type === "mousedown" || t.type === "pointerdown") && (st = !0, Bn("pointer", t));
1763
1763
  }
1764
1764
  function Fi(t) {
1765
1765
  vr(t) && (st = !0, je = "virtual");
1766
1766
  }
1767
1767
  function _i(t) {
1768
- t.target === window || t.target === document || (!st && !br && (je = "virtual", An("virtual", t)), st = !1, br = !1);
1768
+ t.target === window || t.target === document || (!st && !br && (je = "virtual", Bn("virtual", t)), st = !1, br = !1);
1769
1769
  }
1770
1770
  function Ri() {
1771
1771
  st = !1, br = !0;
1772
1772
  }
1773
- function hn(t) {
1773
+ function mn(t) {
1774
1774
  if (typeof window > "u" || zt.get(Pe(t))) return;
1775
1775
  const e = Pe(t), n = ne(t);
1776
1776
  let r = e.HTMLElement.prototype.focus;
1777
1777
  e.HTMLElement.prototype.focus = function() {
1778
1778
  st = !0, r.apply(this, arguments);
1779
- }, n.addEventListener("keydown", vn, !0), n.addEventListener("keyup", vn, !0), n.addEventListener("click", Fi, !0), e.addEventListener("focus", _i, !0), e.addEventListener("blur", Ri, !1), typeof PointerEvent < "u" ? (n.addEventListener("pointerdown", we, !0), n.addEventListener("pointermove", we, !0), n.addEventListener("pointerup", we, !0)) : (n.addEventListener("mousedown", we, !0), n.addEventListener("mousemove", we, !0), n.addEventListener("mouseup", we, !0)), e.addEventListener("beforeunload", () => {
1779
+ }, n.addEventListener("keydown", hn, !0), n.addEventListener("keyup", hn, !0), n.addEventListener("click", Fi, !0), e.addEventListener("focus", _i, !0), e.addEventListener("blur", Ri, !1), typeof PointerEvent < "u" ? (n.addEventListener("pointerdown", we, !0), n.addEventListener("pointermove", we, !0), n.addEventListener("pointerup", we, !0)) : (n.addEventListener("mousedown", we, !0), n.addEventListener("mousemove", we, !0), n.addEventListener("mouseup", we, !0)), e.addEventListener("beforeunload", () => {
1780
1780
  Ni(t);
1781
1781
  }, {
1782
1782
  once: !0
@@ -1786,27 +1786,27 @@ function hn(t) {
1786
1786
  }
1787
1787
  const Ni = (t, e) => {
1788
1788
  const n = Pe(t), r = ne(t);
1789
- e && r.removeEventListener("DOMContentLoaded", e), zt.has(n) && (n.HTMLElement.prototype.focus = zt.get(n).focus, r.removeEventListener("keydown", vn, !0), r.removeEventListener("keyup", vn, !0), r.removeEventListener("click", Fi, !0), n.removeEventListener("focus", _i, !0), n.removeEventListener("blur", Ri, !1), typeof PointerEvent < "u" ? (r.removeEventListener("pointerdown", we, !0), r.removeEventListener("pointermove", we, !0), r.removeEventListener("pointerup", we, !0)) : (r.removeEventListener("mousedown", we, !0), r.removeEventListener("mousemove", we, !0), r.removeEventListener("mouseup", we, !0)), zt.delete(n));
1789
+ e && r.removeEventListener("DOMContentLoaded", e), zt.has(n) && (n.HTMLElement.prototype.focus = zt.get(n).focus, r.removeEventListener("keydown", hn, !0), r.removeEventListener("keyup", hn, !0), r.removeEventListener("click", Fi, !0), n.removeEventListener("focus", _i, !0), n.removeEventListener("blur", Ri, !1), typeof PointerEvent < "u" ? (r.removeEventListener("pointerdown", we, !0), r.removeEventListener("pointermove", we, !0), r.removeEventListener("pointerup", we, !0)) : (r.removeEventListener("mousedown", we, !0), r.removeEventListener("mousemove", we, !0), r.removeEventListener("mouseup", we, !0)), zt.delete(n));
1790
1790
  };
1791
1791
  function Fd(t) {
1792
1792
  const e = ne(t);
1793
1793
  let n;
1794
- return e.readyState !== "loading" ? hn(t) : (n = () => {
1795
- hn(t);
1794
+ return e.readyState !== "loading" ? mn(t) : (n = () => {
1795
+ mn(t);
1796
1796
  }, e.addEventListener("DOMContentLoaded", n)), () => Ni(t, n);
1797
1797
  }
1798
1798
  typeof document < "u" && Fd();
1799
1799
  function ct() {
1800
1800
  return je !== "pointer";
1801
1801
  }
1802
- function mn() {
1802
+ function bn() {
1803
1803
  return je;
1804
1804
  }
1805
1805
  function Li(t) {
1806
- je = t, An(t, null);
1806
+ je = t, Bn(t, null);
1807
1807
  }
1808
1808
  function Oi() {
1809
- hn();
1809
+ mn();
1810
1810
  let [t, e] = z(je);
1811
1811
  return L(() => {
1812
1812
  let n = () => {
@@ -1834,7 +1834,7 @@ function Rd(t, e, n) {
1834
1834
  return t = t || (n == null ? void 0 : n.target) instanceof l && !_d.has(n == null || (r = n.target) === null || r === void 0 ? void 0 : r.type) || (n == null ? void 0 : n.target) instanceof i || (n == null ? void 0 : n.target) instanceof o && (n == null ? void 0 : n.target.isContentEditable), !(t && e === "keyboard" && n instanceof a && !Md[n.key]);
1835
1835
  }
1836
1836
  function Nd(t, e, n) {
1837
- hn(), L(() => {
1837
+ mn(), L(() => {
1838
1838
  let r = (l, i) => {
1839
1839
  Rd(!!(n != null && n.isTextInput), l, i) && t(ct());
1840
1840
  };
@@ -1872,10 +1872,10 @@ function qt(t) {
1872
1872
  }
1873
1873
  };
1874
1874
  }
1875
- let bn = !1, Jn = 0;
1875
+ let gn = !1, Jn = 0;
1876
1876
  function gr() {
1877
- bn = !0, setTimeout(() => {
1878
- bn = !1;
1877
+ gn = !0, setTimeout(() => {
1878
+ gn = !1;
1879
1879
  }, 50);
1880
1880
  }
1881
1881
  function Il(t) {
@@ -1916,13 +1916,13 @@ function kt(t) {
1916
1916
  }), n && n(!1), o(!1);
1917
1917
  }, f = {};
1918
1918
  return typeof PointerEvent < "u" ? (f.onPointerEnter = (p) => {
1919
- bn && p.pointerType === "mouse" || s(p, p.pointerType);
1919
+ gn && p.pointerType === "mouse" || s(p, p.pointerType);
1920
1920
  }, f.onPointerLeave = (p) => {
1921
1921
  !l && p.currentTarget.contains(p.target) && d(p, p.pointerType);
1922
1922
  }) : (f.onTouchStart = () => {
1923
1923
  a.ignoreEmulatedMouseEvents = !0;
1924
1924
  }, f.onMouseEnter = (p) => {
1925
- !a.ignoreEmulatedMouseEvents && !bn && s(p, "mouse"), a.ignoreEmulatedMouseEvents = !1;
1925
+ !a.ignoreEmulatedMouseEvents && !gn && s(p, "mouse"), a.ignoreEmulatedMouseEvents = !1;
1926
1926
  }, f.onMouseLeave = (p) => {
1927
1927
  !l && p.currentTarget.contains(p.target) && d(p, "mouse");
1928
1928
  }), {
@@ -1952,7 +1952,7 @@ function zi(t) {
1952
1952
  isPointerDown: !1,
1953
1953
  ignoreEmulatedMouseEvents: !1
1954
1954
  }), o = oe((u) => {
1955
- n && un(u, e) && (l && l(u), i.current.isPointerDown = !0);
1955
+ n && sn(u, e) && (l && l(u), i.current.isPointerDown = !0);
1956
1956
  }), a = oe((u) => {
1957
1957
  n && n(u);
1958
1958
  });
@@ -1962,16 +1962,16 @@ function zi(t) {
1962
1962
  const c = e.current, s = ne(c);
1963
1963
  if (typeof PointerEvent < "u") {
1964
1964
  let d = (f) => {
1965
- u.isPointerDown && un(f, e) && a(f), u.isPointerDown = !1;
1965
+ u.isPointerDown && sn(f, e) && a(f), u.isPointerDown = !1;
1966
1966
  };
1967
1967
  return s.addEventListener("pointerdown", o, !0), s.addEventListener("pointerup", d, !0), () => {
1968
1968
  s.removeEventListener("pointerdown", o, !0), s.removeEventListener("pointerup", d, !0);
1969
1969
  };
1970
1970
  } else {
1971
1971
  let d = (p) => {
1972
- u.ignoreEmulatedMouseEvents ? u.ignoreEmulatedMouseEvents = !1 : u.isPointerDown && un(p, e) && a(p), u.isPointerDown = !1;
1972
+ u.ignoreEmulatedMouseEvents ? u.ignoreEmulatedMouseEvents = !1 : u.isPointerDown && sn(p, e) && a(p), u.isPointerDown = !1;
1973
1973
  }, f = (p) => {
1974
- u.ignoreEmulatedMouseEvents = !0, u.isPointerDown && un(p, e) && a(p), u.isPointerDown = !1;
1974
+ u.ignoreEmulatedMouseEvents = !0, u.isPointerDown && sn(p, e) && a(p), u.isPointerDown = !1;
1975
1975
  };
1976
1976
  return s.addEventListener("mousedown", o, !0), s.addEventListener("mouseup", d, !0), s.addEventListener("touchstart", o, !0), s.addEventListener("touchend", f, !0), () => {
1977
1977
  s.removeEventListener("mousedown", o, !0), s.removeEventListener("mouseup", d, !0), s.removeEventListener("touchstart", o, !0), s.removeEventListener("touchend", f, !0);
@@ -1984,7 +1984,7 @@ function zi(t) {
1984
1984
  a
1985
1985
  ]);
1986
1986
  }
1987
- function un(t, e) {
1987
+ function sn(t, e) {
1988
1988
  if (t.button > 0) return !1;
1989
1989
  if (t.target) {
1990
1990
  const n = t.target.ownerDocument;
@@ -2060,14 +2060,14 @@ function Vi(t) {
2060
2060
  type: "longpressend"
2061
2061
  });
2062
2062
  }
2063
- }), d = Dn(l && !e ? o : void 0);
2063
+ }), d = kn(l && !e ? o : void 0);
2064
2064
  return {
2065
2065
  longPressProps: H(s, d)
2066
2066
  };
2067
2067
  }
2068
2068
  function ve(t) {
2069
2069
  const e = ne(t);
2070
- if (mn() === "virtual") {
2070
+ if (bn() === "virtual") {
2071
2071
  let n = e.activeElement;
2072
2072
  Pi(() => {
2073
2073
  e.activeElement === n && t.isConnected && Le(t);
@@ -2094,7 +2094,7 @@ function Hi(t, e) {
2094
2094
  }
2095
2095
  const _l = /* @__PURE__ */ A.createContext(null), yr = "react-aria-focus-scope-restore";
2096
2096
  let te = null;
2097
- function Bn(t) {
2097
+ function Xt(t) {
2098
2098
  let { children: e, contain: n, restoreFocus: r, autoFocus: l } = t, i = I(null), o = I(null), a = I([]), { parentNode: u } = Y(_l) || {}, c = V(() => new xr({
2099
2099
  scopeRef: a
2100
2100
  }), [
@@ -2102,7 +2102,7 @@ function Bn(t) {
2102
2102
  ]);
2103
2103
  J(() => {
2104
2104
  let f = u || se.root;
2105
- if (se.getTreeNode(f.scopeRef) && te && !yn(te, f.scopeRef)) {
2105
+ if (se.getTreeNode(f.scopeRef) && te && !$n(te, f.scopeRef)) {
2106
2106
  let p = se.getTreeNode(te);
2107
2107
  p && (f = p);
2108
2108
  }
@@ -2137,7 +2137,7 @@ function Bn(t) {
2137
2137
  ]), J(() => () => {
2138
2138
  var f, p, m;
2139
2139
  let y = (m = (p = se.getTreeNode(a)) === null || p === void 0 || (f = p.parent) === null || f === void 0 ? void 0 : f.scopeRef) !== null && m !== void 0 ? m : null;
2140
- (a === te || yn(a, te)) && (!y || se.getTreeNode(y)) && (te = y), se.removeTreeNode(a);
2140
+ (a === te || $n(a, te)) && (!y || se.getTreeNode(y)) && (te = y), se.removeTreeNode(a);
2141
2141
  }, [
2142
2142
  a
2143
2143
  ]);
@@ -2249,10 +2249,10 @@ function Ud(t, e) {
2249
2249
  let m = c.shiftKey ? p.previousNode() : p.nextNode();
2250
2250
  m || (p.currentNode = c.shiftKey ? d[d.length - 1].nextElementSibling : d[0].previousElementSibling, m = c.shiftKey ? p.previousNode() : p.nextNode()), c.preventDefault(), m && Oe(m, !0);
2251
2251
  }, a = (c) => {
2252
- (!te || yn(te, t)) && de(c.target, t.current) ? (te = t, n.current = c.target) : Lt(t) && !gn(c.target, t) ? n.current ? n.current.focus() : te && te.current && $r(te.current) : Lt(t) && (n.current = c.target);
2252
+ (!te || $n(te, t)) && de(c.target, t.current) ? (te = t, n.current = c.target) : Lt(t) && !yn(c.target, t) ? n.current ? n.current.focus() : te && te.current && $r(te.current) : Lt(t) && (n.current = c.target);
2253
2253
  }, u = (c) => {
2254
2254
  r.current && cancelAnimationFrame(r.current), r.current = requestAnimationFrame(() => {
2255
- if (i.activeElement && Lt(t) && !gn(i.activeElement, t))
2255
+ if (i.activeElement && Lt(t) && !yn(i.activeElement, t))
2256
2256
  if (te = t, i.body.contains(c.target)) {
2257
2257
  var s;
2258
2258
  n.current = c.target, (s = n.current) === null || s === void 0 || s.focus();
@@ -2272,21 +2272,21 @@ function Ud(t, e) {
2272
2272
  ]);
2273
2273
  }
2274
2274
  function Wi(t) {
2275
- return gn(t);
2275
+ return yn(t);
2276
2276
  }
2277
2277
  function de(t, e) {
2278
2278
  return !t || !e ? !1 : e.some((n) => n.contains(t));
2279
2279
  }
2280
- function gn(t, e = null) {
2280
+ function yn(t, e = null) {
2281
2281
  if (t instanceof Element && t.closest("[data-react-aria-top-layer]")) return !0;
2282
2282
  for (let { scopeRef: n } of se.traverse(se.getTreeNode(e)))
2283
2283
  if (n && de(t, n.current)) return !0;
2284
2284
  return !1;
2285
2285
  }
2286
2286
  function Gd(t) {
2287
- return gn(t, te);
2287
+ return yn(t, te);
2288
2288
  }
2289
- function yn(t, e) {
2289
+ function $n(t, e) {
2290
2290
  var n;
2291
2291
  let r = (n = se.getTreeNode(e)) === null || n === void 0 ? void 0 : n.parent;
2292
2292
  for (; r; ) {
@@ -2364,7 +2364,7 @@ function Zd(t, e, n) {
2364
2364
  const i = ne(l ? l[0] : void 0);
2365
2365
  if (!e || n) return;
2366
2366
  let o = () => {
2367
- (!te || yn(te, t)) && de(i.activeElement, t.current) && (te = t);
2367
+ (!te || $n(te, t)) && de(i.activeElement, t.current) && (te = t);
2368
2368
  };
2369
2369
  return i.addEventListener("focusin", o, !1), l == null || l.forEach((a) => a.addEventListener("focusin", o, !1)), () => {
2370
2370
  i.removeEventListener("focusin", o, !1), l == null || l.forEach((a) => a.removeEventListener("focusin", o, !1));
@@ -2513,7 +2513,7 @@ class xr {
2513
2513
  }
2514
2514
  }
2515
2515
  let se = new Wr();
2516
- function Xt(t = {}) {
2516
+ function Zt(t = {}) {
2517
2517
  let { autoFocus: e = !1, isTextInput: n, within: r } = t, l = I({
2518
2518
  isFocused: !1,
2519
2519
  isFocusVisible: e || ct()
@@ -2527,7 +2527,7 @@ function Xt(t = {}) {
2527
2527
  }, [], {
2528
2528
  isTextInput: n
2529
2529
  });
2530
- let { focusProps: d } = Tn({
2530
+ let { focusProps: d } = An({
2531
2531
  isDisabled: r,
2532
2532
  onFocusChange: s
2533
2533
  }), { focusWithinProps: f } = qt({
@@ -2548,7 +2548,7 @@ function Jd(t) {
2548
2548
  return r;
2549
2549
  }
2550
2550
  function Qd(t, e) {
2551
- let { children: n, ...r } = t, l = Pn(e), i = {
2551
+ let { children: n, ...r } = t, l = Dn(e), i = {
2552
2552
  ...r,
2553
2553
  ref: l
2554
2554
  };
@@ -2558,7 +2558,7 @@ function Qd(t, e) {
2558
2558
  }
2559
2559
  let ef = /* @__PURE__ */ A.forwardRef(Qd);
2560
2560
  function Tt(t, e) {
2561
- let { focusProps: n } = Tn(t), { keyboardProps: r } = ji(t), l = H(n, r), i = Jd(e), o = t.isDisabled ? {} : i, a = I(t.autoFocus);
2561
+ let { focusProps: n } = An(t), { keyboardProps: r } = ji(t), l = H(n, r), i = Jd(e), o = t.isDisabled ? {} : i, a = I(t.autoFocus);
2562
2562
  return L(() => {
2563
2563
  a.current && e.current && ve(e.current), a.current = !1;
2564
2564
  }, [
@@ -2828,7 +2828,7 @@ function In(t, e) {
2828
2828
  }
2829
2829
  const qi = 7e3;
2830
2830
  let Be = null;
2831
- function $n(t, e = "assertive", n = qi) {
2831
+ function xn(t, e = "assertive", n = qi) {
2832
2832
  Be ? Be.announce(t, e, n) : (Be = new mf(), (typeof IS_REACT_ACT_ENVIRONMENT == "boolean" ? IS_REACT_ACT_ENVIRONMENT : typeof jest < "u") ? Be.announce(t, e, n) : setTimeout(() => {
2833
2833
  Be != null && Be.isAttached() && (Be == null || Be.announce(t, e, n));
2834
2834
  }, 100));
@@ -3052,7 +3052,7 @@ function Sf(t, e, n) {
3052
3052
  }), { focusableProps: x } = Tt(t, n), k = H(y, x), C = fe(t, {
3053
3053
  labelable: !0
3054
3054
  });
3055
- return kn(n, e.isSelected, e.setSelected), {
3055
+ return Tn(n, e.isSelected, e.setSelected), {
3056
3056
  labelProps: H(E, {
3057
3057
  onClick: (D) => D.preventDefault()
3058
3058
  }),
@@ -3187,7 +3187,7 @@ function eo(t, e) {
3187
3187
  type: o,
3188
3188
  pattern: t.pattern
3189
3189
  };
3190
- return kn(e, u, c), Ur(t, d, e), L(() => {
3190
+ return Tn(e, u, c), Ur(t, d, e), L(() => {
3191
3191
  if (e.current instanceof Pe(e.current).HTMLTextAreaElement) {
3192
3192
  let C = e.current;
3193
3193
  Object.defineProperty(C, "defaultValue", {
@@ -3248,7 +3248,7 @@ const Ke = {
3248
3248
  bottom: "top",
3249
3249
  left: "left",
3250
3250
  right: "left"
3251
- }, xn = {
3251
+ }, En = {
3252
3252
  top: "bottom",
3253
3253
  bottom: "top",
3254
3254
  left: "right",
@@ -3262,7 +3262,7 @@ const Ke = {
3262
3262
  }, to = {
3263
3263
  width: "totalWidth",
3264
3264
  height: "totalHeight"
3265
- }, sn = {};
3265
+ }, cn = {};
3266
3266
  let be = typeof document < "u" && window.visualViewport;
3267
3267
  function Wl(t) {
3268
3268
  let e = 0, n = 0, r = 0, l = 0, i = 0, o = 0, a = {}, u = (be == null ? void 0 : be.scale) > 1;
@@ -3307,18 +3307,18 @@ function Df(t) {
3307
3307
  };
3308
3308
  }
3309
3309
  function Gl(t) {
3310
- if (sn[t]) return sn[t];
3310
+ if (cn[t]) return cn[t];
3311
3311
  let [e, n] = t.split(" "), r = Ke[e] || "right", l = wf[r];
3312
3312
  Ke[n] || (n = "center");
3313
3313
  let i = Cr[r], o = Cr[l];
3314
- return sn[t] = {
3314
+ return cn[t] = {
3315
3315
  placement: e,
3316
3316
  crossPlacement: n,
3317
3317
  axis: r,
3318
3318
  crossAxis: l,
3319
3319
  size: i,
3320
3320
  crossSize: o
3321
- }, sn[t];
3321
+ }, cn[t];
3322
3322
  }
3323
3323
  function tr(t, e, n, r, l, i, o, a, u, c) {
3324
3324
  let { placement: s, crossPlacement: d, axis: f, crossAxis: p, size: m, crossSize: y } = r, g = {};
@@ -3326,7 +3326,7 @@ function tr(t, e, n, r, l, i, o, a, u, c) {
3326
3326
  const E = t[p] - n[y] + u + c, S = t[p] + t[y] - u - c;
3327
3327
  if (g[p] = hr(g[p], E, S), s === f) {
3328
3328
  const x = a ? o[m] : e[to[m]];
3329
- g[xn[f]] = Math.floor(x - t[f] + l);
3329
+ g[En[f]] = Math.floor(x - t[f] + l);
3330
3330
  } else g[f] = Math.floor(t[f] + t[m] + l);
3331
3331
  return g;
3332
3332
  }
@@ -3340,12 +3340,12 @@ function kf(t, e, n, r, l, i, o, a) {
3340
3340
  }
3341
3341
  function Yl(t, e, n, r, l, i) {
3342
3342
  let { placement: o, axis: a, size: u } = i;
3343
- return o === a ? Math.max(0, n[a] - t[a] - t.scroll[a] + e[a] - r[a] - r[xn[a]] - l) : Math.max(0, t[u] + t[a] + t.scroll[a] - e[a] - n[a] - n[u] - r[a] - r[xn[a]] - l);
3343
+ return o === a ? Math.max(0, n[a] - t[a] - t.scroll[a] + e[a] - r[a] - r[En[a]] - l) : Math.max(0, t[u] + t[a] + t.scroll[a] - e[a] - n[a] - n[u] - r[a] - r[En[a]] - l);
3344
3344
  }
3345
3345
  function Tf(t, e, n, r, l, i, o, a, u, c, s, d, f, p, m, y) {
3346
3346
  let g = Gl(t), { size: E, crossAxis: S, crossSize: x, placement: k, crossPlacement: C } = g, D = tr(e, a, n, g, s, d, c, f, m, y), _ = s, v = Yl(a, c, e, l, i + s, g);
3347
3347
  if (o && r[E] > v) {
3348
- let $e = Gl(`${xn[k]} ${C}`), Ae = tr(e, a, n, $e, s, d, c, f, m, y);
3348
+ let $e = Gl(`${En[k]} ${C}`), Ae = tr(e, a, n, $e, s, d, c, f, m, y);
3349
3349
  Yl(a, c, e, l, i + s, $e) > v && (g = $e, D = Ae, _ = s);
3350
3350
  }
3351
3351
  let B = "bottom";
@@ -3640,13 +3640,13 @@ const nr = typeof document < "u" && window.visualViewport, Ff = /* @__PURE__ */
3640
3640
  "submit",
3641
3641
  "reset"
3642
3642
  ]);
3643
- let cn = 0, rr;
3643
+ let dn = 0, rr;
3644
3644
  function _f(t = {}) {
3645
3645
  let { isDisabled: e } = t;
3646
3646
  J(() => {
3647
3647
  if (!e)
3648
- return cn++, cn === 1 && (wn() ? rr = Nf() : rr = Rf()), () => {
3649
- cn--, cn === 0 && rr();
3648
+ return dn++, dn === 1 && (Pn() ? rr = Nf() : rr = Rf()), () => {
3649
+ dn--, dn === 0 && rr();
3650
3650
  };
3651
3651
  }, [
3652
3652
  e
@@ -3771,7 +3771,7 @@ function Vf(t) {
3771
3771
  n
3772
3772
  ]), !n) return null;
3773
3773
  let l = /* @__PURE__ */ A.createElement(jf, r);
3774
- return /* @__PURE__ */ Sn.createPortal(l, n);
3774
+ return /* @__PURE__ */ Cn.createPortal(l, n);
3775
3775
  }
3776
3776
  var io = {};
3777
3777
  io = {
@@ -4069,12 +4069,12 @@ function Xf(t) {
4069
4069
  ]), { getContainer: a } = qf();
4070
4070
  if (!t.portalContainer && a && (n = a()), !n) return null;
4071
4071
  let u = t.children;
4072
- return t.disableFocusManagement || (u = /* @__PURE__ */ A.createElement(Bn, {
4072
+ return t.disableFocusManagement || (u = /* @__PURE__ */ A.createElement(Xt, {
4073
4073
  restoreFocus: !0,
4074
4074
  contain: l && !r
4075
4075
  }, u)), u = /* @__PURE__ */ A.createElement(zo.Provider, {
4076
4076
  value: o
4077
- }, /* @__PURE__ */ A.createElement(Bd, null, u)), /* @__PURE__ */ Sn.createPortal(u, n);
4077
+ }, /* @__PURE__ */ A.createElement(Bd, null, u)), /* @__PURE__ */ Cn.createPortal(u, n);
4078
4078
  }
4079
4079
  function Zf() {
4080
4080
  let t = Y(zo), e = t == null ? void 0 : t.setContain;
@@ -4242,7 +4242,7 @@ function Vo(t) {
4242
4242
  } else f || (p.current.scrollTop = S.current.top, p.current.scrollLeft = S.current.left);
4243
4243
  if (e.focusedKey != null) {
4244
4244
  let $ = p.current.querySelector(`[data-key="${CSS.escape(e.focusedKey.toString())}"]`);
4245
- $ && ($.contains(document.activeElement) || Le($), mn() === "keyboard" && Ze($, {
4245
+ $ && ($.contains(document.activeElement) || Le($), bn() === "keyboard" && Ze($, {
4246
4246
  containingElement: r.current
4247
4247
  }));
4248
4248
  }
@@ -4268,7 +4268,7 @@ function Vo(t) {
4268
4268
  let D = I(e.focusedKey);
4269
4269
  L(() => {
4270
4270
  if (e.isFocused && e.focusedKey != null && (e.focusedKey !== D.current || C.current) && (p != null && p.current)) {
4271
- let P = mn(), w = r.current.querySelector(`[data-key="${CSS.escape(e.focusedKey.toString())}"]`);
4271
+ let P = bn(), w = r.current.querySelector(`[data-key="${CSS.escape(e.focusedKey.toString())}"]`);
4272
4272
  if (!w)
4273
4273
  return;
4274
4274
  (P === "keyboard" || C.current) && (Ai(p.current, w), P !== "virtual" && Ze(w, {
@@ -5283,7 +5283,7 @@ function Ma(t, e, n) {
5283
5283
  }
5284
5284
  },
5285
5285
  onKeyUp: E
5286
- }), { focusProps: pt } = Tn({
5286
+ }), { focusProps: pt } = An({
5287
5287
  onBlur: k,
5288
5288
  onFocus: S,
5289
5289
  onFocusChange: x
@@ -5516,7 +5516,7 @@ function xt(t, e) {
5516
5516
  };
5517
5517
  }
5518
5518
  function gp(t) {
5519
- let { isDisabled: e } = t, n = I(!1), { focusProps: r } = Tn({
5519
+ let { isDisabled: e } = t, n = I(!1), { focusProps: r } = An({
5520
5520
  onFocusChange: (s) => {
5521
5521
  n.current = s;
5522
5522
  }
@@ -6224,7 +6224,7 @@ function xp(t, e) {
6224
6224
  }
6225
6225
  e.selectionManager.selectionMode === "multiple" && (s.length === 0 || l === "all" || l.size > 1 || i.current === "all" || ((o = i.current) === null || o === void 0 ? void 0 : o.size) > 1) && s.push(l === "all" ? r.format("selectedAll") : r.format("selectedCount", {
6226
6226
  count: l.size
6227
- })), s.length > 0 && $n(s.join(" ")), i.current = l;
6227
+ })), s.length > 0 && xn(s.join(" ")), i.current = l;
6228
6228
  }, [
6229
6229
  l
6230
6230
  ]);
@@ -6249,7 +6249,7 @@ function Sp(t) {
6249
6249
  e,
6250
6250
  r
6251
6251
  ]);
6252
- return Dn(l);
6252
+ return kn(l);
6253
6253
  }
6254
6254
  function Cp(t, e, n) {
6255
6255
  let { isVirtualized: r, keyboardDelegate: l, focusMode: i, scrollRef: o, getRowText: a, onRowAction: u, onCellAction: c } = t, { selectionManager: s } = e;
@@ -6478,7 +6478,7 @@ function Dp(t, e, n) {
6478
6478
  }), x = -1;
6479
6479
  e.selectedValue != null ? e.selectedValue === r && (x = 0) : (e.lastFocusedValue === r || e.lastFocusedValue == null) && (x = 0), a && (x = void 0);
6480
6480
  let { name: k, descriptionId: C, errorMessageId: D, validationBehavior: _ } = gu.get(e);
6481
- return kn(n, e.selectedValue, e.setSelectedValue), Ur({
6481
+ return Tn(n, e.selectedValue, e.setSelectedValue), Ur({
6482
6482
  validationBehavior: _
6483
6483
  }, e, n), {
6484
6484
  labelProps: H(m, {
@@ -6885,7 +6885,7 @@ function ts(t, e, n) {
6885
6885
  }
6886
6886
  function Bp(t, e, n) {
6887
6887
  let r = es.get(e) || {}, { autoComplete: l, name: i = r.name, isDisabled: o = r.isDisabled } = t, { validationBehavior: a, isRequired: u } = r, c = Oi(), { visuallyHiddenProps: s } = Qi();
6888
- kn(t.selectRef, e.selectedKey, e.setSelectedKey), Ur({
6888
+ Tn(t.selectRef, e.selectedKey, e.setSelectedKey), Ur({
6889
6889
  validationBehavior: a,
6890
6890
  focus: () => n.current.focus()
6891
6891
  }, e, t.selectRef);
@@ -7505,7 +7505,7 @@ class Fp extends _a {
7505
7505
  }
7506
7506
  }
7507
7507
  let _p = !1;
7508
- function En() {
7508
+ function Sn() {
7509
7509
  return _p;
7510
7510
  }
7511
7511
  function Rp(t) {
@@ -7541,7 +7541,7 @@ function Np(t, e, n) {
7541
7541
  id: d,
7542
7542
  keyboardDelegate: s
7543
7543
  }, e, n);
7544
- l && (f["aria-rowcount"] = e.collection.size + e.collection.headerRows.length), En() && "expandedKeys" in e && (f.role = "treegrid");
7544
+ l && (f["aria-rowcount"] = e.collection.size + e.collection.headerRows.length), Sn() && "expandedKeys" in e && (f.role = "treegrid");
7545
7545
  let { column: p, direction: m } = e.sortDescriptor || {}, y = ft(Rp(ll), "@react-aria/table"), g = V(() => {
7546
7546
  var S;
7547
7547
  let x = (S = e.collection.columns.find((k) => k.key === p)) === null || S === void 0 ? void 0 : S.textValue;
@@ -7552,9 +7552,9 @@ function Np(t, e, n) {
7552
7552
  m,
7553
7553
  p,
7554
7554
  e.collection.columns
7555
- ]), E = Dn(g);
7555
+ ]), E = kn(g);
7556
7556
  return Ti(() => {
7557
- $n(g, "assertive", 500);
7557
+ xn(g, "assertive", 500);
7558
7558
  }, [
7559
7559
  g
7560
7560
  ]), {
@@ -7582,10 +7582,10 @@ function Op(t, e, n) {
7582
7582
  },
7583
7583
  ref: n
7584
7584
  }), { focusableProps: s } = Tt({}, n), d = null, f = ((r = e.sortDescriptor) === null || r === void 0 ? void 0 : r.column) === i.key, p = (l = e.sortDescriptor) === null || l === void 0 ? void 0 : l.direction;
7585
- i.props.allowsSorting && !pn() && (d = f ? p : "none");
7585
+ i.props.allowsSorting && !vn() && (d = f ? p : "none");
7586
7586
  let m = ft(Lp(ll), "@react-aria/table"), y;
7587
- o && (y = `${m.format("sortable")}`, f && p && pn() && (y = `${y}, ${m.format(p)}`));
7588
- let g = Dn(y), E = e.collection.size === 0;
7587
+ o && (y = `${m.format("sortable")}`, f && p && vn() && (y = `${y}, ${m.format(p)}`));
7588
+ let g = kn(y), E = e.collection.size === 0;
7589
7589
  return L(() => {
7590
7590
  E && e.selectionManager.focusedKey === i.key && e.selectionManager.setFocusedKey(null);
7591
7591
  }, [
@@ -7623,9 +7623,9 @@ const oi = {
7623
7623
  };
7624
7624
  function zp(t, e, n) {
7625
7625
  let { node: r, isVirtualized: l } = t, { rowProps: i, ...o } = Pp(t, e, n), { direction: a } = He();
7626
- l && !(En() && "expandedKeys" in e) ? i["aria-rowindex"] = r.index + 1 + e.collection.headerRows.length : delete i["aria-rowindex"];
7626
+ l && !(Sn() && "expandedKeys" in e) ? i["aria-rowindex"] = r.index + 1 + e.collection.headerRows.length : delete i["aria-rowindex"];
7627
7627
  let u = {};
7628
- if (En() && "expandedKeys" in e) {
7628
+ if (Sn() && "expandedKeys" in e) {
7629
7629
  let m = e.keyMap.get(r.key);
7630
7630
  if (m != null) {
7631
7631
  var c, s, d;
@@ -7654,7 +7654,7 @@ function jp(t, e, n) {
7654
7654
  let { node: r, isVirtualized: l } = t, i = {
7655
7655
  role: "row"
7656
7656
  };
7657
- return l && !(En() && "expandedKeys" in e) && (i["aria-rowindex"] = r.index + 1), {
7657
+ return l && !(Sn() && "expandedKeys" in e) && (i["aria-rowindex"] = r.index + 1), {
7658
7658
  rowProps: i
7659
7659
  };
7660
7660
  }
@@ -7700,7 +7700,7 @@ function Up(t, e, n) {
7700
7700
  e
7701
7701
  ]);
7702
7702
  let s = () => {
7703
- l !== "focus" && (mn() === "pointer" ? o.current = !0 : o.current = !1, u());
7703
+ l !== "focus" && (bn() === "pointer" ? o.current = !0 : o.current = !1, u());
7704
7704
  }, d = () => {
7705
7705
  l !== "focus" && (a.current = !1, o.current = !1, c());
7706
7706
  }, f = () => {
@@ -8964,7 +8964,7 @@ const vv = ({ children: t }) => {
8964
8964
  l.style.setProperty(i, o);
8965
8965
  }), l;
8966
8966
  })();
8967
- return Sn.createPortal(t, r);
8967
+ return Cn.createPortal(t, r);
8968
8968
  }, Us = ({
8969
8969
  id: t,
8970
8970
  isOpen: e,
@@ -9062,7 +9062,7 @@ const vv = ({ children: t }) => {
9062
9062
  className: W("proton-ActionMenu__card", f),
9063
9063
  "data-testid": "ActionMenu-content",
9064
9064
  style: { height: `${g}px` },
9065
- children: /* @__PURE__ */ b.jsx("div", { ref: x, children: /* @__PURE__ */ b.jsx("div", { ...v, ref: S, children: w ? /* @__PURE__ */ b.jsxs(Bn, { autoFocus: !0, contain: !0, children: [
9065
+ children: /* @__PURE__ */ b.jsx("div", { ref: x, children: /* @__PURE__ */ b.jsx("div", { ...v, ref: S, children: w ? /* @__PURE__ */ b.jsxs(Xt, { autoFocus: !0, contain: !0, children: [
9066
9066
  i && /* @__PURE__ */ b.jsx("div", { className: "proton-ActionMenu__content", children: typeof i == "function" ? i({ close: D }) : i }),
9067
9067
  C && /* @__PURE__ */ b.jsx(
9068
9068
  "div",
@@ -9308,22 +9308,22 @@ const qs = {
9308
9308
  icon: ke.GRAY_MEDIUM_LIGHT
9309
9309
  },
9310
9310
  success: {
9311
- background: en.SUPER_LIGHT,
9312
- title: en.DARK,
9313
- content: en.MEDIUM,
9314
- icon: en.LIGHT
9315
- },
9316
- warning: {
9317
9311
  background: tn.SUPER_LIGHT,
9318
9312
  title: tn.DARK,
9319
9313
  content: tn.MEDIUM,
9320
9314
  icon: tn.LIGHT
9321
9315
  },
9322
- danger: {
9316
+ warning: {
9323
9317
  background: nn.SUPER_LIGHT,
9324
9318
  title: nn.DARK,
9325
9319
  content: nn.MEDIUM,
9326
9320
  icon: nn.LIGHT
9321
+ },
9322
+ danger: {
9323
+ background: rn.SUPER_LIGHT,
9324
+ title: rn.DARK,
9325
+ content: rn.MEDIUM,
9326
+ icon: rn.LIGHT
9327
9327
  }
9328
9328
  }, yv = {
9329
9329
  default: "default",
@@ -10422,8 +10422,8 @@ function tc(t, e) {
10422
10422
  }
10423
10423
  return n;
10424
10424
  }
10425
- function Zt(t, e, n) {
10426
- let r = tc(n, t.slot) || {}, { ref: l, ...i } = r, o = Pn(V(() => ed(e, l), [
10425
+ function Jt(t, e, n) {
10426
+ let r = tc(n, t.slot) || {}, { ref: l, ...i } = r, o = Dn(V(() => ed(e, l), [
10427
10427
  e,
10428
10428
  l
10429
10429
  ])), a = H(i, t);
@@ -10475,7 +10475,7 @@ function nc(t, e, n) {
10475
10475
  let l = window.getComputedStyle(t.current);
10476
10476
  if (l.animationName && l.animationName !== "none" && l.animation !== r.current) {
10477
10477
  let i = (a) => {
10478
- a.target === t.current && (o.removeEventListener("animationend", i), Sn.flushSync(() => {
10478
+ a.target === t.current && (o.removeEventListener("animationend", i), Cn.flushSync(() => {
10479
10479
  n();
10480
10480
  }));
10481
10481
  }, o = t.current;
@@ -10501,8 +10501,8 @@ const Qv = /* @__PURE__ */ Q(null), eh = /* @__PURE__ */ new Set([
10501
10501
  "value"
10502
10502
  ]), th = /* @__PURE__ */ Q({});
10503
10503
  function nh(t, e) {
10504
- [t, e] = Zt(t, e, th), t = rh(t);
10505
- let n = t, { isPending: r } = n, { buttonProps: l, isPressed: i } = In(t, e), { focusProps: o, isFocused: a, isFocusVisible: u } = Xt(t), { hoverProps: c, isHovered: s } = kt({
10504
+ [t, e] = Jt(t, e, th), t = rh(t);
10505
+ let n = t, { isPending: r } = n, { buttonProps: l, isPressed: i } = In(t, e), { focusProps: o, isFocused: a, isFocusVisible: u } = Zt(t), { hoverProps: c, isHovered: s } = kt({
10506
10506
  ...t,
10507
10507
  isDisabled: t.isDisabled || r
10508
10508
  }), d = {
@@ -10523,7 +10523,7 @@ function nh(t, e) {
10523
10523
  let E = {
10524
10524
  "aria-labelledby": y || p
10525
10525
  };
10526
- (!g.current && a && r || g.current && a && !r) && $n(E, "assertive"), g.current = r;
10526
+ (!g.current && a && r || g.current && a && !r) && xn(E, "assertive"), g.current = r;
10527
10527
  }, [
10528
10528
  r,
10529
10529
  a,
@@ -10559,7 +10559,7 @@ const rc = /* @__PURE__ */ Mv(nh), lh = /* @__PURE__ */ Q({}), ih = /* @__PURE__
10559
10559
  placement: "bottom"
10560
10560
  });
10561
10561
  function ah(t, e) {
10562
- [t, e] = Zt(t, e, lc);
10562
+ [t, e] = Jt(t, e, lc);
10563
10563
  let n = t.placement, r = {
10564
10564
  position: "absolute",
10565
10565
  [n]: "100%",
@@ -10635,7 +10635,7 @@ function dh(t) {
10635
10635
  }
10636
10636
  const fh = /* @__PURE__ */ Q(null);
10637
10637
  function ph(t, e) {
10638
- return [t, e] = Zt(t, e, ic), /* @__PURE__ */ A.createElement(Rv, {
10638
+ return [t, e] = Jt(t, e, ic), /* @__PURE__ */ A.createElement(Rv, {
10639
10639
  content: /* @__PURE__ */ A.createElement(Wv, t)
10640
10640
  }, (n) => n.size > 0 && /* @__PURE__ */ A.createElement(vh, {
10641
10641
  props: t,
@@ -10680,7 +10680,7 @@ function vh({ props: t, collection: e, menuRef: n }) {
10680
10680
  style: t.style,
10681
10681
  values: {}
10682
10682
  });
10683
- return /* @__PURE__ */ A.createElement(Bn, null, /* @__PURE__ */ A.createElement("div", {
10683
+ return /* @__PURE__ */ A.createElement(Xt, null, /* @__PURE__ */ A.createElement("div", {
10684
10684
  ...fe(t),
10685
10685
  ...u,
10686
10686
  ...y,
@@ -10767,12 +10767,12 @@ function mh(t, e, n) {
10767
10767
  }
10768
10768
  const Rr = /* @__PURE__ */ Q(null), bh = /* @__PURE__ */ Vv("item", function(e, n, r) {
10769
10769
  var l;
10770
- [e, n] = Zt(e, n, Rr);
10771
- let i = (l = tc(Rr)) === null || l === void 0 ? void 0 : l.id, o = Y(sl), a = Pn(n), { menuItemProps: u, labelProps: c, descriptionProps: s, keyboardShortcutProps: d, ...f } = Ma({
10770
+ [e, n] = Jt(e, n, Rr);
10771
+ let i = (l = tc(Rr)) === null || l === void 0 ? void 0 : l.id, o = Y(sl), a = Dn(n), { menuItemProps: u, labelProps: c, descriptionProps: s, keyboardShortcutProps: d, ...f } = Ma({
10772
10772
  ...e,
10773
10773
  id: i,
10774
10774
  key: r.key
10775
- }, o, a), { isFocusVisible: p, focusProps: m } = Xt(), { hoverProps: y, isHovered: g } = kt({
10775
+ }, o, a), { isFocusVisible: p, focusProps: m } = Zt(), { hoverProps: y, isHovered: g } = kt({
10776
10776
  isDisabled: f.isDisabled
10777
10777
  }), E = At({
10778
10778
  ...e,
@@ -10842,7 +10842,7 @@ function gh(t) {
10842
10842
  }, t.children));
10843
10843
  }
10844
10844
  function yh({ UNSTABLE_portalContainer: t, ...e }, n) {
10845
- [e, n] = Zt(e, n, ac);
10845
+ [e, n] = Jt(e, n, ac);
10846
10846
  let r = Y(cl), l = Hs(e), i = e.isOpen != null || e.defaultOpen != null || !r ? l : r, o = Jv(n, i.isOpen) || e.isExiting || !1;
10847
10847
  return !i.isOpen && !o ? null : /* @__PURE__ */ A.createElement(Vf, {
10848
10848
  portalContainer: t
@@ -11012,7 +11012,7 @@ function r4({
11012
11012
  }
11013
11013
  const Nr = (t) => {
11014
11014
  let e = I(null), { state: n } = t, { listBoxProps: r } = np(t, n, e);
11015
- return /* @__PURE__ */ b.jsx(Bn, { contain: !0, restoreFocus: !0, autoFocus: !0, children: /* @__PURE__ */ b.jsx(
11015
+ return /* @__PURE__ */ b.jsx(Xt, { contain: !0, restoreFocus: !0, autoFocus: !0, children: /* @__PURE__ */ b.jsx(
11016
11016
  "ul",
11017
11017
  {
11018
11018
  ...r,
@@ -11340,7 +11340,7 @@ function Dh({ column: t, state: e }) {
11340
11340
  n
11341
11341
  );
11342
11342
  const { align: l = "left" } = t.props;
11343
- let { isFocusVisible: i, focusProps: o } = Xt(), a = ((u = e.sortDescriptor) == null ? void 0 : u.direction) === "ascending" ? "▲" : "▼";
11343
+ let { isFocusVisible: i, focusProps: o } = Zt(), a = ((u = e.sortDescriptor) == null ? void 0 : u.direction) === "ascending" ? "▲" : "▼";
11344
11344
  return /* @__PURE__ */ b.jsxs(
11345
11345
  "th",
11346
11346
  {
@@ -11390,7 +11390,7 @@ function kh({ item: t, children: e, state: n }) {
11390
11390
  },
11391
11391
  n,
11392
11392
  r
11393
- ), { isFocusVisible: a, focusProps: u } = Xt();
11393
+ ), { isFocusVisible: a, focusProps: u } = Zt();
11394
11394
  return /* @__PURE__ */ b.jsx(
11395
11395
  "tr",
11396
11396
  {
@@ -11407,7 +11407,7 @@ function kh({ item: t, children: e, state: n }) {
11407
11407
  );
11408
11408
  }
11409
11409
  function Th({ cell: t, state: e, ...n }) {
11410
- let r = I(), { gridCellProps: l } = Vp({ node: t }, e, r), { isFocusVisible: i, focusProps: o } = Xt();
11410
+ let r = I(), { gridCellProps: l } = Vp({ node: t }, e, r), { isFocusVisible: i, focusProps: o } = Zt();
11411
11411
  const { align: a } = t.props;
11412
11412
  return /* @__PURE__ */ b.jsx(
11413
11413
  "td",
@@ -11783,7 +11783,7 @@ function Nh({
11783
11783
  return document.addEventListener("keydown", i), () => {
11784
11784
  document.removeEventListener("keydown", i);
11785
11785
  };
11786
- }, [e]), /* @__PURE__ */ b.jsxs(
11786
+ }, [e]), /* @__PURE__ */ b.jsx(
11787
11787
  "div",
11788
11788
  {
11789
11789
  ...l,
@@ -11797,10 +11797,10 @@ function Nh({
11797
11797
  t ? "proton-Backdrop__fade-in" : "proton-Backdrop__overlay"
11798
11798
  ),
11799
11799
  onClick: () => e == null ? void 0 : e(),
11800
- children: [
11801
- e && /* @__PURE__ */ b.jsx("div", { className: "proton-Backdrop__close-button", "aria-hidden": "true", children: "ESC" }),
11802
- n
11803
- ]
11800
+ children: /* @__PURE__ */ b.jsxs(Xt, { contain: !0, autoFocus: !0, children: [
11801
+ n,
11802
+ e && /* @__PURE__ */ b.jsx("div", { className: "proton-Backdrop__close-button", "aria-hidden": "true", children: "ESC" })
11803
+ ] })
11804
11804
  }
11805
11805
  );
11806
11806
  }
@@ -11814,13 +11814,22 @@ const Lh = (t) => {
11814
11814
  };
11815
11815
  function f4({
11816
11816
  image: t,
11817
- onBackgroundEvent: e
11817
+ imageUrl: e = "",
11818
+ onLoad: n,
11819
+ onBackgroundEvent: r
11818
11820
  }) {
11819
- const { palette: n } = Ie();
11820
- console.log(n);
11821
- const r = Nc(n.BASE_COLOR), l = Lh(r);
11822
- return console.log(l), /* @__PURE__ */ b.jsxs(Nh, { fadeIn: !1, onBackgroundEvent: e, children: [
11823
- t && t,
11821
+ const { palette: l } = Ie(), i = Nc(l.BASE_COLOR), o = Lh(i);
11822
+ return /* @__PURE__ */ b.jsxs(Nh, { fadeIn: !1, onBackgroundEvent: r, children: [
11823
+ t ? /* @__PURE__ */ b.jsx("div", { className: "proton-Backdrop__image", "aria-hidden": "true", children: t }) : /* @__PURE__ */ b.jsx(
11824
+ "img",
11825
+ {
11826
+ alt: "",
11827
+ src: e,
11828
+ className: "proton-Backdrop__image",
11829
+ onLoad: (a) => n == null ? void 0 : n(a.currentTarget),
11830
+ "aria-hidden": "true"
11831
+ }
11832
+ ),
11824
11833
  /* @__PURE__ */ b.jsx(
11825
11834
  "div",
11826
11835
  {
@@ -11831,7 +11840,7 @@ function f4({
11831
11840
  WebkitBackdropFilter: "blur(24px) brightness(75%)",
11832
11841
  backdropFilter: "blur(24px) brightness(75%)",
11833
11842
  filter: "brightness(50%)",
11834
- background: l
11843
+ background: o
11835
11844
  }
11836
11845
  }
11837
11846
  )