@sheetxl/studio-vanilla 0.3.18 → 0.3.20

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.
Files changed (94) hide show
  1. package/browser/cjs/{M2DWfdK0ctQctT7T.cjs → B-9AKoIXEd-ulFuY.cjs} +2 -2
  2. package/browser/cjs/{CfnTR1Qy-WVFzRhw.cjs → BPdcMei67VVXsIlT.cjs} +4 -4
  3. package/browser/cjs/{Da9leDv0BrMDcAmM.cjs → BRJqic9ew--MKBtM.cjs} +1 -1
  4. package/browser/cjs/{S1ymoLlv7Uf-qfRz.cjs → BVX0aBbb7I-Kr9jc.cjs} +48 -48
  5. package/browser/cjs/BWmDn9V2sxtBmc6p.cjs +6 -0
  6. package/browser/cjs/{DRPysX3BgTyOtc_X.cjs → BpecyHhrGjCZE4te.cjs} +1 -1
  7. package/browser/cjs/{DvjIxJUC4K8kmZsN.cjs → BwGmOm-0YbK8wfol.cjs} +2 -2
  8. package/browser/cjs/{DAGAHrQyWku5BzOx.cjs → BzXx3M5W6subztPb.cjs} +2 -2
  9. package/browser/cjs/{C7S-2ysc4XzmIGIC.cjs → C0LJ0bF3u-3P9xS-.cjs} +2 -2
  10. package/browser/cjs/{DcKGSA3SMuEvjd87.cjs → C6t8cCjO4T_Spvjd.cjs} +1 -1
  11. package/browser/cjs/{_ziVh-PPWxWmEGfz.cjs → C9RhDco7MuSv11tm.cjs} +3 -3
  12. package/browser/cjs/{D_yi3Bmt7QylbNjX.cjs → CIERBNfPNBXwwSjF.cjs} +2 -2
  13. package/browser/cjs/{DWmar9vh-C0GMWUE.cjs → CLkZVJrhqrGRT7EY.cjs} +1 -1
  14. package/browser/cjs/{DU5bkZX7g1nGYiyr.cjs → CXwshmt0OewyJfbd.cjs} +2 -2
  15. package/browser/cjs/CcLVF4EIHey434Rb.cjs +6 -0
  16. package/browser/cjs/{BYKCnVVe-UC0DLAg.cjs → CgnC4fGFEo3MyV2x.cjs} +1 -1
  17. package/browser/cjs/{BQDBBqqYeHWRLSmz.cjs → Cl0cEDzKsPIVTFUl.cjs} +5 -5
  18. package/browser/cjs/{fkUUKUigUVeizJCn.cjs → DIonFfSsVgz-APZ5.cjs} +6 -6
  19. package/browser/cjs/{Cyis9v9OePqed0Dh.cjs → DV7nfhw95uXOc3j5.cjs} +2 -2
  20. package/browser/cjs/{DWRHniG382TBBpFz.cjs → D_m11V6SqD8ZwpMI.cjs} +3 -3
  21. package/browser/cjs/{DqW0_yEVBgywVFtY.cjs → DrepEMxM-QaJ8YDx.cjs} +1 -1
  22. package/browser/cjs/{DtIlU_avOLio9EiE.cjs → DtOzJ-WMg99faUjm.cjs} +1 -1
  23. package/browser/cjs/DttPtqkuFAJyEAN3.cjs +12 -0
  24. package/browser/cjs/{BqsLsLOIcCoQLkFG.cjs → Ggiiir_7aP_cXY_b.cjs} +2 -2
  25. package/browser/cjs/{asqh4V32TzlgSg5e.cjs → Vz5CvuEA-X08grjB.cjs} +1 -1
  26. package/browser/cjs/index.cjs +2 -2
  27. package/browser/cjs/qZ6Vl_sLywkC5RaU.cjs +6 -0
  28. package/{cdn/assets/B048AhsMgarmATbo.js → browser/esm/2zQv7N1BLM5b5SIm.mjs} +9 -9
  29. package/browser/esm/{CxpsUomBmsPdQKN7.mjs → 3KBcYITgi01N4TNv.mjs} +7 -7
  30. package/{cdn/assets/B8PLUmI-u31BZVd6.js → browser/esm/8_OfjXQ6fzbtH-9u.mjs} +1 -1
  31. package/browser/esm/{Z1hTdWF7Gnd7lwEi.mjs → B6bM984q736FqYsz.mjs} +1 -1
  32. package/browser/esm/B7jQrPqkaYVNv-as.mjs +84 -0
  33. package/{cdn/assets/Dp2nf7t-XHCeT9z1.js → browser/esm/B8-YcyfsXmJeuMiP.mjs} +2 -2
  34. package/browser/esm/{DXfVp9l0_p8tTvaN.mjs → BHNhgRX5eU1xhun6.mjs} +3622 -3530
  35. package/browser/esm/{DyhSx6j-hlOPAYJZ.mjs → BJ7YCFsebpVSTx7u.mjs} +2 -2
  36. package/{cdn/assets/CMIrbndkU0UVjjQ_.js → browser/esm/BJQKOvL-x79vdFAs.mjs} +1 -1
  37. package/{cdn/assets/Dctd5ghWrESGG3Co.js → browser/esm/Bah4Gz0wMfZQ-d68.mjs} +1 -1
  38. package/browser/esm/Bas7osg_0v4Pzo34.mjs +41 -0
  39. package/browser/esm/{Ds9ulL0El--2XZxz.mjs → Bh-yYlNifjJSLSUP.mjs} +47 -47
  40. package/browser/esm/{CEM1UbNtZh6zUcI4.mjs → Bi5JEwcdCUy1Scr4.mjs} +3 -3
  41. package/browser/esm/{B_lXgGve4BaGb9VP.mjs → BoWW29GsMFycnCgj.mjs} +5 -5
  42. package/browser/esm/{vsshjgK_uLUMXLx1.mjs → CABW-eWs3Z1wU1vK.mjs} +90 -90
  43. package/browser/esm/{Dao0wUfvplQebarN.mjs → Cla5lXoGQSxvUMVw.mjs} +4 -4
  44. package/browser/esm/{yBjDi6dOfUg5E0mg.mjs → D0qgtKFnSobrHC2F.mjs} +5 -5
  45. package/browser/esm/{vO-cPppKuuwM-ZbD.mjs → D8bW70p6OB7P1DpI.mjs} +1 -1
  46. package/{cdn/assets/D0Cgu7sUw30-mnqB.js → browser/esm/DB1WsS0LRj2NPsFd.mjs} +7 -7
  47. package/browser/esm/{CCGl8RxWO4yKms9p.mjs → DgDZxwvfJyTly9Uu.mjs} +1 -1
  48. package/{cdn/assets/Cx5_1Ld9VgK4afkO.js → browser/esm/DmE1sCvAX5Z9Ia15.mjs} +1 -1
  49. package/browser/esm/HGUzGKrEwqYcdKbM.mjs +46 -0
  50. package/{cdn/assets/Bwmetegu2MJ05lq3.js → browser/esm/UPoO_Vlq41Hmj-Ku.mjs} +8 -8
  51. package/browser/esm/{Bu74cvcXGNxQ6eQO.mjs → dQ66kiennyNr0dND.mjs} +1 -1
  52. package/browser/esm/index.mjs +2 -2
  53. package/browser/esm/{DscLpbq31HrJWVSt.mjs → pptIDlmrkAbz6i1c.mjs} +17 -17
  54. package/browser/esm/{DmdaLSunj1pIaeEo.mjs → x6PmuzLfP5nqS_eQ.mjs} +4 -4
  55. package/cdn/assets/{b5siqWNPQWp_hlIg.js → 0vZqExkLfT4asC9K.js} +2 -2
  56. package/cdn/assets/{DXZHEN_G41ARU9aP.js → 1ASZw9IfvnArDaCZ.js} +4 -4
  57. package/{browser/esm/B8PLUmI-u31BZVd6.mjs → cdn/assets/8_OfjXQ6fzbtH-9u.js} +1 -1
  58. package/cdn/assets/{IXjjn0b7hP-r-rz5.js → B5zelATPrbDla2Iy.js} +90 -90
  59. package/cdn/assets/{Z1hTdWF7Gnd7lwEi.js → B6bM984q736FqYsz.js} +1 -1
  60. package/cdn/assets/B7jQrPqkaYVNv-as.js +84 -0
  61. package/{browser/esm/CMIrbndkU0UVjjQ_.mjs → cdn/assets/BJQKOvL-x79vdFAs.js} +1 -1
  62. package/cdn/assets/{DpXpV2Nd-U9CeW99.js → BSsHFJzgfxmp5r7_.js} +4 -4
  63. package/{browser/esm/Dctd5ghWrESGG3Co.mjs → cdn/assets/Bah4Gz0wMfZQ-d68.js} +1 -1
  64. package/cdn/assets/{DcwFhmc6DauSay_m.js → BziPRQRGrFtCnyRv.js} +7 -7
  65. package/{browser/esm/xQa55VzyxKLtju1P.mjs → cdn/assets/C6y3ZvDtBqiKjmQR.js} +7 -7
  66. package/cdn/assets/CP2hI6uxS16oQXqQ.js +41 -0
  67. package/{browser/esm/xCvG1lefZTf09iDX.mjs → cdn/assets/CYXS2N-s5O4VNSpQ.js} +2 -2
  68. package/cdn/assets/{BfCDUWippQ188QJ_.js → CbXEnmr2CeR0TImv.js} +5 -5
  69. package/cdn/assets/{CXyKsX-Rk4hkAgns.js → CyUSCTdWkG7ZxVra.js} +3610 -3518
  70. package/cdn/assets/{DXkBcCCoCQhFBFpQ.js → D0NB6zWEw5Rdh0kS.js} +3 -3
  71. package/cdn/assets/{vO-cPppKuuwM-ZbD.js → D8bW70p6OB7P1DpI.js} +1 -1
  72. package/cdn/assets/{JWXHlKikGyP_aFCO.js → DYYGpOI8W9jNCrTX.js} +17 -17
  73. package/cdn/assets/{CCGl8RxWO4yKms9p.js → DgDZxwvfJyTly9Uu.js} +1 -1
  74. package/cdn/assets/{B5Xa0YYj-Y9Ob5he.js → Dj4FGU0a8x6XVJsN.js} +47 -47
  75. package/{browser/esm/Cx5_1Ld9VgK4afkO.mjs → cdn/assets/DmE1sCvAX5Z9Ia15.js} +1 -1
  76. package/cdn/assets/DresaRXt2fvt83HL.js +46 -0
  77. package/{browser/esm/5KE3eJeALYas2fJL.mjs → cdn/assets/TLsARwdDVPeqjguR.js} +9 -9
  78. package/cdn/assets/{Bu74cvcXGNxQ6eQO.js → dQ66kiennyNr0dND.js} +1 -1
  79. package/cdn/assets/{BKj70d8kss8lWQ5j.js → pgLOdNAK0tTv9jW5.js} +5 -5
  80. package/{browser/esm/BElryNS11jWM5tq7.mjs → cdn/assets/zMYtuFnY5e4kuvlC.js} +8 -8
  81. package/cdn/index.js +2 -2
  82. package/cdn/loader.js +1 -1
  83. package/package.json +3 -3
  84. package/types/index.d.ts +1 -1
  85. package/browser/cjs/BYQV2q8HPKlf74j3.cjs +0 -6
  86. package/browser/cjs/ClYi27L-BwfwOane.cjs +0 -6
  87. package/browser/cjs/DvCk-FEyF55Ifc2r.cjs +0 -6
  88. package/browser/cjs/hRorav-Vugk2j14d.cjs +0 -12
  89. package/browser/esm/CATPGvRDTTOuHtl8.mjs +0 -46
  90. package/browser/esm/DT7M18T3_fx1cPVf.mjs +0 -80
  91. package/browser/esm/Dmp9Rj_xUISYWU8A.mjs +0 -41
  92. package/cdn/assets/DBZHYaXm5oENOlcW.js +0 -41
  93. package/cdn/assets/DT7M18T3_fx1cPVf.js +0 -80
  94. package/cdn/assets/c46EuNJ8AHDaEf22.js +0 -46
