@sheetxl/studio-mui 0.8.0-beta.10 → 0.8.0-beta.11

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 (119) hide show
  1. package/browser/esm/0BWO0bLZ8Vm_dKd2.mjs +582 -0
  2. package/browser/esm/BAbq4-I5f5oUiNaF.mjs +141 -0
  3. package/browser/esm/BED6h6YAwCf1HEQJ.mjs +161 -0
  4. package/browser/esm/{CEvZe2cZK-voZTif.mjs → BXhNFzyEGokTF-BL.mjs} +5 -5
  5. package/browser/esm/BYE9gCDWKyx6mnVs.mjs +381 -0
  6. package/browser/esm/{DBtc4lku0uHVcqWn.mjs → BjvD_4t2KGsZP5V8.mjs} +3 -3
  7. package/browser/esm/{DU3J8Gcf-WpBxNYg.mjs → BknfGJouygmnpFIU.mjs} +4 -4
  8. package/browser/esm/{D8al_cJ4U-NgzwoK.mjs → BlE_8o8tO2AgAlaj.mjs} +19 -17
  9. package/browser/esm/BokqKEpU6TFgfRs6.mjs +252 -0
  10. package/browser/esm/{DHY19rkSiiRZxShC.mjs → Brsh5yscJ_4uKFXp.mjs} +3 -3
  11. package/browser/esm/Bujtz_Guj88d03vI.mjs +831 -0
  12. package/browser/esm/Buqcl7J75MJrhpVE.mjs +1379 -0
  13. package/browser/esm/BvhYPwX3GrRaO9CM.mjs +319 -0
  14. package/browser/esm/C0wlMAIn9iREPK6w.mjs +87 -0
  15. package/browser/esm/C8JU4KsMasmLvojI.mjs +103 -0
  16. package/browser/esm/{CjznclrKqJRi7u9O.mjs → C9pIZVACtl9unFOp.mjs} +2 -2
  17. package/browser/esm/CBD4RiRKbbZtSXV-.mjs +318 -0
  18. package/browser/esm/{Blaj2R5hYxtLAW__.mjs → CEtXsBzEjEKk9GOj.mjs} +6 -6
  19. package/browser/esm/{CIu1bjPJe_x31Oww.mjs → COlZu93LRwuBvjE-.mjs} +3 -3
  20. package/browser/esm/{CoSiOS-og0zFw4Ws.mjs → CTjqDD-swFMZzI-Y.mjs} +2 -2
  21. package/browser/esm/CWkOgdL7mOKiTR62.mjs +975 -0
  22. package/browser/esm/ChSVxkPTIjgcC8PL.mjs +412 -0
  23. package/browser/esm/{5cbK03T_Oh3tNdR7.mjs → ClBvNPeNCAhuVWrG.mjs} +1 -1
  24. package/browser/esm/CyLn6zOOp_biA3xU.mjs +335 -0
  25. package/browser/esm/CynTY0oNtyJnoaBq.mjs +14 -0
  26. package/browser/esm/{xKiLJKiLxto8SayF.mjs → D3rRUK4dIM5gUSmj.mjs} +2 -2
  27. package/browser/esm/D9ISy7VkaRRFJl46.mjs +515 -0
  28. package/browser/esm/{fb126BNj3F8URR19.mjs → DDc6rDuU9JAo1DH_.mjs} +3 -3
  29. package/browser/esm/DDczwkXhz_MHub4z.mjs +197 -0
  30. package/browser/esm/{X1Db3b_7b_7OuCk6.mjs → DEv4pIEgYr5C7etm.mjs} +1 -1
  31. package/browser/esm/DG21x7RKDpge6zAE.mjs +31 -0
  32. package/browser/esm/DJOOed_OtB-XT7f3.mjs +437 -0
  33. package/browser/esm/{9eKCkvqpMQwqcXiw.mjs → DKtJxrpN0axtuQ0l.mjs} +1 -1
  34. package/browser/esm/DRSCS6aLiYmPjUz1.mjs +1543 -0
  35. package/browser/esm/{ByeL_BZuJ2kl8gtf.mjs → DTpRkgsTm_zYnWfW.mjs} +1 -1
  36. package/browser/esm/DV6i9RQZfJiKtEaJ.mjs +2552 -0
  37. package/browser/esm/DdcZrjMLWVukWcU5.mjs +7473 -0
  38. package/browser/esm/Di3BUxA0SqFWWgeg.mjs +94 -0
  39. package/browser/esm/DnGaP5F7mLwCGUYG.mjs +408 -0
  40. package/browser/esm/DpD4fg2WcyiKX_2K.mjs +414 -0
  41. package/browser/esm/{C1Rp2hZrApo5MUc8.mjs → Ds3XRkne7HxcXD8J.mjs} +2 -2
  42. package/browser/esm/{sFOAxZpxXo-qvDSp.mjs → DsoNMWDwHZP8UXQd.mjs} +1 -1
  43. package/browser/esm/G0Inqm6Eqw47dMpa.mjs +212 -0
  44. package/browser/esm/{B1Yp_uy1vFHcJB3U.mjs → HViD4Wfoi0mmqk9w.mjs} +1 -1
  45. package/browser/esm/LZoYSQAYV2wksnDv.mjs +386 -0
  46. package/browser/esm/{CtEFHbzYNvYjDYvi.mjs → QgaAIDUMmBQBsXP9.mjs} +8 -8
  47. package/browser/esm/{D6S8kVTzOjCn0-SK.mjs → YThnrg3PadGs7B4j.mjs} +51 -51
  48. package/browser/esm/index.mjs +1028 -170
  49. package/browser/esm/ttjcNHcFn8O6hfnd.mjs +1288 -0
  50. package/browser/esm/{yZxC4qUENOlMhVUH.mjs → w_JrR69vEpvoyeMy.mjs} +1 -1
  51. package/browser/esm/{DmCQbW4zwkT_Rq88.mjs → xFqkfN8QMCxvsetB.mjs} +1 -1
  52. package/browser/esm/{IQLeaAbtGTipUsOD.mjs → zqilJefihVd7At2T.mjs} +22 -21
  53. package/licenses/dependencies.txt +94 -94
  54. package/node/esm/{BYsG3KYVmxSe_CIQ.mjs → 1bf4gn-2vld4BZ9u.mjs} +1 -1
  55. package/node/esm/{CKu1AtRgyltyEdEN.mjs → 3WghtBXAvCDwcVrq.mjs} +1 -1
  56. package/node/esm/{cqzp431iNSLWictb.mjs → 4HmLH0bPVJCZLgik.mjs} +22 -22
  57. package/node/esm/{BYVLi0md4AYuDsB_.mjs → B0bdb_6p7fQI_ivo.mjs} +28 -28
  58. package/node/esm/BIMkjQUwG4Ih-6Sh.mjs +142 -0
  59. package/node/esm/BNg4QQY0WAPLE0q7.mjs +141 -0
  60. package/node/esm/BPzcW4BejRqso338.mjs +72 -0
  61. package/node/esm/BR45ogAR-hY2bE60.mjs +318 -0
  62. package/node/esm/BlN7G0DVC24zauig.mjs +197 -0
  63. package/node/esm/{ah3CUg4-VmNstGk_.mjs → Bph-sR3l6AYWeuxK.mjs} +2 -2
  64. package/node/esm/CPq-MIdEnc-53JpF.mjs +319 -0
  65. package/node/esm/CSAnTp5rwId0DUb8.mjs +380 -0
  66. package/node/esm/CWcv7UVXF8IUB0PC.mjs +1379 -0
  67. package/node/esm/{D9rzScOA9pEYFrtz.mjs → CYIoK22I6Yvv12_x.mjs} +20 -20
  68. package/node/esm/CZyA9uD4SkTvqp_G.mjs +1283 -0
  69. package/node/esm/{ci8d-mF1H9wnYzix.mjs → CjC6s3RUJQNCF7mP.mjs} +1 -1
  70. package/node/esm/{D6oQL8knsPpgdXuk.mjs → CuMePia6i_8yfJ6S.mjs} +9 -9
  71. package/node/esm/CvRbu8JPxFarsSR-.mjs +412 -0
  72. package/node/esm/{DNSjK5DAH3M14Qbc.mjs → CyafafEgfmjLqE5O.mjs} +1 -1
  73. package/node/esm/D-xqQ5qOSd6WrzwJ.mjs +94 -0
  74. package/node/esm/DLqBHdFp6wvm6EGs.mjs +212 -0
  75. package/node/esm/{BcwMb6CyVfvEwbHn.mjs → DMXLxp3T0E0SRTQc.mjs} +1 -1
  76. package/node/esm/{DZzvTQxIKr9LbEsA.mjs → DWqvf4H5F2wMnZ0L.mjs} +32 -30
  77. package/node/esm/DatM6eEYPpAtIMy-.mjs +405 -0
  78. package/node/esm/Db3dbaYLKUO66T9s.mjs +1689 -0
  79. package/node/esm/{B_jRGdwGFkudwmL-.mjs → DdEzhVqYTrGODXrz.mjs} +1 -1
  80. package/node/esm/DeZJlLk8WJ3BLtLs.mjs +975 -0
  81. package/node/esm/DfCuL8AUxMFoEG2s.mjs +519 -0
  82. package/node/esm/{Bb1sLMqXWKjdve23.mjs → Do-zCKziWhoG5eAv.mjs} +2 -2
  83. package/node/esm/{B8SQfjKjzYHLxzZR.mjs → DpJ2gmZJioCyq8La.mjs} +67 -67
  84. package/node/esm/{ETK6T6G0SIcFXDe5.mjs → XEDcegsv5AGKBfu2.mjs} +40 -40
  85. package/node/esm/index.mjs +8941 -13558
  86. package/node/esm/yCUxQuqVuC4DHKPx.mjs +385 -0
  87. package/node/esm/zITjZ7R4raDqhP-n.mjs +515 -0
  88. package/package.json +9 -9
  89. package/resources/locales/de/ui.msg.json +97 -0
  90. package/resources/locales/en/ui.msg.json +97 -0
  91. package/types/src/anchorItems/AnchorItemsDescriptor.d.ts +4 -4
  92. package/types/src/anomalies/AnomaliesPlugin.d.ts +5 -0
  93. package/types/src/anomalies/AnomaliesTaskPane.d.ts +17 -0
  94. package/types/src/anomalies/index.d.ts +3 -0
  95. package/types/src/border/BorderTemplateIcon.d.ts +6 -1
  96. package/types/src/chart/ChartFormatPanel.d.ts +20 -0
  97. package/types/src/chart/ChartPlugin.d.ts +6 -0
  98. package/types/src/chart/index.d.ts +3 -0
  99. package/types/src/comments/CommentCard.d.ts +2 -2
  100. package/types/src/conditions/useFormulaOption.d.ts +2 -2
  101. package/types/src/dialog/WorkbookStatisticsDialog.d.ts +1 -1
  102. package/types/src/format/BorderPreview.d.ts +11 -4
  103. package/types/src/format/useFormatSelection.d.ts +4 -4
  104. package/types/src/formulaBar/MobileFormulaBar.d.ts +18 -6
  105. package/types/src/formulaBar/MobileInputToolbar.d.ts +9 -3
  106. package/types/src/formulaBar/useFormulaBarSession.d.ts +6 -3
  107. package/types/src/index.d.ts +15 -6
  108. package/types/src/protection/ProtectedCellsPanel.d.ts +2 -2
  109. package/types/src/protection/{SheetProtectionPanel.d.ts → WorksheetProtectionPanel.d.ts} +6 -6
  110. package/types/src/protection/index.d.ts +1 -1
  111. package/types/src/slicer/PresetSlicerStylesCommandButton.d.ts +2 -2
  112. package/types/src/workbook/DefaultRenderers.d.ts +2 -2
  113. package/types/src/workbook/WorkbookContextMenu.d.ts +4 -0
  114. package/browser/esm/Biy7bhzzzPb5sfRN.mjs +0 -152
  115. package/browser/esm/COv-m-c2byCgvU3M.mjs +0 -14861
  116. package/browser/esm/Die9NXVFveHvcCT-.mjs +0 -4205
  117. package/browser/esm/sam1KGQZ59B_fADz.mjs +0 -1941
  118. package/node/esm/BYwXhrEwkRAt9nJS.mjs +0 -71
  119. package/node/esm/Cmt8Wv806N7NmE4Y.mjs +0 -3344
