@sheetxl/studio-mui 0.8.0-beta.5 → 0.8.0-beta.7

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 (91) hide show
  1. package/browser/cjs/{Bi26L7L89ZK_y5Pk.cjs → 2tG9HJLr-WjsOCP3.cjs} +1 -1
  2. package/browser/cjs/{BGvoJjUs21bbuE1i.cjs → 3RXtLkq7wTAV6y_e.cjs} +1 -1
  3. package/browser/cjs/4_Zy3pR6YXkzISoK.cjs +1 -0
  4. package/browser/cjs/{BXkdjAb4jpTr412c.cjs → BD50lsTki7wvzb5g.cjs} +1 -1
  5. package/browser/cjs/BcBrhEv9acaTxPkO.cjs +13 -0
  6. package/browser/cjs/ByIUHPOa02D7XbdC.cjs +1 -0
  7. package/browser/cjs/{eCw4rAEIYE3BftpG.cjs → CkroJ2FmfFvk6Eyv.cjs} +1 -1
  8. package/browser/cjs/Clzu4HOXk3QSlzUD.cjs +8 -0
  9. package/browser/cjs/{B9GcCj7sj8XdjPZF.cjs → CzJvR12QCQb-0Rtn.cjs} +1 -1
  10. package/browser/cjs/{3uprnzi2l0iT17Dg.cjs → D-Yo5aV9STT5KH4G.cjs} +1 -1
  11. package/browser/cjs/{BHb7TnK1NmimV4OX.cjs → DwkiLFWUtLC8ZcIQ.cjs} +1 -1
  12. package/browser/cjs/{BQMCM3iFn4MNWAkB.cjs → HuPFsmz7kyZVo3c7.cjs} +1 -1
  13. package/browser/cjs/index.cjs +1 -1
  14. package/browser/esm/{GZvjjMyv09_4zahu.mjs → 0Rpk1T56LoSnDrmq.mjs} +2 -2
  15. package/browser/esm/{C2Ja33FV0pE1u_b4.mjs → 3L04oqyfyjRxhmzg.mjs} +2 -2
  16. package/browser/esm/7gisHVXYgcPxWH8-.mjs +223 -0
  17. package/browser/esm/{Ot_3uk9g5RQpAjcQ.mjs → B57WM1X24rsvTF_o.mjs} +1 -1
  18. package/browser/esm/{ZLszpvKCQ6ZVPKdC.mjs → B7k8enrhC2Rvqhn1.mjs} +3 -3
  19. package/browser/esm/{C828ANqeXNxG8adc.mjs → BK4OEmeaw-kC-vAN.mjs} +1345 -1307
  20. package/browser/esm/{0RwF0cH7JQ-VqL4E.mjs → BWAIbfQZ6h5xVLdB.mjs} +1 -1
  21. package/browser/esm/{26__l2vZsdgD-nJx.mjs → B_PhUn6yySwXt2wo.mjs} +2 -2
  22. package/browser/esm/{DkuGZXKiwLKsUN_D.mjs → C36WT3I3aIR8y7I6.mjs} +2 -2
  23. package/browser/esm/{DDYeKYs_XIOjhieg.mjs → CH7ZfljN7ru0Y9Wg.mjs} +2 -2
  24. package/browser/esm/{aNqEbtO2cALJwwos.mjs → CpTqhDZotYaKGbLl.mjs} +1 -1
  25. package/browser/esm/{ONmBo80X5eV6cBBI.mjs → D3BwGfI_IEjay0dA.mjs} +1 -1
  26. package/browser/esm/{DFQo3TQ5Lpt6_Vid.mjs → D7HOLngE_1FYF6y6.mjs} +3 -3
  27. package/browser/esm/{P8cqCkmugGNd2vkm.mjs → D88iVsgfDG9k-qf_.mjs} +3 -3
  28. package/browser/esm/{CfwoCDjpHNheDLn1.mjs → DErAKw-lIK3RY8m-.mjs} +1 -1
  29. package/browser/esm/{bC4EbB4OILhPseb3.mjs → DNhLiDpvz3lAR190.mjs} +2 -2
  30. package/browser/esm/{DG26kflIdO_PIeNZ.mjs → DR95Rgl8ItgWla8V.mjs} +2 -2
  31. package/browser/esm/{BDHzwq_DKJi-l3vm.mjs → DvYZOxsaTNeBKuFq.mjs} +98 -97
  32. package/browser/esm/{DkWV5seJEk7n5n4f.mjs → DyNZEBlugP-x15kP.mjs} +3 -3
  33. package/browser/esm/{BhUPwPyeqs6QNdfZ.mjs → DzWcb3yuPXS0E4_P.mjs} +3 -3
  34. package/browser/esm/{DFAzrYRM9N1LhRsL.mjs → WftYXVWvPKx99H0H.mjs} +2 -2
  35. package/browser/esm/{DzxWYVoWw4-RT-Ia.mjs → eoNyVUe5ZEpHwJ7k.mjs} +1 -1
  36. package/browser/esm/{FZXipbgDJzTXFMSX.mjs → hFLn30a6N1fEy7fz.mjs} +2225 -1546
  37. package/browser/esm/index.mjs +56 -56
  38. package/browser/esm/{D_kD4qmjhElkOeRw.mjs → jkFhDHWwKoyTSSDL.mjs} +1 -1
  39. package/node/esm/{CAe57GIDt8E3Sj1R.mjs → BTI9exTFHEYzVjw9.mjs} +1 -1
  40. package/node/esm/{BKpja0BXFbcWlnni.mjs → BbXHuDHRHOW_6Sbs.mjs} +1 -1
  41. package/node/esm/{6HLpHxyQNZYCN2_o.mjs → BlD3bHo8AAxK7O1j.mjs} +1 -1
  42. package/node/esm/{DCJNQumUzquqdCpn.mjs → CbpkRpNbQYYOJbxH.mjs} +3 -3
  43. package/node/esm/{DHVHJBTqBhlJQXpX.mjs → Ccrq9TNkiiSHKw-m.mjs} +1 -1
  44. package/node/esm/{aAEiFrxe-aYXbogR.mjs → CpteKzMPi39jxmYL.mjs} +1 -1
  45. package/node/esm/{4HI6dheaskyg9kLm.mjs → Cul_Vgip2OE8yFBQ.mjs} +1 -1
  46. package/node/esm/{CS307VndSoCLgQ-m.mjs → DA2gosTk8L-FUVI5.mjs} +1171 -1132
  47. package/node/esm/{BOsZituO28YENQvh.mjs → DP23-d6_VRFro0_D.mjs} +103 -102
  48. package/node/esm/{B9mtSfhFe3Hjcx9T.mjs → DQtpY5kX99aMHygs.mjs} +1 -1
  49. package/node/esm/{C4o3AryrtuiHuFLr.mjs → DifZAchLTKOmWpkv.mjs} +1 -1
  50. package/node/esm/{BT8pKXqqPi8PAXbL.mjs → Dvvg1Yo2e7OGd8sv.mjs} +1 -1
  51. package/node/esm/{COd_Ly7pt0y62C8c.mjs → YKY4d8_Ckc8nPQqI.mjs} +9 -9
  52. package/node/esm/index.mjs +3538 -2860
  53. package/node/esm/{B77SESbao6p6Y4Dy.mjs → lH1iFsECniBRMubb.mjs} +8 -8
  54. package/node/esm/{oAiHfSODZnkRxiTN.mjs → v0BFuYjhq2G8zDRe.mjs} +1 -1
  55. package/package.json +9 -9
  56. package/resources/locales/de/ui.msg.json +22 -4
  57. package/resources/locales/en/ui.msg.json +22 -4
  58. package/types/src/anchorItems/AnchorItemsDescriptor.d.ts +6 -0
  59. package/types/src/comments/CommentCard.d.ts +41 -0
  60. package/types/src/comments/CommentsPlugin.d.ts +6 -0
  61. package/types/src/comments/CommentsTaskPane.d.ts +23 -0
  62. package/types/src/comments/index.d.ts +4 -0
  63. package/types/src/conditions/BetweenOption.d.ts +5 -0
  64. package/types/src/conditions/ScalarOption.d.ts +18 -0
  65. package/types/src/dialog/index.d.ts +0 -1
  66. package/types/src/filter/FilterList.d.ts +3 -3
  67. package/types/src/form/FormulaField.d.ts +6 -0
  68. package/types/src/format/AlignmentPanel.d.ts +1 -2
  69. package/types/src/format/BorderPreview.d.ts +23 -13
  70. package/types/src/format/useFormatSelection.d.ts +3 -2
  71. package/types/src/index.d.ts +1 -0
  72. package/types/src/itemsPanel/EditorCommit.d.ts +32 -0
  73. package/types/src/itemsPanel/EditorPanel.d.ts +1 -2
  74. package/types/src/itemsPanel/ItemsDescriptor.d.ts +13 -0
  75. package/types/src/itemsPanel/index.d.ts +1 -0
  76. package/types/src/studio/StudioCommands.d.ts +2 -2
  77. package/types/src/studio/StudioProps.d.ts +1 -1
  78. package/types/src/studio/StudioSplitPane.d.ts +1 -1
  79. package/types/src/studio/useStudioApp.d.ts +2 -2
  80. package/types/src/template/useTemplateCatalog.d.ts +5 -5
  81. package/types/src/workbook/DefaultRenderers.d.ts +3 -1
  82. package/types/src/workbook/WorkbookElement.d.ts +1 -1
  83. package/browser/cjs/CucKgy044KxMHXrx.cjs +0 -13
  84. package/browser/cjs/Cy_XmYq6BsWmCXkk.cjs +0 -3
  85. package/browser/cjs/L0TaaQ9lceHCeg8C.cjs +0 -8
  86. package/browser/cjs/QI6GKw7uo1f8gY8C.cjs +0 -1
  87. package/browser/cjs/iFPhqab5w95hHEsT.cjs +0 -1
  88. package/browser/esm/BkCuNLKQc4KN4Ss4.mjs +0 -97
  89. package/browser/esm/CMBpd4LN1GYbtCdW.mjs +0 -222
  90. package/node/esm/r_EDiG9j1gFuHgF9.mjs +0 -98
  91. package/types/src/dialog/CommentsDialog.d.ts +0 -11