@@ -1,11 +1,11 @@
1
- import { jsx as g, jsxs as se, Fragment as Gt } from "react/jsx-runtime";
1
+ import { jsx as g, jsxs as se, Fragment as Kt } from "react/jsx-runtime";
2
2
  import * as ve from "react";
3
- import T, { memo as Me, forwardRef as ce, useRef as le, useMemo as te, useState as ae, useEffect as K, useLayoutEffect as dt, useCallback as ne, Component as Kt, createElement as fe, createContext as xn, useContext as yn, isValidElement as wn, cloneElement as vn } from "react";
4
- import { g as xt, f as yt, u as Ye, h as En, i as Cn, j as Sn, k as Ln, l as Mn, m as je, n as wt, o as vt, p as Mt, q as Dn, P as Tn, r as Zt, t as On, v as Wn, w as ie, x as Xt, I as Dt, U as pt, y as Fn, Z as ye, A as Qt, C as Nn, G as Yt, H as An, J as mt, K as Jt, L as Rn, R as In, M as Pn, N as jn, V as Hn, W as zn, $ as _n, B as xe, Y as qn, E as Bn, _ as Vn, a0 as ht, a1 as $n, a2 as Un, a3 as Gn, a4 as Kn, a5 as Zn, a6 as Xn, Q as Qn, a7 as ee, a8 as We, a9 as Tt, aa as Yn, ab as Jn, ac as eo, ad as to, ae as no, af as oo, ag as nt, ah as Fe, ai as ro, aj as ao, ak as io, al as so, am as Ot, an as Wt, ao as lo, ap as co, aq as uo, ar as po, as as _e } from "./CXyKsX-Rk4hkAgns.js";
3
+ import T, { memo as Me, forwardRef as ce, useRef as le, useMemo as te, useState as ae, useEffect as G, useLayoutEffect as dt, useCallback as ne, Component as Gt, createElement as fe, createContext as xn, useContext as yn, isValidElement as wn, cloneElement as vn } from "react";
4
+ import { g as xt, d as yt, u as Qe, e as En, f as Cn, h as Sn, j as Ln, l as Mn, s as je, m as wt, n as vt, o as Mt, p as Dn, q as Tn, r as Zt, t as On, x as Wn, v as ie, U as Xt, D as Dt, W as pt, X as Fn, w as ye, y as Jt, z as Nn, A as Qt, C as An, H as mt, K as Yt, L as Rn, N as In, O as Pn, Q as jn, R as Hn, V as zn, Z as _n, B as xe, _ as qn, E as Bn, $ as Vn, a0 as ht, a1 as $n, a2 as Un, a3 as Kn, a4 as Gn, a5 as Zn, a6 as Xn, J as Jn, a7 as ee, a8 as We, a9 as Tt, aa as Qn, ab as Yn, ac as eo, ad as to, ae as no, af as oo, ag as nt, ah as Fe, ai as ro, aj as ao, ak as io, al as so, am as Ot, an as Wt, ao as lo, ap as co, aq as uo, ar as po, as as _e } from "./CyUSCTdWkG7ZxVra.js";
5
5
  import { createPortal as mo } from "react-dom";
6
6
  import { CommonUtils as ot, UndoManager as ho, Workbook as Ft, PartialError as fo } from "@sheetxl/sdk";