@@ -0,0 +1,161 @@
1
+ /**
2
+ * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.11
3
+ *
4
+ * (C) 2026-present SheetXL Inc. & Michael T. Ford
5
+ * License: The license can be found at https://www.sheetxl.com/license.
6
+ */
7
+ import { Color as e } from "@sheetxl/sdk";
8
+ import { useGridColorScheme as t, useModelListener as n, useWorkbook as r } from "@sheetxl/react";
9
+ import { themeSurfaceProps as i } from "@sheetxl/utils-react";
10
+ import { Fragment as a, memo as o, useCallback as s, useReducer as c } from "react";
11
+ import { SimpleTooltip as l } from "@sheetxl/utils-mui";
12
+ import { jsx as u, jsxs as d } from "react/jsx-runtime";
13
+ import { Box as f } from "@mui/material";
14
+ var p = (t, n) => {
15
+ if (!t) return null;
16
+ let r = n?.getStyles();
17
+ try {
18
+ return new e(t, r?.schemeLookup(), r?.indexedLookup());
19
+ } catch {
20
+ return null;
21
+ }
22
+ }, m = () => {
23
+ let e = r(), a = t(), o = a === "dark", [l, u] = c((e) => e + 1, 0);
24
+ n(e, { onThemeChange: () => u() }, { ignoreModelChange: !0 });
25
+ let d = s((t) => p(t, e), [e, l]), f = e?.getStyles().schemeLookup();
26
+ return {
27
+ workbook: e,
28
+ schemeLookup: f,
29
+ themeKey: l,
30
+ gridColorScheme: a,
31
+ darkMode: o,
32
+ toColor: d,
33
+ propsColorPanel: {
34
+ schemeLookup: f,
35
+ darkMode: o,
36
+ ...i("grid", a)
37
+ }
38
+ };
39
+ }, h = "var(--sxl-color-base-100, rgb(255, 255, 255))", g = "var(--sxl-color-base-300, rgb(224, 224, 224))", _ = "var(--sxl-color-primary, rgb(33, 115, 70))", v = "var(--sxl-color-base-content, rgba(0, 0, 0, 0.87))", y = "var(--sxl-color-error, rgb(211, 47, 47))", b = (e) => Math.round(e).toString(16).padStart(2, "0"), x = (t, n, r) => new e(`#${b(t)}${b(n)}${b(r)}`).toCSS("adaptive"), S = (e, t, n, r) => {
40
+ if (e.length === 0) return n;
41
+ let i = (t) => p(e[t].color, r)?.toRGBA() ?? null;
42
+ if (e.length === 1) {
43
+ let e = i(0);
44
+ return e ? x(e.red, e.green, e.blue) : n;
45
+ }
46
+ let a = t * (e.length - 1), o = Math.min(Math.floor(a), e.length - 2), s = a - o, c = i(o), l = i(o + 1);
47
+ if (!c || !l) return n;
48
+ let u = (e, t) => Math.round(e + (t - e) * s);
49
+ return x(u(c.red, l.red), u(c.green, l.green), u(c.blue, l.blue));
50
+ }, C = (e, t, n = null) => Array.from({ length: 5 }, (r, i) => u(f, { sx: {
51
+ width: "100%",
52
+ height: "100%",
53
+ backgroundColor: S(e, i / 4, t, n)
54
+ } })), w = [
55
+ 70,
56
+ 100,
57
+ 20,
58
+ 50,
59
+ 90
60
+ ], T = (e, t, n) => {
61
+ let r = e.direction === "rightToLeft";
62
+ return w.map((i) => u(f, {
63
+ sx: {
64
+ width: "100%",
65
+ height: "100%",
66
+ display: "flex",
67
+ alignItems: "center",
68
+ justifyContent: r ? "flex-end" : "flex-start"
69
+ },
70
+ children: u(f, { sx: {
71
+ width: `${i}%`,
72
+ height: "100%",
73
+ boxSizing: "border-box",
74
+ background: e.gradient ? `linear-gradient(to ${r ? "left" : "right"}, ${t}, transparent)` : t,
75
+ border: `1px solid ${n ?? t}`,
76
+ borderRadius: "1px"
77
+ } })
78
+ }));
79
+ }, E = o((e) => {
80
+ let { rows: n, ...r } = e, i = t(), o = (e, t) => ({
81
+ borderRight: +(t < 2),
82
+ borderBottom: +(e < n.length - 1),
83
+ borderColor: g,
84
+ minWidth: 0,
85
+ overflow: "hidden",
86
+ display: "flex",
87
+ alignItems: "center"
88
+ });
89
+ return u(f, {
90
+ className: "sxl-cf-scale-mini-grid",
91
+ "data-sxl-theme-surface": "grid",
92
+ "data-sxl-theme-mode": i,
93
+ sx: {
94
+ display: "grid",
95
+ backgroundColor: h,
96
+ gridTemplateColumns: "10% 80% 10%",
97
+ gridTemplateRows: `repeat(${n.length}, minmax(0, 1fr))`,
98
+ width: "100%",
99
+ height: "100%"
100
+ },
101
+ ...r,
102
+ children: n.map((e, t) => d(a, { children: [
103
+ u(f, { sx: o(t, 0) }),
104
+ u(f, {
105
+ sx: o(t, 1),
106
+ children: e
107
+ }),
108
+ u(f, { sx: o(t, 2) })
109
+ ] }, t))
110
+ });
111
+ });
112
+ E.displayName = "ScaleMiniGrid";
113
+ var D = o((e) => {
114
+ let { title: n, sheet: r, disabled: i, sx: a, className: o, children: s, ...c } = e, d = t(), p = !!c.onClick, m = u(f, {
115
+ component: p ? "button" : "div",
116
+ ...p ? { disabled: i } : null,
117
+ className: o ? `sxl-cf-preset-chip ${o}` : "sxl-cf-preset-chip",
118
+ ...r ? {
119
+ "data-sxl-theme-surface": "grid",
120
+ "data-sxl-theme-mode": d
121
+ } : null,
122
+ sx: {
123
+ width: "34px",
124
+ height: "26px",
125
+ padding: 0,
126
+ flex: "0 0 auto",
127
+ display: "flex",
128
+ alignItems: "center",
129
+ justifyContent: "center",
130
+ overflow: "hidden",
131
+ background: r ? h : "none",
132
+ color: r ? v : void 0,
133
+ border: (e) => `1px solid ${r ? g : e.palette.divider}`,
134
+ borderRadius: 1,
135
+ fontSize: "12px",
136
+ lineHeight: 1,
137
+ ...p ? {
138
+ cursor: "pointer",
139
+ "&:hover": { borderColor: "primary.main" },
140
+ "&:disabled": { cursor: "default" }
141
+ } : null,
142
+ ...a
143
+ },
144
+ ...c,
145
+ children: s
146
+ });
147
+ return n ? u(l, {
148
+ disableInteractive: !0,
149
+ title: n,
150
+ children: u(f, {
151
+ component: "span",
152
+ sx: {
153
+ display: "inline-flex",
154
+ flex: "0 0 auto"
155
+ },
156
+ children: m
157
+ })
158
+ }) : m;
159
+ });
160
+ D.displayName = "PresetChip";
161
+ export { v as a, T as c, y as i, p as l, _ as n, E as o, h as r, C as s, D as t, m as u };
@@ -1,11 +1,11 @@
1
1
  /**
2
- * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.10
2
+ * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.11
3
3
  *
4
4
  * (C) 2026-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
6
6
  */