@@ -0,0 +1,223 @@
1
+ /**
2
+ * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.7
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 "./CpTqhDZotYaKGbLl.mjs";
8
+ import { useFormulaInput as t, useFormulaInputParts as n } from "@sheetxl/react";
9
+ import { DynamicIcon as r, useTranslator as i } from "@sheetxl/utils-react";
10
+ import a, { forwardRef as o, memo as s, useEffect as c, useId as ee, useImperativeHandle as te, useMemo as ne, useRef as l } from "react";
11
+ import { ExhibitIconButton as u } from "@sheetxl/utils-mui";
12
+ import { Fragment as re, jsx as d, jsxs as f } from "react/jsx-runtime";
13
+ import { Box as ie, FormControl as ae, InputAdornment as p, TextField as m } from "@mui/material";
14
+ var h = typeof window < "u" && window.HTMLElement !== void 0 && typeof document < "u";
15
+ a.createContext(null).displayName = "HookFormControlContext", h ? a.useLayoutEffect : a.useEffect;
16
+ var g = a.createContext(null);
17
+ g.displayName = "HookFormContext";
18
+ var _ = () => a.useContext(g), v = (e) => {
19
+ e.button === 0 && e.preventDefault();
20
+ }, y = "20px", b = "4px", x = `calc(${y} + ${b})`, S = s(o((a, o) => {
21
+ let { grammar: s = "formula", formName: h, formOptions: g, disabled: x, className: S, sx: C, onKeyDown: oe, onFocus: se, value: ce, onChangeInput: le, onChangeText: ue, onDone: w, changeOn: de, apiRef: fe, workbook: T, home: E, equals: pe, pickAs: me, pickSpills: he, allowMulti: ge, allowCrossSheet: _e, required: D, label: O, labelPlacement: k = "floating", placeholder: A, helperText: j, showError: M = !0, onChangeError: N, validationError: P, hideAdornment: F, classNameInput: I, argument: ve, id: ye, ...be } = a, L = i(), R = k === "above", xe = ee(), z = ye ?? xe, B = s === "formula", V = O === void 0 ? L(B ? "formulaInput.label" : "rangeInput.label") : O, Se = A ?? L(B ? "formulaInput.placeholder" : "rangeInput.placeholder"), H = _(), U = h && H ? H.register(h, g) : null, W = t({
22
+ value: ce,
23
+ onChange: le,
24
+ onChangeText: ue,
25
+ onDone: w,
26
+ changeOn: de,
27
+ workbook: T,
28
+ home: E,
29
+ equals: pe,
30
+ pickAs: me,
31
+ pickSpills: he,
32
+ allowMulti: ge,
33
+ allowCrossSheet: _e,
34
+ required: D,
35
+ disabled: x
36
+ }, s);
37
+ te(fe, () => W, [W]);
38
+ let G = n({
39
+ api: W,
40
+ grammar: s,
41
+ disabled: x,
42
+ workbook: T,
43
+ home: E,
44
+ argument: ve
45
+ }), K = !!W.error && !G.inputExpected, q = K || !!P, Ce = M && q ? L(K ? W.error : P) : j === void 0 ? " " : j, J = l(H);
46
+ J.current = H;
47
+ let Y = l(N);
48
+ Y.current = N;
49
+ let X = l(null), Z = K ? W.error : null, Q = l(null);
50
+ c(() => {
51
+ Z !== Q.current && (Q.current = Z, Y.current?.(Z));
52
+ }, [Z]), c(() => {
53
+ if (W.error === X.current || (X.current = W.error, !h)) return;
54
+ let e = J.current;
55
+ e && (W.error ? e.setError(h, { message: W.error }) : e.clearErrors(h));
56
+ }, [W.error, h]);
57
+ let $ = !!w, we = ne(() => F ? void 0 : d(p, {
58
+ tabIndex: -1,
59
+ onMouseDown: v,
60
+ sx: {
61
+ display: "flex",
62
+ position: "relative",
63
+ flex: "0"
64
+ },
65
+ position: "end",
66
+ children: W.engaged && $ ? f(re, { children: [d(u, {
67
+ dense: !0,
68
+ outlined: !1,
69
+ color: "primary",
70
+ "aria-label": "commit-reference",
71
+ icon: d(r, { iconKey: "CheckSuccess" }),
72
+ propsTooltip: {
73
+ label: L("referenceInput.commit"),
74
+ simple: !0
75
+ },
76
+ disabled: !!W.error,
77
+ tabIndex: -1,
78
+ onMouseDown: v,
79
+ onClick: () => {
80
+ W.commit();
81
+ }
82
+ }), d(u, {
83
+ dense: !0,
84
+ outlined: !1,
85
+ color: "warning",
86
+ "aria-label": "cancel-reference",
87
+ icon: d(r, { iconKey: "CloseError" }),
88
+ propsTooltip: {
89
+ label: L("referenceInput.cancel"),
90
+ simple: !0
91
+ },
92
+ tabIndex: -1,
93
+ onMouseDown: v,
94
+ onClick: () => {
95
+ W.cancel();
96
+ }
97
+ })] }) : d(u, {
98
+ dense: !0,
99
+ outlined: !1,
100
+ disabled: x || !W.canSelectCurrent,
101
+ sx: { "&.Mui-disabled": { opacity: .35 } },
102
+ "aria-label": "select-current-range",
103
+ icon: d(r, { iconKey: "SelectRangeMode" }),
104
+ propsTooltip: {
105
+ label: L("referenceInput.selectCurrent"),
106
+ simple: !0
107
+ },
108
+ tabIndex: -1,
109
+ onMouseDown: v,
110
+ onClick: () => {
111
+ W.engaged || W.togglePoint(), W.selectCurrent();
112
+ }
113
+ })
114
+ }), [
115
+ F,
116
+ x,
117
+ $,
118
+ W.engaged,
119
+ W.canSelectCurrent,
120
+ W.togglePoint,
121
+ W.selectCurrent,
122
+ W.commit,
123
+ W.cancel,
124
+ !!W.error
125
+ ]);
126
+ return f(ae, {
127
+ sx: {
128
+ minWidth: 135,
129
+ width: "100%",
130
+ ...C
131
+ },
132
+ size: "small",
133
+ ref: (e) => {
134
+ G.containerRef.current = e, typeof o == "function" ? o(e) : o && (o.current = e);
135
+ },
136
+ className: e("sxl-formula-field", S),
137
+ "data-grammar": s,
138
+ ...be,
139
+ children: [
140
+ R ? d(ie, {
141
+ component: "label",
142
+ htmlFor: z,
143
+ sx: {
144
+ lineHeight: y,
145
+ marginBottom: b,
146
+ paddingLeft: "14px",
147
+ display: "flex",
148
+ alignItems: "center",
149
+ gap: "4px",
150
+ overflow: "hidden",
151
+ whiteSpace: "nowrap",
152
+ fontSize: "0.8rem",
153
+ color: x ? "text.disabled" : "text.primary"
154
+ },
155
+ children: V
156
+ }) : null,
157
+ d(m, {
158
+ id: z,
159
+ label: R ? void 0 : V,
160
+ placeholder: Se,
161
+ disabled: x,
162
+ error: q,
163
+ helperText: Ce,
164
+ sx: { "& .MuiFormHelperText-root": {
165
+ marginTop: b,
166
+ ...R ? { lineHeight: y } : null
167
+ } },
168
+ slotProps: {
169
+ input: { endAdornment: we },
170
+ inputLabel: { shrink: !0 },
171
+ htmlInput: {
172
+ className: I,
173
+ spellCheck: !1,
174
+ autoComplete: "off",
175
+ readOnly: x || W.inputProps.readOnly,
176
+ name: h,
177
+ sx: {
178
+ paddingTop: (e) => e.spacing(R || V == null ? 1 : 1.25),
179
+ paddingBottom: (e) => e.spacing(R || V == null ? 1 : .75),
180
+ ...G.overlayActive ? {
181
+ color: "transparent",
182
+ caretColor: (e) => e.palette.text.primary
183
+ } : null
184
+ },
185
+ onSelect: (e) => {
186
+ W.inputProps.onSelect(e), G.inputHandlers.onSelect(e);
187
+ },
188
+ onScroll: G.inputHandlers.onScroll,
189
+ onMouseMove: G.inputHandlers.onMouseMove,
190
+ onMouseLeave: G.inputHandlers.onMouseLeave,
191
+ onDragStart: G.inputHandlers.onDragStart
192
+ }
193
+ },
194
+ value: W.inputProps.value,
195
+ inputRef: (e) => {
196
+ G.inputElRef.current = e, W.inputProps.ref(e), U?.ref && U.ref(e);
197
+ },
198
+ onChange: (e) => {
199
+ W.inputProps.onChange(e), G.inputHandlers.onSelect(e), U?.onChange(e);
200
+ },
201
+ onKeyDown: (e) => {
202
+ G.handleKeyDown(e) || (W.inputProps.onKeyDown(e), e.defaultPrevented || oe?.(e));
203
+ },
204
+ onPointerDown: G.inputHandlers.onPointerDown,
205
+ onMouseDown: W.inputProps.onMouseDown,
206
+ onFocus: (e) => {
207
+ W.inputProps.onFocus(e), se?.(e);
208
+ },
209
+ onBlur: (e) => {
210
+ W.inputProps.onBlur(e), U?.onBlur(e);
211
+ },
212
+ onContextMenu: (e) => {
213
+ e.stopPropagation();
214
+ }
215
+ }),
216
+ G.overlayElement,
217
+ G.tipElement,
218
+ G.hintElement
219
+ ]
220
+ });
221
+ }));
222
+ S.displayName = "FormulaField";
223
+ export { S as n, _ as r, x as t };
@@ -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.5
2
+ * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.7
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.
@@ -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.5
2
+ * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.8.0-beta.7
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 "./aNqEbtO2cALJwwos.mjs";
8
- import { r as t } from "./CMBpd4LN1GYbtCdW.mjs";
7
+ import { t as e } from "./CpTqhDZotYaKGbLl.mjs";
8
+ import { r as t } from "./7gisHVXYgcPxWH8-.mjs";
9
9
  import { useInputField as n } from "@sheetxl/react";
10
10
  import { DynamicIcon as r, useTextSelectionDrag as i, useTranslator as a } from "@sheetxl/utils-react";
11
11
  import { forwardRef as o, memo as s, useEffect as c, useImperativeHandle as l, useMemo as u, useRef as d } from "react";