7
7
  /**
8
- * @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.3.18
8
+ * @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.3.20
9
9
  *
10
10
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
11
11
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -18,19 +18,19 @@ const ko = je("div", { name: "MuiCollapse", slot: "Root", overridesResolver: (e,
18
18
  const { ownerState: r } = e;
19
19
  return [o.root, o[r.orientation], r.state === "entered" && o.entered, r.state === "exited" && !r.in && r.collapsedSize === "0px" && o.hidden];
20
20
  } })(Dn(({ theme: e }) => ({ height: 0, overflow: "hidden", transition: e.transitions.create("height"), variants: [{ props: { orientation: "horizontal" }, style: { height: "auto", width: 0, transition: e.transitions.create("width") } }, { props: { state: "entered" }, style: { height: "auto", overflow: "visible" } }, { props: { state: "entered", orientation: "horizontal" }, style: { width: "auto" } }, { props: ({ ownerState: o }) => o.state === "exited" && !o.in && o.collapsedSize === "0px", style: { visibility: "hidden" } }] }))), bo = je("div", { name: "MuiCollapse", slot: "Wrapper", overridesResolver: (e, o) => o.wrapper })({ display: "flex", width: "100%", variants: [{ props: { orientation: "horizontal" }, style: { width: "auto", height: "100%" } }] }), xo = je("div", { name: "MuiCollapse", slot: "WrapperInner", overridesResolver: (e, o) => o.wrapperInner })({ width: "100%", variants: [{ props: { orientation: "horizontal" }, style: { width: "auto", height: "100%" } }] }), ft = ve.forwardRef(function(e, o) {
21
- const r = Ye({ props: e, name: "MuiCollapse" }), { addEndListener: t, children: n, className: a, collapsedSize: i = "0px", component: l, easing: s, in: c, onEnter: u, onEntered: m, onEntering: k, onExit: y, onExited: b, onExiting: f, orientation: x = "vertical", style: h, timeout: d = En.standard, TransitionComponent: L = Cn, ...w } = r, R = { ...r, orientation: x, collapsedSize: i }, M = ((C) => {
21
+ const r = Qe({ props: e, name: "MuiCollapse" }), { addEndListener: t, children: n, className: a, collapsedSize: i = "0px", component: l, easing: s, in: c, onEnter: u, onEntered: m, onEntering: k, onExit: y, onExited: b, onExiting: f, orientation: x = "vertical", style: h, timeout: d = En.standard, TransitionComponent: L = Cn, ...w } = r, R = { ...r, orientation: x, collapsedSize: i }, M = ((C) => {
22
22
  const { orientation: W, classes: V } = C;
23
23
  return vt({ root: ["root", `${W}`], entered: ["entered"], hidden: ["hidden"], wrapper: ["wrapper", `${W}`], wrapperInner: ["wrapperInner", `${W}`] }, go, V);
24
- })(R), j = Sn(), q = Ln(), N = ve.useRef(null), z = ve.useRef(), G = typeof i == "number" ? `${i}px` : i, Q = x === "horizontal", I = Q ? "width" : "height", oe = ve.useRef(null), A = Mn(o, oe), E = (C) => (W) => {
24
+ })(R), j = Sn(), q = Ln(), N = ve.useRef(null), z = ve.useRef(), K = typeof i == "number" ? `${i}px` : i, J = x === "horizontal", I = J ? "width" : "height", oe = ve.useRef(null), A = Mn(o, oe), E = (C) => (W) => {
25
25
  if (C) {
26
26
  const V = oe.current;
27
27
  W === void 0 ? C(V) : C(V, W);
28
28
  }
29
- }, S = () => N.current ? N.current[Q ? "clientWidth" : "clientHeight"] : 0, P = E((C, W) => {
30
- N.current && Q && (N.current.style.position = "absolute"), C.style[I] = G, u && u(C, W);
29
+ }, S = () => N.current ? N.current[J ? "clientWidth" : "clientHeight"] : 0, P = E((C, W) => {
30
+ N.current && J && (N.current.style.position = "absolute"), C.style[I] = K, u && u(C, W);
31
31
  }), D = E((C, W) => {
32
32
  const V = S();
33
- N.current && Q && (N.current.style.position = "");
33
+ N.current && J && (N.current.style.position = "");
34
34
  const { duration: re, easing: me } = Mt({ style: h, timeout: d, easing: s }, { mode: "enter" });
35
35
  if (d === "auto") {
36
36
  const ue = j.transitions.getAutoHeightDuration(V);
@@ -41,24 +41,24 @@ const ko = je("div", { name: "MuiCollapse", slot: "Root", overridesResolver: (e,
41
41
  C.style[I] = "auto", m && m(C, W);
42
42
  }), _ = E((C) => {
43
43
  C.style[I] = `${S()}px`, y && y(C);
44
- }), Y = E(b), H = E((C) => {
44
+ }), Q = E(b), H = E((C) => {
45
45
  const W = S(), { duration: V, easing: re } = Mt({ style: h, timeout: d, easing: s }, { mode: "exit" });
46
46
  if (d === "auto") {
47
47
  const me = j.transitions.getAutoHeightDuration(W);
48
48
  C.style.transitionDuration = `${me}ms`, z.current = me;
49
49
  } else C.style.transitionDuration = typeof V == "string" ? V : `${V}ms`;
50
- C.style[I] = G, C.style.transitionTimingFunction = re, f && f(C);
50
+ C.style[I] = K, C.style.transitionTimingFunction = re, f && f(C);
51
51
  });
52
- return g(L, { in: c, onEnter: P, onEntered: B, onEntering: D, onExit: _, onExited: Y, onExiting: H, addEndListener: (C) => {
52
+ return g(L, { in: c, onEnter: P, onEntered: B, onEntering: D, onExit: _, onExited: Q, onExiting: H, addEndListener: (C) => {
53
53
  d === "auto" && q.start(z.current || 0, C), t && t(oe.current, C);
54
- }, nodeRef: oe, timeout: d === "auto" ? null : d, ...w, children: (C, { ownerState: W, ...V }) => g(ko, { as: l, className: wt(M.root, a, { entered: M.entered, exited: !c && G === "0px" && M.hidden }[C]), style: { [Q ? "minWidth" : "minHeight"]: G, ...h }, ref: A, ownerState: { ...R, state: C }, ...V, children: g(bo, { ownerState: { ...R, state: C }, className: M.wrapper, ref: N, children: g(xo, { ownerState: { ...R, state: C }, className: M.wrapperInner, children: n }) }) }) });
54
+ }, nodeRef: oe, timeout: d === "auto" ? null : d, ...w, children: (C, { ownerState: W, ...V }) => g(ko, { as: l, className: wt(M.root, a, { entered: M.entered, exited: !c && K === "0px" && M.hidden }[C]), style: { [J ? "minWidth" : "minHeight"]: K, ...h }, ref: A, ownerState: { ...R, state: C }, ...V, children: g(bo, { ownerState: { ...R, state: C }, className: M.wrapper, ref: N, children: g(xo, { ownerState: { ...R, state: C }, className: M.wrapperInner, children: n }) }) }) });
55
55
  });
56
56
  function yo(e) {
57
57
  return xt("MuiCard", e);
58
58
  }
59
59
  ft && (ft.muiSupportAuto = !0), yt("MuiCard", ["root"]);
60
60
  const wo = je(Tn, { name: "MuiCard", slot: "Root", overridesResolver: (e, o) => o.root })({ overflow: "hidden" }), vo = ve.forwardRef(function(e, o) {
61
- const r = Ye({ props: e, name: "MuiCard" }), { className: t, raised: n = !1, ...a } = r, i = { ...r, raised: n }, l = ((s) => {
61
+ const r = Qe({ props: e, name: "MuiCard" }), { className: t, raised: n = !1, ...a } = r, i = { ...r, raised: n }, l = ((s) => {
62
62
  const { classes: c } = s;
63
63
  return vt({ root: ["root"] }, yo, c);
64
64
  })(i);
@@ -72,7 +72,7 @@ const Co = je("div", { name: "MuiCardActions", slot: "Root", overridesResolver:
72
72
  const { ownerState: r } = e;
73
73
  return [o.root, !r.disableSpacing && o.spacing];
74
74
  } })({ display: "flex", alignItems: "center", padding: 8, variants: [{ props: { disableSpacing: !1 }, style: { "& > :not(style) ~ :not(style)": { marginLeft: 8 } } }] }), So = ve.forwardRef(function(e, o) {
75
- const r = Ye({ props: e, name: "MuiCardActions" }), { disableSpacing: t = !1, className: n, ...a } = r, i = { ...r, disableSpacing: t }, l = ((s) => {
75
+ const r = Qe({ props: e, name: "MuiCardActions" }), { disableSpacing: t = !1, className: n, ...a } = r, i = { ...r, disableSpacing: t }, l = ((s) => {
76
76
  const { classes: c, disableSpacing: u } = s;
77
77
  return vt({ root: ["root", !u && "spacing"] }, Eo, c);
78
78
  })(i);
@@ -94,11 +94,11 @@ const Co = je("div", { name: "MuiCardActions", slot: "Root", overridesResolver:
94
94
  }), r;
95
95
  })(e));
96
96
  function To(e) {
97
- const o = Ye({ props: e, name: "MuiCssBaseline" }), { children: r, enableColorScheme: t = !1 } = o;
97
+ const o = Qe({ props: e, name: "MuiCssBaseline" }), { children: r, enableColorScheme: t = !1 } = o;
98
98
  return se(ve.Fragment, { children: [gt && g(Do, { enableColorScheme: t }), !gt && !t && g("span", { className: Ze, style: { display: "none" } }), r] });
99
99
  }
100
100
  const Oo = On(g("path", { d: "M12 2C6.47 2 2 6.47 2 12s4.47 10 10 10 10-4.47 10-10S17.53 2 12 2m0 18c-4.41 0-8-3.59-8-8s3.59-8 8-8 8 3.59 8 8-3.59 8-8 8m3.59-13L12 10.59 8.41 7 7 8.41 10.59 12 7 15.59 8.41 17 12 13.41 15.59 17 17 15.59 13.41 12 17 8.41z" }), "CancelOutlined"), Wo = xn(null), rt = { didCatch: !1, error: null };
101
- class Fo extends Kt {
101
+ class Fo extends Gt {
102
102
  constructor(o) {
103
103
  super(o), this.resetErrorBoundary = this.resetErrorBoundary.bind(this), this.state = rt;
104
104
  }
@@ -320,7 +320,7 @@ function bt(e, o) {
320
320
  };
321
321
  }, [e, o]);
322
322
  }
323
- function Qe(e) {
323
+ function Je(e) {
324
324
  var o = e.timeout, r = e.style, t = r === void 0 ? {} : r, n = e.mode;
325
325
  return { duration: typeof o == "object" ? o[n] || 0 : o, easing: t.transitionTimingFunction, delay: t.transitionDelay };
326
326
  }
@@ -374,12 +374,12 @@ var ln = ce(function(e, o) {
374
374
  var r = e.children, t = e.direction, n = t === void 0 ? "down" : t, a = e.in, i = e.style, l = e.timeout, s = l === void 0 ? 0 : l, c = e.onEnter, u = e.onEntered, m = e.onExit, k = e.onExited, y = He(e, ["children", "direction", "in", "style", "timeout", "onEnter", "onEntered", "onExit", "onExited"]), b = le(null), f = bt(r.ref, b), x = bt(f, o), h = ne(function() {
375
375
  b.current && Ve(n, b.current);
376
376
  }, [n]);
377
- return K(function() {
377
+ return G(function() {
378
378
  if (!a && n !== "down" && n !== "right") {
379
379
  var d = function(w, R) {
380
380
  var M;
381
381
  function j() {
382
- for (var q = this, N = arguments.length, z = new Array(N), G = 0; G < N; G++) z[G] = arguments[G];
382
+ for (var q = this, N = arguments.length, z = new Array(N), K = 0; K < N; K++) z[K] = arguments[K];
383
383
  clearTimeout(M), M = setTimeout(function() {
384
384
  w.apply(q, z);
385
385
  }, R);
@@ -394,15 +394,15 @@ var ln = ce(function(e, o) {
394
394
  d.clear(), L.removeEventListener("resize", d);
395
395
  };
396
396
  }
397
- }, [n, a]), K(function() {
397
+ }, [n, a]), G(function() {
398
398
  a || h();
399
399
  }, [a, h]), fe(Ct, Object.assign({ appear: !0, nodeRef: b, onEnter: function(d, L) {
400
400
  Ve(n, d), an(d), c && c(d, L);
401
401
  }, onEntered: u, onEntering: function(d) {
402
- var L = Qe({ timeout: s, mode: "enter", style: O({}, i, { transitionTimingFunction: i?.transitionTimingFunction || "cubic-bezier(0.0, 0, 0.2, 1)" }) });
402
+ var L = Je({ timeout: s, mode: "enter", style: O({}, i, { transitionTimingFunction: i?.transitionTimingFunction || "cubic-bezier(0.0, 0, 0.2, 1)" }) });
403
403
  d.style.webkitTransition = Le("-webkit-transform", L), d.style.transition = Le("transform", L), d.style.webkitTransform = "none", d.style.transform = "none";
404
404
  }, onExit: function(d) {
405
- var L = Qe({ timeout: s, mode: "exit", style: O({}, i, { transitionTimingFunction: i?.transitionTimingFunction || "cubic-bezier(0.4, 0, 0.6, 1)" }) });
405
+ var L = Je({ timeout: s, mode: "exit", style: O({}, i, { transitionTimingFunction: i?.transitionTimingFunction || "cubic-bezier(0.4, 0, 0.6, 1)" }) });
406
406
  d.style.webkitTransition = Le("-webkit-transform", L), d.style.transition = Le("transform", L), Ve(n, d), m && m(d);
407
407
  }, onExited: function(d) {
408
408
  d.style.webkitTransition = "", d.style.transition = "", k && k(d);
@@ -443,13 +443,13 @@ var cn = "notistack-CollapseWrapper", Io = function(e) {
443
443
  }, onEntered: function(c) {
444
444
  c.style.height = "auto";
445
445
  }, onEntering: function(c) {
446
- var u = s(), m = Qe({ timeout: 175, mode: "enter" }), k = m.duration, y = m.easing;
446
+ var u = s(), m = Je({ timeout: 175, mode: "enter" }), k = m.duration, y = m.easing;
447
447
  c.style.transitionDuration = typeof k == "string" ? k : k + "ms", c.style.height = u + "px", c.style.transitionTimingFunction = y || "";
448
448
  }, onExit: function(c) {
449
449
  c.style.height = s() + "px";
450
450
  }, onExited: n, onExiting: function(c) {
451
451
  an(c);
452
- var u = Qe({ timeout: 175, mode: "exit" }), m = u.duration, k = u.easing;
452
+ var u = Je({ timeout: 175, mode: "exit" }), m = u.duration, k = u.easing;
453
453
  c.style.transitionDuration = typeof m == "string" ? m : m + "ms", c.style.height = it, c.style.transitionTimingFunction = k || "";
454
454
  }, nodeRef: i, timeout: 175 }, function(c, u) {
455
455
  return fe("div", Object.assign({ ref: l, className: ge(_t.root, c === "entered" && _t.entered), style: O({ pointerEvents: "all", overflow: "hidden", minHeight: it, transition: Le("height") }, c === "entered" && { overflow: "visible" }, {}, c === "exited" && !t && { visibility: "hidden" }) }, u), fe("div", { ref: a, className: cn, style: { display: "flex", width: "100%" } }, r));
@@ -469,7 +469,7 @@ function Pe(e, o) {
469
469
  };
470
470
  }, jo);
471
471
  }
472
- var Ho = typeof window < "u" ? dt : K;
472
+ var Ho = typeof window < "u" ? dt : G;
473
473
  function Bt(e) {
474
474
  var o = le(e);
475
475
  return Ho(function() {
@@ -486,7 +486,7 @@ var st, dn = ce(function(e, o) {
486
486
  y(null, "timeout", s);
487
487
  }, h));
488
488
  });
489
- K(function() {
489
+ G(function() {
490
490
  return c && b(n), function() {
491
491
  k.current && clearTimeout(k.current);
492
492
  };
@@ -496,7 +496,7 @@ var st, dn = ce(function(e, o) {
496
496
  }, x = ne(function() {
497
497
  n != null && b(0.5 * n);
498
498
  }, [n, b]);
499
- return K(function() {
499
+ return G(function() {
500
500
  if (!i && c) return window.addEventListener("focus", x), window.addEventListener("blur", f), function() {
501
501
  window.removeEventListener("focus", x), window.removeEventListener("blur", f);
502
502
  };
@@ -517,7 +517,7 @@ var Ae = ze({ root: { backgroundColor: "#313131", fontSize: "0.875rem", lineHeig
517
517
  return typeof m == "function" && (m = m(r)), T.createElement(St, { ref: o, role: "alert", "aria-describedby": Vt, style: s, className: ge("notistack-MuiContent", Io(i), Ae.root, Ae[i], c, !l && u && Ae.lessPadding) }, T.createElement("div", { id: Vt, className: Ae.message }, l ? null : u, t), m && T.createElement("div", { className: Ae.action }, m));
518
518
  });
519
519
  pn.displayName = "MaterialDesignContent";
520
- var Re, lt, Ue, Ge, ct, _o = Me(pn), qo = ze({ wrappedRoot: { width: "100%", position: "relative", transform: "translateX(0)", top: 0, right: 0, bottom: 0, left: 0, minWidth: "288px" } }), Bo = function(e) {
520
+ var Re, lt, Ue, Ke, ct, _o = Me(pn), qo = ze({ wrappedRoot: { width: "100%", position: "relative", transform: "translateX(0)", top: 0, right: 0, bottom: 0, left: 0, minWidth: "288px" } }), Bo = function(e) {
521
521
  var o = le(), r = ae(!0), t = r[0], n = r[1], a = Pe([e.snack.onClose, e.onClose]), i = ne(function() {
522
522
  o.current = setTimeout(function() {
523
523
  n(function(q) {
@@ -525,7 +525,7 @@ var Re, lt, Ue, Ge, ct, _o = Me(pn), qo = ze({ wrappedRoot: { width: "100%", pos
525
525
  });
526
526
  }, 125);
527
527
  }, []);
528
- K(function() {
528
+ G(function() {
529
529
  return function() {
530
530
  o.current && clearTimeout(o.current);
531
531
  };
@@ -536,9 +536,9 @@ var Re, lt, Ue, Ge, ct, _o = Me(pn), qo = ze({ wrappedRoot: { width: "100%", pos
536
536
  var N = { containerRoot: !0, containerAnchorOriginTopCenter: !0, containerAnchorOriginBottomCenter: !0, containerAnchorOriginTopRight: !0, containerAnchorOriginBottomRight: !0, containerAnchorOriginTopLeft: !0, containerAnchorOriginBottomLeft: !0 };
537
537
  return Object.keys(q).filter(function(z) {
538
538
  return !N[z];
539
- }).reduce(function(z, G) {
540
- var Q;
541
- return O({}, z, ((Q = {})[G] = q[G], Q));
539
+ }).reduce(function(z, K) {
540
+ var J;
541
+ return O({}, z, ((J = {})[K] = q[K], J));
542
542
  }, {});
543
543
  }(c);
544
544
  }, [c]), y = s.open, b = s.SnackbarProps, f = s.TransitionComponent, x = s.TransitionProps, h = s.transitionDuration, d = s.disableWindowBlurListener, L = s.content, w = He(s, ["open", "SnackbarProps", "TransitionComponent", "TransitionProps", "transitionDuration", "disableWindowBlurListener", "content", "entered", "requestClose", "onEnter", "onEntered", "onExit", "onExited"]), R = O({ direction: (l = w.anchorOrigin, l.horizontal !== "center" ? qt[l.horizontal] : qt[l.vertical]), timeout: h }, x), M = L;
@@ -550,8 +550,8 @@ var Re, lt, Ue, Ge, ct, _o = Me(pn), qo = ze({ wrappedRoot: { width: "100%", pos
550
550
  return T.createElement(un, { in: t, onExited: j.onExited }, T.createElement(dn, { open: y, id: w.id, disableWindowBlurListener: d, autoHideDuration: w.autoHideDuration, className: ge(qo.wrappedRoot, k.root, k[Po(w.anchorOrigin)]), SnackbarProps: b, onClose: a }, T.createElement(f, Object.assign({}, R, { appear: !0, in: y, onExit: j.onExit, onExited: i, onEnter: j.onEnter, onEntered: Pe([j.onEntered, function() {
551
551
  e.snack.requestClose && a(null, "instructed", e.snack.id);
552
552
  }], w.id) }), M || T.createElement(m, Object.assign({}, w)))));
553
- }, Ie = 20, ut = 6, Vo = 2, $t = "." + cn, Ke = ze({ root: (Re = { boxSizing: "border-box", display: "flex", maxHeight: "100%", position: "fixed", zIndex: 1400, height: "auto", width: "auto", transition: Le(["top", "right", "bottom", "left", "max-width"], { duration: 300, easing: "ease" }), pointerEvents: "none" }, Re[$t] = { padding: ut + "px 0px", transition: "padding 300ms ease 0ms" }, Re.maxWidth = "calc(100% - " + 2 * Ie + "px)", Re[at] = { width: "100%", maxWidth: "calc(100% - 32px)" }, Re), rootDense: (lt = {}, lt[$t] = { padding: Vo + "px 0px" }, lt), top: { top: Ie - ut + "px", flexDirection: "column" }, bottom: { bottom: Ie - ut + "px", flexDirection: "column-reverse" }, left: (Ue = { left: Ie + "px" }, Ue[Xe] = { alignItems: "flex-start" }, Ue[at] = { left: "16px" }, Ue), right: (Ge = { right: Ie + "px" }, Ge[Xe] = { alignItems: "flex-end" }, Ge[at] = { right: "16px" }, Ge), center: (ct = { left: "50%", transform: "translateX(-50%)" }, ct[Xe] = { alignItems: "center" }, ct) }), $o = Me(function(e) {
554
- var o = e.classes, r = o === void 0 ? {} : o, t = e.anchorOrigin, n = e.dense, a = e.children, i = ge("notistack-SnackbarContainer", Ke[t.vertical], Ke[t.horizontal], Ke.root, r.containerRoot, r["containerAnchorOrigin" + Et(t)], n && Ke.rootDense);
553
+ }, Ie = 20, ut = 6, Vo = 2, $t = "." + cn, Ge = ze({ root: (Re = { boxSizing: "border-box", display: "flex", maxHeight: "100%", position: "fixed", zIndex: 1400, height: "auto", width: "auto", transition: Le(["top", "right", "bottom", "left", "max-width"], { duration: 300, easing: "ease" }), pointerEvents: "none" }, Re[$t] = { padding: ut + "px 0px", transition: "padding 300ms ease 0ms" }, Re.maxWidth = "calc(100% - " + 2 * Ie + "px)", Re[at] = { width: "100%", maxWidth: "calc(100% - 32px)" }, Re), rootDense: (lt = {}, lt[$t] = { padding: Vo + "px 0px" }, lt), top: { top: Ie - ut + "px", flexDirection: "column" }, bottom: { bottom: Ie - ut + "px", flexDirection: "column-reverse" }, left: (Ue = { left: Ie + "px" }, Ue[Xe] = { alignItems: "flex-start" }, Ue[at] = { left: "16px" }, Ue), right: (Ke = { right: Ie + "px" }, Ke[Xe] = { alignItems: "flex-end" }, Ke[at] = { right: "16px" }, Ke), center: (ct = { left: "50%", transform: "translateX(-50%)" }, ct[Xe] = { alignItems: "center" }, ct) }), $o = Me(function(e) {
554
+ var o = e.classes, r = o === void 0 ? {} : o, t = e.anchorOrigin, n = e.dense, a = e.children, i = ge("notistack-SnackbarContainer", Ge[t.vertical], Ge[t.horizontal], Ge.root, r.containerRoot, r["containerAnchorOrigin" + Et(t)], n && Ge.rootDense);
555
555
  return T.createElement("div", { className: i }, a);
556
556
  }), Ut = function(e) {
557
557
  return !(typeof e == "string" || wn(e));
@@ -565,8 +565,8 @@ var Re, lt, Ue, Ge, ct, _o = Me(pn), qo = ze({ wrappedRoot: { width: "100%", pos
565
565
  return d === void 0 && (d = !1), d ? O({}, be[h], {}, x[h], {}, f[h]) : h === "autoHideDuration" ? (M = f.autoHideDuration, j = x.autoHideDuration, (q = function(N) {
566
566
  return typeof N == "number" || N === null;
567
567
  })(M) ? M : q(j) ? j : be.autoHideDuration) : h === "transitionDuration" ? (L = f.transitionDuration, w = x.transitionDuration, (R = function(N, z) {
568
- return z.some(function(G) {
569
- return typeof N === G;
568
+ return z.some(function(K) {
569
+ return typeof N === K;
570
570
  });
571
571
  })(L, ["string", "number"]) ? L : R(L, ["object"]) ? O({}, be.transitionDuration, {}, R(w, ["object"]) && w, {}, L) : R(w, ["string", "number"]) ? w : R(w, ["object"]) ? O({}, be.transitionDuration, {}, w) : be.transitionDuration) : f[h] || x[h] || be[h];
572
572
  var L, w, R, M, j, q;
@@ -645,7 +645,7 @@ var Re, lt, Ue, Ge, ct, _o = Me(pn), qo = ze({ wrappedRoot: { width: "100%", pos
645
645
  }, nn(o, [{ key: "maxSnack", get: function() {
646
646
  return this.props.maxSnack || be.maxSnack;
647
647
  } }]), o;
648
- }(Kt), mn = function() {
648
+ }(Gt), mn = function() {
649
649
  return yn(rn);
650
650
  };
651
651
  const pe = { card: "_card_1a398_7", actionRoot: "_actionRoot_1a398_11", icons: "_icons_1a398_16", expand: "_expand_1a398_22", expandOpen: "_expandOpen_1a398_29", stackTraceContainer: "_stackTraceContainer_1a398_33" }, hn = ce((e, o) => {
@@ -654,12 +654,12 @@ const pe = { card: "_card_1a398_7", actionRoot: "_actionRoot_1a398_11", icons: "
654
654
  }, []), y = ne(() => {
655
655
  s(r);
656
656
  }, [r, s]), b = a?.message || String(t);
657
- return g(St, { ref: o, className: mt(pe.root, "error-snackbar"), children: se(vo, { className: pe.card, style: { backgroundColor: c.palette.error.dark, border: `1px solid ${c.palette.error.dark}` }, children: [se(So, { className: pe.actionRoot, children: [i ? null : n?.error, g(Vn, { variant: "body2", component: "div", className: pe.typography, style: { color: c.palette.text.primary }, children: b }), g("div", { style: { flex: "1 1 auto" } }), se("div", { className: pe.icons, children: [a ? g(ht, { "aria-label": "Show more", size: "small", className: mt(pe.expand, { [pe.expandOpen]: u }), style: { color: c.palette.action.active }, onClick: k, children: g($n, {}) }) : null, g(ht, { size: "small", className: pe.expand, style: { color: c.palette.action.active }, onClick: y, children: g(Un, { fontSize: "small" }) })] })] }), a ? g(ft, { in: u, timeout: "auto", unmountOnExit: !0, children: g("div", { className: pe.stackTraceContainer, style: { backgroundColor: c.palette.error.light, borderTop: `1px solid ${c.palette.error.main}` }, children: g(Gn, { error: a, hideLineNumbers: !0 }) }) }) : null] }) });
657
+ return g(St, { ref: o, className: mt(pe.root, "error-snackbar"), children: se(vo, { className: pe.card, style: { backgroundColor: c.palette.error.dark, border: `1px solid ${c.palette.error.dark}` }, children: [se(So, { className: pe.actionRoot, children: [i ? null : n?.error, g(Vn, { variant: "body2", component: "div", className: pe.typography, style: { color: c.palette.text.primary }, children: b }), g("div", { style: { flex: "1 1 auto" } }), se("div", { className: pe.icons, children: [a ? g(ht, { "aria-label": "Show more", size: "small", className: mt(pe.expand, { [pe.expandOpen]: u }), style: { color: c.palette.action.active }, onClick: k, children: g($n, {}) }) : null, g(ht, { size: "small", className: pe.expand, style: { color: c.palette.action.active }, onClick: y, children: g(Un, { fontSize: "small" }) })] })] }), a ? g(ft, { in: u, timeout: "auto", unmountOnExit: !0, children: g("div", { className: pe.stackTraceContainer, style: { backgroundColor: c.palette.error.light, borderTop: `1px solid ${c.palette.error.main}` }, children: g(Kn, { error: a, hideLineNumbers: !0 }) }) }) : null] }) });
658
658
  });
659
659
  hn.displayName = "ToastError";
660
660
  const fn = Me(ce((e, o) => {
661
661
  const { commands: r, commandHook: t, scope: n = "workbook", disabled: a = !1, ...i } = e, l = ie((c) => {
662
- const u = { variant: ro.Menuitem, parentFloat: c.floatReference, commandHook: t, scope: n, disabled: a }, m = se(Gt, { children: [g(nt, { ...u, command: r.getCommand("newWorkbook"), icon: Fe(g(ao, {})) }), g(io, { orientation: "horizontal" }), g(nt, { ...u, command: r.getCommand("openWorkbook"), icon: Fe(g(so, {})) }), g(Ot, { ...u, commands: r, quickCommand: "saveWorkbook", icon: Fe(g(uo, {})), createPopupPanel: (k) => {
662
+ const u = { variant: ro.Menuitem, parentFloat: c.floatReference, commandHook: t, scope: n, disabled: a }, m = se(Kt, { children: [g(nt, { ...u, command: r.getCommand("newWorkbook"), icon: Fe(g(ao, {})) }), g(io, { orientation: "horizontal" }), g(nt, { ...u, command: r.getCommand("openWorkbook"), icon: Fe(g(so, {})) }), g(Ot, { ...u, commands: r, quickCommand: "saveWorkbook", icon: Fe(g(uo, {})), createPopupPanel: (k) => {
663
663
  const y = { ...u, parentFloat: k.floatReference, scope: "saveWorkbook" }, b = [];
664
664
  return ye.getWriteFormats().forEach((f) => {
665
665
  if (f.isDefault) return;
@@ -678,17 +678,17 @@ const fn = Me(ce((e, o) => {
678
678
  return g(Ot, { commands: r, disabled: a, commandHook: t, scope: n, label: s, tooltip: "Options for saving and loading the workbook.", sx: { paddingBottom: "0px", "& button": { paddingTop: "0px", paddingBottom: "0px", height: (c) => `calc(1.25rem + ${c.spacing(2)}px)` } }, ...i, createPopupPanel: l, icon: g(po, { className: "label", icon: null, label: s }) });
679
679
  }));
680
680
  fn.displayName = "StandaloneFileCommandButton";
681
- const Go = g(no, { label: "SheetXL", description: "Visit me at sheetxl.com.", children: g(xe, { sx: { width: "24px", height: "24px", marginBottom: "4px", marginLeft: "6px" }, children: g(oo, { onClick: () => {
681
+ const Ko = g(no, { label: "SheetXL", description: "Visit me at sheetxl.com.", children: g(xe, { sx: { width: "24px", height: "24px", marginBottom: "4px", marginLeft: "6px" }, children: g(oo, { onClick: () => {
682
682
  window?.open("https://www.sheetxl.com", "_blank");
683
683
  }, style: { width: "24px", height: "24px", cursor: "pointer" } }) }) }), gn = Me(ce((e, o) => {
684
- const { commands: r, workbook: t, logo: n = Go, mainElement: a, showFileMenu: i = !0, showAppearanceMenu: l = !0, ...s } = e, { reference: c } = Hn(), [u, { width: m }] = zn(), k = m < 530, y = i ? g(fn, { commands: r, commandHook: { beforeExecute() {
684
+ const { commands: r, workbook: t, logo: n = Ko, mainElement: a, showFileMenu: i = !0, showAppearanceMenu: l = !0, ...s } = e, { reference: c } = Hn(), [u, { width: m }] = zn(), k = m < 530, y = i ? g(fn, { commands: r, commandHook: { beforeExecute() {
685
685
  c?.closeAll();
686
686
  }, onError(h, d, L) {
687
687
  } } }) : null, b = l ? g(_n, { commands: r, commandHook: { beforeExecute() {
688
688
  c?.closeAll();
689
689
  }, onError(h, d, L) {
690
690
  } } }) : null, f = te(() => ({ paddingLeft: (h) => h.spacing(1), paddingRight: (h) => h.spacing(1) }), []), x = le(null);
691
- return g(xe, { ref: Jt([x, u, o]), ...s, children: qn({ commands: r, renderCompact: k, workbook: t, selectWrapper: (h) => se(xe, { sx: { display: "flex", flex: "1", flexDirection: "row", alignItems: "stretch", gap: (d) => d.spacing(1), paddingLeft: (d) => d.spacing(1), paddingRight: (d) => d.spacing(1) }, children: [se(xe, { sx: { display: "flex", flexDirection: "row", alignItems: "center", flex: "1 1 100%", gap: (d) => d.spacing(0.5) }, children: [n, se(xe, { sx: { display: "flex", flexDirection: "row", alignItems: "center", gap: (d) => d.spacing(0.25) }, children: [y, h] })] }), g(xe, { sx: { display: "flex", flexDirection: "row", flex: "1 1 300%", overflow: "hidden", alignItems: "center", justifyContent: "center" }, children: a }), g(xe, { sx: { display: "flex", alignItems: "center", justifyContent: "end", flex: k && !b ? "0 0 auto" : "1 1 100%" }, children: b })] }), selectProps: f, toolbarsProps: { Home: { sx: {} } } }) });
691
+ return g(xe, { ref: Yt([x, u, o]), ...s, children: qn({ commands: r, renderCompact: k, workbook: t, selectWrapper: (h) => se(xe, { sx: { display: "flex", flex: "1", flexDirection: "row", alignItems: "stretch", gap: (d) => d.spacing(1), paddingLeft: (d) => d.spacing(1), paddingRight: (d) => d.spacing(1) }, children: [se(xe, { sx: { display: "flex", flexDirection: "row", alignItems: "center", flex: "1 1 100%", gap: (d) => d.spacing(0.5) }, children: [n, se(xe, { sx: { display: "flex", flexDirection: "row", alignItems: "center", gap: (d) => d.spacing(0.25) }, children: [y, h] })] }), g(xe, { sx: { display: "flex", flexDirection: "row", flex: "1 1 300%", overflow: "hidden", alignItems: "center", justifyContent: "center" }, children: a }), g(xe, { sx: { display: "flex", alignItems: "center", justifyContent: "end", flex: k && !b ? "0 0 auto" : "1 1 100%" }, children: b })] }), selectProps: f, toolbarsProps: { Home: { sx: {} } } }) });
692
692
  }));
693
693
  gn.displayName = "StandaloneWorkbookToolbar";
694
694
  const kn = Me(ce((e, o) => {
@@ -698,7 +698,7 @@ const kn = Me(ce((e, o) => {
698
698
  h((A) => ({ ...A, isMounted: !0 }));
699
699
  }, []), L = ne(() => {
700
700
  h((A) => ({ ...A, isMounted: !1 }));
701
- }, []), w = Kn(), R = Zn(), M = Xn(), j = le(/* @__PURE__ */ new Set()), q = te(() => {
701
+ }, []), w = Gn(), R = Zn(), M = Xn(), j = le(/* @__PURE__ */ new Set()), q = te(() => {
702
702
  const A = (E, S) => {
703
703
  if (S?.onceKey) {
704
704
  if (j.current.has(S.onceKey)) return;
@@ -721,17 +721,17 @@ const kn = Me(ce((e, o) => {
721
721
  const D = { ...S, onKeyDown: (B) => {
722
722
  u?.dispatchToFocusedCommand(B), B.isDefaultPrevented() || B.isPropagationStopped() || S?.onKeyDown?.(B);
723
723
  } };
724
- return w(E, { sort: () => import("./BKj70d8kss8lWQ5j.js"), numberFormat: () => import("./D0Cgu7sUw30-mnqB.js"), hyperlink: () => import("./c46EuNJ8AHDaEf22.js"), comments: () => import("./DcwFhmc6DauSay_m.js"), find: () => import("./JWXHlKikGyP_aFCO.js"), tableDetails: () => import("./B048AhsMgarmATbo.js"), tableNew: () => import("./Bwmetegu2MJ05lq3.js"), namedDetails: () => import("./BfCDUWippQ188QJ_.js") }[E], D, P);
724
+ return w(E, { sort: () => import("./pgLOdNAK0tTv9jW5.js"), numberFormat: () => import("./C6y3ZvDtBqiKjmQR.js"), hyperlink: () => import("./DresaRXt2fvt83HL.js"), comments: () => import("./BziPRQRGrFtCnyRv.js"), find: () => import("./DYYGpOI8W9jNCrTX.js"), tableDetails: () => import("./TLsARwdDVPeqjguR.js"), tableNew: () => import("./zMYtuFnY5e4kuvlC.js"), namedDetails: () => import("./CbXEnmr2CeR0TImv.js") }[E], D, P);
725
725
  }, showOptions: R, showInputOptions: M, showError: (E) => {
726
726
  let S, P = _e.Error, D = "Unknown Error";
727
727
  typeof E == "string" ? D = E : E instanceof Error && (S = E, E.message && (D = E.message)), E instanceof fo && (P = _e.Info), A(D, { type: P, enqueueProps: { error: S } });
728
728
  } };
729
729
  }, []), N = ne(() => {
730
730
  }, []), z = ((A) => {
731
- const { workbook: E, setWorkbook: S, importExportDisabled: P, workbookTitle: D = "export", setWorkbookTitle: B, notifier: _, requestWorkbookTitle: Y, themeModeOptions: H, undoManager: C, commands: W, onExecute: V } = A, re = ie(H?.onForceModeChange, [H?.onForceModeChange]), me = ie(H?.onForceLightGridChange, [H?.onForceLightGridChange]), ue = ie(H?.onForceLightImagesChange, [H?.onForceLightImagesChange]), Je = ie(async (F = null, X = null) => {
731
+ const { workbook: E, setWorkbook: S, importExportDisabled: P, workbookTitle: D = "export", setWorkbookTitle: B, notifier: _, requestWorkbookTitle: Q, themeModeOptions: H, undoManager: C, commands: W, onExecute: V } = A, re = ie(H?.onForceModeChange, [H?.onForceModeChange]), me = ie(H?.onForceLightGridChange, [H?.onForceLightGridChange]), ue = ie(H?.onForceLightImagesChange, [H?.onForceLightImagesChange]), Ye = ie(async (F = null, X = null) => {
732
732
  const p = [];
733
- let v, $ = null, J = null;
734
- if (typeof F == "string" ? J = F : $ = F, v = $ ? F : await Qn.openFileDialog(J ?? ye.getAllReadFormatTypeAsString().join(",")), !v) return null;
733
+ let v, $ = null, Y = null;
734
+ if (typeof F == "string" ? Y = F : $ = F, v = $ ? F : await Jn.openFileDialog(Y ?? ye.getAllReadFormatTypeAsString().join(",")), !v) return null;
735
735
  const he = { source: v, constructorOptions: X, onWarning: (tt) => {
736
736
  p.push(tt);
737
737
  } }, Oe = await ye.read(he, _);
@@ -739,12 +739,12 @@ const kn = Me(ce((e, o) => {
739
739
  ` + p.join(`
740
740
  `))), Oe;
741
741
  }, [V, _, E]), De = ie(async (F, X, p) => {
742
- if (!X && Y) {
743
- const v = await Y("Enter Workbook name to " + (p.isDefault ? "Save." : `Export as ${p.description}.`));
742
+ if (!X && Q) {
743
+ const v = await Q("Enter Workbook name to " + (p.isDefault ? "Save." : `Export as ${p.description}.`));
744
744
  return v !== null && ye.writeFile(v, F, { formatType: p.key });
745
745
  }
746
746
  return ye.writeFile(X, F, { formatType: p.key });
747
- }, [_, E, Y]), U = ne(() => ({ contains: (F) => !0, focus() {
747
+ }, [_, E, Q]), U = ne(() => ({ contains: (F) => !0, focus() {
748
748
  } }), []), ke = te(() => {
749
749
  const F = [];
750
750
  P || (ye.getWriteFormats().forEach((p) => {
@@ -754,8 +754,8 @@ const kn = Me(ce((e, o) => {
754
754
  _?.showError?.(he);
755
755
  });
756
756
  })));
757
- const J = v ? "saveWorkbook" : `saveWorkbookAs${p.key}`;
758
- F.push(new ee(J, U, $, (he) => {
757
+ const Y = v ? "saveWorkbook" : `saveWorkbookAs${p.key}`;
758
+ F.push(new ee(Y, U, $, (he) => {
759
759
  De(E, he ?? D, p).catch((Oe) => {
760
760
  _?.showError?.(Oe);
761
761
  });
@@ -763,16 +763,16 @@ const kn = Me(ce((e, o) => {
763
763
  }), F.push(new ee("openWorkbook", U, { label: "Open Workbook…", scopedLabels: { workbook: "Open…" }, description: "Open a workbook from the desktop.", shortcut: { key: "O", modifiers: [We.Ctrl] } }, async (p = null) => {
764
764
  const v = { date1904: E.isDate1904(), ...E.options };
765
765
  try {
766
- const $ = await Je(p, v);
766
+ const $ = await Ye(p, v);
767
767
  if (!$) return;
768
- const J = $.title, he = $.workbook, Oe = he.getSelectedSheet();
768
+ const Y = $.title, he = $.workbook, Oe = he.getSelectedSheet();
769
769
  if ($.formatType.mimeType === "text/csv") {
770
- const tt = E.findValidSheetName(J);
770
+ const tt = E.findValidSheetName(Y);
771
771
  await E.doBatch(async () => {
772
772
  const Lt = Oe.getUsedRange();
773
773
  Lt ? await E.getSheets().add({ name: tt, autoSelect: !0 }).getRange({ colStart: 0, rowStart: 0, colEnd: 0, rowEnd: 0 }).copyFrom(Lt) : _?.showMessage("The file appears to be blank.");
774
- }, `Import CSV '${J}'`);
775
- } else E?.close(), B?.(J), S(he);
774
+ }, `Import CSV '${Y}'`);
775
+ } else E?.close(), B?.(Y), S(he);
776
776
  } catch ($) {
777
777
  _?.showError?.($);
778
778
  }
@@ -798,11 +798,11 @@ const kn = Me(ce((e, o) => {
798
798
  })];
799
799
  }, [E, D, _, P, H, W, C]), Z = te(() => {
800
800
  let F = null;
801
- return F = W ? W.createChildGroup(U, "standaloneWorkbook", !1) : new Qt(U, "standaloneWorkbook"), F.addCommands(ke, !0), F;
801
+ return F = W ? W.createChildGroup(U, "standaloneWorkbook", !1) : new Jt(U, "standaloneWorkbook"), F.addCommands(ke, !0), F;
802
802
  }, [W, ke]);
803
- Yn({ manager: C, commands: Z, notifier: _ });
803
+ Qn({ manager: C, commands: Z, notifier: _ });
804
804
  const { themeMode: Te } = Xt();
805
- K(() => {
805
+ G(() => {
806
806
  if (!H || !Z) return;
807
807
  const F = H.forceMode === "dark" || !H.forceMode && Te === "dark";
808
808
  Z.getCommand("themeMode").update({ state: H.forceMode ?? null, label: F ? "Dark Mode" : "Light Mode", scopedLabels: { appearance: F ? "Dark Mode" : "Light Mode" } }).updateCallback(() => {
@@ -815,10 +815,10 @@ const kn = Me(ce((e, o) => {
815
815
  ue(!H.forceLightImages);
816
816
  });
817
817
  }, [Te, H, ke]);
818
- const { showModal: et } = Jn();
819
- return K(() => {
818
+ const { showModal: et } = Yn();
819
+ return G(() => {
820
820
  const F = () => new Promise((X, p) => {
821
- const v = T.lazy(() => import("./DpXpV2Nd-U9CeW99.js")), $ = et(v, { title: "Shortcut Keys Reference", commands: Z, onDone: () => {
821
+ const v = T.lazy(() => import("./BSsHFJzgfxmp5r7_.js")), $ = et(v, { title: "Shortcut Keys Reference", commands: Z, onDone: () => {
822
822
  $.hide();
823
823
  }, TransitionProps: { onExited: () => {
824
824
  X(!0);
@@ -831,7 +831,7 @@ const kn = Me(ce((e, o) => {
831
831
  E(S);
832
832
  }, { selectAll: !0, requestReason: A }) : E(l);
833
833
  }), themeModeOptions: k, undoManager: c, notifier: q, onExecute: N });
834
- K(() => {
834
+ G(() => {
835
835
  x.starting.size <= 0 || !x.isMounted || h((A) => {
836
836
  const E = new Map(A.running);
837
837
  return A.starting.forEach((S, P) => {
@@ -845,17 +845,17 @@ const kn = Me(ce((e, o) => {
845
845
  }), { ...A, starting: /* @__PURE__ */ new Map(), running: E };
846
846
  });
847
847
  }, [x]);
848
- const [G, Q] = ae(null);
849
- K(() => {
850
- x.starting.size !== 0 || x.running.size !== 0 ? Q(g(Yt, { icon: g(eo, { sx: { transform: "scale(0.7)", marginLeft: "-6px" } }), panel: !0, label: x.label, onMount: d, onUnmount: L, sx: { position: "absolute", left: "0", top: "0", width: "100%", height: "100%", zIndex: "9999" } })) : Q(null);
848
+ const [K, J] = ae(null);
849
+ G(() => {
850
+ x.starting.size !== 0 || x.running.size !== 0 ? J(g(Qt, { icon: g(eo, { sx: { transform: "scale(0.7)", marginLeft: "-6px" } }), panel: !0, label: x.label, onMount: d, onUnmount: L, sx: { position: "absolute", left: "0", top: "0", width: "100%", height: "100%", zIndex: "9999" } })) : J(null);
851
851
  }, [x.starting, x.running]);
852
852
  const I = te(() => g(to, { commands: z, disableHover: !0, sx: { padding: "0" }, buttonProps: { sx: { maxHeight: "22px" } } }), [z]), oe = { notifier: q, commands: z };
853
- return r && (oe.statusBarProps = { childrenEnd: I }), se(Gt, { children: [G, s ? T.cloneElement(s, oe) : null] });
853
+ return r && (oe.statusBarProps = { childrenEnd: I }), se(Kt, { children: [K, s ? T.cloneElement(s, oe) : null] });
854
854
  }));
855
855
  kn.displayName = "SnackbarAndCommandsWrapper";
856
856
  const bn = Me(ce((e, o) => {
857
- const { className: r, sx: t, style: n, onElementLoad: a, onError: i, undoManager: l, errorPanel: s = Wn, onKeyDown: c, workbook: u, createWorkbookOptions: m, onWorkbookChange: k, logo: y, importExportDisabled: b = !1, themeModeOptions: f, autoFocus: x = !1, commands: h, title: d, onTitleChange: L, titleProps: w, ...R } = e, M = le(null), j = ie(k, [k]), q = ie(L ?? w?.onTitleChange, [L ?? w?.onTitleChange]), N = w?.placeHolder ?? "Untitled", z = f?.forceMode, { themeMode: G, source: Q } = Xt({ mode: z }), I = te(() => ({ ...f, light: Dt(!1, ot.deepMerge(f?.theme ?? {}, f?.light ?? {})), dark: Dt(!0, ot.deepMerge(f?.theme ?? {}, f?.dark ?? {})) }), [f]), oe = G === pt.Dark, [A, E] = ae(null);
858
- K(() => {
857
+ const { className: r, sx: t, style: n, onElementLoad: a, onError: i, undoManager: l, errorPanel: s = Wn, onKeyDown: c, workbook: u, createWorkbookOptions: m, onWorkbookChange: k, logo: y, importExportDisabled: b = !1, themeModeOptions: f, autoFocus: x = !1, commands: h, title: d, onTitleChange: L, titleProps: w, ...R } = e, M = le(null), j = ie(k, [k]), q = ie(L ?? w?.onTitleChange, [L ?? w?.onTitleChange]), N = w?.placeHolder ?? "Untitled", z = f?.forceMode, { themeMode: K, source: J } = Xt({ mode: z }), I = te(() => ({ ...f, light: Dt(!1, ot.deepMerge(f?.theme ?? {}, f?.light ?? {})), dark: Dt(!0, ot.deepMerge(f?.theme ?? {}, f?.dark ?? {})) }), [f]), oe = K === pt.Dark, [A, E] = ae(null);
858
+ G(() => {
859
859
  E(l ?? new ho());
860
860
  }, [l]);
861
861
  const [S, P] = ae(null), [D, B] = ae(null), _ = Fn();
@@ -877,54 +877,54 @@ const bn = Me(ce((e, o) => {
877
877
  })();
878
878
  }
879
879
  }, [D]);
880
- const [Y, H] = ae(null);
881
- K(() => {
880
+ const [Q, H] = ae(null);
881
+ G(() => {
882
882
  if (!A || !S) return;
883
883
  A.clear();
884
884
  const p = S?.workbook?.getTransactions();
885
885
  return p ? p.addListener({ onCommitEnd: (v) => {
886
- v.getDescription() ? A.addUndoOperation({ description: v.getDescription(), undo: () => (p.revert(v.getId()), Y.source?.focus(), () => {
887
- p.restore(v.getId()), Y.source?.focus();
886
+ v.getDescription() ? A.addUndoOperation({ description: v.getDescription(), undo: () => (p.revert(v.getId()), Q.source?.focus(), () => {
887
+ p.restore(v.getId()), Q.source?.focus();
888
888
  }) }) : console.warn("commit has no description", v);
889
889
  } }) : void 0;
890
- }, [A, S, Y]);
890
+ }, [A, S, Q]);
891
891
  const C = ie((p) => {
892
892
  p ? A.setRepeatableOperation({ description: p.label(), repeat: async () => p.execute() }) : A.setRepeatableOperation(null);
893
893
  }, [A]), [W, V] = ae(d ?? w?.title ?? "");
894
- K(() => {
894
+ G(() => {
895
895
  V(d ?? w?.title ?? "");
896
- }, [d ?? w?.title]), K(() => {
896
+ }, [d ?? w?.title]), G(() => {
897
897
  q?.(W);
898
898
  }, [W]);
899
899
  const [re, me] = ae(null), ue = te(() => {
900
900
  const p = () => ({ contains: (v) => !0, focus() {
901
901
  } });
902
- return h ? h.createChildGroup(p, "application", !1) : new Qt(p, "application");
903
- }, [h]), Je = ie((p) => {
902
+ return h ? h.createChildGroup(p, "application", !1) : new Jt(p, "application");
903
+ }, [h]), Ye = ie((p) => {
904
904
  me(p.source.getViewportElement()), H(p), ue.activate("sheet"), a?.(p);
905
905
  }, [ue]);
906
- K(() => {
907
- Y && x && Y.source?.focus(typeof x == "object" ? x : void 0);
908
- }, [Y]);
906
+ G(() => {
907
+ Q && x && Q.source?.focus(typeof x == "object" ? x : void 0);
908
+ }, [Q]);
909
909
  const De = le(null), U = ne((p) => {
910
910
  let v = null;
911
911
  return w?.hidden || (v = g(Nn, { ...w, style: { maxWidth: "100%", ...w?.style }, workbook: M.current, ref: De, title: W, placeHolder: N, onTitleChange: ($) => {
912
912
  V($);
913
913
  } })), g(gn, { ...p, logo: y, mainElement: v, showFileMenu: !b, showAppearanceMenu: !!(I?.onForceLightGridChange || I?.onForceLightImagesChange || I?.onForceModeChange) });
914
914
  }, [y, W, w, I, b, ue]);
915
- K(() => {
915
+ G(() => {
916
916
  const p = (v) => v.preventDefault();
917
917
  return M.current?.addEventListener("wheel", p, { passive: !1 }), () => {
918
918
  M.current?.removeEventListener("wheel", p);
919
919
  };
920
920
  }, []);
921
- const ke = te(() => g(Yt, { transparentBackground: !0, sx: t, style: n }), [t, n]), Z = ne(({ error: p }) => (i?.(p), g(s, { sx: t, style: n, error: p ?? "Unable to display empty workbook." })), [t, n, i]), Te = te(() => ({ ...t, "& .SnackbarContainer-root": { position: "absolute !important" }, "& .notistack-Snackbar": { minWidth: "unset" }, "& .notistack-MuiContent *": { fontFamily: (p) => p.typography.fontFamily }, "& #notistack-snackbar": { maxWidth: "560px", whiteSpace: "pre-wrap" }, "*": { userSelect: "none" } }), [t]), et = Jt([M, o]), F = te(() => {
921
+ const ke = te(() => g(Qt, { transparentBackground: !0, sx: t, style: n }), [t, n]), Z = ne(({ error: p }) => (i?.(p), g(s, { sx: t, style: n, error: p ?? "Unable to display empty workbook." })), [t, n, i]), Te = te(() => ({ ...t, "& .SnackbarContainer-root": { position: "absolute !important" }, "& .notistack-Snackbar": { minWidth: "unset" }, "& .notistack-MuiContent *": { fontFamily: (p) => p.typography.fontFamily }, "& #notistack-snackbar": { maxWidth: "560px", whiteSpace: "pre-wrap" }, "*": { userSelect: "none" } }), [t]), et = Yt([M, o]), F = te(() => {
922
922
  if (!S) return ke;
923
923
  if (S.error || !S.workbook) return Z({ error: S.error });
924
924
  let p = null, v = null, $ = !1;
925
- return I && (p = oe ? I.dark : I.light, v = oe && !I.forceLightGrid ? I.dark : I.light, $ = I.forceLightImages), g(An, { sx: Te, style: n, tabIndex: 0, autoFocus: !0, workbook: S.workbook, ref: et, renderToolbar: U, onElementLoad: Je, onRepeatCommandChange: C, onKeyDown: (J) => {
926
- c?.(J);
927
- }, gridTheme: v, headersTheme: p, forceLightImages: $, className: mt(r, "sheetxl-workbook"), onContextMenu: (J) => J.preventDefault(), ...R }, "WorkbookElement");
925
+ return I && (p = oe ? I.dark : I.light, v = oe && !I.forceLightGrid ? I.dark : I.light, $ = I.forceLightImages), g(An, { sx: Te, style: n, tabIndex: 0, autoFocus: !0, workbook: S.workbook, ref: et, renderToolbar: U, onElementLoad: Ye, onRepeatCommandChange: C, onKeyDown: (Y) => {
926
+ c?.(Y);
927
+ }, gridTheme: v, headersTheme: p, forceLightImages: $, className: mt(r, "sheetxl-workbook"), onContextMenu: (Y) => Y.preventDefault(), ...R }, "WorkbookElement");
928
928
  }, [S, W, A, ke, I, R, U, Te]);
929
929
  let X = g(Fo, { fallbackRender: Z, children: g(Uo, { maxSnack: 3, domRoot: re, anchorOrigin: { vertical: "bottom", horizontal: "right" }, autoHideDuration: 3500, onClose: (p, v, $) => {
930
930
  M.current?.focus();
@@ -932,9 +932,9 @@ const bn = Me(ce((e, o) => {
932
932
  return I && (X = se(jn, { theme: oe ? I.dark : I.light, children: [I.cssBaseline ? g(To, {}) : null, X] })), X;
933
933
  }));
934
934
  bn.displayName = "EagerStandaloneWorkbook";
935
- const Ko = Object.freeze(Object.defineProperty({ __proto__: null, default: bn }, Symbol.toStringTag, { value: "Module" })), er = Object.freeze(Object.defineProperty({ __proto__: null, E: Ko, c: ge }, Symbol.toStringTag, { value: "Module" }));
935
+ const Go = Object.freeze(Object.defineProperty({ __proto__: null, default: bn }, Symbol.toStringTag, { value: "Module" })), er = Object.freeze(Object.defineProperty({ __proto__: null, E: Go, c: ge }, Symbol.toStringTag, { value: "Module" }));
936
936
  export {
937
+ er as B,
937
938
  ft as C,
938
- er as a,
939
939
  ge as f
940
940
  };
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.3.18
2
+ * @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.3.20
3
3
  *
4
4
  * (C) 2025-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -0,0 +1,84 @@
1
+ import { Workbook as J } from "@sheetxl/sdk";
2
+ /**
3
+ * @license @sheetxl/studio-vanilla - SheetXL Studio - Vanilla entry point for integrating SheetXL UI. - v0.3.20
4
+ *
5
+ * (C) 2025-present SheetXL Inc. & Michael T. Ford
6
+ * License: The license can be found at https://www.sheetxl.com/license.
7
+ */
8
+ const k = async (p, l) => {
9
+ const c = await p.toJSON(), b = l?.whiteSpace ?? 0;
10
+ let g;
11
+ l?.beforeWrite?.(p, c), g = b === 0 ? JSON.stringify(c) : function(i, r = 2) {
12
+ const n = [];
13
+ function s(o) {
14
+ const e = r * o;
15
+ return n[e] === void 0 && (n[e] = " ".repeat(e)), n[e];
16
+ }
17
+ return function o(e, f, a, B) {
18
+ if (e == null || typeof e != "object") return JSON.stringify(e);
19
+ const A = s(f), d = s(f + 1);
20
+ if (Array.isArray(e)) {
21
+ const u = e.length;
22
+ if (u === 0) return "[]";
23
+ if (a !== 0) return JSON.stringify(e);
24
+ let y = `[
25
+ `;
26
+ for (let h = 0; h < u; h++) y += d + o(e[h], f + 1, a + 1, !0), h < u - 1 && (y += `,
27
+ `);
28
+ return y += `
29
+ ` + A + "]", y;
30
+ }
31
+ const m = Object.keys(e), O = m.length;
32
+ if (O === 0) return "{}";
33
+ if (!(a < 2)) return JSON.stringify(e);
34
+ let S = `{
35
+ `;
36
+ B || (a = 0);
37
+ for (let u = 0; u < O; u++) {
38
+ const y = m[u];
39
+ S += d + JSON.stringify(y) + ": " + o(e[y], f + 1, a, !1), u < O - 1 && (S += `,
40
+ `);
41
+ }
42
+ return S += `
43
+ ` + A + "}", S;
44
+ }(i, 0, 0, !1);
45
+ }(c, b);
46
+ let w = new TextEncoder().encode(g).buffer;
47
+ const t = l?.compress ?? !0;
48
+ return t && (w = await async function(i, r = "gzip") {
49
+ let n;
50
+ i instanceof SharedArrayBuffer ? (n = new ArrayBuffer(i.byteLength), new Uint8Array(n).set(new Uint8Array(i))) : n = i;
51
+ const s = new ReadableStream({ start(f) {
52
+ f.enqueue(n), f.close();
53
+ } }), o = new CompressionStream(r), e = s.pipeThrough(o);
54
+ return (await new Response(e).blob()).arrayBuffer();
55
+ }(w, typeof t == "string" ? t : void 0)), w;
56
+ }, z = async (p, l) => {
57
+ let c = p;
58
+ (function(t) {
59
+ if (t.byteLength < 4) return !1;
60
+ const i = new Uint8Array(t), r = { gzip: [31, 139], zip: [80, 75, 3, 4], bz2: [66, 90, 104], br: [206, 178, 207, 129] }, n = Object.keys(r);
61
+ for (let s = 0; s < n.length; s++) {
62
+ const o = n[s], e = r[o];
63
+ let f = !0;
64
+ for (let a = 0; a < e.length; a++) if (i[a] !== e[a]) {
65
+ f = !1;
66
+ break;
67
+ }
68
+ if (f) return o;
69
+ }
70
+ return !1;
71
+ })(c) && (c = await async function(t, i = "gzip") {
72
+ let r;
73
+ t instanceof SharedArrayBuffer ? (r = new ArrayBuffer(t.byteLength), new Uint8Array(r).set(new Uint8Array(t))) : r = t;
74
+ const n = new Blob([r]).stream(), s = new DecompressionStream(i), o = n.pipeThrough(s);
75
+ return (await new Response(o).blob()).arrayBuffer();
76
+ }(c));
77
+ let b = new TextDecoder().decode(c);
78
+ const g = JSON.parse(b), w = { ...l?.constructorOptions ?? {}, json: g };
79
+ return new J(w);
80
+ };
81
+ export {
82
+ z as fromBufferJSON,
83
+ k as toBufferJSON
84
+ };