7
- import { t as e } from "./Biy7bhzzzPb5sfRN.mjs";
8
- import { n as t } from "./fb126BNj3F8URR19.mjs";
7
+ import { n as e } from "./DDc6rDuU9JAo1DH_.mjs";
8
+ import { InputField as t } from "./index.mjs";
9
9
  import { useReferenceMode as n } from "@sheetxl/react";
10
10
  import { useCallbackRef as r, useTranslator as i } from "@sheetxl/utils-react";
11
11
  import { memo as a, useCallback as o, useMemo as s, useState as c } from "react";
@@ -86,7 +86,7 @@ var p = ["Ok", "Cancel"], m = a((a) => {
86
86
  range: "flex",
87
87
  flexDirection: "column"
88
88
  },
89
- children: [u(e, {
89
+ children: [u(t, {
90
90
  sx: { paddingTop: (e) => e.spacing(1.5) },
91
91
  formName: "name",
92
92
  defaultInput: E,
@@ -96,7 +96,7 @@ var p = ["Ok", "Cancel"], m = a((a) => {
96
96
  onFocus: (e) => {
97
97
  M || e.target?.select(), N(!0);
98
98
  }
99
- }), u(t, {
99
+ }), u(e, {
100
100
  grammar: "reference",
101
101
  formName: "range",
102
102
  value: A.displayValue,
@@ -0,0 +1,381 @@
1
+ /**
2
+ * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.11
3
+ *
4
+ * (C) 2026-present SheetXL Inc. & Michael T. Ford
5
+ * License: The license can be found at https://www.sheetxl.com/license.
6
+ */
7
+ import { t as e } from "./ClBvNPeNCAhuVWrG.mjs";
8
+ import { n as t } from "./DG21x7RKDpge6zAE.mjs";
9
+ import { i as n, n as r, t as i } from "./BokqKEpU6TFgfRs6.mjs";
10
+ import { t as a } from "./CynTY0oNtyJnoaBq.mjs";
11
+ import { n as o, r as s, t as c } from "./CTjqDD-swFMZzI-Y.mjs";
12
+ import { DynamicIcon as l, NotifierType as u, useNotifier as d, useTranslator as f } from "@sheetxl/utils-react";
13
+ import { forwardRef as p, memo as m, useCallback as h, useEffect as g, useMemo as _, useReducer as ee, useRef as v, useState as y } from "react";
14
+ import { SimpleTooltip as te } from "@sheetxl/utils-mui";
15
+ import { jsx as b, jsxs as x } from "react/jsx-runtime";
16
+ import { Box as S, Button as C, IconButton as ne, Typography as w } from "@mui/material";
17
+ var T = m((t) => {
18
+ let { children: r, messageKeys: i, onSave: o, onCancel: s, className: c, ...l } = t, u = f(), d = v(/* @__PURE__ */ new Set()), p = _(() => ({ register: (e) => (d.current.add(e), () => {
19
+ d.current.delete(e);
20
+ }) }), []), m = h(() => {
21
+ let e = !0;
22
+ for (let t of Array.from(d.current)) t() || (e = !1);
23
+ e && o();
24
+ }, [o]), g = _(() => e("sxl-items-editor", "sxl-anchor-items-editor", c, {}, n.editor), [c]);
25
+ return x(S, {
26
+ sx: {
27
+ display: "flex",
28
+ flexDirection: "column",
29
+ justifyContent: "space-between",
30
+ height: "100%",
31
+ gap: (e) => e.spacing(2)
32
+ },
33
+ ...l,
34
+ className: g,
35
+ children: [b(a.Provider, {
36
+ value: p,
37
+ children: r
38
+ }), b(S, {
39
+ className: n["editor-buttons"],
40
+ sx: {
41
+ gap: (e) => e.spacing(1),
42
+ paddingTop: (e) => e.spacing(2),
43
+ borderTop: (e) => `1px solid ${e.palette.divider}`
44
+ },
45
+ children: x(S, {
46
+ sx: {
47
+ display: "grid",
48
+ gridAutoFlow: "column",
49
+ gridAutoColumns: "1fr",
50
+ gap: (e) => e.spacing(1)
51
+ },
52
+ children: [b(C, {
53
+ variant: "outlined",
54
+ onClick: s,
55
+ children: u(i.cancel)
56
+ }), b(C, {
57
+ variant: "contained",
58
+ onClick: m,
59
+ children: u(i.save)
60
+ })]
61
+ })
62
+ })]
63
+ });
64
+ });
65
+ T.displayName = "EditorPanel";
66
+ var E = .5, re = 0, D = /* @__PURE__ */ new WeakMap(), O = m(p((a, p) => {
67
+ let { title: m, workbook: O, descriptor: k, args: A, headerActions: j, listActions: M, dragReorder: ie = !1, className: N, ...P } = a, F = f(), I = d(), L = k.messageKeys, R = _(() => {
68
+ let { createDraft: e, save: t, EditorBody: n } = k;
69
+ return e && t && n && L.cancel && L.save ? {
70
+ createDraft: e,
71
+ commit: t,
72
+ EditorBody: n,
73
+ keys: {
74
+ cancel: L.cancel,
75
+ save: L.save
76
+ }
77
+ } : null;
78
+ }, [k, L]), [z, B] = y(!1), [V, H] = y(null), [U, ae] = y(""), W = v(null), G = v(null), [oe, K] = ee((e) => e + 1, 0);
79
+ g(() => k.subscribe(O, {
80
+ onChange: () => K(),
81
+ onInvalidated: () => {
82
+ H(null), K();
83
+ }
84
+ }), [O, k]);
85
+ let q = v(void 0);
86
+ g(() => {
87
+ if (q.current === A) return;
88
+ q.current = A;
89
+ let e = A?.draft;
90
+ try {
91
+ let t = null, n = null;
92
+ e === void 0 ? A?.insert && R && !k.isReadOnly(O) ? t = R.createDraft(O) : A?.edit !== void 0 && R && !k.isReadOnly(O) && (n = A.edit, t = R.createDraft(O, n)) : k.isReadOnly(O) || (t = k.createSeededDraft?.(O, e) ?? null), t && H({
93
+ draft: t,
94
+ target: n
95
+ });
96
+ } catch (e) {
97
+ I.showMessage?.(e.message, { type: u.Error });
98
+ }
99
+ }, [
100
+ A,
101
+ O,
102
+ k,
103
+ R,
104
+ I
105
+ ]);
106
+ let J = v(O);
107
+ J.current !== O && (J.current = O, V !== null && H(null));
108
+ let Y = k.isReadOnly(O), X = !Y && R !== null, Z = ie && !Y && !!k.moveBy, Q = v(!1);
109
+ s(G, Z, Q);
110
+ let $ = h((e, t) => {
111
+ let n = k.getItems(O)[e];
112
+ if (n !== void 0) {
113
+ Q.current = !0;
114
+ try {
115
+ k.moveBy(n, t - e, O);
116
+ } catch (e) {
117
+ Q.current = !1, I.showMessage?.(e.message, { type: u.Error });
118
+ }
119
+ }
120
+ }, [
121
+ k,
122
+ O,
123
+ I
124
+ ]), se = h(async () => {
125
+ if (V && R) {
126
+ try {
127
+ await k.beforeSave?.(V.draft);
128
+ let e = k.validate?.(V.draft) ?? null;
129
+ if (e) return void I.showMessage?.(F(e), { type: u.Error });
130
+ await R.commit(O, V.draft, V.target);
131
+ } catch (e) {
132
+ I.showMessage?.(e.message, { type: u.Error });
133
+ return;
134
+ }
135
+ H(null);
136
+ }
137
+ }, [
138
+ V,
139
+ k,
140
+ R,
141
+ O,
142
+ I,
143
+ F
144
+ ]), ce = _(() => {
145
+ let e = k.getItems(O), t = !!k.getSearchText, n = t ? U.trim().toLowerCase() : "", a = n ? e.filter((e) => k.getSearchText(e, F).toLowerCase().includes(n)) : e, s = Z && !n, d = [];
146
+ if (e.length === 0) return d.push(b(S, { sx: { flex: "1 1 0" } }, "spacer-top")), d.push(x(S, {
147
+ sx: {
148
+ display: "flex",
149
+ flex: "0 0 auto",
150
+ flexDirection: "column",
151
+ alignItems: "center",
152
+ alignSelf: "center",
153
+ gap: (e) => e.spacing(2.5),
154
+ maxWidth: "min(360px, 90%)"
155
+ },
156
+ children: [b(w, {
157
+ variant: "body2",
158
+ align: "center",
159
+ children: X && L.addPrompt ? F(L.addPrompt) : F(L.none)
160
+ }), X && L.new && b(C, {
161
+ variant: "contained",
162
+ sx: { textTransform: "none" },
163
+ onClick: () => {
164
+ H({
165
+ draft: R.createDraft(O),
166
+ target: null
167
+ });
168
+ },
169
+ children: F(L.new)
170
+ })]
171
+ }, "no-items")), d.push(b(S, { sx: { flex: "1.5 1 0" } }, "spacer-bottom")), (j || M) && d.unshift(x(S, {
172
+ sx: {
173
+ display: "flex",
174
+ alignItems: "center",
175
+ justifyContent: "flex-end",
176
+ flex: "0 0 auto"
177
+ },
178
+ children: [j, M]
179
+ }, "header-actions")), d;
180
+ if (d.push(x(S, {
181
+ sx: {
182
+ display: "flex",
183
+ alignItems: "center",
184
+ justifyContent: "center"
185
+ },
186
+ children: [
187
+ b(S, {
188
+ sx: { flex: "1 1 100%" },
189
+ children: L.heading ? b(w, {
190
+ variant: "body2",
191
+ children: F(L.heading)
192
+ }) : null
193
+ }),
194
+ j,
195
+ X && L.insert && b(te, {
196
+ disableInteractive: !0,
197
+ title: F(L.insert),
198
+ children: b(ne, {
199
+ onClick: (e) => {
200
+ e.stopPropagation(), H({
201
+ draft: R.createDraft(O),
202
+ target: null
203
+ });
204
+ },
205
+ children: b(l, { iconKey: "Insert" })
206
+ })
207
+ }, "add-new")
208
+ ]
209
+ }, "add-new")), t && d.push(b(i, {
210
+ value: U,
211
+ onChange: ae,
212
+ placeholder: L.search ? F(L.search) : void 0,
213
+ clearLabel: L.clearSearch ? F(L.clearSearch) : void 0,
214
+ sx: {
215
+ flexShrink: 0,
216
+ mx: E
217
+ }
218
+ }, "search")), M && d.push(b(S, {
219
+ sx: {
220
+ display: "flex",
221
+ alignItems: "center",
222
+ justifyContent: "flex-end",
223
+ flex: "0 0 auto",
224
+ mx: E,
225
+ mt: -.5
226
+ },
227
+ children: M
228
+ }, "list-actions")), a.length === 0) return d.push(b(S, { sx: { flex: "1 1 0" } }, "spacer-top")), d.push(b(w, {
229
+ variant: "body2",
230
+ align: "center",
231
+ sx: {
232
+ color: "text.secondary",
233
+ alignSelf: "center",
234
+ maxWidth: "min(360px, 90%)"
235
+ },
236
+ children: L.noMatches ? F(L.noMatches) : null
237
+ }, "no-matches")), d.push(b(S, { sx: { flex: "1.5 1 0" } }, "spacer-bottom")), d;
238
+ let f = a.map((e) => k.getItemKey?.(e) ?? ((e) => {
239
+ let t = D.get(e);
240
+ return t === void 0 && (t = "item-" + re++, D.set(e, t)), t;
241
+ })(e)), p = [];
242
+ a.forEach((t, i) => {
243
+ let a = k.isItemReadOnly?.(t, O) ?? Y, o = n ? e.indexOf(t) : i, l = b(r, {
244
+ item: t,
245
+ messageKeys: L,
246
+ title: k.getCardTitle(t, F),
247
+ subtitle: k.getCardSubtitle?.(t, F),
248
+ Subtitle: k.CardSubtitle,
249
+ readOnly: a,
250
+ canMoveUp: o > 0,
251
+ canMoveDown: o < e.length - 1,
252
+ onMoveBy: k.moveBy ? (e) => k.moveBy(t, e, O) : void 0,
253
+ onDuplicate: k.duplicate ? () => {
254
+ try {
255
+ k.duplicate(t, O);
256
+ } catch (e) {
257
+ I.showMessage?.(e.message, { type: u.Error });
258
+ }
259
+ } : void 0,
260
+ onDelete: () => {
261
+ try {
262
+ k.delete(t, O);
263
+ } catch (e) {
264
+ I.showMessage?.(e.message, { type: u.Error });
265
+ }
266
+ },
267
+ onEdit: R ? () => H({
268
+ draft: R.createDraft(O, t),
269
+ target: t
270
+ }) : void 0,
271
+ onSelect: k.select ? () => {
272
+ try {
273
+ k.select(t, O);
274
+ } catch (e) {
275
+ I.showMessage?.(e.message, { type: u.Error });
276
+ }
277
+ } : void 0,
278
+ subscribeItem: k.subscribeItem,
279
+ Media: k.CardMedia,
280
+ Body: k.CardBody
281
+ }, f[i]);
282
+ p.push(s ? b(c, {
283
+ id: f[i],
284
+ disabled: a,
285
+ children: l
286
+ }, f[i]) : l);
287
+ });
288
+ let m = b(S, {
289
+ ref: G,
290
+ sx: {
291
+ display: "flex",
292
+ flex: "1 1 auto",
293
+ flexDirection: "column",
294
+ overflowY: "auto",
295
+ overflowX: "visible",
296
+ paddingLeft: (e) => e.spacing(E),
297
+ paddingRight: (e) => e.spacing(E),
298
+ paddingTop: (e) => e.spacing(E),
299
+ paddingBottom: (e) => e.spacing(E),
300
+ gap: (e) => e.spacing(1.5)
301
+ },
302
+ children: p
303
+ }, "list-container");
304
+ return d.push(s ? b(o, {
305
+ ids: f,
306
+ onMove: $,
307
+ scrollRef: G,
308
+ children: m
309
+ }, "list-container") : m), d;
310
+ }, [
311
+ oe,
312
+ F,
313
+ Y,
314
+ X,
315
+ R,
316
+ O,
317
+ k,
318
+ j,
319
+ M,
320
+ I,
321
+ Z,
322
+ $,
323
+ U
324
+ ]), le = _(() => e("sxl-items-details", "sxl-anchor-items-details", `sxl-${k.key}-details`, N, {
325
+ editing: V !== null,
326
+ "sxl-has-focus": z,
327
+ "sxl-read-only": Y
328
+ }, n["details-panel"]), [
329
+ N,
330
+ z,
331
+ Y,
332
+ V,
333
+ k
334
+ ]), ue = t([W, p]);
335
+ if (V !== null && R) {
336
+ let e = R.EditorBody;
337
+ return b(S, {
338
+ onFocus: () => B(!0),
339
+ onBlur: (e) => {
340
+ W?.current?.contains(e.relatedTarget) || B(!1);
341
+ },
342
+ ref: ue,
343
+ sx: {
344
+ paddingLeft: (e) => e.spacing(1.5),
345
+ paddingRight: (e) => e.spacing(1.5),
346
+ paddingTop: (e) => e.spacing(1.5),
347
+ paddingBottom: (e) => e.spacing(1.5)
348
+ },
349
+ className: le,
350
+ ...P,
351
+ children: b(T, {
352
+ messageKeys: R.keys,
353
+ onSave: se,
354
+ onCancel: () => H(null),
355
+ children: b(e, {
356
+ draft: V.draft,
357
+ workbook: O
358
+ })
359
+ })
360
+ });
361
+ }
362
+ return b(S, {
363
+ onFocus: () => B(!0),
364
+ onBlur: (e) => {
365
+ W?.current?.contains(e.relatedTarget) || B(!1);
366
+ },
367
+ ref: ue,
368
+ sx: {
369
+ gap: (e) => e.spacing(1),
370
+ paddingLeft: (e) => e.spacing(1.5),
371
+ paddingRight: (e) => e.spacing(1.5),
372
+ paddingTop: (e) => e.spacing(1.5),
373
+ paddingBottom: (e) => e.spacing(1.5)
374
+ },
375
+ className: le,
376
+ ...P,
377
+ children: ce
378
+ });
379
+ }));
380
+ O.displayName = "ItemsPanel";
381
+ export { O as t };
@@ -1,11 +1,11 @@
1
1
  /**
2
- * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.10
2
+ * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.11
3
3
  *
4
4
  * (C) 2026-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
6
6
  */
7
- import { c as e, t } from "./sam1KGQZ59B_fADz.mjs";
8
- import { t as n } from "./IQLeaAbtGTipUsOD.mjs";
7
+ import { c as e, t } from "./BvhYPwX3GrRaO9CM.mjs";
8
+ import { t as n } from "./zqilJefihVd7At2T.mjs";
9
9
  import { IFill as r, ShapeStyleUtils as i } from "@sheetxl/sdk";
10
10
  import { useGridColorScheme as a } from "@sheetxl/react";
11
11
  import { useTranslator as o } from "@sheetxl/utils-react";
@@ -1,10 +1,10 @@
1
1
  /**
2
- * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.10
2
+ * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.11
3
3
  *
4
4
  * (C) 2026-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
6
6
  */
7
- import { i as e, n as t, r as n } from "./CIu1bjPJe_x31Oww.mjs";
7
+ import { i as e, n as t, r as n } from "./COlZu93LRwuBvjE-.mjs";
8
8
  import { useReferenceMode as r, useWorkbook as i } from "@sheetxl/react";
9
9
  import { useCallbackRef as a, useTranslator as o } from "@sheetxl/utils-react";
10
10
  import { memo as s, useMemo as c, useRef as l, useState as u } from "react";
@@ -16,10 +16,10 @@ var m = s((s) => {
16
16
  E,
17
17
  w
18
18
  ]), N = b ?? M[0], P = f(N), [F] = u(() => {
19
- let e = T?.getSelectedSheet()?.getSelectedCell();
19
+ let e = T?.getSelectedWorksheet()?.getSelectedCell();
20
20
  return e ? {
21
21
  ...e.getCoords(),
22
- scope: e.getSheet().getName()
22
+ scope: e.getWorksheet().getName()
23
23
  } : void 0;
24
24
  }), I = !!r().getMode()?.activeInput, L = l(!1), R = a((e, n, r) => {
25
25
  if (n || e !== t.Next) {
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.10
2
+ * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.11
3
3
  *
4
4
  * (C) 2026-present SheetXL Inc. & Michael T. Ford
5
5
  * License: The license can be found at https://www.sheetxl.com/license.
@@ -44,27 +44,29 @@ var d = ["Ok"], f = [
44
44
  value: (n[e.Error] ?? 0).toLocaleString()
45
45
  }
46
46
  ];
47
- }, r = t.getSelectedSheet(), i = r.getUsedRange()?.getCoords(), a = i ? r.getRange({
48
- rowStart: i.rowEnd,
49
- colStart: i.colEnd,
50
- rowEnd: i.rowEnd,
51
- colEnd: i.colEnd
52
- }).getAddress() : "–";
53
- return [{
54
- titleKey: u("workbookStatistics.currentSheet"),
55
- subTitle: r.getName(),
56
- rows: [{
57
- labelKey: u("workbookStatistics.endOfSheet"),
58
- value: a
59
- }, ...n(r.getStats({ onError: "ignore" }))]
60
- }, {
47
+ }, r = {
61
48
  titleKey: u("workbookStatistics.workbook"),
62
49
  subTitle: null,
63
50
  rows: [{
64
51
  labelKey: u("workbookStatistics.sheets"),
65
- value: t.getSheets().getCount().toLocaleString()
52
+ value: t.getWorksheets().getCount().toLocaleString()
66
53
  }, ...n(t.getStats({ onError: "ignore" }))]
67
- }];
54
+ }, i = t.getSelectedWorksheet();
55
+ if (!i) return [r];
56
+ let a = i.getUsedRange()?.getCoords(), o = a ? i.getRange({
57
+ rowStart: a.rowEnd,
58
+ colStart: a.colEnd,
59
+ rowEnd: a.rowEnd,
60
+ colEnd: a.colEnd
61
+ }).getAddress() : "–";
62
+ return [{
63
+ titleKey: u("workbookStatistics.currentSheet"),
64
+ subTitle: i.getName(),
65
+ rows: [{
66
+ labelKey: u("workbookStatistics.endOfSheet"),
67
+ value: o
68
+ }, ...n(i.getStats({ onError: "ignore" }))]
69
+ }, r];
68
70
  }, [p]);
69
71
  return o(a, {
70
72
  title: y("workbookStatistics.title"),