@sheetxl/studio-mui 0.6.9 → 0.6.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 (38) hide show
  1. package/browser/cjs/{Dy8tMdAvieDNFyNN.cjs → BBBvXsvZhLgSqZNk.cjs} +1 -1
  2. package/browser/cjs/{DSWZ0c6YrATHKT05.cjs → BSvsMgB3H4B0xPda.cjs} +2 -2
  3. package/browser/cjs/{NYv7o9QPsXmI71mF.cjs → CfT2CEOLlhFLn0t3.cjs} +2 -2
  4. package/browser/cjs/{P_MTTr3k6LbqArTi.cjs → Ctx4ZIqNnlm0-3mu.cjs} +1 -1
  5. package/browser/cjs/{DQUtpkYC0M_fQv5_.cjs → Cxe156EXOARhhR5j.cjs} +1 -1
  6. package/browser/cjs/{StodJUERc9sXjDM3.cjs → D4v9fvs_6yA4xOQd.cjs} +2 -2
  7. package/browser/cjs/{CybaPr_tDqBYYm7l.cjs → DcqkEl49eLdpjRiH.cjs} +1 -1
  8. package/browser/cjs/{BMUK7WDOHjdCTlnL.cjs → DzUiVA1Ca2k-tCDH.cjs} +2 -2
  9. package/browser/cjs/{Bo0KAIoyc8wjrX0Z.cjs → R10YCGYxKY4kjzJl.cjs} +11 -11
  10. package/browser/cjs/{BK-SPf2iAdtY2v2r.cjs → _JFrRjH4em_qMvcy.cjs} +2 -2
  11. package/browser/cjs/index.cjs +2 -2
  12. package/browser/cjs/{LeRvKTH-iRno1m6n.cjs → rLmaAeAwi0EO7HAp.cjs} +3 -3
  13. package/browser/cjs/{D11dQP9ASVFsBy2m.cjs → v_pcA1TooWbzImY5.cjs} +1 -1
  14. package/browser/esm/{BrkDPL7uUPTUnJf1.mjs → BQ-6gxTFwCGDYAyE.mjs} +2 -2
  15. package/browser/esm/{CjX3_GVACz2x1KDj.mjs → BjrxQ8ayARGuy4Na.mjs} +1746 -1743
  16. package/browser/esm/{CQdHuWRKrc46Ov6t.mjs → BwnoyH0CHNe7vNCI.mjs} +1 -1
  17. package/browser/esm/{qGhUWftd5xiC-hxc.mjs → C1_z147Gjl1Zesw9.mjs} +1 -1
  18. package/browser/esm/{C-SjjwB782n9nBYJ.mjs → CmHfEjWLPuiA3VoA.mjs} +1 -1
  19. package/browser/esm/{q8P-1V6WnCy4m7sv.mjs → DYTXYx5ZA1TP5Oyq.mjs} +2 -2
  20. package/browser/esm/{CkNOojlllvYRHHW-.mjs → Rb1Pxn6UVOSOCM2w.mjs} +1 -1
  21. package/browser/esm/{oJGEc64Ccgag_PQZ.mjs → bBhoXacT6w7HfKrE.mjs} +2 -2
  22. package/browser/esm/{D0-6I_5PCSF8a7L7.mjs → gjdORpjyDLONRrqI.mjs} +1 -1
  23. package/browser/esm/index.mjs +2 -2
  24. package/browser/esm/{5ec1MS8QFxg_wTk6.mjs → qR9cLFUTo7EsaMOF.mjs} +3 -3
  25. package/browser/esm/{q6UgUqJldJL6n2-x.mjs → t475Bsje1XlSObvp.mjs} +2 -2
  26. package/browser/esm/{7bB6IyFR78AK_xsc.mjs → twFQzQkSGYrnkiBL.mjs} +2 -2
  27. package/node/esm/{BYoYizxJTZD7MEGg.mjs → B-qK-3UHgv6Eg1am.mjs} +1 -1
  28. package/node/esm/{BTK5i03GS-FeY98T.mjs → BRvede6q1RS-tV7I.mjs} +1 -1
  29. package/node/esm/{BVBW-cMRTjK6KVFg.mjs → BrRpZiTdCkp6XLJD.mjs} +1 -1
  30. package/node/esm/{CNeOpyGVrqmfLHyT.mjs → BsLOtrgn8geSSe4y.mjs} +1 -1
  31. package/node/esm/{D1dqpyBV7ZLrMRVk.mjs → BwYoiAGrXUMYTT6C.mjs} +1 -1
  32. package/node/esm/{cm-ecS0S68xhC_Yj.mjs → Bwh9njUvNl0ttDuA.mjs} +1 -1
  33. package/node/esm/{DeCgfM0e20R-VV0G.mjs → DKg0TuxCg7QCEAE_.mjs} +1 -1
  34. package/node/esm/{CLc5xV4p8QWx-rjD.mjs → DSdhIAo7VPb4M3-Q.mjs} +1 -1
  35. package/node/esm/{BTkpV3euK14xAUB8.mjs → DuwSZB7sC53vsrOv.mjs} +1 -1
  36. package/node/esm/index.mjs +380 -377
  37. package/node/esm/{BqgO5jB5pGXA3Hk4.mjs → qQDEISio0hvWk5Ti.mjs} +1 -1
  38. package/package.json +8 -8
@@ -1,5 +1,5 @@
1
1
  /**
2
- * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.6.9
2
+ * @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.6.11
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.
@@ -7,14 +7,14 @@
7
7
  import { Color as e, IColor as t, ITheme as o, CommonUtils as n, IBorder as a, IFont as r, NumberFormat as l, IFontCollection as i, IStyle as s, ITextFrame as d, Table as c, IFill as m, CoordUtils as p, ISheet as u, LicenseManager as g, Workbook as h, TypesUtils as f } from "@sheetxl/sdk";
8
8
  import { LicenseManager } from "@sheetxl/sdk";
9
9
  import { jsx as x, jsxs as b, Fragment as y } from "react/jsx-runtime";
10
- import w, { memo as k, forwardRef as S, useMemo as C, useCallback as v, isValidElement as T, useState as D, useEffect as P, Suspense as R, useRef as M, createElement as F, useReducer as B, useImperativeHandle as N, useLayoutEffect as A } from "react";
11
- import { Box as E, Typography as I, IconButton as L, MenuItem as H, Divider as W, Button as z, SvgIcon as $, Input as O, FormControlLabel as V, Checkbox as G, useMediaQuery as U, FormControl as j, TextField as _, InputAdornment as q, Slider as K, Paper as X, CircularProgress as Z, DialogTitle as J, Select as Y, Tabs as Q, Tab as ee, Card as te, CardActions as oe, Collapse as ne, CssBaseline as ae } from "@mui/material";
12
- import { themeIcon as re, CommandButton as le, ExhibitDivider as ie, FormatIndentDecreaseIcon as se, FormatIndentIncreaseIcon as de, defaultCreatePopupPanel as ce, CommandPopupButton as me, TextVerticalTopIcon as pe, TextVerticalCenterIcon as ue, TextVerticalBottomIcon as ge, TextHorizontalOverflowIcon as he, TextHorizontalWrapIcon as fe, TextHorizontalClipIcon as xe, TextHorizontalShrinkIcon as be, TextRotation315Icon as ye, TextRotation45Icon as we, TextRotation90Icon as ke, TextRotation2702Icon as Se, TextRotationCustomIcon as Ce, TextRotation0Icon as ve, InputCommandButton as Te, SimpleTooltip as De, LoadingPanel as Pe, PopupButtonType as Re, ExhibitPopupIconButton as Me, ExhibitPopupMenuItem as Fe, ColorizedCircleIcon as Be, ExhibitMenuItem as Ne, createStrokeShadowFilter as Ae, strokeShadowFilter as Ee, ColorizedStrokeIcon as Ie, ExhibitTooltip as Le, ExhibitIconButton as He, CommandTooltip as We, MergeAllIcon as ze, MergeHorizontalIcon as $e, MergeVerticalIcon as Oe, MergeUnMergeIcon as Ve, FreezeBothIcon as Ge, FreezeRowsIcon as Ue, FreezeColumnsIcon as je, FreezeIcon as _e, FindIcon as qe, FindReplaceIcon as Ke, GotoIcon as Xe, TextSizeIncreaseIcon as Ze, TextSizeDecreaseIcon as Je, SelectedIcon as Ye, CurrencyDollarIcon as Qe, PercentIcon as et, CommaIcon as tt, IncreaseDecimalIcon2 as ot, DecreaseDecimalIcon2 as nt, ClearAllIcon as at, ClearFormatsIcon as rt, ClearContentsIcon as lt, FillDownIcon as it, InsertCells as st, InsertRowIcon as dt, InsertColumn2Icon as ct, BlankIcon as mt, RemoveCellsIcon as pt, RemoveRowIcon as ut, RemoveColumn2Icon as gt, LabelIcon as ht, SortIncreaseIcon as ft, SortDecreaseIcon as xt, SortCustomIcon as bt, FilterToggleIcon as yt, FilterClearIcon as wt, FilterReapplyIcon as kt, RedoIcon as St, UndoIcon as Ct, TextStrikeIcon as vt, TextSuperscriptIcon as Tt, TextSubscriptIcon as Dt, TextUnderlineIcon as Pt, TextUnderlineDoubleIcon as Rt, TextUnderlineAccountingIcon as Mt, TextUnderlineAccountingDoubleIcon as Ft, PasteIcon as Bt, PasteValuesIcon as Nt, PasteFormatsIcon as At, PasteFormulasIcon as Et, PasteTransposeIcon as It, PasteLinksIcon as Lt, NewPresetStylesIcon as Ht, PresetStylesIcon as Wt, ExhibitMenuHeader as zt, ContextMenu as $t, Theme2Icon as Ot, SystemDefaultDarkMode as Vt, SystemDefaultLightMode as Gt, GithubIcon as Ut, DiscordIcon as jt, DocumentationIcon as _t, TicketIcon as qt, HelpIcon as Kt, InsertImageIcon as Xt, WalkingCopyIcon as Zt, SimpleCommandPopupButton as Jt, FunctionThinIcon as Yt, FunctionSumIcon as Qt, FormulaGroupIcon as eo, FormulaFinancialIcon as to, FormulaLogicalIcon as oo, FormulaTextIcon as no, FormulaDateTimeIcon as ao, FormulaLookupReferenceIcon as ro, FormulaMathTrigIcon as lo, FormulaStatisticalIcon as io, FormulaEngineeringIcon as so, FormulaInformationIcon as co, FormulaCubeIcon as mo, FormulaDatabaseIcon as po, FormulaWebIcon as uo, FormulaCustomIcon as go, ExhibitOptionButton as ho, SelectRangeModeIcon as fo, hexToRGB as xo, useFloatStack as bo, CellSelectionIcon as yo, CellSelectionRemoveIcon as wo, CellSelectionEditIcon as ko, InsertTableIcon as So, CellSelectionInsertIcon as Co, CloseErrorIcon as vo, CheckSuccessIcon as To, FunctionIcon as Do, VisibilityOffIcon as Po, elevateColor as Ro, ThemedIcon as Mo, ScriptNewIcon as Fo, ScriptFormulaIcon as Bo, ScriptMacroIcon as No, ScriptSaveIcon as Ao, CommandToolbar as Eo, CodeIcon as Io, ScriptRunIcon as Lo, ColorizedTextIcon as Ho, ColorizedFillIcon as Wo, FormatPaintIcon as zo, TextBoldIcon as $o, TextItalicIcon as Oo, InsertHyperlinkIcon as Vo, InsertCommentIcon as Go, FullScreenOffIcon as Uo, FullScreenIcon as jo, createScrollEdgeButton as _o, createScrollEndButton as qo, createScrollStartButton as Ko, HideColumnIcon as Xo, ShowColumnIcon as Zo, HideRowIcon as Jo, ShowRowIcon as Yo, ColumnsResizeAutoIcon as Qo, RowsResizeAutoIcon as en, CutIcon as tn, DrawAspectIcon as on, DrawAlignLeftIcon as nn, DrawResizeIcon as an, DrawAlignDistributeVertIcon as rn, DrawAlignDistributeHorzIcon as ln, DrawAlignBottomIcon as sn, DrawAlignMiddleIcon as dn, DrawAlignTopIcon as cn, DrawAlignRightIcon as mn, DrawAlignCenterIcon as pn, DrawMoveBackwardIcon as un, DrawToBackIcon as gn, DrawMoveForwardIcon as hn, DrawToFrontIcon as fn, scrollbarTheming as xn, StackTrace as bn, FileNewIcon as yn, FileOpenIcon as wn, FileDownloadAsCSVIcon as kn, FileDownloadAsExcelIcon as Sn, FileDownloadAsSheetIcon as Cn, useResolvedThemeMode as vn, ThemeMode as Tn, useModal as Dn, useLazyWindow as Pn, useOptionsDialog as Rn, useInputDialog as Mn, AnimatedTraversingEllipsisIcon as Fn, ErrorPanel as Bn, createExhibitTheme as Nn, ModalProvider as An, ErrorAlertIcon as En } from "@sheetxl/utils-mui";
10
+ import w, { memo as k, forwardRef as S, useMemo as C, useCallback as v, isValidElement as T, useState as D, useEffect as P, Suspense as R, useRef as M, createElement as F, useReducer as B, useImperativeHandle as N, useLayoutEffect as E } from "react";
11
+ import { Box as A, Typography as I, IconButton as L, MenuItem as H, Divider as W, Button as z, SvgIcon as $, Input as O, FormControlLabel as V, Checkbox as G, useMediaQuery as U, FormControl as j, TextField as _, InputAdornment as q, Slider as K, Paper as X, CircularProgress as Z, DialogTitle as J, Select as Y, Tabs as Q, Tab as ee, Card as te, CardActions as oe, Collapse as ne, CssBaseline as ae } from "@mui/material";
12
+ import { themeIcon as re, CommandButton as le, ExhibitDivider as ie, FormatIndentDecreaseIcon as se, FormatIndentIncreaseIcon as de, defaultCreatePopupPanel as ce, CommandPopupButton as me, TextVerticalTopIcon as pe, TextVerticalCenterIcon as ue, TextVerticalBottomIcon as ge, TextHorizontalOverflowIcon as he, TextHorizontalWrapIcon as fe, TextHorizontalClipIcon as xe, TextHorizontalShrinkIcon as be, TextRotation315Icon as ye, TextRotation45Icon as we, TextRotation90Icon as ke, TextRotation2702Icon as Se, TextRotationCustomIcon as Ce, TextRotation0Icon as ve, InputCommandButton as Te, SimpleTooltip as De, LoadingPanel as Pe, PopupButtonType as Re, ExhibitPopupIconButton as Me, ExhibitPopupMenuItem as Fe, ColorizedCircleIcon as Be, ExhibitMenuItem as Ne, createStrokeShadowFilter as Ee, strokeShadowFilter as Ae, ColorizedStrokeIcon as Ie, ExhibitTooltip as Le, ExhibitIconButton as He, CommandTooltip as We, MergeAllIcon as ze, MergeHorizontalIcon as $e, MergeVerticalIcon as Oe, MergeUnMergeIcon as Ve, FreezeBothIcon as Ge, FreezeRowsIcon as Ue, FreezeColumnsIcon as je, FreezeIcon as _e, FindIcon as qe, FindReplaceIcon as Ke, GotoIcon as Xe, TextSizeIncreaseIcon as Ze, TextSizeDecreaseIcon as Je, SelectedIcon as Ye, CurrencyDollarIcon as Qe, PercentIcon as et, CommaIcon as tt, IncreaseDecimalIcon2 as ot, DecreaseDecimalIcon2 as nt, ClearAllIcon as at, ClearFormatsIcon as rt, ClearContentsIcon as lt, FillDownIcon as it, InsertCells as st, InsertRowIcon as dt, InsertColumn2Icon as ct, BlankIcon as mt, RemoveCellsIcon as pt, RemoveRowIcon as ut, RemoveColumn2Icon as gt, LabelIcon as ht, SortIncreaseIcon as ft, SortDecreaseIcon as xt, SortCustomIcon as bt, FilterToggleIcon as yt, FilterClearIcon as wt, FilterReapplyIcon as kt, RedoIcon as St, UndoIcon as Ct, TextStrikeIcon as vt, TextSuperscriptIcon as Tt, TextSubscriptIcon as Dt, TextUnderlineIcon as Pt, TextUnderlineDoubleIcon as Rt, TextUnderlineAccountingIcon as Mt, TextUnderlineAccountingDoubleIcon as Ft, PasteIcon as Bt, PasteValuesIcon as Nt, PasteFormatsIcon as Et, PasteFormulasIcon as At, PasteTransposeIcon as It, PasteLinksIcon as Lt, NewPresetStylesIcon as Ht, PresetStylesIcon as Wt, ExhibitMenuHeader as zt, ContextMenu as $t, Theme2Icon as Ot, SystemDefaultDarkMode as Vt, SystemDefaultLightMode as Gt, GithubIcon as Ut, DiscordIcon as jt, DocumentationIcon as _t, TicketIcon as qt, HelpIcon as Kt, InsertImageIcon as Xt, WalkingCopyIcon as Zt, SimpleCommandPopupButton as Jt, FunctionThinIcon as Yt, FunctionSumIcon as Qt, FormulaGroupIcon as eo, FormulaFinancialIcon as to, FormulaLogicalIcon as oo, FormulaTextIcon as no, FormulaDateTimeIcon as ao, FormulaLookupReferenceIcon as ro, FormulaMathTrigIcon as lo, FormulaStatisticalIcon as io, FormulaEngineeringIcon as so, FormulaInformationIcon as co, FormulaCubeIcon as mo, FormulaDatabaseIcon as po, FormulaWebIcon as uo, FormulaCustomIcon as go, ExhibitOptionButton as ho, SelectRangeModeIcon as fo, hexToRGB as xo, useFloatStack as bo, CellSelectionIcon as yo, CellSelectionRemoveIcon as wo, CellSelectionEditIcon as ko, InsertTableIcon as So, CellSelectionInsertIcon as Co, CloseErrorIcon as vo, CheckSuccessIcon as To, FunctionIcon as Do, VisibilityOffIcon as Po, elevateColor as Ro, ThemedIcon as Mo, ScriptNewIcon as Fo, ScriptFormulaIcon as Bo, ScriptMacroIcon as No, ScriptSaveIcon as Eo, CommandToolbar as Ao, CodeIcon as Io, ScriptRunIcon as Lo, ColorizedTextIcon as Ho, ColorizedFillIcon as Wo, FormatPaintIcon as zo, TextBoldIcon as $o, TextItalicIcon as Oo, InsertHyperlinkIcon as Vo, InsertCommentIcon as Go, FullScreenOffIcon as Uo, FullScreenIcon as jo, createScrollEdgeButton as _o, createScrollEndButton as qo, createScrollStartButton as Ko, HideColumnIcon as Xo, ShowColumnIcon as Zo, HideRowIcon as Jo, ShowRowIcon as Yo, ColumnsResizeAutoIcon as Qo, RowsResizeAutoIcon as en, CutIcon as tn, DrawAspectIcon as on, DrawAlignLeftIcon as nn, DrawResizeIcon as an, DrawAlignDistributeVertIcon as rn, DrawAlignDistributeHorzIcon as ln, DrawAlignBottomIcon as sn, DrawAlignMiddleIcon as dn, DrawAlignTopIcon as cn, DrawAlignRightIcon as mn, DrawAlignCenterIcon as pn, DrawMoveBackwardIcon as un, DrawToBackIcon as gn, DrawMoveForwardIcon as hn, DrawToFrontIcon as fn, scrollbarTheming as xn, StackTrace as bn, FileNewIcon as yn, FileOpenIcon as wn, FileDownloadAsCSVIcon as kn, FileDownloadAsExcelIcon as Sn, FileDownloadAsSheetIcon as Cn, useResolvedThemeMode as vn, ThemeMode as Tn, useModal as Dn, useLazyWindow as Pn, useOptionsDialog as Rn, useInputDialog as Mn, AnimatedTraversingEllipsisIcon as Fn, ErrorPanel as Bn, createExhibitTheme as Nn, ModalProvider as En, ErrorAlertIcon as An } from "@sheetxl/utils-mui";
13
13
  import In from "clsx";
14
14
  import { FormatAlignLeft as Ln, FormatAlignCenter as Hn, FormatAlignRight as Wn, FormatAlignJustify as zn, Colorize as $n, DarkMode as On, LightMode as Vn, Keyboard as Gn, Remove as Un, Add as jn, ExpandLess as _n, ExpandMore as qn, Lock as Kn, MoreHoriz as Xn, WebhookOutlined as Zn, Close as Jn, AddCircleOutline as Yn, Menu as Qn, CancelOutlined as ea } from "@mui/icons-material";
15
15
  import { useCommands as ta, CommandButtonType as oa, useCallbackRef as na, ReactUtils as aa, KeyCodes as ra, useCommand as la, useEditMode as ia, useMouseDownAndHoldListener as sa, NotificationType as da, useImperativeElement as ca, SplitPane as ma, RoundedTab as pa, SimpleCommand as ua, Command as ga, KeyModifiers as ha, CommandGroup as fa, ToolTipPlacement as xa, ScrollPane as ba, useUndoManager as ya } from "@sheetxl/utils-react";
16
16
  import { useTheme as wa, alpha as ka, getOverlayAlpha as Sa, ThemeProvider as Ca } from "@mui/material/styles";
17
- import { StyledStrokePath as va, StaticBorderRenderer as Ta, FontUtils as Da, useModelListener as Pa, createCellEditStateFromCell as Ra, SheetCellEditor as Ma, ScriptEditor as Fa, useDocThemes as Ba, TabStrip as Na, SheetElement as Aa, SheetScrollbar as Ea, PictureEditor as Ia, ChartEditor as La, EmptyFrame as Ha, LogoNoPaddingIcon as Wa } from "@sheetxl/react";
17
+ import { StyledStrokePath as va, StaticBorderRenderer as Ta, FontUtils as Da, useModelListener as Pa, createCellEditStateFromCell as Ra, SheetCellEditor as Ma, ScriptEditor as Fa, useDocThemes as Ba, TabStrip as Na, SheetElement as Ea, SheetScrollbar as Aa, PictureEditor as Ia, ChartEditor as La, EmptyFrame as Ha, LogoNoPaddingIcon as Wa } from "@sheetxl/react";
18
18
  import { alpha as za } from "@mui/system";
19
19
  import { useFormContext as $a } from "react-hook-form";
20
20
  import { ResizableBox as Oa } from "react-resizable";
@@ -38,7 +38,7 @@ const tr = k(S((e2, t2) => {
38
38
  const e3 = { ...n2 };
39
39
  return delete e3.beforeExecute, e3;
40
40
  }, [n2]), p2 = v((e3, t3) => {
41
- const o3 = { variant: oa.Menuitem, commandHook: n2, scope: a2, disabled: r2 }, l3 = b(y, { children: [x(le, { ...o3, command: t3.getCommand("formatAlignLeftToggle"), icon: c2.get("formatAlignLeftToggle") }), x(le, { ...o3, command: t3.getCommand("formatAlignCenterToggle"), icon: c2.get("formatAlignCenterToggle") }), x(le, { ...o3, command: t3.getCommand("formatAlignRightToggle"), icon: c2.get("formatAlignRightToggle") }), x(le, { ...o3, command: t3.getCommand("formatAlignJustifyToggle"), icon: c2.get("formatAlignJustifyToggle") }), x(ie, { orientation: "horizontal" }), x(le, { ...o3, command: t3.getCommand("formatAlignCenterContinuousToggle"), icon: c2.get("formatAlignCenterContinuousToggle") }), x(le, { ...o3, command: t3.getCommand("formatAlignFillToggle"), icon: c2.get("formatAlignFillToggle") }), x(le, { ...o3, command: t3.getCommand("formatAlignDistributedHorizontalToggle"), icon: c2.get("formatAlignDistributedHorizontalToggle") })] }), s3 = b(E, { sx: { className: In("quick-buttons"), display: "flex", alignItems: "center", justifyContent: "center" }, onClick: (e4) => e4.stopPropagation(), children: [x(le, { command: t3.getCommand("formatIndentDecrease"), commandHook: m2, scope: a2, disabled: r2, icon: re(x(se, {})) }), x(le, { command: t3.getCommand("formatIndentIncrease"), commandHook: m2, scope: a2, disabled: r2, icon: re(x(de, {})) })] }), d3 = b(E, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, ...i2, children: [s3, x(ie, { orientation: "horizontal" }), x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: l3 })] });
41
+ const o3 = { variant: oa.Menuitem, commandHook: n2, scope: a2, disabled: r2 }, l3 = b(y, { children: [x(le, { ...o3, command: t3.getCommand("formatAlignLeftToggle"), icon: c2.get("formatAlignLeftToggle") }), x(le, { ...o3, command: t3.getCommand("formatAlignCenterToggle"), icon: c2.get("formatAlignCenterToggle") }), x(le, { ...o3, command: t3.getCommand("formatAlignRightToggle"), icon: c2.get("formatAlignRightToggle") }), x(le, { ...o3, command: t3.getCommand("formatAlignJustifyToggle"), icon: c2.get("formatAlignJustifyToggle") }), x(ie, { orientation: "horizontal" }), x(le, { ...o3, command: t3.getCommand("formatAlignCenterContinuousToggle"), icon: c2.get("formatAlignCenterContinuousToggle") }), x(le, { ...o3, command: t3.getCommand("formatAlignFillToggle"), icon: c2.get("formatAlignFillToggle") }), x(le, { ...o3, command: t3.getCommand("formatAlignDistributedHorizontalToggle"), icon: c2.get("formatAlignDistributedHorizontalToggle") })] }), s3 = b(A, { sx: { className: In("quick-buttons"), display: "flex", alignItems: "center", justifyContent: "center" }, onClick: (e4) => e4.stopPropagation(), children: [x(le, { command: t3.getCommand("formatIndentDecrease"), commandHook: m2, scope: a2, disabled: r2, icon: re(x(se, {})) }), x(le, { command: t3.getCommand("formatIndentIncrease"), commandHook: m2, scope: a2, disabled: r2, icon: re(x(de, {})) })] }), d3 = b(A, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, ...i2, children: [s3, x(ie, { orientation: "horizontal" }), x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: l3 })] });
42
42
  return ce({ ...e3, children: d3 });
43
43
  }, [r2, n2]);
44
44
  return x(me, { ref: t2, parentFloat: l2, commands: o2, commandHook: n2, scope: a2, createPopupPanel: p2, label: "Horizontal Alignment", tooltip: "Configure how text is placed in the horizontal direction of the cell.", quickCommand: d2, icon: c2.get(d2) ?? x(Ln, {}), ...i2 });
@@ -140,12 +140,12 @@ const tr = k(S((e2, t2) => {
140
140
  let i4 = l3[e4];
141
141
  n3.push(x(pr, { schemeColorLookup: o2, colorDef: i4, selectedColor: a2, previewColor: r2, onSelectColorDef: g2, onPreviewColorDef: h2, swatchProps: m2, compareRGB: d2, darkMode: c2 }, t3 + " " + e4));
142
142
  }
143
- let i3 = x(E, { className: "button-col", sx: { display: "flex", flexDirection: "column", justifyContent: "space-between", boxShadow: (e4) => e4.shadows[2], borderRadius: "2px", overflow: "hidden" }, children: n3 }, "" + t3);
143
+ let i3 = x(A, { className: "button-col", sx: { display: "flex", flexDirection: "column", justifyContent: "space-between", boxShadow: (e4) => e4.shadows[2], borderRadius: "2px", overflow: "hidden" }, children: n3 }, "" + t3);
144
144
  e3.push(i3);
145
145
  }
146
146
  return e3;
147
147
  }, [u2, a2, r2, g2, h2]), y2 = C(() => t2 ? x(I, { noWrap: true, component: "div", sx: { display: "flex", flexShrink: "0", paddingLeft: "6px", paddingBottom: "4px", paddingTop: "0px", userSelect: "none", color: (e3) => e3.palette.text.secondary }, children: t2 }) : null, [t2]);
148
- return b(E, { style: { ...s2 }, children: [y2, x(E, { sx: { display: "flex", flexDirection: "row", gap: "6px", marginBottom: "14px", flexWrap: "wrap", justifyContent: "flex-start" }, ...p2, children: f2 })] });
148
+ return b(A, { style: { ...s2 }, children: [y2, x(A, { sx: { display: "flex", flexDirection: "row", gap: "6px", marginBottom: "14px", flexWrap: "wrap", justifyContent: "flex-start" }, ...p2, children: f2 })] });
149
149
  }), gr = (e2, t2) => ({ description: e2, definition: { val: t2, adjs: [] } }), hr = (t2, o2, n2, a2, r2, l2) => {
150
150
  const i2 = gr(t2, o2);
151
151
  a2?.push(i2);
@@ -153,8 +153,8 @@ const tr = k(S((e2, t2) => {
153
153
  r2?.set(d2, s2);
154
154
  const c2 = s2.toRGBA().toString();
155
155
  l2?.set(c2, s2);
156
- }, fr = w.lazy(() => import("./DeCgfM0e20R-VV0G.mjs")), xr = k(S((t2, a2) => {
157
- const { selectedColor: r2 = null, previewColor: l2 = t2.selectedColor ?? null, recentColors: i2, schemeLookup: s2, disableAlpha: d2 = false, previewDebounceTime: c2 = 100, initialPanelType: m2, defaultButtonSize: p2 = 24, width: u2, onElementLoad: g2, onDone: h2, onEyeDropStart: f2, onEyeDropStop: w2, onPreviewColor: k2, onPreviewColorImmediate: S2, onSelectColor: T2, autoColor: M2, autoColorLabel: F2 = "Automatic", autoColorPosition: B2 = lr.Start, compareRGB: N2 = false, darkMode: A2 = false, ...$2 } = t2, O2 = l2 || r2, V2 = na(k2, [k2]), G2 = na(S2, [S2]), U2 = na(T2, [T2]), j2 = na(f2, [f2]), _2 = na(w2, [w2]), [q2, K2] = D(false), X2 = wa(), Z2 = C(() => s2 || e.getDefaultSchemeLookup(), [s2]), J2 = C(() => {
156
+ }, fr = w.lazy(() => import("./DKg0TuxCg7QCEAE_.mjs")), xr = k(S((t2, a2) => {
157
+ const { selectedColor: r2 = null, previewColor: l2 = t2.selectedColor ?? null, recentColors: i2, schemeLookup: s2, disableAlpha: d2 = false, previewDebounceTime: c2 = 100, initialPanelType: m2, defaultButtonSize: p2 = 24, width: u2, onElementLoad: g2, onDone: h2, onEyeDropStart: f2, onEyeDropStop: w2, onPreviewColor: k2, onPreviewColorImmediate: S2, onSelectColor: T2, autoColor: M2, autoColorLabel: F2 = "Automatic", autoColorPosition: B2 = lr.Start, compareRGB: N2 = false, darkMode: E2 = false, ...$2 } = t2, O2 = l2 || r2, V2 = na(k2, [k2]), G2 = na(S2, [S2]), U2 = na(T2, [T2]), j2 = na(f2, [f2]), _2 = na(w2, [w2]), [q2, K2] = D(false), X2 = wa(), Z2 = C(() => s2 || e.getDefaultSchemeLookup(), [s2]), J2 = C(() => {
158
158
  const e2 = /* @__PURE__ */ new Map(), t3 = /* @__PURE__ */ new Map(), n2 = [];
159
159
  hr("Primary Background", "bg1", Z2, n2, e2, t3), hr("Primary Text", "tx1", Z2, n2, e2, t3), hr("Secondary Background", "bg2", Z2, n2, e2, t3), hr("Secondary Text", "tx2", Z2, n2, e2, t3), hr("Accent 1", "accent1", Z2, n2, e2, t3), hr("Accent 2", "accent2", Z2, n2, e2, t3), hr("Accent 3", "accent3", Z2, n2, e2, t3), hr("Accent 4", "accent4", Z2, n2, e2, t3), hr("Accent 5", "accent5", Z2, n2, e2, t3), hr("Accent 6", "accent6", Z2, n2, e2, t3);
160
160
  const a3 = o.buildPalette(n2, Z2, e2, t3), r3 = [];
@@ -229,7 +229,7 @@ const tr = k(S((e2, t2) => {
229
229
  K2(false), "AbortError" !== e2?.name && console.error(e2);
230
230
  });
231
231
  }, children: x($n, {}) });
232
- }, [J2, A2]), me2 = C(() => {
232
+ }, [J2, E2]), me2 = C(() => {
233
233
  if (!Y2) return;
234
234
  const e2 = { opacity: Y2 ? 1 : "0", position: "absolute", top: "0px", left: "0px", width: "100%", height: "100%", boxSizing: "border-box" };
235
235
  return x(R, { fallback: x("div", { style: e2, children: x(Pe, {}) }), children: x(fr, { style: e2, selectedColor: O2 ? O2.toRGBA().toString() : "transparent", onColorChange: de2, disableAlpha: d2 }) });
@@ -240,9 +240,9 @@ const tr = k(S((e2, t2) => {
240
240
  re2(null);
241
241
  }, onClick: () => {
242
242
  se2(null);
243
- }, children: [x(E, { sx: { flex: "none", boxShadow: (e3) => e3.shadows[2], borderRadius: (e3) => e3.spacing(0.5), overflow: "hidden" }, children: x(pr, { schemeColorLookup: Z2, colorDef: e2, selectedColor: null === r2 ? M2 : r2, previewColor: null === l2 ? M2 : l2, defaultButtonSize: p2, isLarge: true, darkMode: A2, compareRGB: N2, swatchProps: pe2 }) }), x(I, { noWrap: true, component: "div", style: { display: "flex", flex: "1 1 100%", marginLeft: "8px", userSelect: "none" }, children: F2 })] }) });
243
+ }, children: [x(A, { sx: { flex: "none", boxShadow: (e3) => e3.shadows[2], borderRadius: (e3) => e3.spacing(0.5), overflow: "hidden" }, children: x(pr, { schemeColorLookup: Z2, colorDef: e2, selectedColor: null === r2 ? M2 : r2, previewColor: null === l2 ? M2 : l2, defaultButtonSize: p2, isLarge: true, darkMode: E2, compareRGB: N2, swatchProps: pe2 }) }), x(I, { noWrap: true, component: "div", style: { display: "flex", flex: "1 1 100%", marginLeft: "8px", userSelect: "none" }, children: F2 })] }) });
244
244
  }, [M2, F2, Z2, r2, l2]);
245
- return b(E, { ref: a2, sx: { width: u2, outline: "none", padding: "10px 10px", overflow: "hidden", boxSizing: "content-box" }, ...$2, children: [b("div", { style: { position: "relative", display: "flex" }, children: [b("div", { style: { opacity: Y2 ? "0" : 1 }, children: [ue2 && B2 === lr.Start ? b(y, { children: [ue2, x(W, { light: true, style: { marginTop: "2px", marginBottom: "10px" } })] }) : null, x(ur, { title: "Theme Colors", schemeColorLookup: Z2, colorDefs: J2.primaryColors, selectedColor: r2, previewColor: void 0 === l2 ? r2 : l2, swatchProps: pe2, onPreviewColorDef: re2, onSelectColorDef: se2, compareRGB: N2, darkMode: A2 }), x(ur, { schemeColorLookup: Z2, colorDefs: J2.modifiedPresets, selectedColor: r2, previewColor: void 0 === l2 ? r2 : l2, swatchProps: pe2, onPreviewColorDef: re2, onSelectColorDef: se2, compareRGB: N2, darkMode: A2 }), x(W, { light: true, style: { marginBottom: "10px" } }), x(ur, { title: "Standard Colors", schemeColorLookup: Z2, colorDefs: J2.standardColors, selectedColor: r2, previewColor: void 0 === l2 ? r2 : l2, swatchProps: pe2, onPreviewColorDef: re2, onSelectColorDef: se2, compareRGB: N2, darkMode: A2 }), b("div", { style: { opacity: 0 === J2.recentColorsLimited.length ? "0" : void 0, display: 0 === J2.recentColorsLimited.length ? "none" : void 0 }, children: [x(W, { light: true, style: { marginBottom: "10px" } }), x(ur, { title: "Recent Colors", schemeColorLookup: Z2, colorDefs: J2.recentColorsLimited, selectedColor: r2, previewColor: void 0 === l2 ? r2 : l2, swatchProps: pe2, onPreviewColorDef: re2, onSelectColorDef: se2, compareRGB: N2, darkMode: A2 })] }), ue2 && B2 === lr.End ? b(y, { children: [x(W, { light: true, sx: { marginTop: "2px", marginBottom: "2px" } }), ue2, x("div", { style: { marginBottom: "2px" } })] }) : null] }), me2] }), x(W, { light: true, style: { marginBottom: "10px" } }), b("div", { style: { display: "flex", flexDirection: "row", alignItems: "center", justifyContent: "space-around", gap: "8px", paddingLeft: "2px", paddingRight: "2px" }, children: [ce2, x("div", { style: { flex: "1 1 100%", background: "pink" } }), x(z, { style: { minWidth: "75px", maxWidth: "75px" }, value: "check", variant: "outlined", size: "small", onClick: () => {
245
+ return b(A, { ref: a2, sx: { width: u2, outline: "none", padding: "10px 10px", overflow: "hidden", boxSizing: "content-box" }, ...$2, children: [b("div", { style: { position: "relative", display: "flex" }, children: [b("div", { style: { opacity: Y2 ? "0" : 1 }, children: [ue2 && B2 === lr.Start ? b(y, { children: [ue2, x(W, { light: true, style: { marginTop: "2px", marginBottom: "10px" } })] }) : null, x(ur, { title: "Theme Colors", schemeColorLookup: Z2, colorDefs: J2.primaryColors, selectedColor: r2, previewColor: void 0 === l2 ? r2 : l2, swatchProps: pe2, onPreviewColorDef: re2, onSelectColorDef: se2, compareRGB: N2, darkMode: E2 }), x(ur, { schemeColorLookup: Z2, colorDefs: J2.modifiedPresets, selectedColor: r2, previewColor: void 0 === l2 ? r2 : l2, swatchProps: pe2, onPreviewColorDef: re2, onSelectColorDef: se2, compareRGB: N2, darkMode: E2 }), x(W, { light: true, style: { marginBottom: "10px" } }), x(ur, { title: "Standard Colors", schemeColorLookup: Z2, colorDefs: J2.standardColors, selectedColor: r2, previewColor: void 0 === l2 ? r2 : l2, swatchProps: pe2, onPreviewColorDef: re2, onSelectColorDef: se2, compareRGB: N2, darkMode: E2 }), b("div", { style: { opacity: 0 === J2.recentColorsLimited.length ? "0" : void 0, display: 0 === J2.recentColorsLimited.length ? "none" : void 0 }, children: [x(W, { light: true, style: { marginBottom: "10px" } }), x(ur, { title: "Recent Colors", schemeColorLookup: Z2, colorDefs: J2.recentColorsLimited, selectedColor: r2, previewColor: void 0 === l2 ? r2 : l2, swatchProps: pe2, onPreviewColorDef: re2, onSelectColorDef: se2, compareRGB: N2, darkMode: E2 })] }), ue2 && B2 === lr.End ? b(y, { children: [x(W, { light: true, sx: { marginTop: "2px", marginBottom: "2px" } }), ue2, x("div", { style: { marginBottom: "2px" } })] }) : null] }), me2] }), x(W, { light: true, style: { marginBottom: "10px" } }), b("div", { style: { display: "flex", flexDirection: "row", alignItems: "center", justifyContent: "space-around", gap: "8px", paddingLeft: "2px", paddingRight: "2px" }, children: [ce2, x("div", { style: { flex: "1 1 100%", background: "pink" } }), x(z, { style: { minWidth: "75px", maxWidth: "75px" }, value: "check", variant: "outlined", size: "small", onClick: () => {
246
246
  ee2();
247
247
  }, children: x("div", Y2 ? { children: "Preset" } : { children: "Custom" }) }), x(z, { variant: "contained", size: "small", style: { minWidth: "75px" }, onClick: () => {
248
248
  Promise.resolve(h2?.()).then(() => {
@@ -260,14 +260,14 @@ const tr = k(S((e2, t2) => {
260
260
  T2.current || (k2(e3), b2?.(e3));
261
261
  }, [b2]), N2 = na((e3, t3) => {
262
262
  T2.current || (k2(void 0), y2?.(e3, t3));
263
- }, [y2]), A2 = C(() => x(E, { sx: { width: "24px", height: "24px", color: "inherit", "--sxl-color-active": `${S2?.toCSS(g2) ?? "transparent"}`, "& .activeColor": { fill: `${S2?.toCSS(g2) ?? "transparent"}` }, "& .style_grey": { fill: (e3) => e3.palette.text.icon ?? e3.palette.action.active } }, children: "function" == typeof a2 ? a2() : a2 }), [S2, a2, g2]), I2 = na((e3) => {
263
+ }, [y2]), E2 = C(() => x(A, { sx: { width: "24px", height: "24px", color: "inherit", "--sxl-color-active": `${S2?.toCSS(g2) ?? "transparent"}`, "& .activeColor": { fill: `${S2?.toCSS(g2) ?? "transparent"}` }, "& .style_grey": { fill: (e3) => e3.palette.text.icon ?? e3.palette.action.active } }, children: "function" == typeof a2 ? a2() : a2 }), [S2, a2, g2]), I2 = na((e3) => {
264
264
  y2?.(n2, false);
265
265
  }, [y2, n2]), [L2, H2] = D(false), W2 = v((e3) => {
266
266
  const { closeFloat: t3, closeFloatAll: n3 } = e3;
267
267
  return x(xr, { ...m2, selectedColor: o2, previewColor: w2, onDone: p2 ? n3 : t3, onKeyDown: (e4) => {
268
268
  e4.which === ra.Enter && (p2 ? n3() : t3());
269
269
  }, onPreviewColorImmediate: B2, onPreviewColor: F2, onSelectColor: N2, onEyeDropStart: () => H2(true), onEyeDropStop: () => H2(false), compareRGB: u2, darkMode: g2 });
270
- }, [o2, w2, p2, S2, m2?.autoColor, g2]), z2 = { onQuickClick: n2 ? I2 : void 0, createPopupPanel: W2, popupProps: { popperProps: { resizeOnOverflow: false } }, onPopupOpen: R2, onPopupClose: P2, tooltip: r2 || l2 || "Color", label: l2, icon: A2, ...h2 };
270
+ }, [o2, w2, p2, S2, m2?.autoColor, g2]), z2 = { onQuickClick: n2 ? I2 : void 0, createPopupPanel: W2, popupProps: { popperProps: { resizeOnOverflow: false } }, onPopupOpen: R2, onPopupClose: P2, tooltip: r2 || l2 || "Color", label: l2, icon: E2, ...h2 };
271
271
  return c2 === Re.Toolbar ? x(Me, { ref: t2, ...z2 }) : x(Fe, { ref: t2, ...z2 });
272
272
  })), wr = 82, kr = (e2) => {
273
273
  const { styleColor: t2, length: o2 = wr, width: n2 = 1, dashArray: a2 = null, sx: r2, isDouble: l2 = false, isAngled: i2 = false, darkMode: s2 = false, ...d2 } = e2;
@@ -280,17 +280,17 @@ const tr = k(S((e2, t2) => {
280
280
  if ("None" === t4.description && !c2) continue;
281
281
  const a2 = x(kr, { styleColor: i2, length: wr, width: t4.width, darkMode: m2, dashArray: t4.pattern, isDouble: t4.description.toLowerCase().includes("double"), isAngled: t4.description.toLowerCase().includes("slant") });
282
282
  let d4 = null;
283
- d4 = n2 ? b(y, { children: [x(E, { sx: { marginRight: "6px" }, children: t4.description }), b(E, { sx: { marginLeft: "6px", marginRight: "6px", display: "flex", alignItems: "center", flex: "1 1 100%" }, children: [x("div", { style: { flex: "1 1 100%" } }), a2] })] }) : "None" === t4.description ? "None" : a2, p3.push(x(Ne, { className: "border-stroke", tabIndex: 0, sx: { height: "28px", "& svg path.activeColor": { filter: Ae(4) }, paddingLeft: "16px", background: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` }, tooltipProps: { description: n2 ? "" : t4.description }, icon: null, disabled: r2, onMouseDown: (e5) => e5.preventDefault(), onMouseUp: () => {
283
+ d4 = n2 ? b(y, { children: [x(A, { sx: { marginRight: "6px" }, children: t4.description }), b(A, { sx: { marginLeft: "6px", marginRight: "6px", display: "flex", alignItems: "center", flex: "1 1 100%" }, children: [x("div", { style: { flex: "1 1 100%" } }), a2] })] }) : "None" === t4.description ? "None" : a2, p3.push(x(Ne, { className: "border-stroke", tabIndex: 0, sx: { height: "28px", "& svg path.activeColor": { filter: Ee(4) }, paddingLeft: "16px", background: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` }, tooltipProps: { description: n2 ? "" : t4.description }, icon: null, disabled: r2, onMouseDown: (e5) => e5.preventDefault(), onMouseUp: () => {
284
284
  l3(), g2(t4.style);
285
285
  }, onKeyDown: (e5) => {
286
286
  e5.which === ra.Enter && l3();
287
287
  }, selected: t4.style === s2, parentFloat: o3, children: d4 }, e4));
288
288
  }
289
- return x(E, { sx: { display: "flex", flexDirection: "column", paddingTop: "4px", paddingBottom: "4px" }, children: p3 });
289
+ return x(A, { sx: { display: "flex", flexDirection: "column", paddingTop: "4px", paddingBottom: "4px" }, children: p3 });
290
290
  }, [r2, c2, i2, s2, m2]), f2 = C(() => {
291
291
  const e3 = a.BuiltInDefinitions.get(s2);
292
292
  let t3;
293
- return t3 = "None" === e3.description ? x(E, { sx: { minWidth: `${wr}px` }, children: "None" }) : x(kr, { styleColor: i2, length: wr, width: e3.width, dashArray: e3.pattern, darkMode: m2, isDouble: e3.description.toLowerCase().includes("double"), isAngled: e3.description.toLowerCase().includes("slant") }), x(E, { className: "border-stroke", sx: { paddingLeft: "12px", marginLeft: "4px", marginRight: "4px", height: "24px", display: "flex", alignItems: "center", "& svg path.activeColor": { filter: Ae() } }, children: t3 });
293
+ return t3 = "None" === e3.description ? x(A, { sx: { minWidth: `${wr}px` }, children: "None" }) : x(kr, { styleColor: i2, length: wr, width: e3.width, dashArray: e3.pattern, darkMode: m2, isDouble: e3.description.toLowerCase().includes("double"), isAngled: e3.description.toLowerCase().includes("slant") }), x(A, { className: "border-stroke", sx: { paddingLeft: "12px", marginLeft: "4px", marginRight: "4px", height: "24px", display: "flex", alignItems: "center", "& svg path.activeColor": { filter: Ee() } }, children: t3 });
294
294
  }, [s2, i2]), w2 = C(() => a.BuiltInDefinitions.get(s2), [s2]), k2 = { disabled: r2, icon: f2, tooltip: "Border Style: " + w2.description, sx: { background: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, ...p2 }, createPopupPanel: h2, ...u2 };
295
295
  return o2 === Re.Toolbar ? x(Me, { ...k2 }) : x(Fe, { ...k2 });
296
296
  })), Cr = k(S((t2, o2) => {
@@ -301,7 +301,7 @@ const tr = k(S((e2, t2) => {
301
301
  o3.length < 6 && (n3 = true);
302
302
  const r3 = n3 ? t3.left : null, l3 = n3 ? t3.top : null, i3 = n3 ? t3.right : null, d3 = n3 ? t3.bottom : null, c3 = n3 ? t3.vertical : null, m3 = n3 ? t3.horizontal : null;
303
303
  let p3 = "";
304
- return l3 || r3 || (p3 += "M 3,5 H 5 V 3 H 3 "), l3 || (p3 += "M 7,5 H 9 V 3 H 7 "), l3 || c3 || (p3 += "M 11,5 h 2 V 3 h -2 "), l3 || (p3 += "M 15,5 h 2 V 3 h -2 "), l3 || i3 || (p3 += "M 19,5 h 2 V 3 h -2 "), r3 || (p3 += "M 3,9 H 5 V 7 H 3 "), c3 || (p3 += "M 11,9 h 2 V 7 h -2 "), i3 || (p3 += "M 19,9 h 2 V 7 h -2 "), m3 || r3 || (p3 += "M 3,13 H 5 V 11 H 3 "), m3 || (p3 += "M 7,13 H 9 V 11 H 7 "), m3 || c3 || (p3 += "M 11,13 h 2 v -2 h -2 "), m3 || i3 || (p3 += "M 19,13 h 2 v -2 h -2 "), m3 || (p3 += "M 15,13 h 2 v -2 h -2 "), r3 || (p3 += "M 3,17 H 5 V 15 H 3 "), c3 || (p3 += "M 11,17 h 2 v -2 h -2 "), i3 || (p3 += "M 19,17 h 2 v -2 h -2 "), d3 || r3 || (p3 += "M 3,21 H 5 V 19 H 3 "), d3 || (p3 += "M 7,21 H 9 V 19 H 7 "), d3 || c3 || (p3 += "M 11,21 h 2 v -2 h -2 "), d3 || (p3 += "M 15,21 h 2 v -2 h -2 "), d3 || i3 || (p3 += "M 19,21 h 2 v -2 h -2 "), b("div", { style: { width: "24px", height: "24px", position: "relative" }, children: [x($, { sx: { position: "absolute", top: "0px", left: "0px", "& path": { opacity: "0.8", transform: "translate(-0.5px, -0.5px)" } }, children: x("path", { d: p3 }) }), x(E, { sx: { width: "24px", height: "24px", display: "flex", alignItems: "center", justifyContent: "center", position: "absolute", top: "-1px", left: "-1px", "& svg path": { filter: Ee } }, children: x(Ta, { getBorderAt: (e3, n4) => {
304
+ return l3 || r3 || (p3 += "M 3,5 H 5 V 3 H 3 "), l3 || (p3 += "M 7,5 H 9 V 3 H 7 "), l3 || c3 || (p3 += "M 11,5 h 2 V 3 h -2 "), l3 || (p3 += "M 15,5 h 2 V 3 h -2 "), l3 || i3 || (p3 += "M 19,5 h 2 V 3 h -2 "), r3 || (p3 += "M 3,9 H 5 V 7 H 3 "), c3 || (p3 += "M 11,9 h 2 V 7 h -2 "), i3 || (p3 += "M 19,9 h 2 V 7 h -2 "), m3 || r3 || (p3 += "M 3,13 H 5 V 11 H 3 "), m3 || (p3 += "M 7,13 H 9 V 11 H 7 "), m3 || c3 || (p3 += "M 11,13 h 2 v -2 h -2 "), m3 || i3 || (p3 += "M 19,13 h 2 v -2 h -2 "), m3 || (p3 += "M 15,13 h 2 v -2 h -2 "), r3 || (p3 += "M 3,17 H 5 V 15 H 3 "), c3 || (p3 += "M 11,17 h 2 v -2 h -2 "), i3 || (p3 += "M 19,17 h 2 v -2 h -2 "), d3 || r3 || (p3 += "M 3,21 H 5 V 19 H 3 "), d3 || (p3 += "M 7,21 H 9 V 19 H 7 "), d3 || c3 || (p3 += "M 11,21 h 2 v -2 h -2 "), d3 || (p3 += "M 15,21 h 2 v -2 h -2 "), d3 || i3 || (p3 += "M 19,21 h 2 v -2 h -2 "), b("div", { style: { width: "24px", height: "24px", position: "relative" }, children: [x($, { sx: { position: "absolute", top: "0px", left: "0px", "& path": { opacity: "0.8", transform: "translate(-0.5px, -0.5px)" } }, children: x("path", { d: p3 }) }), x(A, { sx: { width: "24px", height: "24px", display: "flex", alignItems: "center", justifyContent: "center", position: "absolute", top: "-1px", left: "-1px", "& svg path": { filter: Ae } }, children: x(Ta, { getBorderAt: (e3, n4) => {
305
305
  if (!u2 || 0 === o3.length) return null;
306
306
  const a2 = e3.rowIndex, r4 = e3.colIndex, l4 = {};
307
307
  return 0 === a2 ? (l4.top = t3.top, l4.bottom = t3.horizontal) : (l4.top = t3.horizontal, l4.bottom = t3.bottom), 0 === r4 ? (l4.left = t3.left, l4.right = t3.vertical) : (l4.left = t3.vertical, l4.right = t3.right), u2?.(l4);
@@ -316,20 +316,20 @@ const tr = k(S((e2, t2) => {
316
316
  return n3;
317
317
  }, []), N2 = v((e2) => {
318
318
  h2?.(e2);
319
- }, []), A2 = v((e2) => {
319
+ }, []), E2 = v((e2) => {
320
320
  f2?.(e2);
321
321
  }, []), I2 = v((t3) => {
322
322
  const { closeFloatAll: o3, floatReference: l3 } = t3, c3 = (e2, t4, n3 = "bottom", r3 = false) => {
323
323
  const l4 = B2(e2, R2 ?? null, r3 ? a.StrokeStyle.None : P2 ?? null), i3 = r3 ? B2([], R2 ?? null, P2 ?? null) : l4;
324
324
  return x(He, { icon: F2(i3), sx: { background: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` }, tooltipProps: { label: t4, simple: true, placement: n3 }, onClick: () => {
325
- o3(), A2(l4), N2(l4);
325
+ o3(), E2(l4), N2(l4);
326
326
  } });
327
- }, m3 = b(y, { children: [b(E, { sx: { display: "flex", padding: "6px 16px", justifyContent: "center", rowGap: "2px", gap: "2px" }, children: [c3([a.Edge.Left, a.Edge.Top, a.Edge.Right, a.Edge.Bottom, a.Edge.Horizontal, a.Edge.Vertical], "All Borders", "top"), c3([a.Edge.Horizontal, a.Edge.Vertical], "Inner Borders", "top"), c3([a.Edge.Horizontal], "Inside Horizontal Borders", "top"), c3([a.Edge.Vertical], "Inside Vertical Borders", "top"), c3([a.Edge.Left, a.Edge.Top, a.Edge.Right, a.Edge.Bottom], "Outside Borders", "top")] }), b(E, { sx: { display: "flex", padding: "6px 16px", justifyContent: "center", rowGap: "2px", gap: "2px" }, children: [c3([a.Edge.Left], "Left Borders"), c3([a.Edge.Top], "Top Borders"), c3([a.Edge.Right], "Right Borders"), c3([a.Edge.Bottom], "Bottom Borders"), c3([a.Edge.Left, a.Edge.Top, a.Edge.Right, a.Edge.Bottom, a.Edge.Horizontal, a.Edge.Vertical, a.Edge.DiagonalUp, a.Edge.DiagonalDown], "No Borders", "bottom", true)] })] }), p3 = x(y, { children: b(E, { sx: { display: "flex", padding: "6px 16px", flexDirection: "row", gap: "6px" }, children: [x(yr, { variant: Re.Toolbar, icon: x(Ie, {}), selectedColor: P2 === a.StrokeStyle.None ? new e("transparent") : R2, onPreviewColor: (e2) => {
327
+ }, m3 = b(y, { children: [b(A, { sx: { display: "flex", padding: "6px 16px", justifyContent: "center", rowGap: "2px", gap: "2px" }, children: [c3([a.Edge.Left, a.Edge.Top, a.Edge.Right, a.Edge.Bottom, a.Edge.Horizontal, a.Edge.Vertical], "All Borders", "top"), c3([a.Edge.Horizontal, a.Edge.Vertical], "Inner Borders", "top"), c3([a.Edge.Horizontal], "Inside Horizontal Borders", "top"), c3([a.Edge.Vertical], "Inside Vertical Borders", "top"), c3([a.Edge.Left, a.Edge.Top, a.Edge.Right, a.Edge.Bottom], "Outside Borders", "top")] }), b(A, { sx: { display: "flex", padding: "6px 16px", justifyContent: "center", rowGap: "2px", gap: "2px" }, children: [c3([a.Edge.Left], "Left Borders"), c3([a.Edge.Top], "Top Borders"), c3([a.Edge.Right], "Right Borders"), c3([a.Edge.Bottom], "Bottom Borders"), c3([a.Edge.Left, a.Edge.Top, a.Edge.Right, a.Edge.Bottom, a.Edge.Horizontal, a.Edge.Vertical, a.Edge.DiagonalUp, a.Edge.DiagonalDown], "No Borders", "bottom", true)] })] }), p3 = x(y, { children: b(A, { sx: { display: "flex", padding: "6px 16px", flexDirection: "row", gap: "6px" }, children: [x(yr, { variant: Re.Toolbar, icon: x(Ie, {}), selectedColor: P2 === a.StrokeStyle.None ? new e("transparent") : R2, onPreviewColor: (e2) => {
328
328
  T2(e2);
329
329
  }, onSelectColor: (e2, t4) => {
330
330
  T2(e2);
331
331
  }, darkMode: s2, tooltip: "Border Color", panelProps: { disableAlpha: true, autoColor: n2, schemeLookup: r2 }, disabled: i2 || P2 === a.StrokeStyle.None, parentFloat: l3, shouldCloseFloatAll: false }), x(Sr, { selectedStyle: P2, onSelectStyle: k2, styleColor: R2, darkMode: s2, variant: Re.Toolbar, parentFloat: l3 })] }) });
332
- return b(E, { sx: { display: "flex", flexDirection: "column", paddingTop: "4px", paddingBottom: "4px" }, onClick: (e2) => e2.stopPropagation(), children: [d2 ? p3 : m3, x(ie, { orientation: "horizontal" }), d2 ? m3 : p3] });
332
+ return b(A, { sx: { display: "flex", flexDirection: "column", paddingTop: "4px", paddingBottom: "4px" }, onClick: (e2) => e2.stopPropagation(), children: [d2 ? p3 : m3, x(ie, { orientation: "horizontal" }), d2 ? m3 : p3] });
333
333
  }, [P2, R2, n2, r2, s2]), L2 = C(() => F2(M2), [M2, s2]);
334
334
  return x(Me, { ref: o2, createPopupPanel: I2, popupProps: { popperProps: { resizeOnOverflow: false } }, createTooltip: ({ children: e2 }, t3) => x(Le, { label: "Borders", description: "Set the borders.", disabled: t3, children: e2 }), onQuickClick: () => {
335
335
  h2?.(M2);
@@ -375,7 +375,7 @@ const tr = k(S((e2, t2) => {
375
375
  if (!n2) return null;
376
376
  const e3 = { ...n2 };
377
377
  return delete e3.beforeExecute, e3;
378
- }, [n2]), k2 = ta(l2, ["formatFontSizeIncrease", "formatFontSizeDecrease"]), S2 = C(() => k2 ? b(E, { className: In("quick-buttons", {}), sx: { display: "flex", alignItems: "center", justifyContent: "center" }, onClick: (e3) => e3.stopPropagation(), children: [x(le, { command: k2[0], commandHook: w2, icon: re(x(Ze, {})) }), x(le, { command: k2[1], icon: re(x(Je, {})) })] }) : null, [k2]), T2 = wa(), R2 = C(() => `${r.getSharedMeasurer()("12.3", Math.round(T2.typography.fontSize), T2.typography.fontFamily).width}px`, [T2]), M2 = v((e3) => {
378
+ }, [n2]), k2 = ta(l2, ["formatFontSizeIncrease", "formatFontSizeDecrease"]), S2 = C(() => k2 ? b(A, { className: In("quick-buttons", {}), sx: { display: "flex", alignItems: "center", justifyContent: "center" }, onClick: (e3) => e3.stopPropagation(), children: [x(le, { command: k2[0], commandHook: w2, icon: re(x(Ze, {})) }), x(le, { command: k2[1], icon: re(x(Je, {})) })] }) : null, [k2]), T2 = wa(), R2 = C(() => `${r.getSharedMeasurer()("12.3", Math.round(T2.typography.fontSize), T2.typography.fontFamily).width}px`, [T2]), M2 = v((e3) => {
379
379
  const { onMouseDown: t3, onMouseUp: n3, ...a3 } = e3;
380
380
  return x(L, { component: "div", ...a3, disableRipple: true, children: x(O, { inputMode: "numeric", disabled: s2 || !o2 || o2.disabled(), inputProps: { name: "font-input", autoComplete: "off", tabIndex: 0, type: "number", maxLength: 4, max: 409, min: 2 }, sx: { "&::before": { borderBottom: "1px solid transparent" }, "&:hover:not(.Mui-disabled):not(.Mui-focused):not(.Mui-error):before": { borderBottom: (e4) => `1px solid ${e4.palette.text.icon ?? e4.palette.action.active}` }, "&:hover:not(.Mui-disabled):not(.Mui-error):before": { borderBottom: (e4) => `1px solid ${e4.palette.error.main}` }, "::after": { borderBottom: (e4) => `1px solid ${e4.palette.primary.main}` }, paddingTop: "0px", paddingBottom: "0px", paddingLeft: "0px", paddingRight: "0px", fontSize: (e4) => `${Math.round(e4.typography.fontSize)}px`, width: R2, color: (e4) => e4.palette.text.secondary, input: { padding: "0 0", textAlign: "center", MozAppearance: "textfield", "&:hover:not(.Mui-disabled):not(.Mui-error)": { color: (e4) => e4.palette.text.primary }, "&:focus:not(.Mui-disabled):not(.Mui-error)": { color: (e4) => e4.palette.text.primary } }, "input::-webkit-inner-spin-button": { WebkitAppearance: "none", margin: "0" }, minHeight: "24px" }, value: h2, onFocus: (e4) => {
381
381
  e4.target?.select();
@@ -407,9 +407,9 @@ const tr = k(S((e2, t2) => {
407
407
  0 === o3.button && t3(i2[e4]);
408
408
  }, onKeyDown: (o3) => {
409
409
  o3.keyCode !== ra.Enter && o3.keyCode !== ra.Space || t3(i2[e4]);
410
- }, sx: { paddingTop: "4px", paddingBottom: "4px" }, children: x(E, { sx: { display: "flex", flex: "1 1 100%", justifyContent: "end" }, children: i2[e4] }) }, "fontSize-" + e4));
410
+ }, sx: { paddingTop: "4px", paddingBottom: "4px" }, children: x(A, { sx: { display: "flex", flex: "1 1 100%", justifyContent: "end" }, children: i2[e4] }) }, "fontSize-" + e4));
411
411
  }
412
- const l3 = b(E, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, ...u2, children: [S2, x(ie, { orientation: "horizontal" }), x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: r2 })] });
412
+ const l3 = b(A, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, ...u2, children: [S2, x(ie, { orientation: "horizontal" }), x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: r2 })] });
413
413
  return ce({ ...e3, children: l3 });
414
414
  }, [s2, o2?.state(), n2]);
415
415
  return x(Me, { ref: t2, sx: { ...p2 }, tabIndex: -1, outlined: true, disabled: s2, parentFloat: d2, createPopupPanel: F2, createTooltip: ({ children: e3 }, t3) => x(Le, { label: o2?.label(), description: o2?.description(), disabled: t3 || o2?.disabled(), children: e3 }), createQuickButton: M2, ...u2 });
@@ -421,7 +421,7 @@ const tr = k(S((e2, t2) => {
421
421
  0 === e3.button && a2(r2.numberFormat);
422
422
  }, onKeyDown: (e3) => {
423
423
  e3.keyCode !== ra.Enter && e3.keyCode !== ra.Space || a2(r2.numberFormat);
424
- }, ...s2, children: b(E, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden" }, children: [b(I, { component: "div", children: [r2.formatType, r2.formatType === l.Type.Custom ? "…" : ""] }), x(I, { variant: "caption", component: "div", sx: { color: (e3) => za(e3.palette.text.primary, 0.6), paddingTop: n2 && n2.length > 0 ? "1px" : void 0, overflow: "hidden", textOverflow: "ellipsis" }, children: n2 && n2.length > 0 ? n2 : " " })] }) });
424
+ }, ...s2, children: b(A, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden" }, children: [b(I, { component: "div", children: [r2.formatType, r2.formatType === l.Type.Custom ? "…" : ""] }), x(I, { variant: "caption", component: "div", sx: { color: (e3) => za(e3.palette.text.primary, 0.6), paddingTop: n2 && n2.length > 0 ? "1px" : void 0, overflow: "hidden", textOverflow: "ellipsis" }, children: n2 && n2.length > 0 ? n2 : " " })] }) });
425
425
  }), Fr = k(S((e2, t2) => {
426
426
  const { commands: o2, commandHook: n2, scope: a2, sx: i2, disabled: s2 = false, parentFloat: d2, ...c2 } = e2, m2 = ta(o2, ["formatNumberFormat"])[0], p2 = m2?.state() ? l.Styles.lookupStyle(m2?.state()).formatType : l.Type.General, u2 = C(() => {
427
427
  if (!n2) return null;
@@ -444,13 +444,13 @@ const tr = k(S((e2, t2) => {
444
444
  }
445
445
  const g3 = { numberFormat: "", formatType: l.Type.Custom }, h3 = p2 === l.Type.Custom, f3 = x(Mr, { selected: h3, disabled: s2 || !m2 || m2.disabled(), formattedValue: h3 ? r2.getNumberFormat().displayText : "", handleSetFormat: () => {
446
446
  n2?.beforeExecute?.(m2, m2?.state()), t3.getCommand("formatNumberDialog")?.execute(m2?.state()), n2?.onExecute?.(m2, m2?.state());
447
- }, format: g3, sx: { flex: "0", width: "100%" } }, l.Type.Custom), y2 = b(E, { className: "quick-buttons", sx: { display: "flex", alignItems: "center", justifyContent: "center" }, onClick: (e4) => e4.stopPropagation(), children: [x(le, { command: t3.getCommand("formatNumberFormatAccountingStyle"), commandHook: u2, scope: a2, icon: x(Qe, {}) }), x(le, { command: t3.getCommand("formatNumberFormatPercentStyle"), commandHook: u2, scope: a2, icon: x(et, {}) }), x(le, { command: t3.getCommand("formatNumberFormatCommaStyle"), commandHook: u2, scope: a2, icon: x(tt, {}) }), x(le, { command: t3.getCommand("formatNumberFormatIncreaseDecimal"), commandHook: u2, scope: a2, icon: re(x(ot, {})) }), x(le, { command: t3.getCommand("formatNumberFormatDecreaseDecimal"), commandHook: u2, scope: a2, icon: re(x(nt, {})) })] }), w2 = b(E, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, ...c2, children: [y2, x(ie, { orientation: "horizontal" }), x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: d3 }), x(ie, { orientation: "horizontal" }), f3] });
447
+ }, format: g3, sx: { flex: "0", width: "100%" } }, l.Type.Custom), y2 = b(A, { className: "quick-buttons", sx: { display: "flex", alignItems: "center", justifyContent: "center" }, onClick: (e4) => e4.stopPropagation(), children: [x(le, { command: t3.getCommand("formatNumberFormatAccountingStyle"), commandHook: u2, scope: a2, icon: x(Qe, {}) }), x(le, { command: t3.getCommand("formatNumberFormatPercentStyle"), commandHook: u2, scope: a2, icon: x(et, {}) }), x(le, { command: t3.getCommand("formatNumberFormatCommaStyle"), commandHook: u2, scope: a2, icon: x(tt, {}) }), x(le, { command: t3.getCommand("formatNumberFormatIncreaseDecimal"), commandHook: u2, scope: a2, icon: re(x(ot, {})) }), x(le, { command: t3.getCommand("formatNumberFormatDecreaseDecimal"), commandHook: u2, scope: a2, icon: re(x(nt, {})) })] }), w2 = b(A, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, ...c2, children: [y2, x(ie, { orientation: "horizontal" }), x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: d3 }), x(ie, { orientation: "horizontal" }), f3] });
448
448
  return ce({ ...e3, children: w2 });
449
449
  }, [m2?.context(), m2?.state(), n2, a2]), h2 = wa(), f2 = C(() => {
450
450
  const e3 = l.Type.MediumTime;
451
451
  return `${r.getSharedMeasurer()(e3, Math.round(h2.typography.fontSize), h2.typography.fontFamily).width}px`;
452
452
  }, [h2]);
453
- return x(me, { ref: t2, commands: o2, sx: i2, outlined: true, disabled: s2, parentFloat: d2, createPopupPanel: g2, createTooltip: ({ children: e3 }, t3) => x(Le, { label: m2?.label(), description: m2?.description(), disabled: t3, children: e3 }), icon: x(E, { sx: { display: "flex", paddingLeft: "4px", paddingRight: "4px", fontSize: (e3) => `${Math.round(e3.typography.fontSize)}px`, color: (e3) => e3.palette.text.secondary, fontFamily: (e3) => e3.typography.fontFamily, width: f2 }, children: x(E, { sx: { overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "pre" }, children: p2 }) }), ...c2 });
453
+ return x(me, { ref: t2, commands: o2, sx: i2, outlined: true, disabled: s2, parentFloat: d2, createPopupPanel: g2, createTooltip: ({ children: e3 }, t3) => x(Le, { label: m2?.label(), description: m2?.description(), disabled: t3, children: e3 }), icon: x(A, { sx: { display: "flex", paddingLeft: "4px", paddingRight: "4px", fontSize: (e3) => `${Math.round(e3.typography.fontSize)}px`, color: (e3) => e3.palette.text.secondary, fontFamily: (e3) => e3.typography.fontFamily, width: f2 }, children: x(A, { sx: { overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "pre" }, children: p2 }) }), ...c2 });
454
454
  })), Br = k(S((e2, t2) => {
455
455
  const { commands: o2, commandHook: n2, scope: a2, disabled: r2 = false, ...l2 } = e2, i2 = v((e3, t3) => {
456
456
  const o3 = { variant: oa.Menuitem, commandHook: n2, scope: "clear", disabled: r2 }, a3 = b(y, { children: [x(le, { ...o3, command: t3.getCommand("clearAll"), icon: x(at, {}) }), x(le, { ...o3, command: t3.getCommand("clearFormats"), icon: re(x(rt, {})) }), x(le, { ...o3, command: t3.getCommand("clearContents"), icon: re(x(lt, {})) }), x(le, { ...o3, command: t3.getCommand("clearComments") }), x(le, { ...o3, command: t3.getCommand("clearHyperlinks") })] });
@@ -463,7 +463,7 @@ const tr = k(S((e2, t2) => {
463
463
  return ce({ ...e3, children: a3 });
464
464
  }, [r2, n2, a2]);
465
465
  return x(me, { ref: t2, commands: o2, disabled: r2, commandHook: n2, label: "Fill", tooltip: "Fill the selected cells with the value from one of the corners.", createPopupPanel: i2, icon: re(x(it, {})), ...l2 });
466
- })), Ar = k(S((e2, t2) => {
466
+ })), Er = k(S((e2, t2) => {
467
467
  const { commands: o2, commandHook: n2, scope: a2, disabled: r2 = false, disableSheet: l2 = false, preferSingleMenu: i2 = true, showQuickButton: s2 = true, variant: d2 = oa.Toolbar, ...c2 } = e2, m2 = ["insertCellsShiftDown", "insertCellsShiftRight", "insertRows", "insertColumns"], p2 = ta(o2, m2), { singleCommand: u2, allDisabled: g2 } = C(() => {
468
468
  let e3 = null, t3 = 0;
469
469
  for (let o3 = 0; o3 < p2.length; o3++) p2[o3] && !p2[o3]?.disabled() && (i2 && d2 === oa.Menuitem && (e3 = 0 === t3 ? p2[o3] : null), t3++);
@@ -479,7 +479,7 @@ const tr = k(S((e2, t2) => {
479
479
  return ce({ ...e3, children: i3 });
480
480
  }, [r2, p2, n2, a2, h2]);
481
481
  return u2 ? x(le, { ref: t2, variant: d2, commandHook: n2, disabled: r2, command: u2, icon: h2.get(u2.key()), ...c2 }) : x(me, { ref: t2, variant: d2, quickCommand: "insertCells", commands: o2, commandHook: n2, scope: a2, disabled: r2 || g2, tooltip: b(y, { children: [x("span", { children: "Insert new cells, rows or columns to your workbook." }), x("br", {}), x("span", { children: "To insert multiple rows or columns at a time, select multiple rows or columns in the sheet and click Insert." })] }), createPopupPanel: f2, icon: re(x(ct, {})), ...c2 });
482
- })), Er = k(S((e2, t2) => {
482
+ })), Ar = k(S((e2, t2) => {
483
483
  const { commands: o2, commandHook: n2, scope: a2, disabled: r2 = false, disableSheet: l2 = false, preferSingleMenu: i2 = true, showQuickButton: s2 = true, variant: d2 = oa.Toolbar, ...c2 } = e2, m2 = ta(o2, ["deleteCellsShiftUp", "deleteCellsShiftLeft", "deleteRows", "deleteColumns"]), { singleCommand: p2, allDisabled: u2 } = C(() => {
484
484
  let e3 = null, t3 = 0;
485
485
  for (let o3 = 0; o3 < m2.length; o3++) m2[o3] && !m2[o3]?.disabled() && (i2 && d2 === oa.Menuitem && (e3 = 0 === t3 ? m2[o3] : null), t3++);
@@ -562,18 +562,18 @@ const Lr = k(S((e2, t2) => {
562
562
  0 === t5.button && l3(e4 + 1);
563
563
  }, onKeyDown: (t5) => {
564
564
  t5.isDefaultPrevented() || t5.keyCode !== ra.Enter && t5.keyCode !== ra.Space || l3(e4 + 1);
565
- }, children: b(E, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "row", alignItems: "center", overflow: "hidden" }, children: [x(I, { component: "div", children: t4 }), x(mt, {})] }) }, `action:${e4}`));
565
+ }, children: b(A, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "row", alignItems: "center", overflow: "hidden" }, children: [x(I, { component: "div", children: t4 }), x(mt, {})] }) }, `action:${e4}`));
566
566
  }
567
567
  let c3 = null;
568
568
  if (!a2 && r2) {
569
569
  const o4 = { scope: "undo", commands: t3, variant: oa.Menuitem, parentFloat: e3.floatReference };
570
570
  c3 = [], c3.push(x(zr, { ...o4, quickCommand: "redo", isRedo: true }, "nested:redo")), f2.hasRedo() && f2.hasUndo() && c3.push(x(ie, { orientation: "horizontal" }, "action:redo-div"));
571
571
  }
572
- const m3 = b(E, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, onClick: () => {
572
+ const m3 = b(A, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, onClick: () => {
573
573
  e3.closeFloatAll();
574
574
  }, onMouseLeave: () => {
575
575
  S2(0);
576
- }, children: [c3, x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: d3 }), x(ie, { orientation: "horizontal" }), i3] });
576
+ }, children: [c3, x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: d3 }), x(ie, { orientation: "horizontal" }), i3] });
577
577
  return ce({ ...e3, children: m3 });
578
578
  }, [g2?.context(), g2?.state(), i2, f2, k2, w2]);
579
579
  return x(me, { ref: t2, commands: c2, quickCommand: o2, scope: i2, disabled: w2, label: g2?.label() ?? (a2 ? "Redo" : "Undo"), tooltip: x(y, { children: x("span", { children: `${g2?.label() ?? "No"} last actions.` }) }), createPopupPanel: C2, icon: n2 ?? re(x(a2 ? St : Ct, {})), selected: false, ...m2 });
@@ -597,12 +597,12 @@ const Vr = k(S((e2, t2) => {
597
597
  0 === e5.button && e5.preventDefault();
598
598
  }, onKeyDown: (o3) => {
599
599
  o3.keyCode !== ra.Enter && o3.keyCode !== ra.Space || t3(a3[e4].key);
600
- }, children: x(E, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden" }, children: x(I, { component: "div", sx: { whiteSpace: "nowrap", overflow: "hidden", textOverflow: "ellipsis", fontFamily: () => a3[e4]?.key }, children: a3[e4].description }) }) }, e4 + "" + a3[e4].key));
600
+ }, children: x(A, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden" }, children: x(I, { component: "div", sx: { whiteSpace: "nowrap", overflow: "hidden", textOverflow: "ellipsis", fontFamily: () => a3[e4]?.key }, children: a3[e4].description }) }) }, e4 + "" + a3[e4].key));
601
601
  }
602
- const i3 = x(E, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%" }, ...c2, children: x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: r2 }) });
602
+ const i3 = x(A, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%" }, ...c2, children: x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: r2 }) });
603
603
  return ce({ ...e3, children: i3 });
604
604
  }, [l2, o2?.state()]);
605
- return x(Me, { ref: t2, sx: { ...a2 }, outlined: true, disabled: l2, parentFloat: i2, createPopupPanel: g2, createTooltip: ({ children: e3 }, t3) => x(Le, { label: o2?.label(), description: o2?.description(), disabled: t3, children: e3 }), icon: x(E, { sx: { display: "flex", paddingLeft: "4px", paddingRight: "4px", fontSize: (e3) => `${Math.round(e3.typography.fontSize)}px`, fontFamily: (e3) => e3.typography.fontFamily, color: (e3) => e3.palette.text.secondary, width: u2 }, children: x(E, { sx: { overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "pre" }, children: m2 }) }), ...c2 });
605
+ return x(Me, { ref: t2, sx: { ...a2 }, outlined: true, disabled: l2, parentFloat: i2, createPopupPanel: g2, createTooltip: ({ children: e3 }, t3) => x(Le, { label: o2?.label(), description: o2?.description(), disabled: t3, children: e3 }), icon: x(A, { sx: { display: "flex", paddingLeft: "4px", paddingRight: "4px", fontSize: (e3) => `${Math.round(e3.typography.fontSize)}px`, fontFamily: (e3) => e3.typography.fontFamily, color: (e3) => e3.palette.text.secondary, width: u2 }, children: x(A, { sx: { overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "pre" }, children: m2 }) }), ...c2 });
606
606
  })), Gr = k(S((e2, t2) => {
607
607
  const { commands: o2, commandHook: n2, scope: a2, disabled: r2 = false, ...l2 } = e2, i2 = ta(o2, ["formatStrikeThroughToggle", "formatSuperscriptToggle", "formatSubscriptToggle"]), s2 = C(() => {
608
608
  for (let e3 = 0; e3 < i2.length; e3++) if (i2[e3]?.state()) return i2[e3].key();
@@ -630,7 +630,7 @@ const Vr = k(S((e2, t2) => {
630
630
  })), jr = k(S((e2, t2) => {
631
631
  const { command: o2, commands: n2, commandHook: a2, scope: r2, includePasteAllInPopup: l2 = true, disabled: i2 = false, ...s2 } = e2, d2 = na((e3, t3) => {
632
632
  const o3 = { variant: oa.Menuitem, commandHook: a2, scope: "paste", disabled: i2 }, n3 = [];
633
- return l2 && (n3.push(F(le, { ...o3, command: t3.getCommand("paste"), key: "paste", icon: x(Bt, {}) })), n3.push(x(ie, { orientation: "horizontal" }, "paste-div"))), n3.push(F(le, { ...o3, command: t3.getCommand("pasteValues"), key: "pasteValues", icon: re(x(Nt, {})) })), n3.push(F(le, { ...o3, command: t3.getCommand("pasteFormats"), key: "pasteFormats", icon: re(x(At, {})) })), n3.push(F(le, { ...o3, command: t3.getCommand("pasteFormulas"), key: "pasteFormulas", icon: re(x(Et, {})) })), n3.push(F(le, { ...o3, command: t3.getCommand("pasteTranspose"), key: "pasteTranspose", icon: re(x(It, {})) })), n3.push(F(le, { ...o3, command: t3.getCommand("pasteLinks"), key: "pasteLinks", icon: re(x(Lt, {})) })), ce({ ...e3, children: n3 });
633
+ return l2 && (n3.push(F(le, { ...o3, command: t3.getCommand("paste"), key: "paste", icon: x(Bt, {}) })), n3.push(x(ie, { orientation: "horizontal" }, "paste-div"))), n3.push(F(le, { ...o3, command: t3.getCommand("pasteValues"), key: "pasteValues", icon: re(x(Nt, {})) })), n3.push(F(le, { ...o3, command: t3.getCommand("pasteFormats"), key: "pasteFormats", icon: re(x(Et, {})) })), n3.push(F(le, { ...o3, command: t3.getCommand("pasteFormulas"), key: "pasteFormulas", icon: re(x(At, {})) })), n3.push(F(le, { ...o3, command: t3.getCommand("pasteTranspose"), key: "pasteTranspose", icon: re(x(It, {})) })), n3.push(F(le, { ...o3, command: t3.getCommand("pasteLinks"), key: "pasteLinks", icon: re(x(Lt, {})) })), ce({ ...e3, children: n3 });
634
634
  }, [i2, a2, r2, l2]);
635
635
  return x(me, { ref: t2, commands: n2, commandHook: a2, scope: r2, createPopupPanel: d2, label: "Paste", tooltip: "Add content to the clipboard to your document.", quickCommand: "paste", icon: x(Bt, {}), ...s2 });
636
636
  })), _r = k(S((e2, t2) => {
@@ -647,11 +647,11 @@ const Vr = k(S((e2, t2) => {
647
647
  return x(me, { ref: t2, commands: o2, disabled: r2, commandHook: n2, scope: a2, label: "Workbook View", tooltip: "Options to configure how the workbook is displayed.", createPopupPanel: i2, icon: x(ht, { icon: null, label: "Workbook View" }), ...l2 });
648
648
  })), Kr = k(S((e2, t2) => {
649
649
  const { value: o2, cellStyle: n2, styles: a2, createTemporaryCell: r2, bodyStyle: l2, sx: i2, borderProps: s2, disabled: c2, ...m2 } = e2, p2 = C(() => r2({ value: o2, style: n2 }), [o2, n2, r2]), u2 = C(() => p2.getStyle(), [p2, l2]), g2 = C(() => u2.getFill().toCSS(l2?.darkMode ?? false), [u2]), h2 = u2.getInsets(), f2 = u2.getFont(), b2 = v(() => u2.getBorder(), [u2]);
650
- return x(E, { ref: t2, sx: { width: "100px", textOverflow: "ellipsis", display: "flex", alignItems: "stretch", background: l2?.fill, filter: c2 ? "grayscale(0.4) opacity(0.8);" : "none", "& .fill": { flex: "1 1 100%", overflow: "hidden", ...g2 }, "& .text": { flex: "1 1 100%", ...f2.toCSS(l2?.darkMode ?? false, 1), boxSizing: "border-box", padding: `${h2.top}px ${h2.right}px ${h2.bottom}px ${h2.left}px`, margin: "0px", outline: "none", resize: "none", overflow: "hidden", textOverflow: "ellipsis", verticalAlign: "baseline", textDecoration: f2.toCSS().textDecoration, textAlign: d.toCSSHorizontalTextAlign(p2.getRenderHorizontalAlignment()), background: "transparent", maxHeight: "100%", whiteSpace: "pre", wordWrap: "break-word" }, ...i2 }, ...m2, children: x(Ta, { getBorderAt: b2, darkMode: l2?.darkMode ?? false, rowCount: 1, columnCount: 1, style: { display: "flex", flex: "1 1 100%", width: "100%", maxWidth: "100%", justifyContent: "start", alignItems: "stretch", ...s2?.style }, ...s2, children: x(E, { className: "fill", sx: { paddingLeft: "4px", paddingRight: "4px", marginLeft: "-1px", marginTop: "-1px", marginRight: "-1px", marginBottom: "-1px", overflow: "hidden", display: "flex", alignItems: "center" }, children: x(E, { className: "text", children: o2 }) }) }) });
650
+ return x(A, { ref: t2, sx: { width: "100px", textOverflow: "ellipsis", display: "flex", alignItems: "stretch", background: l2?.fill, filter: c2 ? "grayscale(0.4) opacity(0.8);" : "none", "& .fill": { flex: "1 1 100%", overflow: "hidden", ...g2 }, "& .text": { flex: "1 1 100%", ...f2.toCSS(l2?.darkMode ?? false, 1), boxSizing: "border-box", padding: `${h2.top}px ${h2.right}px ${h2.bottom}px ${h2.left}px`, margin: "0px", outline: "none", resize: "none", overflow: "hidden", textOverflow: "ellipsis", verticalAlign: "baseline", textDecoration: f2.toCSS().textDecoration, textAlign: d.toCSSHorizontalTextAlign(p2.getRenderHorizontalAlignment()), background: "transparent", maxHeight: "100%", whiteSpace: "pre", wordWrap: "break-word" }, ...i2 }, ...m2, children: x(Ta, { getBorderAt: b2, darkMode: l2?.darkMode ?? false, rowCount: 1, columnCount: 1, style: { display: "flex", flex: "1 1 100%", width: "100%", maxWidth: "100%", justifyContent: "start", alignItems: "stretch", ...s2?.style }, ...s2, children: x(A, { className: "fill", sx: { paddingLeft: "4px", paddingRight: "4px", marginLeft: "-1px", marginTop: "-1px", marginRight: "-1px", marginBottom: "-1px", overflow: "hidden", display: "flex", alignItems: "center" }, children: x(A, { className: "text", children: o2 }) }) }) });
651
651
  })), Xr = k((e2) => {
652
652
  const { styles: t2, namedStyle: o2, selectedNamed: n2, hasContextMenu: a2 = true, bodyStyle: r2, onSelectNamed: l2, createTemporaryCell: i2, parentFloat: d2, commands: c2, disabled: m2, commandHook: p2, ...u2 } = e2, g2 = v((e3) => {
653
653
  const t3 = { variant: oa.Menuitem, commandHook: p2, context: "cellStyle" }, n3 = b(y, { children: [x(le, { ...t3, sx: { fontWeight: 550 }, command: c2.getCommand("formatCellStyle"), commandState: o2, disabled: m2, icon: re(x(Wt, {})) }), x(ie, { orientation: "horizontal" }), x(le, { ...t3, command: c2.getCommand("modifyCellStyle"), commandState: { named: o2 } }), x(le, { ...t3, command: c2.getCommand("deleteCellStyle"), commandState: o2, disabled: m2 || o2?.getName() === s.BuiltInName.Normal })] });
654
- return ce({ ...e3, children: x(E, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: n3 }) }) });
654
+ return ce({ ...e3, children: x(A, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: n3 }) }) });
655
655
  }, []), h2 = o2?.getName() === n2?.getName();
656
656
  let f2 = x(He, { sx: { borderRadius: "2px", padding: "2px", margin: "0px 0px", display: "flex", border: (e3) => `solid ${h2 ? e3.palette.primary.dark : "transparent"} 1px` }, tooltipProps: { label: o2.getName(), placement: "bottom-start" }, disabled: m2, icon: null, onClick: () => {
657
657
  l2?.(o2);
@@ -674,19 +674,19 @@ const Vr = k(S((e2, t2) => {
674
674
  const o4 = c3(t4[e5]);
675
675
  o4 && n4.push(o4);
676
676
  }
677
- return 0 === n4.length ? null : b(E, { children: [o3 ? x(ie, { orientation: "horizontal" }) : null, x(zt, { children: e4 }, e4 + "-header"), x(E, { sx: { display: "flex", gap: "2px", marginBottom: "6px", flexWrap: "wrap", width: "646px", maxWidth: "100%" }, children: n4 }, e4 + "-presets")] }, e4);
677
+ return 0 === n4.length ? null : b(A, { children: [o3 ? x(ie, { orientation: "horizontal" }) : null, x(zt, { children: e4 }, e4 + "-header"), x(A, { sx: { display: "flex", gap: "2px", marginBottom: "6px", flexWrap: "wrap", width: "646px", maxWidth: "100%" }, children: n4 }, e4 + "-presets")] }, e4);
678
678
  }, p3 = (e4, t4) => {
679
679
  const o3 = [];
680
680
  for (let e5 = 0; e5 < t4.length; e5++) {
681
681
  const n4 = c3(t4[e5]);
682
682
  n4 && o3.push(n4);
683
683
  }
684
- return 0 === o3.length ? null : x(E, { sx: { display: "flex", gap: "2px", marginBottom: "6px", flexWrap: "wrap", flexDirection: "column", flex: "0 0 0%" }, children: o3 }, e4 + "-presets");
684
+ return 0 === o3.length ? null : x(A, { sx: { display: "flex", gap: "2px", marginBottom: "6px", flexWrap: "wrap", flexDirection: "column", flex: "0 0 0%" }, children: o3 }, e4 + "-presets");
685
685
  }, f3 = [];
686
686
  f3.push(m3("Custom", i3, false)), f3.push(m3("Good, Bad and Neutral", [s.BuiltInName.Normal, s.BuiltInName.Bad, s.BuiltInName.Good, s.BuiltInName.Neutral], i3.length > 0)), f3.push(m3("Data and Model", [s.BuiltInName.Calculation, s.BuiltInName.CheckCell, s.BuiltInName.ExplanatoryText, s.BuiltInName.FollowedHyperlink, s.BuiltInName.Hyperlink, s.BuiltInName.Input, s.BuiltInName.LinkedCell, s.BuiltInName.Note, s.BuiltInName.Output, s.BuiltInName.WarningText])), f3.push(m3("Titles and Headings", [s.BuiltInName.Heading1, s.BuiltInName.Heading2, s.BuiltInName.Heading3, s.BuiltInName.Heading4, s.BuiltInName.Title, s.BuiltInName.Total]));
687
687
  let w3 = [];
688
688
  var k3, S3;
689
- return w3.push(p3("Accent 1", [s.BuiltInName.Accent1_20, s.BuiltInName.Accent1_40, s.BuiltInName.Accent1_60, s.BuiltInName.Accent1])), w3.push(p3("Accent 2", [s.BuiltInName.Accent2_20, s.BuiltInName.Accent2_40, s.BuiltInName.Accent2_60, s.BuiltInName.Accent2])), w3.push(p3("Accent 3", [s.BuiltInName.Accent3_20, s.BuiltInName.Accent3_40, s.BuiltInName.Accent3_60, s.BuiltInName.Accent3])), w3.push(p3("Accent 4", [s.BuiltInName.Accent4_20, s.BuiltInName.Accent4_40, s.BuiltInName.Accent4_60, s.BuiltInName.Accent4])), w3.push(p3("Accent 5", [s.BuiltInName.Accent5_20, s.BuiltInName.Accent5_40, s.BuiltInName.Accent5_60, s.BuiltInName.Accent5])), w3.push(p3("Accent 6", [s.BuiltInName.Accent6_20, s.BuiltInName.Accent6_40, s.BuiltInName.Accent6_60, s.BuiltInName.Accent6])), f3.push((k3 = "Themed Cell Styles", S3 = w3, b(E, { children: [x(ie, { orientation: "horizontal" }), x(zt, { children: k3 }, k3 + "-header"), x(E, { sx: { display: "flex", gap: "2px", flexWrap: "wrap", alignItems: "start", flexDirection: "row" }, children: S3 }, k3 + "-presets")] }, k3))), f3.push(m3("Number Format", [s.BuiltInName.Comma, s.BuiltInName.Comma0, s.BuiltInName.Currency, s.BuiltInName.Currency0, s.BuiltInName.Percent])), b(E, { sx: { display: "flex", flexDirection: "column", maxWidth: "100%", paddingTop: (e4) => `${e4.shape.borderRadius}px`, paddingBottom: (e4) => `${e4.shape.borderRadius}px` }, children: [x(E, { onContextMenu: () => {
689
+ return w3.push(p3("Accent 1", [s.BuiltInName.Accent1_20, s.BuiltInName.Accent1_40, s.BuiltInName.Accent1_60, s.BuiltInName.Accent1])), w3.push(p3("Accent 2", [s.BuiltInName.Accent2_20, s.BuiltInName.Accent2_40, s.BuiltInName.Accent2_60, s.BuiltInName.Accent2])), w3.push(p3("Accent 3", [s.BuiltInName.Accent3_20, s.BuiltInName.Accent3_40, s.BuiltInName.Accent3_60, s.BuiltInName.Accent3])), w3.push(p3("Accent 4", [s.BuiltInName.Accent4_20, s.BuiltInName.Accent4_40, s.BuiltInName.Accent4_60, s.BuiltInName.Accent4])), w3.push(p3("Accent 5", [s.BuiltInName.Accent5_20, s.BuiltInName.Accent5_40, s.BuiltInName.Accent5_60, s.BuiltInName.Accent5])), w3.push(p3("Accent 6", [s.BuiltInName.Accent6_20, s.BuiltInName.Accent6_40, s.BuiltInName.Accent6_60, s.BuiltInName.Accent6])), f3.push((k3 = "Themed Cell Styles", S3 = w3, b(A, { children: [x(ie, { orientation: "horizontal" }), x(zt, { children: k3 }, k3 + "-header"), x(A, { sx: { display: "flex", gap: "2px", flexWrap: "wrap", alignItems: "start", flexDirection: "row" }, children: S3 }, k3 + "-presets")] }, k3))), f3.push(m3("Number Format", [s.BuiltInName.Comma, s.BuiltInName.Comma0, s.BuiltInName.Currency, s.BuiltInName.Currency0, s.BuiltInName.Percent])), b(A, { sx: { display: "flex", flexDirection: "column", maxWidth: "100%", paddingTop: (e4) => `${e4.shape.borderRadius}px`, paddingBottom: (e4) => `${e4.shape.borderRadius}px` }, children: [x(A, { onContextMenu: () => {
690
690
  }, sx: { display: "flex", flexDirection: "column", paddingTop: "6px", paddingBottom: "0px", paddingLeft: "16px", paddingRight: "16px" }, children: f3 }), x(ie, { orientation: "horizontal" }), x(le, { variant: oa.Menuitem, commandState: h2, command: t3.getCommand("newCellStyle"), context: "styles", commandHook: a2, disabled: d2, icon: re(x(Ht, {})) })] });
691
691
  }, [h2, g2?.().getTheme(), f2]), k2 = na((e3) => {
692
692
  const t3 = 18 / r.getDeviceScale(), o3 = u2?.createTemporaryCell(e3);
@@ -727,7 +727,7 @@ const Vr = k(S((e2, t2) => {
727
727
  }
728
728
  return t3;
729
729
  }, [b2, a2, r2]), k2 = v((e3, t3) => y2[t3].getBorder() ?? null, [y2]);
730
- return x(E, { ref: t2, className: "table-format-preview", sx: { background: r2?.fill, filter: i2 ? "grayscale(0.4) opacity(0.8);" : "none", "& .styled-element": { position: "absolute" }, ...l2 }, ...u2, children: x(Ta, { getBorderAt: k2, rowCount: 5, columnCount: 5, forceThinBorder: d2, width: 5 * (g2 - 1) + 1, height: 5 * (m2 - 1) + 1, darkMode: r2?.darkMode ?? false, style: { pointerEvents: "none" }, children: x("table", { className: In(s2, "sheetxl-table-preview", Jr), style: { borderCollapse: "collapse", width: 5 * (g2 - 1) + 1, height: 5 * (m2 - 1) + 1 }, children: x("tbody", { children: w2 }) }) }) });
730
+ return x(A, { ref: t2, className: "table-format-preview", sx: { background: r2?.fill, filter: i2 ? "grayscale(0.4) opacity(0.8);" : "none", "& .styled-element": { position: "absolute" }, ...l2 }, ...u2, children: x(Ta, { getBorderAt: k2, rowCount: 5, columnCount: 5, forceThinBorder: d2, width: 5 * (g2 - 1) + 1, height: 5 * (m2 - 1) + 1, darkMode: r2?.darkMode ?? false, style: { pointerEvents: "none" }, children: x("table", { className: In(s2, "sheetxl-table-preview", Jr), style: { borderCollapse: "collapse", width: 5 * (g2 - 1) + 1, height: 5 * (m2 - 1) + 1 }, children: x("tbody", { children: w2 }) }) }) });
731
731
  })), el = (e2, t2, o2, n2, a2) => {
732
732
  e2.beginPath(), e2.moveTo(t2 + 0.5, o2 + 0.5), e2.lineTo(n2 + 0.5, a2 + 0.5), e2.stroke();
733
733
  }, tl = k(S((e2, t2) => {
@@ -777,7 +777,7 @@ const Vr = k(S((e2, t2) => {
777
777
  return x("div", { ref: t2, className: In("table-style-preview", s2), style: { backgroundImage: h2, width: 61, height: 46, ...i2 }, ...p2 });
778
778
  })), ol = k(S((e2, t2) => {
779
779
  const { styleOptions: o2, onStyleOptionsChange: n2, showHeaderRow: a2, onShowHeaderRowChange: r2, showTotalRow: l2, onShowTotalRowChange: i2, showFilterButton: s2, onShowFilterButtonChange: d2, sx: c2, disabled: m2, ...p2 } = e2;
780
- return b(E, { sx: { display: "flex", flexDirection: "column", flexWrap: "wrap", userSelect: "none", pt: 1, pb: 1, "& .MuiFormControlLabel-root": { marginLeft: (e3) => `${e3.spacing(2)}`, marginRight: (e3) => `${e3.spacing(2)}` }, "& .MuiCheckbox-root": { padding: (e3) => `${e3.spacing(0.5)}` }, ...c2 }, ...p2, ref: t2, children: [r2 && x(V, { control: x(G, { checked: a2 ?? false, indeterminate: null == a2, onChange: () => r2(!a2), disabled: m2 || null == a2 }), label: "Header Row", labelPlacement: "end" }), i2 && x(V, { control: x(G, { checked: l2 ?? false, indeterminate: null == l2, onChange: () => i2(!l2), disabled: m2 || null == l2 }), label: "Total Row", labelPlacement: "end" }), x(V, { control: x(G, { checked: o2?.showRowStripes ?? false, indeterminate: !o2, disabled: m2 || !o2, onChange: () => {
780
+ return b(A, { sx: { display: "flex", flexDirection: "column", flexWrap: "wrap", userSelect: "none", pt: 1, pb: 1, "& .MuiFormControlLabel-root": { marginLeft: (e3) => `${e3.spacing(2)}`, marginRight: (e3) => `${e3.spacing(2)}` }, "& .MuiCheckbox-root": { padding: (e3) => `${e3.spacing(0.5)}` }, ...c2 }, ...p2, ref: t2, children: [r2 && x(V, { control: x(G, { checked: a2 ?? false, indeterminate: null == a2, onChange: () => r2(!a2), disabled: m2 || null == a2 }), label: "Header Row", labelPlacement: "end" }), i2 && x(V, { control: x(G, { checked: l2 ?? false, indeterminate: null == l2, onChange: () => i2(!l2), disabled: m2 || null == l2 }), label: "Total Row", labelPlacement: "end" }), x(V, { control: x(G, { checked: o2?.showRowStripes ?? false, indeterminate: !o2, disabled: m2 || !o2, onChange: () => {
781
781
  n2?.({ ...o2, showRowStripes: !o2?.showRowStripes });
782
782
  } }), label: "Banded Rows", labelPlacement: "end" }), x(V, { control: x(G, { checked: o2?.showFirstColumn ?? false, indeterminate: !o2, disabled: m2 || !o2, onChange: () => {
783
783
  n2?.({ ...o2, showFirstColumn: !o2?.showFirstColumn });
@@ -789,7 +789,7 @@ const Vr = k(S((e2, t2) => {
789
789
  })), nl = k((e2) => {
790
790
  const { table: t2, tableStyle: o2, selectedTableStyleName: n2, onSelectTableStyleName: a2, styles: r2, hasContextMenu: l2 = true, bodyStyle: i2, parentFloat: s2, commands: d2, disabled: c2, commandHook: m2, useCanvasPreview: p2 = true, canvas: u2, ...g2 } = e2, h2 = v((e3) => {
791
791
  const t3 = { variant: oa.Menuitem, commandHook: m2, context: "table" }, n3 = b(y, { children: [x(le, { ...t3, command: d2.getCommand("formatTableStyleClearCellStyles"), commandState: o2, disabled: c2, icon: re(x(Wt, {})) }), x(le, { ...t3, sx: { fontWeight: 550 }, command: d2.getCommand("formatTableStyle"), commandState: { name: o2.getName() }, disabled: c2, icon: re(x(Wt, {})) }), x(ie, { orientation: "horizontal" }), x(le, { ...t3, command: d2.getCommand("setDefaultTableStyle"), commandState: o2.getName(), disabled: c2 }), x(ie, { orientation: "horizontal" }), x(le, { ...t3, command: d2.getCommand("deleteTableStyle"), commandState: o2?.getName(), disabled: c2 || !o2 || o2.isBuiltIn() })] });
792
- return ce({ ...e3, children: x(E, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: n3 }) }) });
792
+ return ce({ ...e3, children: x(A, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: n3 }) }) });
793
793
  }, [d2]), f2 = o2?.getName() === n2, w2 = C(() => {
794
794
  const e3 = { table: t2, tableStyle: o2, styles: r2, bodyStyle: i2 };
795
795
  return p2 ? x(tl, { canvas: u2, ...e3 }) : x(Qr, { ...e3 });
@@ -825,7 +825,7 @@ const Vr = k(S((e2, t2) => {
825
825
  const o5 = n3(t4[e5]);
826
826
  o5 && a3.push(o5);
827
827
  }
828
- return 0 === a3.length ? null : b(E, { children: [o4 ? x(ie, { orientation: "horizontal" }) : null, x(zt, { children: e4 }, e4 + "-header"), x(E, { sx: { display: "flex", gap: "2px", marginBottom: "6px", flexWrap: "wrap", width: "481px", maxWidth: "100%" }, children: a3 }, e4 + "-presets")] }, e4);
828
+ return 0 === a3.length ? null : b(A, { children: [o4 ? x(ie, { orientation: "horizontal" }) : null, x(zt, { children: e4 }, e4 + "-header"), x(A, { sx: { display: "flex", gap: "2px", marginBottom: "6px", flexWrap: "wrap", width: "481px", maxWidth: "100%" }, children: a3 }, e4 + "-presets")] }, e4);
829
829
  }, l3 = [], s3 = u2().getCustomTableStyles(), d3 = [];
830
830
  if (s3.length > 0) {
831
831
  for (let e4 = 0; e4 < s3.length; e4++) s3[e4].isShownInTableStyles() && d3.push(s3[e4].getName());
@@ -842,12 +842,12 @@ const Vr = k(S((e2, t2) => {
842
842
  for (let e4 = 0; e4 < 11; e4++) h3.push("TableStyleDark" + (e4 + 1));
843
843
  l3.push(r3("Dark", h3));
844
844
  let f3 = null;
845
- return g2 && (f3 = b(y, { children: [x(ie, { orientation: "horizontal" }), x(le, { variant: oa.Menuitem, command: t3.getCommand("formatTableStyleClearTableStyle"), commandHook: a2, disabled: i2, icon: re(x(rt, {})) })] })), b(E, { sx: { display: "flex", flexDirection: "column", maxWidth: "100%", paddingTop: (e4) => `${e4.shape.borderRadius}px`, paddingBottom: (e4) => `${e4.shape.borderRadius}px` }, children: [x(E, { onContextMenu: () => {
845
+ return g2 && (f3 = b(y, { children: [x(ie, { orientation: "horizontal" }), x(le, { variant: oa.Menuitem, command: t3.getCommand("formatTableStyleClearTableStyle"), commandHook: a2, disabled: i2, icon: re(x(rt, {})) })] })), b(A, { sx: { display: "flex", flexDirection: "column", maxWidth: "100%", paddingTop: (e4) => `${e4.shape.borderRadius}px`, paddingBottom: (e4) => `${e4.shape.borderRadius}px` }, children: [x(A, { onContextMenu: () => {
846
846
  }, sx: { display: "flex", flexDirection: "column", padding: "6px 16px" }, children: l3 }), f3] });
847
- }, [u2, u2?.().getTheme(), T2, k2]), N2 = i2 || !n2 || n2.disabled(), A2 = C(() => {
847
+ }, [u2, u2?.().getTheme(), T2, k2]), N2 = i2 || !n2 || n2.disabled(), E2 = C(() => {
848
848
  if (!p2 || !d2) return re(x(Wt, {}));
849
849
  }, [k2, T2, N2]);
850
- return x(me, { ref: t2, quickCommand: h2, createPopupPanel: B2, commands: o2, label: n2?.label(), commandState: g2, commandHook: a2, selected: null !== g2, createTooltip: ({ children: e3 }, t3) => x(Le, { label: n2?.label(), description: n2?.description(), disabled: t3, children: e3 }), disabled: N2, icon: A2, ...m2 });
850
+ return x(me, { ref: t2, quickCommand: h2, createPopupPanel: B2, commands: o2, label: n2?.label(), commandState: g2, commandHook: a2, selected: null !== g2, createTooltip: ({ children: e3 }, t3) => x(Le, { label: n2?.label(), description: n2?.description(), disabled: t3, children: e3 }), disabled: N2, icon: E2, ...m2 });
851
851
  })), rl = [];
852
852
  rl.push(gr("Primary Background", "bg1")), rl.push(gr("Primary Text", "tx1")), rl.push(gr("Secondary Background", "bg2")), rl.push(gr("Secondary Text", "tx2")), rl.push(gr("Accent 1", "accent1")), rl.push(gr("Accent 2", "accent2")), rl.push(gr("Accent 3", "accent3")), rl.push(gr("Accent 4", "accent4")), rl.push(gr("Accent 5", "accent5")), rl.push(gr("Accent 6", "accent6"));
853
853
  const ll = (e2) => {
@@ -857,9 +857,9 @@ const ll = (e2) => {
857
857
  const a3 = rl[o3];
858
858
  e3.push(x(pr, { schemeColorLookup: t2.schemeLookup(), colorDef: a3, darkMode: n2, selectedColor: null }, o3 + "-colorDef"));
859
859
  }
860
- return x(E, { sx: { display: "flex", flexDirection: "row", flex: "none" }, children: x(E, { sx: { display: "flex", boxShadow: (e4) => e4.shadows[2] }, children: e3 }) });
860
+ return x(A, { sx: { display: "flex", flexDirection: "row", flex: "none" }, children: x(A, { sx: { display: "flex", boxShadow: (e4) => e4.shadows[2] }, children: e3 }) });
861
861
  }, [t2, s2]);
862
- return x(He, { sx: { borderRadius: "2px", padding: "2px", margin: "0px 0px", display: "flex", border: (e3) => `solid ${a2 ? e3.palette.text.primary : "transparent"} 1px`, "&:hover:not([disabled])": { border: (e3) => `solid ${e3.palette.text.primary} 1px !important` } }, icon: null, ...i2, children: b(E, { sx: { border: (e3) => `solid ${e3.palette.divider} 1px`, minWidth: "200px", borderRadius: "2px", padding: "4px 4px", textAlign: "left", display: "flex", gap: "4px", flexDirection: "column", alignItems: "stretch", color: (e3) => a2 ? e3.palette.text.primary : void 0, "&:hover:not([disabled])": { color: (e3) => e3.palette.text.primary } }, children: [x(E, { sx: {}, children: t2.getName() }), b(E, { sx: { paddingTop: "6px", paddingLeft: "12px", paddingRight: "12px", display: "flex", flexDirection: "column", alignItems: "stretch" }, children: [d2, x(E, { sx: { flex: "1 1 100%", textOverflow: "ellipsis", overflow: "hidden", marginTop: "2px", whiteSpace: "pre", fontFamily: () => t2.getFontScheme().getMajorFont() }, children: x(De, { disableInteractive: true, PopperProps: { style: { pointerEvents: "none" }, disablePortal: true, popperOptions: { strategy: "fixed", modifiers: [{ name: "preventOverflow", enabled: true, options: { boundariesElement: "viewport" } }] } }, title: x("div", { style: { textOverflow: "ellipsis", overflow: "hidden", whiteSpace: "pre" }, children: `The font used for the body.
862
+ return x(He, { sx: { borderRadius: "2px", padding: "2px", margin: "0px 0px", display: "flex", border: (e3) => `solid ${a2 ? e3.palette.text.primary : "transparent"} 1px`, "&:hover:not([disabled])": { border: (e3) => `solid ${e3.palette.text.primary} 1px !important` } }, icon: null, ...i2, children: b(A, { sx: { border: (e3) => `solid ${e3.palette.divider} 1px`, minWidth: "200px", borderRadius: "2px", padding: "4px 4px", textAlign: "left", display: "flex", gap: "4px", flexDirection: "column", alignItems: "stretch", color: (e3) => a2 ? e3.palette.text.primary : void 0, "&:hover:not([disabled])": { color: (e3) => e3.palette.text.primary } }, children: [x(A, { sx: {}, children: t2.getName() }), b(A, { sx: { paddingTop: "6px", paddingLeft: "12px", paddingRight: "12px", display: "flex", flexDirection: "column", alignItems: "stretch" }, children: [d2, x(A, { sx: { flex: "1 1 100%", textOverflow: "ellipsis", overflow: "hidden", marginTop: "2px", whiteSpace: "pre", fontFamily: () => t2.getFontScheme().getMajorFont() }, children: x(De, { disableInteractive: true, PopperProps: { style: { pointerEvents: "none" }, disablePortal: true, popperOptions: { strategy: "fixed", modifiers: [{ name: "preventOverflow", enabled: true, options: { boundariesElement: "viewport" } }] } }, title: x("div", { style: { textOverflow: "ellipsis", overflow: "hidden", whiteSpace: "pre" }, children: `The font used for the body.
863
863
  The heading font is '${t2.getFontScheme().getMajorFont()}'.` }), placement: "bottom-start", children: x("div", { children: t2.getFontScheme().getMinorFont() }) }) })] })] }) });
864
864
  }, il = k(S((e2, t2) => {
865
865
  const { themes: o2, selectedTheme: n2, onSelectTheme: a2, sx: r2, disabled: l2 = false, darkMode: i2, ...s2 } = e2, d2 = C(() => {
@@ -878,7 +878,7 @@ The heading font is '${t2.getFontScheme().getMajorFont()}'.` }), placement: "bot
878
878
  }
879
879
  return t3;
880
880
  }, [n2, a2, i2]);
881
- return x(E, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%" }, ref: t2, ...s2, children: b(E, { sx: { display: "flex", flexDirection: "column", overflow: "hidden" }, children: [x(zt, { sx: { paddingLeft: "16px", paddingRight: "16px", paddingTop: "4px", paddingBottom: "2px" }, children: "Themes" }), x(ie, {}), x(E, { sx: { flex: "1 1 100%", overflow: "auto", padding: "6px 16px" }, children: d2 })] }) });
881
+ return x(A, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%" }, ref: t2, ...s2, children: b(A, { sx: { display: "flex", flexDirection: "column", overflow: "hidden" }, children: [x(zt, { sx: { paddingLeft: "16px", paddingRight: "16px", paddingTop: "4px", paddingBottom: "2px" }, children: "Themes" }), x(ie, {}), x(A, { sx: { flex: "1 1 100%", overflow: "auto", padding: "6px 16px" }, children: d2 })] }) });
882
882
  })), sl = k(S((e2, t2) => {
883
883
  const { themes: o2, selectedTheme: n2, onSelectTheme: a2, icon: r2, tooltip: l2, label: i2, variant: s2 = Re.Toolbar, darkMode: d2, panelProps: c2, ...m2 } = e2, p2 = r2 || re(x(Ot, {})), u2 = { createPopupPanel: v((e3) => {
884
884
  const { closeFloatAll: t3 } = e3;
@@ -946,44 +946,47 @@ The heading font is '${t2.getFontScheme().getMajorFont()}'.` }), placement: "bot
946
946
  } });
947
947
  }));
948
948
  gl.displayName = "InsertFunctionSumCommandPopupButton";
949
- const hl = new Map([{ key: "financial", label: "Financial", icon: x(to, {}) }, { key: "logical", label: "Logical", icon: x(oo, {}) }, { key: "text", label: "Text", icon: x(no, {}) }, { key: "dateTime", label: "Date & Time", icon: x(ao, {}) }, { key: "lookupReference", label: "Lookup & Reference", icon: x(ro, {}) }, { key: "mathTrig", label: "Math & Trig", icon: x(lo, {}) }, { key: "statDist", label: "Statistical", icon: x(io, {}) }, { key: "engineering", label: "Engineering", icon: x(so, {}) }, { key: "information", label: "Information", icon: x(co, {}) }, { key: "cube", label: "Cube", icon: x(mo, {}) }, { key: "database", label: "Database", icon: x(po, {}) }, { key: "web", label: "Web", icon: x(uo, {}) }, { key: "custom", label: "Custom", icon: x(go, {}) }].map((e2) => [e2.key, e2]));
950
- k((e2) => {
951
- const { command: t2, formulaFunction: o2, commandHook: n2, disabled: a2 = false, parentFloat: r2, handleInsert: l2, icon: i2, label: s2, sx: d2, ...c2 } = e2;
952
- return x(Ne, { sx: { maxWidth: "360px", display: "flex", "*": { lineHeight: "1.2" }, ...d2 }, disabled: a2, onMouseDown: (e3) => {
949
+ const hl = new Map([{ key: "financial", label: "Financial", icon: x(to, {}) }, { key: "logical", label: "Logical", icon: x(oo, {}) }, { key: "text", label: "Text", icon: x(no, {}) }, { key: "dateTime", label: "Date & Time", icon: x(ao, {}) }, { key: "lookupReference", label: "Lookup & Reference", icon: x(ro, {}) }, { key: "mathTrig", label: "Math & Trig", icon: x(lo, {}) }, { key: "statDist", label: "Statistical", icon: x(io, {}) }, { key: "engineering", label: "Engineering", icon: x(so, {}) }, { key: "information", label: "Information", icon: x(co, {}) }, { key: "cube", label: "Cube", icon: x(mo, {}) }, { key: "database", label: "Database", icon: x(po, {}) }, { key: "web", label: "Web", icon: x(uo, {}) }, { key: "custom", label: "Custom", icon: x(go, {}) }].map((e2) => [e2.key, e2])), fl = k((e2) => {
950
+ const { command: t2, formulaFunction: o2, commandHook: n2, disabled: a2 = false, parentFloat: r2, handleInsert: l2, icon: i2, label: s2, sx: d2, ...c2 } = e2, m2 = new Promise((e3) => {
951
+ o2.getDescriptor().then((t3) => {
952
+ e3(t3.getSummary());
953
+ });
954
+ });
955
+ return x(Ne, { sx: { maxWidth: "360px", display: "flex", "*": { lineHeight: "1.2" }, ...d2 }, disabled: a2, tooltipProps: { label: m2, maxWidth: 1e3 }, onMouseDown: (e3) => {
953
956
  0 === e3.button && e3.preventDefault();
954
957
  }, onMouseUp: (e3) => {
955
958
  0 === e3.button && l2(o2);
956
959
  }, onKeyDown: (e3) => {
957
960
  e3.keyCode === ra.Enter || (e3.keyCode, ra.Space);
958
- }, ...c2, children: x(E, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden" }, children: x(I, { component: "div", children: "Formula Function Here" }) }) });
959
- });
960
- const fl = k(S((e2, t2) => {
961
+ }, ...c2, children: x(A, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden" }, children: x(I, { component: "div", children: o2.getName() }) }) });
962
+ }), xl = k(S((e2, t2) => {
961
963
  const { category: o2, commands: n2, commandHook: a2, scope: r2, sx: l2, disabled: i2 = false, parentFloat: s2, ...d2 } = e2, c2 = ta(n2, ["insertFunction"])[0], m2 = v((e3, t3) => {
962
964
  const n3 = hl.get(o2);
963
965
  if (!n3) return console.warn("invalidate category", o2), null;
964
- const a3 = x(xl, { category: n3.label, ...e3, commands: t3 });
965
- return ce({ ...e3, children: a3 });
966
+ const r3 = { commandHook: a2, ...e3 }, l3 = x(bl, { category: n3.label, ...r3, commands: t3 });
967
+ return ce({ ...e3, children: l3 });
966
968
  }, [o2, c2, a2, r2]), p2 = hl.get(o2);
967
- return x(me, { ref: t2, commands: n2, commandHook: a2, createPopupPanel: m2, label: p2.label ?? "Insert Function", tooltip: p2.label, icon: re(hl.get(o2)?.icon ?? x(eo, {})), ...d2 });
969
+ return x(me, { ref: t2, commands: n2, commandHook: a2, createPopupPanel: m2, label: p2.label, tooltip: "Insert Function", icon: re(hl.get(o2)?.icon ?? x(eo, {})), ...d2 });
968
970
  }));
969
- fl.displayName = "InsertFunctionCommandPopupButton";
970
- const xl = k(S((e2, t2) => {
971
- const { commands: o2, category: n2, ...a2 } = e2, r2 = ta(o2, ["insertFunction"]), [l2, i2] = D([]), [s2, d2] = D(false);
971
+ xl.displayName = "InsertFunctionCommandPopupButton";
972
+ const bl = k(S((e2, t2) => {
973
+ const { commands: o2, category: n2, commandHook: a2, ...r2 } = e2, l2 = ta(o2, ["insertFunction"]), [i2, s2] = D([]), [d2, c2] = D(false);
972
974
  P(() => {
973
975
  (async () => {
974
- d2(true);
975
- const e3 = r2[0]?.context(), t3 = await e3.searchByCategory(n2);
976
- i2(t3), d2(false);
976
+ c2(true);
977
+ const e3 = l2[0]?.context(), t3 = await e3.searchByCategory(n2);
978
+ s2(t3), c2(false);
977
979
  })();
978
980
  }, []);
979
- const c2 = { variant: oa.Menuitem, parentFloat: e2.floatReference, scope: "scripts", shortcut: null }, m2 = [], p2 = l2.length;
980
- for (let e3 = 0; e3 < p2; e3++) {
981
- const t3 = l2[e3];
982
- m2.push(x(le, { ...c2, command: o2.getCommand("executeScript"), commandState: { declaration: t3 }, tooltipProps: { description: `Insert ${t3.getName() ?? "formula"}` }, label: t3.getName() ?? `Script '${t3.getName()}'` }, `formula-${t3.getName()}-${e3}`));
981
+ const m2 = i2.length, p2 = new Array(m2), u2 = o2.getCommand("insertFunction"), g2 = (e3) => {
982
+ a2?.beforeExecute?.(u2, u2?.state()), u2.execute(e3), a2?.onExecute?.(u2, u2?.state());
983
+ };
984
+ for (let e3 = 0; e3 < m2; e3++) {
985
+ const t3 = i2[e3];
986
+ p2[e3] = x(fl, { command: u2, formulaFunction: t3, handleInsert: g2 }, `formula-${t3.getName()}-${e3}`);
983
987
  }
984
- const u2 = x(E, { ref: t2, sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: m2.length > 0 ? x(y, { children: x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: m2 }) }) : null });
985
- return ce({ ...a2, children: u2 });
986
- })), bl = k(S((e2, t2) => {
988
+ return ce({ ...r2, children: x(A, { ref: t2, sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: m2 > 0 ? x(y, { children: x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: p2 }) }) : null }) });
989
+ })), yl = k(S((e2, t2) => {
987
990
  const { disabled: o2, style: n2, className: a2, sx: r2, defaultInput: l2, value: i2, formName: s2, formOptions: d2, onChangeInput: c2, onValidate: m2, onKeyDown: p2, ...u2 } = e2, g2 = $a(), h2 = s2 && g2 ? g2.register(s2, d2) : null, [f2, b2] = D(""), [y2, w2] = D(""), [k2, S2] = D(i2);
988
991
  P(() => {
989
992
  S2(i2), w2("");
@@ -1009,17 +1012,17 @@ const xl = k(S((e2, t2) => {
1009
1012
  e3.stopPropagation();
1010
1013
  } }) });
1011
1014
  }));
1012
- bl.displayName = "NamedInput";
1013
- const yl = (e2) => null === e2 ? "" : e2.toString(), wl = k(S((e2, t2) => {
1014
- const { formName: o2, formOptions: n2, disabled: a2, style: r2, className: l2, sx: i2, onKeyDown: s2, value: d2, onChangeInput: c2, resolvedAddress: m2, ...p2 } = e2, u2 = $a(), g2 = o2 && u2 ? u2.register(o2, n2) : null, [h2, f2] = D(""), [b2, y2] = D(false), [w2, k2] = D(() => yl(d2));
1015
+ yl.displayName = "NamedInput";
1016
+ const wl = (e2) => null === e2 ? "" : e2.toString(), kl = k(S((e2, t2) => {
1017
+ const { formName: o2, formOptions: n2, disabled: a2, style: r2, className: l2, sx: i2, onKeyDown: s2, value: d2, onChangeInput: c2, resolvedAddress: m2, ...p2 } = e2, u2 = $a(), g2 = o2 && u2 ? u2.register(o2, n2) : null, [h2, f2] = D(""), [b2, y2] = D(false), [w2, k2] = D(() => wl(d2));
1015
1018
  P(() => {
1016
- k2(yl(d2)), f2(""), o2 && u2 && u2.clearErrors(o2), y2(false);
1019
+ k2(wl(d2)), f2(""), o2 && u2 && u2.clearErrors(o2), y2(false);
1017
1020
  }, [d2]);
1018
1021
  const S2 = na((e3) => {
1019
1022
  let t3 = "";
1020
1023
  try {
1021
1024
  k2(e3);
1022
- const t4 = yl(d2), o3 = m2(e3);
1025
+ const t4 = wl(d2), o3 = m2(e3);
1023
1026
  o3.toString() !== t4 && c2?.(o3);
1024
1027
  } catch (e4) {
1025
1028
  t3 = "Invalid Range";
@@ -1027,7 +1030,7 @@ const yl = (e2) => null === e2 ? "" : e2.toString(), wl = k(S((e2, t2) => {
1027
1030
  o2 && u2 && (t3 ? u2.setError(o2, { message: t3 }) : u2.clearErrors(o2)), f2(t3), y2(true);
1028
1031
  }, [w2, c2, o2, u2]), T2 = na(async (e3) => {
1029
1032
  if (b2 && e3.keyCode === ra.Escape) {
1030
- const t3 = yl(d2);
1033
+ const t3 = wl(d2);
1031
1034
  k2(t3), f2(""), y2(false), e3.stopPropagation();
1032
1035
  }
1033
1036
  s2?.(e3);
@@ -1042,8 +1045,8 @@ const yl = (e2) => null === e2 ? "" : e2.toString(), wl = k(S((e2, t2) => {
1042
1045
  e3.stopPropagation();
1043
1046
  } }) });
1044
1047
  }));
1045
- wl.displayName = "RangeInput";
1046
- const kl = k(S((e2, t2) => {
1048
+ kl.displayName = "RangeInput";
1049
+ const Sl = k(S((e2, t2) => {
1047
1050
  const { sheet: o2, className: a2, debounceDelay: l2 = 220, sx: i2, ...s2 } = e2, [d2, c2] = D(() => o2.getView().getZoomScale()), [m2, p2] = D(null), u2 = M(0);
1048
1051
  Pa(o2, { onViewChange: () => {
1049
1052
  p2(true), 0 === u2.current && c2(o2.getView().getZoomScale());
@@ -1068,7 +1071,7 @@ const kl = k(S((e2, t2) => {
1068
1071
  }, []), T2 = sa(() => {
1069
1072
  g2(h2(n.findNextStep(o2.getView().getZoomScale(), false, 10)));
1070
1073
  }), R2 = sa(() => g2(h2(n.findNextStep(o2.getView().getZoomScale(), true, 10)))), F2 = wa(), B2 = C(() => `${r.getSharedMeasurer()("100%", Math.round(F2.typography.fontSize), F2.typography.fontFamily).width}px`, [F2]);
1071
- return b(E, { ref: t2, className: In(a2), sx: { padding: "0px 0px", display: "flex", alignItems: "center", color: (e3) => e3.palette.text.secondary, ...i2 }, onFocus: (e3) => {
1074
+ return b(A, { ref: t2, className: In(a2), sx: { padding: "0px 0px", display: "flex", alignItems: "center", color: (e3) => e3.palette.text.secondary, ...i2 }, onFocus: (e3) => {
1072
1075
  e3.relatedTarget && !y2 && w2(e3.relatedTarget);
1073
1076
  }, onBlur: (e3) => {
1074
1077
  y2 && !k2?.current?.contains(e3.relatedTarget) && w2(null);
@@ -1086,12 +1089,12 @@ const kl = k(S((e2, t2) => {
1086
1089
  Math.abs(t3 - 100) < 3 ? g2(100) : g2(t3);
1087
1090
  }, valueLabelFormat: (e3, t3) => `Zoom: ${Math.round(d2)}%` }), x(De, { disableInteractive: true, title: "Zoom In", children: x(L, { sx: { padding: "0", "&:hover:not([disabled])": { color: (e3) => e3.palette.primary.main }, "& svg": { width: "12px", height: "12px" } }, size: "small", onPointerDown: (e3) => {
1088
1091
  0 !== e3.button ? e3.preventDefault() : R2(e3);
1089
- }, children: x(jn, {}) }) }), b(E, { sx: { display: "flex", flexDirection: "row" }, children: [x(E, { sx: { minWidth: "8px" } }), x(I, { noWrap: true, component: "div", onClick: () => {
1092
+ }, children: x(jn, {}) }) }), b(A, { sx: { display: "flex", flexDirection: "row" }, children: [x(A, { sx: { minWidth: "8px" } }), x(I, { noWrap: true, component: "div", onClick: () => {
1090
1093
  g2(100);
1091
1094
  }, sx: { cursor: "pointer", display: "flex", flex: "1 1 100%", fontSize: "0.70rem", marginLeft: "2px", marginRight: "2px", userSelect: "none", justifyContent: "center", width: B2 }, children: x("div", { children: Math.round(d2) + "%" }) })] })] });
1092
1095
  }));
1093
- kl.displayName = "SheetZoomScale";
1094
- const Sl = k(S((e2, t2) => {
1096
+ Sl.displayName = "SheetZoomScale";
1097
+ const Cl = k(S((e2, t2) => {
1095
1098
  const { sx: o2, sheet: n2, gridStyle: a2, children: r2, childrenEnd: l2, ...i2 } = e2;
1096
1099
  N(t2, () => ({}));
1097
1100
  const s2 = M(null);
@@ -1105,28 +1108,28 @@ const Sl = k(S((e2, t2) => {
1105
1108
  const e3 = d2.getMode();
1106
1109
  return e3?.description ? e3.description : "Ready";
1107
1110
  }, [d2]), [m2, p2] = D(false);
1108
- return b(E, { ref: s2, sx: { display: "flex", alignItems: "stretch", flexDirection: "row", flex: "0", paddingLeft: "12px", paddingRight: "12px", gap: "8px", paddingTop: "1px", minHeight: "calc(1em + 8px)", overflow: m2 ? "visible" : "hidden", boxShadow: `0px -1px 0px ${a2.header.edgeStrokeFill}`, ...o2 }, onMouseOver: () => p2(true), onMouseLeave: () => p2(false), ...i2, children: [r2, x("div", { style: { flex: "1 1 100%", display: "flex", alignItems: "end", overflow: "hidden" }, children: x(I, { component: "div", sx: { userSelect: "none", whiteSpace: "pre", overflow: "hidden", textOverflow: "ellipsis", color: (e3) => e3.palette.text.secondary }, variant: "caption", children: c2 }) }), l2 ? x(E, { sx: { display: "flex", alignItems: "center" }, children: l2 }) : null, x(ie, { style: { marginTop: "6px", marginBottom: "6px" } }), x(kl, { sx: { paddingLeft: "4px", minWidth: "175px" }, sheet: n2 })] });
1111
+ return b(A, { ref: s2, sx: { display: "flex", alignItems: "stretch", flexDirection: "row", flex: "0", paddingLeft: "12px", paddingRight: "12px", gap: "8px", paddingTop: "1px", minHeight: "calc(1em + 8px)", overflow: m2 ? "visible" : "hidden", boxShadow: `0px -1px 0px ${a2.header.edgeStrokeFill}`, ...o2 }, onMouseOver: () => p2(true), onMouseLeave: () => p2(false), ...i2, children: [r2, x("div", { style: { flex: "1 1 100%", display: "flex", alignItems: "end", overflow: "hidden" }, children: x(I, { component: "div", sx: { userSelect: "none", whiteSpace: "pre", overflow: "hidden", textOverflow: "ellipsis", color: (e3) => e3.palette.text.secondary }, variant: "caption", children: c2 }) }), l2 ? x(A, { sx: { display: "flex", alignItems: "center" }, children: l2 }) : null, x(ie, { style: { marginTop: "6px", marginBottom: "6px" } }), x(Sl, { sx: { paddingLeft: "4px", minWidth: "175px" }, sheet: n2 })] });
1109
1112
  }));
1110
- Sl.displayName = "StatusBar";
1111
- const Cl = k(S((e2, t2) => {
1112
- const { disabled: o2, names: a2, workbook: l2, restoreFocus: i2, readonly: s2 = false, disabled: d2 = false, commandPopupButtonProps: c2, sx: m2, notifier: u2, ...g2 } = e2, [h2, f2] = D(null), [w2, k2] = D(() => l2.getSelectedRanges().getCoords()), [S2, C2] = D(false), { reference: T2 } = bo({ parentFloat: c2?.parentFloat }), [R2, B2] = D(() => s2 || !l2.getProtection().isStructureAllowed()), N2 = () => h2?.text ?? "", [A2, I2] = D(N2), H2 = na(() => {
1113
- if (T2?.closeAll(), !A2) {
1113
+ Cl.displayName = "StatusBar";
1114
+ const vl = k(S((e2, t2) => {
1115
+ const { disabled: o2, names: a2, workbook: l2, restoreFocus: i2, readonly: s2 = false, disabled: d2 = false, commandPopupButtonProps: c2, sx: m2, notifier: u2, ...g2 } = e2, [h2, f2] = D(null), [w2, k2] = D(() => l2.getSelectedRanges().getCoords()), [S2, C2] = D(false), { reference: T2 } = bo({ parentFloat: c2?.parentFloat }), [R2, B2] = D(() => s2 || !l2.getProtection().isStructureAllowed()), N2 = () => h2?.text ?? "", [E2, I2] = D(N2), H2 = na(() => {
1116
+ if (T2?.closeAll(), !E2) {
1114
1117
  const e4 = N2();
1115
1118
  return I2(N2()), e4;
1116
1119
  }
1117
- if (N2() === A2) return A2;
1118
- const e3 = A2.trim().toLowerCase();
1119
- if ("r" === e3 || "c" === e3) return A2;
1120
+ if (N2() === E2) return E2;
1121
+ const e3 = E2.trim().toLowerCase();
1122
+ if ("r" === e3 || "c" === e3) return E2;
1120
1123
  try {
1121
- const e4 = l2.getRanges(A2);
1124
+ const e4 = l2.getRanges(E2);
1122
1125
  if (e4) return e4.toString();
1123
1126
  } catch (e4) {
1124
1127
  }
1125
- const t3 = a2.getByName(A2);
1126
- if (t3 && t3.getRanges()) return A2;
1128
+ const t3 = a2.getByName(E2);
1129
+ if (t3 && t3.getRanges()) return E2;
1127
1130
  let o3 = null;
1128
1131
  try {
1129
- const e4 = l2.getRanges(A2), t4 = e4.getCoords().map((e5) => ({ $colEnd: true, $rowEnd: true, $colStart: true, $rowStart: true, ...e5 }));
1132
+ const e4 = l2.getRanges(E2), t4 = e4.getCoords().map((e5) => ({ $colEnd: true, $rowEnd: true, $colStart: true, $rowStart: true, ...e5 }));
1130
1133
  o3 = l2.getRanges(t4);
1131
1134
  } catch (e4) {
1132
1135
  }
@@ -1135,13 +1138,13 @@ const Cl = k(S((e2, t2) => {
1135
1138
  o3 = l2.getRanges(e4);
1136
1139
  }
1137
1140
  try {
1138
- let e4 = a2.getByName(A2);
1139
- R2 || e4 || (e4 = a2.addReference(A2, o3)), e4 && f2({ text: e4.getName() });
1141
+ let e4 = a2.getByName(E2);
1142
+ R2 || e4 || (e4 = a2.addReference(E2, o3)), e4 && f2({ text: e4.getName() });
1140
1143
  } catch (e4) {
1141
1144
  I2(N2()), u2.showMessage?.(e4.message, { type: da.Error });
1142
1145
  }
1143
1146
  return null;
1144
- }, [A2, a2, T2, R2]), W2 = na(() => {
1147
+ }, [E2, a2, T2, R2]), W2 = na(() => {
1145
1148
  if (l2.isClosed()) return;
1146
1149
  const e3 = [];
1147
1150
  for (let t4 = 0; t4 < w2.length; t4++) {
@@ -1189,13 +1192,13 @@ const Cl = k(S((e2, t2) => {
1189
1192
  }, [w2, l2, U2]);
1190
1193
  const q2 = M(null), K2 = v((e3) => {
1191
1194
  const { onMouseDown: t3, onMouseUp: o3, ...n2 } = e3;
1192
- return x(L, { ...n2, sx: { ...n2?.sx, display: "flex", flex: "1 1 100%" }, disableRipple: true, children: x(O, { inputMode: "text", inputProps: { tabIndex: 0, name: "input-named-range", maxLength: 255, className: "input", autoFocus: false, spellCheck: false, autoComplete: "off", ref: q2 }, sx: { "&::before": { borderBottom: "1px solid transparent" }, "&:hover:not(.Mui-disabled):not(.Mui-focused):not(.Mui-error):before": { borderBottom: (e4) => `1px solid ${e4.palette.text.icon ?? e4.palette.action.active}` }, "&:hover:not(.Mui-disabled):not(.Mui-error):before": { borderBottom: (e4) => `1px solid ${e4.palette.primary.main}` }, "::after": { borderBottom: (e4) => `1px solid ${e4.palette.primary.main}` }, paddingTop: "0px", paddingBottom: "0px", fontSize: 11 * r.getDeviceScale(), fontStyle: h2?.fontStyle, paddingLeft: (e4) => e4.spacing(0.75), paddingRight: (e4) => e4.spacing(0.75), boxShadow: "none", flex: "1", color: (e4) => e4.palette.text.secondary, input: { padding: "0", textAlign: "left", "&:hover:not(.Mui-disabled):not(.Mui-error)": { color: (e4) => e4.palette.text.primary }, "&:focus:not(.Mui-disabled):not(.Mui-error)": { color: (e4) => e4.palette.text.primary } } }, value: A2, onFocus: (e4) => {
1195
+ return x(L, { ...n2, sx: { ...n2?.sx, display: "flex", flex: "1 1 100%" }, disableRipple: true, children: x(O, { inputMode: "text", inputProps: { tabIndex: 0, name: "input-named-range", maxLength: 255, className: "input", autoFocus: false, spellCheck: false, autoComplete: "off", ref: q2 }, sx: { "&::before": { borderBottom: "1px solid transparent" }, "&:hover:not(.Mui-disabled):not(.Mui-focused):not(.Mui-error):before": { borderBottom: (e4) => `1px solid ${e4.palette.text.icon ?? e4.palette.action.active}` }, "&:hover:not(.Mui-disabled):not(.Mui-error):before": { borderBottom: (e4) => `1px solid ${e4.palette.primary.main}` }, "::after": { borderBottom: (e4) => `1px solid ${e4.palette.primary.main}` }, paddingTop: "0px", paddingBottom: "0px", fontSize: 11 * r.getDeviceScale(), fontStyle: h2?.fontStyle, paddingLeft: (e4) => e4.spacing(0.75), paddingRight: (e4) => e4.spacing(0.75), boxShadow: "none", flex: "1", color: (e4) => e4.palette.text.secondary, input: { padding: "0", textAlign: "left", "&:hover:not(.Mui-disabled):not(.Mui-error)": { color: (e4) => e4.palette.text.primary }, "&:focus:not(.Mui-disabled):not(.Mui-error)": { color: (e4) => e4.palette.text.primary } } }, value: E2, onFocus: (e4) => {
1193
1196
  e4.target?.select();
1194
1197
  }, onKeyDown: (e4) => {
1195
1198
  if (e4.which === ra.Enter || e4.which === ra.Tab) {
1196
- let t4 = A2;
1197
- N2() !== A2 && (e4.stopPropagation(), e4.preventDefault(), t4 = H2()), t4 ? X2(t4) : i2?.();
1198
- } else if (e4.which === ra.Escape) N2() !== A2 ? (I2(N2()), setTimeout(() => {
1199
+ let t4 = E2;
1200
+ N2() !== E2 && (e4.stopPropagation(), e4.preventDefault(), t4 = H2()), t4 ? X2(t4) : i2?.();
1201
+ } else if (e4.which === ra.Escape) N2() !== E2 ? (I2(N2()), setTimeout(() => {
1199
1202
  e4.target?.select();
1200
1203
  }, 0), e4.stopPropagation(), e4.preventDefault()) : i2?.();
1201
1204
  else if (e4.which === ra.Space) return void e4.stopPropagation();
@@ -1204,7 +1207,7 @@ const Cl = k(S((e2, t2) => {
1204
1207
  }, onChange: (e4) => {
1205
1208
  I2(e4.target.value);
1206
1209
  } }) });
1207
- }, [A2, h2]), X2 = na(async (e3) => {
1210
+ }, [E2, h2]), X2 = na(async (e3) => {
1208
1211
  try {
1209
1212
  T2?.closeAll();
1210
1213
  const t3 = a2.lookupByRanges(e3)?.[0];
@@ -1238,16 +1241,16 @@ const Cl = k(S((e2, t2) => {
1238
1241
  return re(x(So, {}));
1239
1242
  } }));
1240
1243
  }
1241
- const m3 = b(E, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, ...g2, children: [R2 ? null : x(le, { ...t3, scope: "namedItem", command: c2?.commands.getCommand("addNamedReference"), icon: re(x(Co, {})) }), i3 && i3.length > 0 ? b(y, { children: [R2 ? null : x(ie, { orientation: "horizontal" }), x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: i3 })] }) : null] });
1244
+ const m3 = b(A, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, ...g2, children: [R2 ? null : x(le, { ...t3, scope: "namedItem", command: c2?.commands.getCommand("addNamedReference"), icon: re(x(Co, {})) }), i3 && i3.length > 0 ? b(y, { children: [R2 ? null : x(ie, { orientation: "horizontal" }), x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: i3 })] }) : null] });
1242
1245
  return ce({ ...e3, children: m3 });
1243
1246
  }, [l2, z2, a2, h2, R2]), J2 = ca(t2, () => ({ focus(e3) {
1244
1247
  q2.current?.focus(e3);
1245
1248
  } }), []);
1246
- return x(E, { className: "outer", sx: { minWidth: 120, flex: "1 1 100%", display: "flex", alignItems: "center", justifyContent: "start", ...m2 }, ref: Va([J2, t2]), ...g2, children: x(Me, { className: "outer-button", sx: { display: "flex", flex: "1 1 100%", "& .tooltip-wrapper": { display: "flex", flex: "1 1 100%", width: "100%", height: "27px" }, ...m2 }, buttonProps: { sx: { backgroundColor: (e3) => e3.palette.background.paper, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` } }, tabIndex: -1, outlined: { color: (e3) => o2 ? e3.palette.action.disabled : ka(e3.palette.divider, 0.2) }, parentFloat: T2, createPopupPanel: Z2, onPopupOpen: () => C2(true), onPopupClose: () => C2(false), createTooltip: ({ children: e3 }, t3) => x(Le, { title: t3 || S2 ? "" : "Name Box", disabled: t3, leaveDelay: 0, sx: { opacity: t3 || S2 ? 0 : 1 }, children: e3 }), createQuickButton: K2 }) });
1249
+ return x(A, { className: "outer", sx: { minWidth: 120, flex: "1 1 100%", display: "flex", alignItems: "center", justifyContent: "start", ...m2 }, ref: Va([J2, t2]), ...g2, children: x(Me, { className: "outer-button", sx: { display: "flex", flex: "1 1 100%", "& .tooltip-wrapper": { display: "flex", flex: "1 1 100%", width: "100%", height: "27px" }, ...m2 }, buttonProps: { sx: { backgroundColor: (e3) => e3.palette.background.paper, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` } }, tabIndex: -1, outlined: { color: (e3) => o2 ? e3.palette.action.disabled : ka(e3.palette.divider, 0.2) }, parentFloat: T2, createPopupPanel: Z2, onPopupOpen: () => C2(true), onPopupClose: () => C2(false), createTooltip: ({ children: e3 }, t3) => x(Le, { title: t3 || S2 ? "" : "Name Box", disabled: t3, leaveDelay: 0, sx: { opacity: t3 || S2 ? 0 : 1 }, children: e3 }), createQuickButton: K2 }) });
1247
1250
  }));
1248
- Cl.displayName = "NamedCollectionEditor";
1249
- const vl = (e2, t2) => x(Cl, { ref: t2, ...e2 }), Tl = k(S((e2, t2) => {
1250
- const { sx: o2, workbook: n2, sheetElement: a2, gridStyle: l2, showNamedCollectionEditor: i2 = true, NamedCollectionEditorProps: s2, renderNamedCollectionEditor: d2 = vl, disabled: c2, commands: m2, ...p2 } = e2, [u2, g2] = D(n2?.getSelectedSheet());
1251
+ vl.displayName = "NamedCollectionEditor";
1252
+ const Tl = (e2, t2) => x(vl, { ref: t2, ...e2 }), Dl = k(S((e2, t2) => {
1253
+ const { sx: o2, workbook: n2, sheetElement: a2, gridStyle: l2, showNamedCollectionEditor: i2 = true, NamedCollectionEditorProps: s2, renderNamedCollectionEditor: d2 = Tl, disabled: c2, commands: m2, ...p2 } = e2, [u2, g2] = D(n2?.getSelectedSheet());
1251
1254
  Pa(n2, { onSheetsChange: (e3) => {
1252
1255
  g2(e3?.getSelectedSheet());
1253
1256
  }, onViewChange(e3) {
@@ -1259,19 +1262,19 @@ const vl = (e2, t2) => x(Cl, { ref: t2, ...e2 }), Tl = k(S((e2, t2) => {
1259
1262
  } }), Pa(u2, { onProtectionChange() {
1260
1263
  f2(u2.getSelection().getCoords().cell);
1261
1264
  } });
1262
- const T2 = S2.current?.getLineHeight() ?? 20, [P2, R2] = D(T2), [F2, B2] = D(5), [N2, A2] = D(1), I2 = na((e3, { size: t3 }) => {
1265
+ const T2 = S2.current?.getLineHeight() ?? 20, [P2, R2] = D(T2), [F2, B2] = D(5), [N2, E2] = D(1), I2 = na((e3, { size: t3 }) => {
1263
1266
  e3.preventDefault(), e3.stopPropagation();
1264
1267
  const o3 = Math.floor(t3.height / T2);
1265
1268
  R2(o3 * T2 + 1), o3 > 1 && B2(o3);
1266
1269
  }, [T2]), L2 = na((e3, { size: t3 }) => {
1267
1270
  const o3 = Math.floor(t3.height / T2);
1268
- A2(o3);
1271
+ E2(o3);
1269
1272
  }, [T2]), H2 = ia(), W2 = H2.getMode();
1270
1273
  let z2 = null;
1271
1274
  "edit" === W2?.key && (z2 = W2.args?.stateAndCoords);
1272
1275
  const $2 = C(() => {
1273
1276
  let e3 = z2?.editState;
1274
- return e3 || (e3 = Ra(() => u2.getRange(h2).getCell())), x(E, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "row", gap: 4 }, children: x(Ma, { ref: S2, activeCoords: h2, sheet: u2, onFocus: () => {
1277
+ return e3 || (e3 = Ra(() => u2.getRange(h2).getCell())), x(A, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "row", gap: 4 }, children: x(Ma, { ref: S2, activeCoords: h2, sheet: u2, onFocus: () => {
1275
1278
  a2?.startEdit({ autoFocus: false, editMode: true, cell: h2 });
1276
1279
  }, defaultTextStyle: v2, useRichStyling: false, disabled: k2, onChangeEdit: (e4) => {
1277
1280
  if (void 0 !== e4.dirty) {
@@ -1293,31 +1296,31 @@ const vl = (e2, t2) => x(Cl, { ref: t2, ...e2 }), Tl = k(S((e2, t2) => {
1293
1296
  a2.submitEdit();
1294
1297
  } }), x(He, { sx: { padding: "0px", margin: "0px 0px", border: "none !important", "&.Mui-focusVisible": { border: "none" }, "&:hover:not([disabled])": { border: "none" } }, dense: true, outlined: false, disabled: true, "aria-label": "commit-formula-function", icon: re(x(Do, { sx: { transform: "scale(0.85)" } })), tooltipProps: { label: "Insert Function", simple: true }, onMouseDown: (e3) => {
1295
1298
  0 === e3.button && e3.preventDefault();
1296
- } })] }), [k2, z2]), U2 = wa(), [j2, _2] = D(false), q2 = C(() => b(E, { sx: { display: "flex", flexDirection: "row", flex: "1 1 100%", gap: (e3) => e3.spacing(0.5), alignItems: "start" }, children: [G2, b(X, { elevation: 0, sx: { display: "flex", flexDirection: "row", flex: "1 1 100%", position: "relative", fontFamily: (e3) => e3.typography.fontFamily, fontSize: 11 * r.getDeviceScale(), "& .editor-placement": { top: "2px !important" }, boxShadow: "none", borderRadius: (e3) => `${e3.shape.borderRadius}px`, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, border: (e3) => `solid ${k2 ? e3.palette.action.disabled : ka(e3.palette.divider, 0.2)} 1px`, "& textarea": { color: (e3) => k2 ? `${e3.palette.text.disabled} !important` : e3.palette.text.primary }, "& .react-resizable-handle": { width: "100%", height: "8px", backgroundColor: "transparent", boxSizing: "content-box", zIndex: 1e3 }, "& .react-resizable-handle-s": { position: "absolute", bottom: "-10px", cursor: "s-resize" } }, onFocus: () => _2(true), onBlur: () => _2(false), onMouseDown: (e3) => {
1299
+ } })] }), [k2, z2]), U2 = wa(), [j2, _2] = D(false), q2 = C(() => b(A, { sx: { display: "flex", flexDirection: "row", flex: "1 1 100%", gap: (e3) => e3.spacing(0.5), alignItems: "start" }, children: [G2, b(X, { elevation: 0, sx: { display: "flex", flexDirection: "row", flex: "1 1 100%", position: "relative", fontFamily: (e3) => e3.typography.fontFamily, fontSize: 11 * r.getDeviceScale(), "& .editor-placement": { top: "2px !important" }, boxShadow: "none", borderRadius: (e3) => `${e3.shape.borderRadius}px`, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, border: (e3) => `solid ${k2 ? e3.palette.action.disabled : ka(e3.palette.divider, 0.2)} 1px`, "& textarea": { color: (e3) => k2 ? `${e3.palette.text.disabled} !important` : e3.palette.text.primary }, "& .react-resizable-handle": { width: "100%", height: "8px", backgroundColor: "transparent", boxSizing: "content-box", zIndex: 1e3 }, "& .react-resizable-handle-s": { position: "absolute", bottom: "-10px", cursor: "s-resize" } }, onFocus: () => _2(true), onBlur: () => _2(false), onMouseDown: (e3) => {
1297
1300
  e3.target?.classList.contains("react-resizable-handle") && e3.preventDefault();
1298
- }, children: [x(E, { className: "formula-editor", sx: { display: "flex", flexDirection: "row", flex: "1 1 100%", position: "relative", alignSelf: "baseline", paddingLeft: (e3) => e3.spacing(1), paddingRight: (e3) => e3.spacing(1) }, children: x(Oa, { height: P2, draggableOpts: { grid: [T2, T2] }, minConstraints: [T2, T2], maxConstraints: [15 * T2, 15 * T2], onResize: L2, onResizeStop: I2, resizeHandles: ["s"], axis: "y", style: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: $2 }) }), x(He, { sx: { padding: "0px", margin: "0px 0px", border: "none !important", "&.Mui-focusVisible": { border: "none" }, "&:hover:not([disabled])": { border: "none" } }, dense: true, outlined: false, "aria-label": "toggle-expand-formula-edit", icon: re(x(N2 > 1 ? _n : qn, {})), tooltipProps: { label: (N2 > 1 ? "Collapse" : "Expand") + " Formula Bar", simple: true }, onMouseDown: (e3) => {
1301
+ }, children: [x(A, { className: "formula-editor", sx: { display: "flex", flexDirection: "row", flex: "1 1 100%", position: "relative", alignSelf: "baseline", paddingLeft: (e3) => e3.spacing(1), paddingRight: (e3) => e3.spacing(1) }, children: x(Oa, { height: P2, draggableOpts: { grid: [T2, T2] }, minConstraints: [T2, T2], maxConstraints: [15 * T2, 15 * T2], onResize: L2, onResizeStop: I2, resizeHandles: ["s"], axis: "y", style: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: $2 }) }), x(He, { sx: { padding: "0px", margin: "0px 0px", border: "none !important", "&.Mui-focusVisible": { border: "none" }, "&:hover:not([disabled])": { border: "none" } }, dense: true, outlined: false, "aria-label": "toggle-expand-formula-edit", icon: re(x(N2 > 1 ? _n : qn, {})), tooltipProps: { label: (N2 > 1 ? "Collapse" : "Expand") + " Formula Bar", simple: true }, onMouseDown: (e3) => {
1299
1302
  0 === e3.button && e3.preventDefault();
1300
1303
  }, onClick: () => {
1301
1304
  const e3 = N2 > 1 ? 1 : F2;
1302
- R2(e3 * T2 + 1), A2(e3);
1303
- } }), x(E, { sx: { position: "absolute", width: "100%", height: "2px", bottom: "0", willChange: "opacity", transition: "opacity 60ms ease-in", opacity: j2 ? 1 : 0, borderBottomWidth: "2px", borderBottomStyle: "solid", borderBottomColor: (e3) => e3.palette.primary.main, borderRadius: (e3) => `${e3.shape.borderRadius}px` } })] })] }), [G2, $2, j2, N2, T2]), K2 = C(() => V2 || q2 ? !V2 && q2 ? q2 : V2 && !q2 ? V2 : x(y, { children: x(ma, { fixedPane: "before", minBefore: "165px", minAfter: "200px", paneBeforeProps: { style: { alignItems: "flex-start" } }, paneAfterProps: { style: { overflow: "visible" } }, resizerProps: { style: { backgroundImage: `url("data:image/svg+xml,%3Csvg width='6' height='13' viewBox='0 0 6 13' version='1.1' fill='${U2.palette.text.icon ?? U2.palette.action.active}' xmlns='http://www.w3.org/2000/svg' xmlns:svg='http://www.w3.org/2000/svg'%3E%3Cpath d='m 4.5961932,11.36243 c 0,0.88365 -0.71627,1.59991 -1.59991,1.59991 -0.88365,0 -1.60005,-0.71626 -1.60005,-1.59991 0,-0.88365 0.7164,-1.6000508 1.60005,-1.6000508 0.88364,0 1.59991,0.7164008 1.59991,1.6000508 m 0,-4.881294 c 0,0.88364 -0.71627,1.60004 -1.59991,1.60004 -0.88365,0 -1.60005,-0.7164 -1.60005,-1.60004 0,-0.88365 0.7164,-1.60005 1.60005,-1.60005 0.88364,0 1.59991,0.7164 1.59991,1.60005 m 0,-4.881226 c 0,0.88365 -0.71627,1.60005 -1.59991,1.60005 -0.88365,0 -1.60005,-0.7164 -1.60005,-1.60005 0,-0.88365 0.7164,-1.59991 1.60005,-1.59991 0.88364,0 1.59991,0.71626 1.59991,1.59991' /%3E%3C/svg%3E%0A")`, backgroundRepeat: "no-repeat", backgroundPosition: "center 6.5px", minWidth: "18px" } }, elementBefore: V2, elementAfter: q2 }) }) : null, [V2, q2]), Z2 = ca(t2, () => ({ isFormulaBarElement: () => true, getNamedCollectionEditorElement: () => O2.current }), []);
1304
- return x(E, { sx: { display: "flex", flexDirection: "row", gap: (e3) => e3.spacing(0.5), ...o2 }, ref: Z2, ...p2, children: K2 });
1305
+ R2(e3 * T2 + 1), E2(e3);
1306
+ } }), x(A, { sx: { position: "absolute", width: "100%", height: "2px", bottom: "0", willChange: "opacity", transition: "opacity 60ms ease-in", opacity: j2 ? 1 : 0, borderBottomWidth: "2px", borderBottomStyle: "solid", borderBottomColor: (e3) => e3.palette.primary.main, borderRadius: (e3) => `${e3.shape.borderRadius}px` } })] })] }), [G2, $2, j2, N2, T2]), K2 = C(() => V2 || q2 ? !V2 && q2 ? q2 : V2 && !q2 ? V2 : x(y, { children: x(ma, { fixedPane: "before", minBefore: "165px", minAfter: "200px", paneBeforeProps: { style: { alignItems: "flex-start" } }, paneAfterProps: { style: { overflow: "visible" } }, resizerProps: { style: { backgroundImage: `url("data:image/svg+xml,%3Csvg width='6' height='13' viewBox='0 0 6 13' version='1.1' fill='${U2.palette.text.icon ?? U2.palette.action.active}' xmlns='http://www.w3.org/2000/svg' xmlns:svg='http://www.w3.org/2000/svg'%3E%3Cpath d='m 4.5961932,11.36243 c 0,0.88365 -0.71627,1.59991 -1.59991,1.59991 -0.88365,0 -1.60005,-0.71626 -1.60005,-1.59991 0,-0.88365 0.7164,-1.6000508 1.60005,-1.6000508 0.88364,0 1.59991,0.7164008 1.59991,1.6000508 m 0,-4.881294 c 0,0.88364 -0.71627,1.60004 -1.59991,1.60004 -0.88365,0 -1.60005,-0.7164 -1.60005,-1.60004 0,-0.88365 0.7164,-1.60005 1.60005,-1.60005 0.88364,0 1.59991,0.7164 1.59991,1.60005 m 0,-4.881226 c 0,0.88365 -0.71627,1.60005 -1.59991,1.60005 -0.88365,0 -1.60005,-0.7164 -1.60005,-1.60005 0,-0.88365 0.7164,-1.59991 1.60005,-1.59991 0.88364,0 1.59991,0.71626 1.59991,1.59991' /%3E%3C/svg%3E%0A")`, backgroundRepeat: "no-repeat", backgroundPosition: "center 6.5px", minWidth: "18px" } }, elementBefore: V2, elementAfter: q2 }) }) : null, [V2, q2]), Z2 = ca(t2, () => ({ isFormulaBarElement: () => true, getNamedCollectionEditorElement: () => O2.current }), []);
1307
+ return x(A, { sx: { display: "flex", flexDirection: "row", gap: (e3) => e3.spacing(0.5), ...o2 }, ref: Z2, ...p2, children: K2 });
1305
1308
  }));
1306
- Tl.displayName = "FormulaBar";
1307
- const Dl = k(S((e2, t2) => {
1309
+ Dl.displayName = "FormulaBar";
1310
+ const Pl = k(S((e2, t2) => {
1308
1311
  const { filter: o2, commands: n2, disabled: a2, sx: r2, floatReference: l2, ...i2 } = e2, s2 = C(() => ({}), []), d2 = C(() => ({ commandHook: { beforeExecute: (e3, t3) => l2.closeAll(), onExecute() {
1309
1312
  }, onError() {
1310
1313
  console.log("onError");
1311
1314
  } }, disabled: a2, parentFloat: l2 }), [a2, l2]), c2 = C(() => ({ ...s2, ...d2, variant: oa.Menuitem }), [s2, d2]), m2 = b(y, { children: [x(le, { ...c2, command: n2.getCommand("sortAscending"), icon: re(x(ft, {})) }), x(le, { ...c2, command: n2.getCommand("sortDescending"), icon: re(x(xt, {})) }), x(ie, { orientation: "horizontal" }), x(le, { ...c2, command: n2.getCommand("autoFilterClear"), icon: re(x(wt, {})) }), []] });
1312
- return x(E, { ref: t2, sx: { paddingTop: "4px", paddingBottom: "4px", display: "flex", flexDirection: "column", ...r2 }, ...i2, children: m2 });
1315
+ return x(A, { ref: t2, sx: { paddingTop: "4px", paddingBottom: "4px", display: "flex", flexDirection: "column", ...r2 }, ...i2, children: m2 });
1313
1316
  }));
1314
- Dl.displayName = "FilterColumnMenu";
1315
- const Pl = k(S((e2, t2) => {
1317
+ Pl.displayName = "FilterColumnMenu";
1318
+ const Rl = k(S((e2, t2) => {
1316
1319
  const { children: o2, className: n2, disabled: a2, style: r2, filter: l2, ...i2 } = e2, s2 = ca(t2, () => ({ isFilters: () => true }), []);
1317
1320
  return x("div", { ref: s2, className: In("filters", n2), style: { position: "relative", display: "flex", flexDirection: "column", alignItems: "center", gap: "8px", ...r2 }, ...i2, children: b("div", { style: { flex: "1 1 100%", display: "flex", minHeight: "100px", minWidth: "220px", alignItems: "center", border: "grey solid 1px", padding: "4px 4px", overflow: "hidden", flexDirection: "column", justifyContent: "space-evenly", marginTop: "4px", marginBottom: "4px", marginLeft: "16px", marginRight: "16px" }, children: [x("div", { children: l2.getName() }), x("div", { children: "Filter Widget" })] }) });
1318
1321
  }));
1319
- Pl.displayName = "Filters";
1320
- const Rl = k(S((e2, t2) => {
1322
+ Rl.displayName = "Filters";
1323
+ const Ml = k(S((e2, t2) => {
1321
1324
  const { children: o2, sheet: n2, style: a2, className: r2, value: l2, index: i2, editing: s2, editable: d2, disabled: c2, selectedIndex: m2, dragging: p2, borderColor: u2, borderWidth: g2, activeColor: h2, background: f2 = "white", tabRadius: w2 = 4, gridTheme: k2, ...S2 } = e2, [C2, v2] = D(() => !!n2 && n2.getProtection().isLocked()), [T2, P2] = D(() => n2 ? n2.getTabColor() : null);
1322
1325
  Pa(n2, { onProtectionChange: () => {
1323
1326
  v2(n2.getProtection().isLocked());
@@ -1330,15 +1333,15 @@ const Rl = k(S((e2, t2) => {
1330
1333
  let F2 = null, B2 = null;
1331
1334
  if (T2 || p2) {
1332
1335
  let e3 = f2;
1333
- T2 ? (B2 = T2.toBlackOrWhite().toCSS(), e3 = T2?.toCSS()) : M2 || (e3 = R2.palette.background.paper), F2 = x(E, { sx: { position: "absolute", boxSizing: "border-box", top: "3px", left: "4px", right: "4.5px", bottom: "1.5px", opacity: M2 ? "50%" : "100%", borderRadius: "4px", border: (e4) => M2 ? `${f2} solid 1px` : `${e4.palette.divider} solid 1px`, background: M2 && T2 ? `linear-gradient(0deg, ${e3} 0%, transparent)` : e3 } });
1336
+ T2 ? (B2 = T2.toBlackOrWhite().toCSS(), e3 = T2?.toCSS()) : M2 || (e3 = R2.palette.background.paper), F2 = x(A, { sx: { position: "absolute", boxSizing: "border-box", top: "3px", left: "4px", right: "4.5px", bottom: "1.5px", opacity: M2 ? "50%" : "100%", borderRadius: "4px", border: (e4) => M2 ? `${f2} solid 1px` : `${e4.palette.divider} solid 1px`, background: M2 && T2 ? `linear-gradient(0deg, ${e3} 0%, transparent)` : e3 } });
1334
1337
  }
1335
1338
  let N2 = null;
1336
1339
  "string" == typeof u2 ? N2 = u2 : u2?.toCSS && (N2 = u2.toCSS());
1337
- const A2 = M2 ? x(E, { sx: { width: "100%", borderRadius: "4px", minWidth: "4px", height: "2px", backgroundColor: (e3) => e3.palette.primary.main } }) : null;
1338
- return x(Ca, { theme: M2 ? k2 ?? R2 : R2, children: x(E, { ref: t2, className: In(r2), sx: { ...a2, display: "flex", flexDirection: "column", minHeight: "0px", fontWeight: M2 ? "700" : "400", fontSize: "0.85rem", letterSpacing: "0", lineHeight: "1", textTransform: "none", minWidth: "unset", cursor: p2 ? "grabbing" : void 0 }, ...S2, children: x(pa, { style: { flex: "1 1 100%", display: "flex", flexDirection: "row" }, radius: w2, strokeColor: M2 ? N2 : "transparent", children: x(z, { sx: { textTransform: "none", borderRadius: "0px", minHeight: "0px", paddingLeft: "11px", paddingRight: "12px", paddingTop: "3px", flex: "1 1 100%", paddingBottom: "3px", fontWeight: M2 ? "700" : "400", fontSize: "0.85rem", letterSpacing: "0", transition: "none", cursor: p2 ? "grabbing" : void 0, color: M2 ? "primary" : B2 || "text.secondary", backgroundColor: M2 ? f2 : "transparent", "&:hover:not([disabled])": { backgroundColor: M2 ? f2 : "transparent" }, "& input": { color: (e3) => `${e3.palette.text.primary}`, textAlign: "center", fontWeight: "500" }, marginTop: "0px", minWidth: "unset" }, disabled: c2, disableRipple: s2, component: "div", children: b(y, { children: [F2, b(E, { sx: { zIndex: "1", display: "flex", flexDirection: "row", alignItems: "center" }, children: [b(E, { sx: { display: "flex", flexDirection: "column", alignItems: "center", rowGap: "1px", lineHeight: "1", marginTop: M2 ? void 0 : "1px" }, children: [o2, A2] }), C2 ? x(Kn, { sx: { scale: "0.80", marginLeft: "2px", width: "22px", height: "22px" }, color: "secondary" }) : x(E, { sx: { minHeight: "22px" } })] })] }) }, l2 + ":" + i2) }) }) });
1340
+ const E2 = M2 ? x(A, { sx: { width: "100%", borderRadius: "4px", minWidth: "4px", height: "2px", backgroundColor: (e3) => e3.palette.primary.main } }) : null;
1341
+ return x(Ca, { theme: M2 ? k2 ?? R2 : R2, children: x(A, { ref: t2, className: In(r2), sx: { ...a2, display: "flex", flexDirection: "column", minHeight: "0px", fontWeight: M2 ? "700" : "400", fontSize: "0.85rem", letterSpacing: "0", lineHeight: "1", textTransform: "none", minWidth: "unset", cursor: p2 ? "grabbing" : void 0 }, ...S2, children: x(pa, { style: { flex: "1 1 100%", display: "flex", flexDirection: "row" }, radius: w2, strokeColor: M2 ? N2 : "transparent", children: x(z, { sx: { textTransform: "none", borderRadius: "0px", minHeight: "0px", paddingLeft: "11px", paddingRight: "12px", paddingTop: "3px", flex: "1 1 100%", paddingBottom: "3px", fontWeight: M2 ? "700" : "400", fontSize: "0.85rem", letterSpacing: "0", transition: "none", cursor: p2 ? "grabbing" : void 0, color: M2 ? "primary" : B2 || "text.secondary", backgroundColor: M2 ? f2 : "transparent", "&:hover:not([disabled])": { backgroundColor: M2 ? f2 : "transparent" }, "& input": { color: (e3) => `${e3.palette.text.primary}`, textAlign: "center", fontWeight: "500" }, marginTop: "0px", minWidth: "unset" }, disabled: c2, disableRipple: s2, component: "div", children: b(y, { children: [F2, b(A, { sx: { zIndex: "1", display: "flex", flexDirection: "row", alignItems: "center" }, children: [b(A, { sx: { display: "flex", flexDirection: "column", alignItems: "center", rowGap: "1px", lineHeight: "1", marginTop: M2 ? void 0 : "1px" }, children: [o2, E2] }), C2 ? x(Kn, { sx: { scale: "0.80", marginLeft: "2px", width: "22px", height: "22px" }, color: "secondary" }) : x(A, { sx: { minHeight: "22px" } })] })] }) }, l2 + ":" + i2) }) }) });
1339
1342
  }));
1340
- Rl.displayName = "SheetTab";
1341
- const Ml = k(S((e2, t2) => {
1343
+ Ml.displayName = "SheetTab";
1344
+ const Fl = k(S((e2, t2) => {
1342
1345
  const { workbook: o2, index: n2, commands: a2, scope: r2 = "sheet", disabled: l2, floatReference: i2, sx: s2, className: d2, tabStripRef: c2, ...m2 } = e2, [p2, u2] = D(o2?.getProtection());
1343
1346
  Pa(o2, { onProtectionChange: (e3) => {
1344
1347
  u2(e3?.getProtection());
@@ -1353,10 +1356,10 @@ const Ml = k(S((e2, t2) => {
1353
1356
  c2?.startEdit(n2);
1354
1357
  });
1355
1358
  }, disabled: l2 || !p2.isStructureAllowed(), parentFloat: i2, children: ["Rename", "sheet" !== r2 ? " Sheet" : ""] }), x(le, { command: a2.getCommand("duplicateSheet"), ...f2, variant: oa.Menuitem }), x(le, { command: a2?.getCommand("protectionSheetToggle"), ...f2, variant: oa.Menuitem, icon: x(Kn, {}) }), x(Ir, { variant: oa.Menuitem, command: a2.getCommand("formatSheetTabColor"), icon: x(Ie, {}), panelProps: { disableAlpha: true, autoColorLabel: "No Tab Color", autoColorPosition: lr.End }, parentFloat: i2 }), x(ie, { orientation: "horizontal" }), x(le, { command: a2.getCommand("hideSheet"), ...f2, variant: oa.Menuitem, icon: re(x(Po, {})) })] });
1356
- return x(E, { ref: t2, className: In("menu", d2), sx: { ...s2 }, ...m2, children: w2 });
1359
+ return x(A, { ref: t2, className: In("menu", d2), sx: { ...s2 }, ...m2, children: w2 });
1357
1360
  }));
1358
- Ml.displayName = "SheetTabMenu";
1359
- const Fl = k(S((e2, t2) => {
1361
+ Fl.displayName = "SheetTabMenu";
1362
+ const Bl = k(S((e2, t2) => {
1360
1363
  const { workbook: o2, gridStyle: n2, floatReference: a2, closeFloatAll: r2, className: l2, ...i2 } = e2, [s2, d2] = D(o2?.getSheets().getItems()), [c2, m2] = D(o2?.getProtection());
1361
1364
  Pa(o2, { onSheetsChange: (e3) => {
1362
1365
  d2(e3.getSheets().getItems());
@@ -1370,9 +1373,9 @@ const Fl = k(S((e2, t2) => {
1370
1373
  if (i3 === u.Visibility.VeryHidden) continue;
1371
1374
  const s3 = r3 === l3, d3 = l3.getProtection().isLocked(), m3 = l3.getTabColor(), p3 = n2?.body.fill ?? "transparent";
1372
1375
  let g2 = null, h2 = null, f2 = p3;
1373
- m3 && (f2 = m3.toCSS(), s3 || (h2 = m3.toBlackOrWhite().toCSS()), g2 = x(E, { sx: { position: "absolute", display: "flex", flexDirection: "column", top: "4px", left: "40px", right: "8px", bottom: "4px", background: s3 ? f2 : "transparent", borderRadius: "4px", border: `solid 1px ${n2.header.edgeStrokeFill}` }, children: x(E, { sx: { flex: "1 1 100%", boxSizing: "content-box", opacity: s3 || i3 === u.Visibility.Hidden ? "50%" : "100%", border: (e4) => s3 ? `${p3} solid 1.5px` : `${e4.palette.divider} solid 1px`, background: s3 && m3 ? `linear-gradient(0deg, ${f2} 0%, ${p3})` : f2, borderRadius: "4px" } }) }));
1376
+ m3 && (f2 = m3.toCSS(), s3 || (h2 = m3.toBlackOrWhite().toCSS()), g2 = x(A, { sx: { position: "absolute", display: "flex", flexDirection: "column", top: "4px", left: "40px", right: "8px", bottom: "4px", background: s3 ? f2 : "transparent", borderRadius: "4px", border: `solid 1px ${n2.header.edgeStrokeFill}` }, children: x(A, { sx: { flex: "1 1 100%", boxSizing: "content-box", opacity: s3 || i3 === u.Visibility.Hidden ? "50%" : "100%", border: (e4) => s3 ? `${p3} solid 1.5px` : `${e4.palette.divider} solid 1px`, background: s3 && m3 ? `linear-gradient(0deg, ${f2} 0%, ${p3})` : f2, borderRadius: "4px" } }) }));
1374
1377
  let w2 = null;
1375
- d3 && (w2 = x(Kn, { color: "secondary" })), i3 !== u.Visibility.Visible && (w2 = re(x(Po, { style: { opacity: c2.isStructureAllowed() ? 1 : 0.7 }, color: "secondary" }))), w2 && (w2 = x(E, { sx: { display: "flex", flex: "1 1 100%", alignItems: "center", ml: "16px", "& *": { lineHeight: "1em", fontSize: "1.3em" } }, children: w2 })), e3.push(x(Ne, { disabled: !c2.isStructureAllowed() && i3 === u.Visibility.Hidden, sx: { color: (e4) => {
1378
+ d3 && (w2 = x(Kn, { color: "secondary" })), i3 !== u.Visibility.Visible && (w2 = re(x(Po, { style: { opacity: c2.isStructureAllowed() ? 1 : 0.7 }, color: "secondary" }))), w2 && (w2 = x(A, { sx: { display: "flex", flex: "1 1 100%", alignItems: "center", ml: "16px", "& *": { lineHeight: "1em", fontSize: "1.3em" } }, children: w2 })), e3.push(x(Ne, { disabled: !c2.isStructureAllowed() && i3 === u.Visibility.Hidden, sx: { color: (e4) => {
1376
1379
  let t4 = s3 ? e4.palette.primary.main : e4.palette.text.secondary;
1377
1380
  return h2 && (t4 = h2), i3 === u.Visibility.Hidden && (t4 = za(t4, e4.palette.action.disabledOpacity)), t4;
1378
1381
  }, borderLeft: (e4) => `${s3 ? e4.palette.primary.main : "transparent"} solid 2px`, paddingLeft: "4px", fontWeight: s3 ? "700" : "400", "&:hover": { fontWeight: "700" } }, icon: s3 ? x(Ye, {}) : void 0, onMouseDown: (e4) => e4.preventDefault(), onMouseUp: () => {
@@ -1383,18 +1386,18 @@ const Fl = k(S((e2, t2) => {
1383
1386
  console.error(e4);
1384
1387
  }
1385
1388
  });
1386
- }, children: b(y, { children: [g2, b(E, { sx: { paddingRight: "0px", paddingLeft: "4px", display: "flex", flexDirection: "row", flex: "1 1 100%", overflow: "hidden", alignItems: "center", zIndex: 2 }, children: [b(E, { className: "sheet-name", sx: { display: "flex", flexDirection: "column", paddingLeft: "8px", paddingRight: "8px", alignItems: "center" }, children: [l3.getName(), x(E, { sx: { height: "0px", opacity: "0", fontWeight: "700" }, children: l3.getName() })] }), w2] })] }) }, "" + o3));
1389
+ }, children: b(y, { children: [g2, b(A, { sx: { paddingRight: "0px", paddingLeft: "4px", display: "flex", flexDirection: "row", flex: "1 1 100%", overflow: "hidden", alignItems: "center", zIndex: 2 }, children: [b(A, { className: "sheet-name", sx: { display: "flex", flexDirection: "column", paddingLeft: "8px", paddingRight: "8px", alignItems: "center" }, children: [l3.getName(), x(A, { sx: { height: "0px", opacity: "0", fontWeight: "700" }, children: l3.getName() })] }), w2] })] }) }, "" + o3));
1387
1390
  }
1388
1391
  return e3;
1389
1392
  }, [o2, c2, s2, a2, n2]);
1390
- return x(E, { ref: t2, className: In("menu", l2), ...i2, children: p2 });
1393
+ return x(A, { ref: t2, className: In("menu", l2), ...i2, children: p2 });
1391
1394
  }));
1392
- Fl.displayName = "SheetsAllMenu";
1393
- let Bl = false, Nl = false;
1395
+ Bl.displayName = "SheetsAllMenu";
1396
+ let Nl = false, El = false;
1394
1397
  let Al = null;
1395
- const El = async (e2) => {
1398
+ const Il = async (e2) => {
1396
1399
  const t2 = await g.getDetails();
1397
- if (Nl || t2.isEval()) {
1400
+ if (El || t2.isEval()) {
1398
1401
  try {
1399
1402
  const e3 = top ?? window;
1400
1403
  e3.SheetXL || (e3.SheetXL = Object.freeze({ getSelectedWorkbook: () => Al?.getWorkbook(), getSelectedSheet: () => Al?.getWorkbook().getSelectedSheet(), getSelectedRange: () => Al?.getWorkbook().getSelectedRange(), getRange: (e4) => Al?.getWorkbook().getRange(e4), getSelectedWorkbookElement: () => Al, getLicenseManager: () => g, moreExamples: () => {
@@ -1402,12 +1405,12 @@ const El = async (e2) => {
1402
1405
  console.table(e4);
1403
1406
  } }));
1404
1407
  } catch (e3) {
1405
- e3 instanceof DOMException || console.error(e3), Bl = true;
1408
+ e3 instanceof DOMException || console.error(e3), Nl = true;
1406
1409
  }
1407
- if (Al !== e2 && (Al = e2, !Bl)) try {
1408
- Bl = true;
1410
+ if (Al !== e2 && (Al = e2, !Nl)) try {
1411
+ Nl = true;
1409
1412
  (top ?? window).SheetXL && (await g._validate(true), g.wasPrinted() && (() => {
1410
- Ga.consoleWithNoSource("%cTip: You can access the API directly in the console.\nTry\n%c>%c SheetXL.getRange('b2:c3').setValues([[42, 'Hello Word'], [new Date(), true]]) %c\n>%c SheetXL.moreExamples()", "color:#ffa726;", "font-family:monospace;color:#1976d2;font-size:12px;", "font-family:monospace;", "font-family:monospace;color:#1976d2;font-size:12px;", "font-family:monospace;"), Bl = true;
1413
+ Ga.consoleWithNoSource("%cTip: You can access the API directly in the console.\nTry\n%c>%c SheetXL.getRange('b2:c3').setValues([[42, 'Hello Word'], [new Date(), true]]) %c\n>%c SheetXL.moreExamples()", "color:#ffa726;", "font-family:monospace;color:#1976d2;font-size:12px;", "font-family:monospace;", "font-family:monospace;color:#1976d2;font-size:12px;", "font-family:monospace;"), Nl = true;
1411
1414
  const e3 = document.getElementById("openEditorLink");
1412
1415
  e3 && e3.addEventListener("click", (e4) => {
1413
1416
  e4.preventDefault(), console.log("openScriptEditor called from console");
@@ -1417,83 +1420,83 @@ const El = async (e2) => {
1417
1420
  e3 instanceof DOMException || console.error(e3);
1418
1421
  }
1419
1422
  }
1420
- }, Il = (e2) => {
1421
- Nl = e2;
1422
- }, Ll = 0.12, Hl = (e2, t2) => {
1423
+ }, Ll = (e2) => {
1424
+ El = e2;
1425
+ }, Hl = 0.12, Wl = (e2, t2) => {
1423
1426
  const o2 = {}, n2 = (e3) => {
1424
1427
  const t3 = e3.palette?.background.default ?? "rgba(255,255,255,1)";
1425
- return { text: { fontFamily: e3.typography?.fontFamily ?? "Calibri", fontSize: e3.typography?.fontSize ?? 8.25, fontWeight: e3.typography?.fontWeightRegular ?? "400", fill: "dark" === e3.palette.mode ? e3.palette?.text?.secondary : e3.palette?.text?.primary }, fill: t3, strokeFill: Ro(t3, Ll, e3.palette?.mode), darkMode: "dark" === e3.palette.mode };
1428
+ return { text: { fontFamily: e3.typography?.fontFamily ?? "Calibri", fontSize: e3.typography?.fontSize ?? 8.25, fontWeight: e3.typography?.fontWeightRegular ?? "400", fill: "dark" === e3.palette.mode ? e3.palette?.text?.secondary : e3.palette?.text?.primary }, fill: t3, strokeFill: Ro(t3, Hl, e3.palette?.mode), darkMode: "dark" === e3.palette.mode };
1426
1429
  }, a2 = n2(t2);
1427
- o2.body = n2(e2), o2.header = { ...o2.body, strokeFill: Ro(o2.body.fill, Ll, e2.palette?.mode), fill: t2 && "dark" === e2.palette.mode && t2.palette.mode !== e2.palette.mode ? o2.body.fill : Ro(o2.body.fill, 0.055, e2.palette?.mode), edgeStrokeFill: "dark" === e2.palette.mode ? o2.body.strokeFill : Ro(o2.body.fill, 0.328, e2.palette?.mode) }, o2.headerHover = (t3) => ({ ...o2.header, strokeFill: Ro(t3?.fill ?? o2.body.fill, 0.22, e2.palette?.mode), fill: Ro(t3?.fill ?? o2.header.fill, 0.065, e2.palette?.mode), text: { ...t3?.text, fontWeight: e2.typography?.fontWeightBold } });
1430
+ o2.body = n2(e2), o2.header = { ...o2.body, strokeFill: Ro(o2.body.fill, Hl, e2.palette?.mode), fill: t2 && "dark" === e2.palette.mode && t2.palette.mode !== e2.palette.mode ? o2.body.fill : Ro(o2.body.fill, 0.055, e2.palette?.mode), edgeStrokeFill: "dark" === e2.palette.mode ? o2.body.strokeFill : Ro(o2.body.fill, 0.328, e2.palette?.mode) }, o2.headerHover = (t3) => ({ ...o2.header, strokeFill: Ro(t3?.fill ?? o2.body.fill, 0.22, e2.palette?.mode), fill: Ro(t3?.fill ?? o2.header.fill, 0.065, e2.palette?.mode), text: { ...t3?.text, fontWeight: e2.typography?.fontWeightBold } });
1428
1431
  const r2 = Ro("dark" !== e2.palette.mode ? e2.palette.primary.light : e2.palette.primary.main, 0.055, e2.palette?.mode);
1429
- o2.headerSelect = { ...o2.header, strokeFill: e2.palette.primary.main, fill: za(r2, 0.2), text: { ...o2.header.text, fill: e2.palette.primary.main }, dividerStrokeFill: za(r2, 0.7) }, o2.headerSelectAll = { ...o2.headerSelect, fill: za(r2, 0.9), text: { ...o2.headerSelect.text, fill: e2.palette.primary.contrastText }, edgeStrokeFill: o2.headerSelect.strokeFill }, o2.buttonSurface = { ...a2, strokeFill: Ro(a2.fill, Ll, t2.palette?.mode), fill: t2 && "dark" === t2.palette.mode && t2.palette.mode !== e2.palette.mode ? a2.fill : Ro(a2.fill, 0.055, t2.palette?.mode), edgeStrokeFill: "dark" === t2.palette.mode ? a2.strokeFill : Ro(a2.fill, 0.328, t2.palette?.mode) }, o2.headerSelection = { fill: e2.palette?.primary?.main ? za(e2.palette?.primary?.main, 0.1) : void 0, strokeFill: e2.palette?.primary?.main }, o2.headerSelectionInactive = { ...o2.headerSelection, fill: e2.palette?.divider ? za(e2.palette?.divider, 0.05) : void 0, strokeFill: "transparent" };
1432
+ o2.headerSelect = { ...o2.header, strokeFill: e2.palette.primary.main, fill: za(r2, 0.2), text: { ...o2.header.text, fill: e2.palette.primary.main }, dividerStrokeFill: za(r2, 0.7) }, o2.headerSelectAll = { ...o2.headerSelect, fill: za(r2, 0.9), text: { ...o2.headerSelect.text, fill: e2.palette.primary.contrastText }, edgeStrokeFill: o2.headerSelect.strokeFill }, o2.buttonSurface = { ...a2, strokeFill: Ro(a2.fill, Hl, t2.palette?.mode), fill: t2 && "dark" === t2.palette.mode && t2.palette.mode !== e2.palette.mode ? a2.fill : Ro(a2.fill, 0.055, t2.palette?.mode), edgeStrokeFill: "dark" === t2.palette.mode ? a2.strokeFill : Ro(a2.fill, 0.328, t2.palette?.mode) }, o2.headerSelection = { fill: e2.palette?.primary?.main ? za(e2.palette?.primary?.main, 0.1) : void 0, strokeFill: e2.palette?.primary?.main }, o2.headerSelectionInactive = { ...o2.headerSelection, fill: e2.palette?.divider ? za(e2.palette?.divider, 0.05) : void 0, strokeFill: "transparent" };
1430
1433
  const l2 = t2 ?? e2, i2 = "dark" === l2.palette.mode;
1431
1434
  return o2.selection = { fill: l2.palette?.primary?.main ? za(l2.palette?.primary?.main, 0.1) : void 0, strokeFill: l2.palette?.primary?.main }, o2.selectionInactive = { ...o2.selection, fill: l2.palette?.divider ? za(l2.palette?.divider, 0.05) : void 0, strokeFill: "transparent" }, o2.selectionRemove = { ...o2.selection, fill: za(l2.palette.warning.light, 0.05), strokeFill: l2.palette.warning.dark }, t2 && (o2.body = n2(t2)), o2.colorShadow = za(l2.palette.action.active, 0.5), o2.colorGrey = l2.palette.action.active, o2.filterDarkInvert = i2 ? "hue-rotate(180deg) invert(1) brightness(95%)" : "none", o2;
1432
- }, Wl = k(S((e2, t2) => {
1435
+ }, zl = k(S((e2, t2) => {
1433
1436
  const { children: o2, sx: n2, parentFloat: a2, ...r2 } = e2, l2 = ca(t2, () => ({}), []), [i2, s2] = qa(), d2 = M(null), c2 = M(null), [m2, p2] = w.useReducer((e3) => e3 + 1, 0), [u2, g2] = D(null), [h2, f2] = D(null), [y2, k2] = D(null), { reference: S2 } = bo({ parentFloat: a2, label: "overflow" });
1434
- A(() => {
1437
+ E(() => {
1435
1438
  c2.current = { refs: [] };
1436
1439
  const e3 = [], t3 = w.Children.toArray(o2);
1437
1440
  let n3 = 0;
1438
1441
  t3.forEach((o3, a3) => {
1439
- e3.push(x(E, { sx: { display: "flex" }, ref: (e4) => {
1442
+ e3.push(x(A, { sx: { display: "flex" }, ref: (e4) => {
1440
1443
  n3++, n3 === t3.length && p2();
1441
1444
  const o4 = { current: null };
1442
1445
  o4.current = e4, c2.current.refs[a3] = o4;
1443
1446
  }, children: o3 }, a3));
1444
1447
  }), g2(e3);
1445
- }, [o2, s2]), A(() => {
1448
+ }, [o2, s2]), E(() => {
1446
1449
  if (!u2) return;
1447
- const e3 = c2.current.refs;
1448
- if (!l2.current || !e3 || 0 === e3.length) return f2(null), void k2(null);
1449
- const t3 = l2.current?.getBoundingClientRect(), o3 = [], n3 = [];
1450
- let a3 = 0, r3 = false;
1451
- for (let o4 = 0; !r3 && o4 < e3.length; o4++) {
1452
- const n4 = e3[o4];
1453
- if (!n4) continue;
1454
- if (!n4.current) {
1455
- r3 = true;
1450
+ const e3 = c2.current.refs, t3 = e3 ? e3.length : 0;
1451
+ if (!l2.current || 0 === t3) return f2(null), void k2(null);
1452
+ const o3 = l2.current?.getBoundingClientRect(), n3 = [], a3 = [];
1453
+ let r3 = 0, i3 = false;
1454
+ for (let n4 = 0; !i3 && n4 < t3; n4++) {
1455
+ const t4 = e3[n4];
1456
+ if (!t4) continue;
1457
+ if (!t4.current) {
1458
+ i3 = true;
1456
1459
  continue;
1457
1460
  }
1458
- const l3 = n4.current.getBoundingClientRect();
1459
- a3 += l3?.width, a3 > t3.width && (r3 = true);
1461
+ const a4 = t4.current.getBoundingClientRect();
1462
+ r3 += a4?.width, r3 > o3.width && (i3 = true);
1460
1463
  }
1461
- if (!r3) return f2(null), void k2([]);
1462
- const i3 = d2.current?.getBoundingClientRect();
1463
- a3 = 0;
1464
- for (let r4 = 0; r4 < e3.length; r4++) {
1465
- const l3 = e3[r4];
1466
- let s3 = false;
1467
- if (l3.current) {
1468
- const e4 = l3.current.getBoundingClientRect();
1469
- a3 += e4?.width, a3 < t3.width - i3.width && (s3 = true);
1464
+ if (!i3) return f2(null), void k2([]);
1465
+ const s3 = d2.current?.getBoundingClientRect();
1466
+ r3 = 0;
1467
+ for (let l3 = 0; l3 < t3; l3++) {
1468
+ const t4 = e3[l3];
1469
+ let i4 = false;
1470
+ if (t4.current) {
1471
+ const e4 = t4.current.getBoundingClientRect();
1472
+ r3 += e4?.width, r3 < o3.width - s3.width && (i4 = true);
1470
1473
  }
1471
- s3 ? o3.push(u2[r4]) : n3.push(u2[r4]);
1474
+ i4 ? n3.push(u2[l3]) : a3.push(u2[l3]);
1472
1475
  }
1473
- f2(o3.length > 0 ? o3 : null), k2(n3.length > 0 ? n3 : null);
1476
+ f2(n3.length > 0 ? n3 : null), k2(a3.length > 0 ? a3 : null);
1474
1477
  }, [o2, u2, s2, S2, m2]);
1475
1478
  const C2 = na((e3) => {
1476
- const t3 = [];
1477
- for (let o4 = 0; o4 < y2.length; o4++) {
1478
- let n3 = w.Children.toArray(y2[o4]);
1479
- const a3 = n3[0];
1480
- n3 = w.Children.toArray(a3.props.children?.props.children ?? a3.props.children);
1481
- const r3 = n3[0], l3 = { ...r3.props };
1482
- l3.parentFloat && (l3.parentFloat = e3.floatReference);
1483
- const i3 = w.cloneElement(r3, l3);
1484
- t3.push(i3);
1479
+ const t3 = [], o3 = y2.length;
1480
+ for (let n4 = 0; n4 < o3; n4++) {
1481
+ const o4 = w.Children.toArray(y2[n4])[0];
1482
+ w.Children.toArray(o4.props.children?.props?.children ?? o4.props.children).forEach((o5, a3) => {
1483
+ const r3 = o5, l3 = { ...r3.props, key: `overflow-${n4}-${a3}${r3.key ?? ""}` };
1484
+ l3.parentFloat && e3 && (l3.parentFloat = e3.floatReference);
1485
+ const i3 = w.cloneElement(r3, l3);
1486
+ t3.push(i3);
1487
+ });
1485
1488
  }
1486
- const o3 = x(E, { className: "overflow-palette-popup-panel", sx: { display: "flex", flexDirection: "row", flexWrap: "wrap", rowGap: (e4) => e4.spacing(0.25), paddingTop: (e4) => e4.spacing(0.5), paddingBottom: (e4) => e4.spacing(0.5), paddingLeft: (e4) => e4.spacing(1), paddingRight: (e4) => e4.spacing(1), overflow: "hidden" }, children: t3 });
1487
- return ce({ ...e3, children: o3 });
1489
+ const n3 = x(A, { className: "overflow-palette-popup-panel", sx: { display: "flex", flexDirection: "row", flexWrap: "wrap", rowGap: (e4) => e4.spacing(0.25), paddingTop: (e4) => e4.spacing(0.5), paddingBottom: (e4) => e4.spacing(0.5), paddingLeft: (e4) => e4.spacing(1), paddingRight: (e4) => e4.spacing(1), overflow: "hidden" }, children: t3 });
1490
+ return ce({ ...e3, children: n3 });
1488
1491
  }, [y2]);
1489
- return b(E, { className: "overflow-palette", sx: { display: "flex", flexDirection: "row", flex: "1 1 100%", width: "100%", maxWidth: "100%", ...n2 }, ref: Va([l2, i2, t2]), ...r2, children: [x(E, { sx: { flexDirection: "row", display: "flex", maxWidth: "100%", flex: "1 1 100%" }, children: h2 ?? u2 }), x(E, { sx: { display: null !== y2 && 0 === y2.length ? "none" : "flex", flex: "1 1 0" }, children: x(Me, { createPopupPanel: C2, ref: d2, parentFloat: S2, createTooltip: ({ children: e3 }, t3) => x(Le, { label: "More", description: "More toolbar options…", disabled: t3, children: e3 }), icon: x(Mo, { children: x(Xn, {}) }) }) })] });
1490
- })), zl = "https://unpkg.com/@sheetxl/scripting-templates/dist", $l = (e2) => {
1492
+ return b(A, { className: "overflow-palette", sx: { display: "flex", flexDirection: "row", flex: "1 1 100%", width: "100%", maxWidth: "100%", ...n2 }, ref: Va([l2, i2, t2]), ...r2, children: [x(A, { sx: { flexDirection: "row", display: "flex", maxWidth: "100%", flex: "1 1 100%" }, children: h2 ?? u2 }), x(A, { sx: { display: null !== y2 && 0 === y2.length ? "none" : "flex", flex: "1 1 0" }, children: x(Me, { createPopupPanel: C2, ref: d2, parentFloat: S2, createTooltip: ({ children: e3 }, t3) => x(Le, { label: "More", description: "More toolbar options…", disabled: t3, children: e3 }), icon: x(Mo, { children: x(Xn, {}) }) }) })] });
1493
+ })), $l = "https://unpkg.com/@sheetxl/scripting-templates/dist", Ol = (e2) => {
1491
1494
  if (e2.metadata?.name) return e2.metadata.name;
1492
1495
  let t2 = (e2.path.split("/").pop() || "").replace(/\.[^/.]+$/, "");
1493
1496
  if ("formula" === e2.metadata?.icon) return t2.toUpperCase();
1494
1497
  t2 = t2.replace(/([a-z])([A-Z])/g, "$1 $2");
1495
1498
  return t2.replace(/[-_]/g, " ").trim().split(/\s+/).map((e3) => e3.charAt(0).toUpperCase() + e3.slice(1)).join(" ");
1496
- }, Ol = async (e2) => {
1499
+ }, Vl = async (e2) => {
1497
1500
  const t2 = Za.relativePath(e2, "./manifest.json"), o2 = await fetch(t2);
1498
1501
  if (!o2.ok) throw new Ua(`Failed to retrieve directory at '${e2}': ${o2.statusText}`);
1499
1502
  const n2 = await o2.text();
@@ -1510,7 +1513,7 @@ const El = async (e2) => {
1510
1513
  if (!n3.ok) throw new Error(`Failed to fetch file at '${t3.path}': ${n3.statusText}`);
1511
1514
  const a3 = await n3.text();
1512
1515
  let r3 = t3.metadata;
1513
- r3?.title || (r3 = { title: $l(t3), ...r3 });
1516
+ r3?.title || (r3 = { title: Ol(t3), ...r3 });
1514
1517
  return { path: t3.path, content: a3, metadata: r3 };
1515
1518
  } catch (e3) {
1516
1519
  console.error(e3.message);
@@ -1518,22 +1521,22 @@ const El = async (e2) => {
1518
1521
  return null;
1519
1522
  });
1520
1523
  return (await Promise.all(r2)).filter((e3) => null !== e3);
1521
- }, Vl = { fontSize: "0.8rem", marginRight: "4px" }, Gl = k((e2) => {
1524
+ }, Gl = { fontSize: "0.8rem", marginRight: "4px" }, Ul = k((e2) => {
1522
1525
  const { disabled: t2, snippet: o2, description: n2, handleInsert: a2, sx: r2, ...l2 } = e2;
1523
1526
  let i2;
1524
- return i2 = "formula" === o2.metadata?.icon ? x(Bo, { sx: Vl }) : "macro" === o2.metadata?.icon ? x(No, { sx: Vl }) : x(Zn, { sx: Vl }), x(Ne, { sx: { maxWidth: "460px", display: "flex", "*": { lineHeight: "1.2" }, ...r2 }, disabled: t2, icon: i2, onMouseDown: (e3) => {
1527
+ return i2 = "formula" === o2.metadata?.icon ? x(Bo, { sx: Gl }) : "macro" === o2.metadata?.icon ? x(No, { sx: Gl }) : x(Zn, { sx: Gl }), x(Ne, { sx: { maxWidth: "460px", display: "flex", "*": { lineHeight: "1.2" }, ...r2 }, disabled: t2, icon: i2, onMouseDown: (e3) => {
1525
1528
  0 === e3.button && e3.preventDefault();
1526
1529
  }, onMouseUp: (e3) => {
1527
1530
  0 === e3.button && a2(o2);
1528
1531
  }, onKeyDown: (e3) => {
1529
1532
  e3.keyCode !== ra.Enter && e3.keyCode !== ra.Space || a2(o2);
1530
- }, ...l2, children: b(E, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden" }, children: [x(I, { component: "div", children: o2.metadata?.title ?? o2.path }), x(I, { variant: "caption", component: "div", sx: { color: (e3) => za(e3.palette.text.secondary ?? e3.palette.text.primary, 0.6), overflow: "hidden", textOverflow: "ellipsis" }, children: o2.metadata?.summary })] }) });
1531
- }), Ul = k(S((e2, t2) => {
1532
- const { commands: o2, commandHook: n2, scope: a2, disabled: r2 = false, scriptPath: l2 = zl, ...i2 } = e2, [s2, d2] = D([]), [c2, m2] = D(true), p2 = ta(o2, ["executeSelectedScript"]), u2 = p2[0]?.context?.();
1533
+ }, ...l2, children: b(A, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden" }, children: [x(I, { component: "div", children: o2.metadata?.title ?? o2.path }), x(I, { variant: "caption", component: "div", sx: { color: (e3) => za(e3.palette.text.secondary ?? e3.palette.text.primary, 0.6), overflow: "hidden", textOverflow: "ellipsis" }, children: o2.metadata?.summary })] }) });
1534
+ }), jl = k(S((e2, t2) => {
1535
+ const { commands: o2, commandHook: n2, scope: a2, disabled: r2 = false, scriptPath: l2 = $l, ...i2 } = e2, [s2, d2] = D([]), [c2, m2] = D(true), p2 = ta(o2, ["executeSelectedScript"]), u2 = p2[0]?.context?.();
1533
1536
  P(() => {
1534
1537
  (async () => {
1535
1538
  try {
1536
- const e3 = await Ol(l2);
1539
+ const e3 = await Vl(l2);
1537
1540
  d2(e3);
1538
1541
  } catch (e3) {
1539
1542
  } finally {
@@ -1548,28 +1551,28 @@ const El = async (e2) => {
1548
1551
  }, i3 = [];
1549
1552
  for (let e4 = 0; e4 < s2.length; e4++) {
1550
1553
  const t4 = s2[e4];
1551
- t4 && i3.push(x(Gl, { handleInsert: l3, snippet: t4 }, t4.path));
1554
+ t4 && i3.push(x(Ul, { handleInsert: l3, snippet: t4 }, t4.path));
1552
1555
  }
1553
- const d3 = b(E, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: [i3.length > 0 ? b(y, { children: [x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: i3 }), x(ie, { orientation: "horizontal" })] }) : null, F(le, { ...a3, key: "help", command: o2.getCommand("help"), icon: re(x(_t, {})) })] });
1556
+ const d3 = b(A, { sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: [i3.length > 0 ? b(y, { children: [x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: i3 }), x(ie, { orientation: "horizontal" })] }) : null, F(le, { ...a3, key: "help", command: o2.getCommand("help"), icon: re(x(_t, {})) })] });
1554
1557
  return ce({ ...e3, children: d3 });
1555
1558
  }, [r2, n2, a2, c2, u2]);
1556
1559
  return x(me, { ref: t2, commands: o2, disabled: r2, commandHook: n2, scope: a2, label: "Insert Script", tooltip: "Inserts a script from a set of templates.", createPopupPanel: g2, icon: re(x(Fo, {})), ...i2 });
1557
- })), jl = k(S((e2, t2) => {
1560
+ })), _l = k(S((e2, t2) => {
1558
1561
  const { commands: o2, parentFloat: n2, commandButtonProps: a2, ...r2 } = e2, l2 = na((e3) => {
1559
1562
  const { commandButtonProps: t3, commandPopupProps: a3 } = e3;
1560
- return x(y, { children: b("div", { style: { display: "flex", flex: "1 1 100%" }, children: [x("div", { children: x(Wl, { parentFloat: n2, style: {}, children: x(le, { ...t3, command: o2.getCommand("saveScripts"), icon: re(x(Ao, {})) }) }) }), x("div", { style: { flex: "1 1 100%" } }), x("div", { children: x(Wl, { parentFloat: n2, style: {}, children: x(Ul, { ...t3, commands: o2 }) }) })] }) });
1563
+ return x(y, { children: b("div", { style: { display: "flex", flex: "1 1 100%" }, children: [x("div", { children: x(zl, { parentFloat: n2, style: {}, children: x(le, { ...t3, command: o2.getCommand("saveScripts"), icon: re(x(Eo, {})) }) }) }), x("div", { style: { flex: "1 1 100%" } }), x("div", { children: x(zl, { parentFloat: n2, style: {}, children: x(jl, { ...t3, commands: o2 }) }) })] }) });
1561
1564
  }, [o2]);
1562
- return x(Eo, { ref: t2, commands: o2, parentFloat: n2, commandButtonProps: a2, createToolbarPalette: l2, ...r2 });
1565
+ return x(Ao, { ref: t2, commands: o2, parentFloat: n2, commandButtonProps: a2, createToolbarPalette: l2, ...r2 });
1563
1566
  }));
1564
- jl.displayName = "ScriptEditorToolbar";
1565
- const _l = { fontSize: "1rem" }, ql = k(S((e2, t2) => {
1566
- const { scriptPath: o2 = zl, onScriptSelect: n2, sx: a2 = aa.EmptyCssProperties, className: r2, buttonMinWidth: l2 = 210, buttonMinHeight: i2 = 80, gap: s2 = 12, ...d2 } = e2, [c2, m2] = D([]), [p2, u2] = D(true), [g2, h2] = D(null);
1567
+ _l.displayName = "ScriptEditorToolbar";
1568
+ const ql = { fontSize: "1rem" }, Kl = k(S((e2, t2) => {
1569
+ const { scriptPath: o2 = $l, onScriptSelect: n2, sx: a2 = aa.EmptyCssProperties, className: r2, buttonMinWidth: l2 = 210, buttonMinHeight: i2 = 80, gap: s2 = 12, ...d2 } = e2, [c2, m2] = D([]), [p2, u2] = D(true), [g2, h2] = D(null);
1567
1570
  if (P(() => {
1568
1571
  (async () => {
1569
1572
  const e3 = [{ path: null, metadata: { title: "Blank Template...", summary: "Start with an empty script." }, content: "" }];
1570
1573
  try {
1571
1574
  u2(true), h2(null);
1572
- const t3 = await Ol(o2);
1575
+ const t3 = await Vl(o2);
1573
1576
  for (let o3 = 0; o3 < t3.length; o3++) {
1574
1577
  const n3 = t3[o3];
1575
1578
  n3 && e3.push(n3);
@@ -1580,17 +1583,17 @@ const _l = { fontSize: "1rem" }, ql = k(S((e2, t2) => {
1580
1583
  m2(e3), u2(false);
1581
1584
  }
1582
1585
  })();
1583
- }, [o2]), p2) return x(E, { display: "flex", justifyContent: "center", alignItems: "center", height: "100%", className: In(r2, "script-select"), sx: { background: (e3) => e3.palette.background.paper, zIndex: 1e3, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, ...a2 }, ...d2, children: x(Z, {}) });
1586
+ }, [o2]), p2) return x(A, { display: "flex", justifyContent: "center", alignItems: "center", height: "100%", className: In(r2, "script-select"), sx: { background: (e3) => e3.palette.background.paper, zIndex: 1e3, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, ...a2 }, ...d2, children: x(Z, {}) });
1584
1587
  let f2 = null;
1585
- g2 && (f2 = b(E, { display: "flex", justifyContent: "center", alignItems: "center", className: In(r2, "script-select", "error-results"), sx: { background: (e3) => e3.palette.error.light, flex: "0", zIndex: 1e3, flexDirection: "column", padding: (e3) => e3.spacing(1), border: (e3) => `1px solid ${e3.palette.error.main}`, borderBottomLeftRadius: 1, borderBottomRightRadius: 1, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` }, ...d2, children: [x(I, { color: "error", variant: "h6", component: "div", gutterBottom: true, children: "Error loading Templates" }), x(I, { color: "error", component: "div", children: g2 })] }));
1588
+ g2 && (f2 = b(A, { display: "flex", justifyContent: "center", alignItems: "center", className: In(r2, "script-select", "error-results"), sx: { background: (e3) => e3.palette.error.light, flex: "0", zIndex: 1e3, flexDirection: "column", padding: (e3) => e3.spacing(1), border: (e3) => `1px solid ${e3.palette.error.main}`, borderBottomLeftRadius: 1, borderBottomRightRadius: 1, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` }, ...d2, children: [x(I, { color: "error", variant: "h6", component: "div", gutterBottom: true, children: "Error loading Templates" }), x(I, { color: "error", component: "div", children: g2 })] }));
1586
1589
  const y2 = (e3) => {
1587
1590
  const t3 = e3.metadata?.icon;
1588
- return "macro" === t3 ? x(No, { sx: _l }) : "formula" === t3 ? x(Bo, { sx: _l }) : "autostart" === t3 ? x(Zn, { sx: _l }) : null;
1591
+ return "macro" === t3 ? x(No, { sx: ql }) : "formula" === t3 ? x(Bo, { sx: ql }) : "autostart" === t3 ? x(Zn, { sx: ql }) : null;
1589
1592
  };
1590
- return b(E, { ref: t2, className: In(r2, "script-select"), sx: { background: (e3) => e3.palette.background.paper, zIndex: 1e3, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, ...a2 }, ...d2, children: [b(E, { p: 3, className: "script-select-content", sx: { overflow: "auto", flex: "1 1 auto" }, children: [x(I, { variant: "h6", gutterBottom: true, children: "Script Template" }), x(I, { variant: "body2", component: "div", color: "text.secondary", gutterBottom: true, children: "Choose from a template to provide a starting point to automate tasks or create user defined functions." }), x(I, { variant: "body2", component: "div", color: "text.secondary", gutterBottom: true, children: "Templates provide a foundation to customize and meet your specific needs." }), x(E, { sx: { display: "grid", gridTemplateColumns: `repeat(auto-fill, minmax(${l2}px, 1fr))`, gap: `${s2}px`, padding: 2, paddingLeft: "0px", paddingRight: "0px" }, children: c2.map((e3, t3) => b(z, { variant: "outlined", sx: { minWidth: l2, minHeight: i2, display: "flex", flexDirection: "column", justifyContent: "flex-start", alignItems: "flex-start", textAlign: "left", padding: 2, textTransform: "none", overflow: "hidden", ...0 === t3 && { borderStyle: "dashed", marginBottom: "8px" }, ...1 === t3 && { gridColumn: "1" } }, onClick: () => n2?.(e3), children: [b(E, { sx: { display: "flex", flexDirection: "row", justifyContent: "space-between", alignItems: "center", width: "100%", marginBottom: 0.5 }, children: [x(I, { variant: "subtitle2", component: "div", children: e3.metadata?.title || e3.path.split("/").pop()?.replace(/\.\w+$/, "") || "Untitled" }), y2(e3)] }), e3.metadata?.summary && x(I, { variant: "body2", component: "div", color: "text.secondary", sx: { overflow: "hidden", display: "flex", flexDirection: "column", textOverflow: "ellipsis", alignItems: "flex-start" }, children: e3.metadata.summary })] }, `${e3.path}-${t3}`)) })] }), f2] });
1593
+ return b(A, { ref: t2, className: In(r2, "script-select"), sx: { background: (e3) => e3.palette.background.paper, zIndex: 1e3, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, ...a2 }, ...d2, children: [b(A, { p: 3, className: "script-select-content", sx: { overflow: "auto", flex: "1 1 auto" }, children: [x(I, { variant: "h6", gutterBottom: true, children: "Script Template" }), x(I, { variant: "body2", component: "div", color: "text.secondary", gutterBottom: true, children: "Choose from a template to provide a starting point to automate tasks or create user defined functions." }), x(I, { variant: "body2", component: "div", color: "text.secondary", gutterBottom: true, children: "Templates provide a foundation to customize and meet your specific needs." }), x(A, { sx: { display: "grid", gridTemplateColumns: `repeat(auto-fill, minmax(${l2}px, 1fr))`, gap: `${s2}px`, padding: 2, paddingLeft: "0px", paddingRight: "0px" }, children: c2.map((e3, t3) => b(z, { variant: "outlined", sx: { minWidth: l2, minHeight: i2, display: "flex", flexDirection: "column", justifyContent: "flex-start", alignItems: "flex-start", textAlign: "left", padding: 2, textTransform: "none", overflow: "hidden", ...0 === t3 && { borderStyle: "dashed", marginBottom: "8px" }, ...1 === t3 && { gridColumn: "1" } }, onClick: () => n2?.(e3), children: [b(A, { sx: { display: "flex", flexDirection: "row", justifyContent: "space-between", alignItems: "center", width: "100%", marginBottom: 0.5 }, children: [x(I, { variant: "subtitle2", component: "div", children: e3.metadata?.title || e3.path.split("/").pop()?.replace(/\.\w+$/, "") || "Untitled" }), y2(e3)] }), e3.metadata?.summary && x(I, { variant: "body2", component: "div", color: "text.secondary", sx: { overflow: "hidden", display: "flex", flexDirection: "column", textOverflow: "ellipsis", alignItems: "flex-start" }, children: e3.metadata.summary })] }, `${e3.path}-${t3}`)) })] }), f2] });
1591
1594
  }));
1592
- ql.displayName = "TemplateSelectPanel";
1593
- const Kl = k(S((e2, t2) => {
1595
+ Kl.displayName = "TemplateSelectPanel";
1596
+ const Xl = k(S((e2, t2) => {
1594
1597
  const { className: o2, sx: n2, editorProps: a2, commands: r2, readOnly: l2 = false, onClose: i2, autoFocusSel: s2, autoFocus: d2 = true, scripts: c2, ...m2 } = e2, p2 = wa(), [u2, g2] = D(false), h2 = M(false), [f2, y2] = D({ message: "Loading", cursor: "", dirty: false }), [w2, k2] = D(null);
1595
1598
  P(() => {
1596
1599
  let e3 = false;
@@ -1605,37 +1608,37 @@ const Kl = k(S((e2, t2) => {
1605
1608
  }, [c2]);
1606
1609
  const S2 = v((e3) => {
1607
1610
  y2((t3) => ({ ...t3, ...e3 }));
1608
- }, []), T2 = M(null), R2 = M(null), [F2, B2] = D(null), N2 = M(null), A2 = na((e3) => {
1611
+ }, []), T2 = M(null), R2 = M(null), [F2, B2] = D(null), N2 = M(null), E2 = na((e3) => {
1609
1612
  if (F2) return F2.focus(e3), true;
1610
1613
  if (s2) {
1611
1614
  const t3 = R2.current?.querySelectorAll?.(s2);
1612
1615
  if (t3 && t3.length > 0) return t3[0]?.focus?.(e3), true;
1613
1616
  }
1614
1617
  return R2.current?.focus?.(e3), false;
1615
- }, [F2, s2, d2]), H2 = C(() => x(Pe, { transitionDelay: "160ms", style: { position: "absolute", width: "100%", height: "100%" }, transparentBackground: false }), []), W2 = C(() => x(X, { elevation: 1, tabIndex: 0, sx: { display: "flex", alignItems: "center", userSelect: "none", flexGrow: 1, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, marginLeft: (e3) => e3.spacing(0.5), marginRight: (e3) => e3.spacing(0.5), marginTop: (e3) => e3.spacing(1), marginBottom: (e3) => e3.spacing(1) }, children: x(jl, { commands: r2 }) }), [p2, r2]), z2 = C(() => x(E, { className: In("script-status-panel", "status-panel"), sx: { display: "flex", alignItems: "stretch", flexDirection: "row", flex: "0", paddingLeft: "12px", paddingRight: "12px", gap: "8px", paddingTop: "1px", minHeight: "calc(1em + 8px)", margin: 0, borderTop: `solid 1px ${p2.palette.divider}` }, children: b("div", { style: { flex: "1 1 100%", display: "flex", alignItems: "center", flexDirection: "row", justifyContent: "center" }, children: [x(I, { component: "div", sx: { userSelect: "none", whiteSpace: "pre", overflow: "hidden", textOverflow: "ellipsis", flex: "1 1 100%", color: (e3) => e3.palette.text.secondary }, variant: "caption", children: f2.message }), x(I, { component: "div", sx: { userSelect: "none", whiteSpace: "pre", overflow: "hidden", textOverflow: "ellipsis", flex: "none", color: (e3) => e3.palette.text.secondary }, variant: "caption", children: f2.dirty ? "Unsaved" : "" }), x(I, { component: "div", sx: { userSelect: "none", whiteSpace: "pre", overflow: "hidden", textOverflow: "ellipsis", flex: "none", marginLeft: "8px", minWidth: "90px", display: "flex", justifyContent: "end", color: (e3) => e3.palette.text.secondary }, variant: "caption", children: f2.cursor })] }) }), [f2]), $2 = C(() => b(E, { className: In("script-editor-content"), sx: { display: "flex", flex: "1 1 100%", width: "100%", flexDirection: "column", boxSizing: "border-box" }, children: [W2, x(E, { sx: { display: "flex", flex: "1 1 100%", width: "100%", flexDirection: "row", position: "relative", boxSizing: "border-box" }, children: x(Fa, { ref: R2, loadingPanel: H2, readOnly: l2, onClose: i2, autoFocus: d2, commands: r2, onStatusChange: S2, darkMode: "dark" === p2.palette.mode, ...a2 }) }), z2] }), [p2, r2, W2, z2, u2, H2, l2, a2, d2, s2, i2, S2]), O2 = C(() => x(J, { className: In({ "Mui-selected": h2.current }), sx: { display: "flex", color: (e3) => e3.palette.text.secondary, boxSizing: "border-box", padding: "0 0", transitionProperty: "opacity", transitionDuration: (e3) => `${e3.transitions.duration.shortest}ms`, opacity: 0.7, "&.Mui-selected": { opacity: 1, transitionDuration: (e3) => e3.transitions.duration.shortest / 2 + "ms" }, backgroundColor: (e3) => ka(e3.palette.action.hover, 0.03), borderBottom: (e3) => `solid ${ka(e3.palette.divider, 0.2)} 1px` }, onPointerDown: (e3) => {
1616
- e3.isDefaultPrevented() || (e3.preventDefault(), A2());
1617
- }, children: b(E, { sx: { display: "flex", flex: "1 1 10%", flexDirection: "row", alignItems: "center", marginTop: (e3) => e3.spacing(0.25), marginBottom: (e3) => e3.spacing(0.25), marginLeft: (e3) => e3.spacing(1), marginRight: (e3) => e3.spacing(1) }, children: [x(E, { sx: { flex: "1 1 100%", paddingLeft: (e3) => e3.spacing(1) }, children: "Script (Typescript)" }), x(Le, { label: "Close", children: x(L, { "aria-label": "close", sx: { color: (e3) => e3.palette.text.icon ?? e3.palette.action.active }, touchRippleRef: T2, onPointerDown: (e3) => {
1618
+ }, [F2, s2, d2]), H2 = C(() => x(Pe, { transitionDelay: "160ms", style: { position: "absolute", width: "100%", height: "100%" }, transparentBackground: false }), []), W2 = C(() => x(X, { elevation: 1, tabIndex: 0, sx: { display: "flex", alignItems: "center", userSelect: "none", flexGrow: 1, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, marginLeft: (e3) => e3.spacing(0.5), marginRight: (e3) => e3.spacing(0.5), marginTop: (e3) => e3.spacing(1), marginBottom: (e3) => e3.spacing(1) }, children: x(_l, { commands: r2 }) }), [p2, r2]), z2 = C(() => x(A, { className: In("script-status-panel", "status-panel"), sx: { display: "flex", alignItems: "stretch", flexDirection: "row", flex: "0", paddingLeft: "12px", paddingRight: "12px", gap: "8px", paddingTop: "1px", minHeight: "calc(1em + 8px)", margin: 0, borderTop: `solid 1px ${p2.palette.divider}` }, children: b("div", { style: { flex: "1 1 100%", display: "flex", alignItems: "center", flexDirection: "row", justifyContent: "center" }, children: [x(I, { component: "div", sx: { userSelect: "none", whiteSpace: "pre", overflow: "hidden", textOverflow: "ellipsis", flex: "1 1 100%", color: (e3) => e3.palette.text.secondary }, variant: "caption", children: f2.message }), x(I, { component: "div", sx: { userSelect: "none", whiteSpace: "pre", overflow: "hidden", textOverflow: "ellipsis", flex: "none", color: (e3) => e3.palette.text.secondary }, variant: "caption", children: f2.dirty ? "Unsaved" : "" }), x(I, { component: "div", sx: { userSelect: "none", whiteSpace: "pre", overflow: "hidden", textOverflow: "ellipsis", flex: "none", marginLeft: "8px", minWidth: "90px", display: "flex", justifyContent: "end", color: (e3) => e3.palette.text.secondary }, variant: "caption", children: f2.cursor })] }) }), [f2]), $2 = C(() => b(A, { className: In("script-editor-content"), sx: { display: "flex", flex: "1 1 100%", width: "100%", flexDirection: "column", boxSizing: "border-box" }, children: [W2, x(A, { sx: { display: "flex", flex: "1 1 100%", width: "100%", flexDirection: "row", position: "relative", boxSizing: "border-box" }, children: x(Fa, { ref: R2, loadingPanel: H2, readOnly: l2, onClose: i2, autoFocus: d2, commands: r2, onStatusChange: S2, darkMode: "dark" === p2.palette.mode, ...a2 }) }), z2] }), [p2, r2, W2, z2, u2, H2, l2, a2, d2, s2, i2, S2]), O2 = C(() => x(J, { className: In({ "Mui-selected": h2.current }), sx: { display: "flex", color: (e3) => e3.palette.text.secondary, boxSizing: "border-box", padding: "0 0", transitionProperty: "opacity", transitionDuration: (e3) => `${e3.transitions.duration.shortest}ms`, opacity: 0.7, "&.Mui-selected": { opacity: 1, transitionDuration: (e3) => e3.transitions.duration.shortest / 2 + "ms" }, backgroundColor: (e3) => ka(e3.palette.action.hover, 0.03), borderBottom: (e3) => `solid ${ka(e3.palette.divider, 0.2)} 1px` }, onPointerDown: (e3) => {
1619
+ e3.isDefaultPrevented() || (e3.preventDefault(), E2());
1620
+ }, children: b(A, { sx: { display: "flex", flex: "1 1 10%", flexDirection: "row", alignItems: "center", marginTop: (e3) => e3.spacing(0.25), marginBottom: (e3) => e3.spacing(0.25), marginLeft: (e3) => e3.spacing(1), marginRight: (e3) => e3.spacing(1) }, children: [x(A, { sx: { flex: "1 1 100%", paddingLeft: (e3) => e3.spacing(1) }, children: "Script (Typescript)" }), x(Le, { label: "Close", children: x(L, { "aria-label": "close", sx: { color: (e3) => e3.palette.text.icon ?? e3.palette.action.active }, touchRippleRef: T2, onPointerDown: (e3) => {
1618
1621
  T2.current?.start(e3, { center: false }), e3.stopPropagation(), e3.preventDefault();
1619
1622
  }, onPointerUp: () => {
1620
1623
  R2.current?.close();
1621
1624
  }, children: x(Jn, {}) }) })] }) }), [p2, u2]), V2 = C(() => {
1622
1625
  let e3;
1623
- return null === w2 ? null : (null === w2.source && (e3 = x(ql, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden", position: "absolute", boxSizing: "border-box", width: "100%", height: "100%" }, onScriptSelect: (e4) => {
1626
+ return null === w2 ? null : (null === w2.source && (e3 = x(Kl, { sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden", position: "absolute", boxSizing: "border-box", width: "100%", height: "100%" }, onScriptSelect: (e4) => {
1624
1627
  R2.current?.getEditor().insertSnippet(e4.content), k2({ source: e4.content ?? "" });
1625
- } })), b(E, { tabIndex: 0, className: In("script-workspace", o2), sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden", alignItems: "stretch", userSelect: "none", flexGrow: 0, outline: "none", backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` }, onPointerDown: (e4) => {
1628
+ } })), b(A, { tabIndex: 0, className: In("script-workspace", o2), sx: { display: "flex", flex: "1 1 100%", flexDirection: "column", overflow: "hidden", alignItems: "stretch", userSelect: "none", flexGrow: 0, outline: "none", backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` }, onPointerDown: (e4) => {
1626
1629
  e4.isDefaultPrevented() || R2.current?.focus();
1627
- }, children: [O2, b(E, { sx: { flex: "1 1 100%", position: "relative", display: "flex" }, children: [$2, e3] })] }));
1630
+ }, children: [O2, b(A, { sx: { flex: "1 1 100%", position: "relative", display: "flex" }, children: [$2, e3] })] }));
1628
1631
  }, [W2, $2, o2, w2]), G2 = ca(t2, () => ({ isScriptWorkspaceElement: () => true, focus: (e3) => {
1629
- A2(e3);
1632
+ E2(e3);
1630
1633
  } }), []);
1631
- return x(E, { sx: { display: "flex", flexDirection: "row", flex: "1 1 100%", position: "relative", ...n2 }, ref: G2, ...m2, onFocus: (e3) => {
1634
+ return x(A, { sx: { display: "flex", flexDirection: "row", flex: "1 1 100%", position: "relative", ...n2 }, ref: G2, ...m2, onFocus: (e3) => {
1632
1635
  g2(true), h2.current = true, G2.current?.contains(e3.target) && e3.target !== G2.current && B2(e3.target), e3.relatedTarget && !N2.current && (N2.current = e3.relatedTarget), m2?.onFocus?.(e3);
1633
1636
  }, onBlur: (e3) => {
1634
1637
  G2?.current?.contains(e3.relatedTarget) || G2?.current === e3.relatedTarget || (N2.current = null, h2.current = false, g2(false)), m2?.onBlur?.(e3);
1635
1638
  }, children: V2 });
1636
1639
  }));
1637
- Kl.displayName = "ScriptWorkspace";
1638
- const Xl = k(S((e2, t2) => {
1640
+ Xl.displayName = "ScriptWorkspace";
1641
+ const Zl = k(S((e2, t2) => {
1639
1642
  const { commands: o2, ...n2 } = e2, a2 = ta(o2, ["executeScript", "showScriptEditor"]), [r2, l2] = D([]), [i2, s2] = D(false), d2 = a2[0]?.context?.();
1640
1643
  P(() => {
1641
1644
  const e3 = d2?.getScripts();
@@ -1651,17 +1654,17 @@ const Xl = k(S((e2, t2) => {
1651
1654
  const t3 = r2[e3];
1652
1655
  m2.push(x(le, { ...c2, command: o2.getCommand("executeScript"), commandState: { declaration: t3 }, tooltipProps: { description: `Execute ${t3.getName() ?? "macro"}` }, icon: re(x(No, {})), label: t3.getName() ?? `Script '${t3.getName()}'` }, `macro-${t3.getName()}-${e3}`));
1653
1656
  }
1654
- const u2 = b(E, { ref: t2, sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: [m2.length > 0 ? b(y, { children: [x(E, { sx: { overflow: "auto", flex: "1 1 100%" }, children: m2 }), x(ie, { orientation: "horizontal" })] }) : null, F(le, { ...c2, key: "show-editor", command: o2.getCommand("showScriptEditor"), icon: re(x(Io, {})) })] });
1657
+ const u2 = b(A, { ref: t2, sx: { display: "flex", flexDirection: "column", flex: "1 1 100%", overflow: "hidden" }, children: [m2.length > 0 ? b(y, { children: [x(A, { sx: { overflow: "auto", flex: "1 1 100%" }, children: m2 }), x(ie, { orientation: "horizontal" })] }) : null, F(le, { ...c2, key: "show-editor", command: o2.getCommand("showScriptEditor"), icon: re(x(Io, {})) })] });
1655
1658
  return ce({ ...n2, children: u2 });
1656
1659
  }));
1657
- Xl.displayName = "RunScriptPopupPanel";
1658
- const Zl = k(S((e2, t2) => {
1660
+ Zl.displayName = "RunScriptPopupPanel";
1661
+ const Jl = k(S((e2, t2) => {
1659
1662
  const { commands: o2, commandHook: n2, scope: a2, disabled: r2 = false, ...l2 } = e2, i2 = "showScriptEditor", s2 = ta(o2, ["executeScript", "showScriptEditor"])[0].context(), d2 = v((e3, t3) => {
1660
- const o3 = x(Xl, { ...e3, commands: t3 });
1663
+ const o3 = x(Zl, { ...e3, commands: t3 });
1661
1664
  return ce({ ...e3, children: o3 });
1662
1665
  }, [r2, s2, n2, a2]);
1663
1666
  return x(me, { ref: t2, commands: o2, commandHook: n2, createPopupPanel: d2, selected: o2.getCommand(i2).state(), label: "Macros", tooltip: "Run or manage macros.", quickCommand: i2, icon: re(x(Lo, {})), ...l2 });
1664
- })), Jl = k(S((e2, t2) => {
1667
+ })), Yl = k(S((e2, t2) => {
1665
1668
  const { commands: o2, parentFloat: n2, commandButtonProps: a2, ...r2 } = e2, [l2, i2] = D(false), s2 = ta(o2, ["executeScript", "showScriptEditor"]), d2 = s2[0]?.context?.();
1666
1669
  P(() => {
1667
1670
  const e3 = d2?.getScripts();
@@ -1688,43 +1691,43 @@ const Zl = k(S((e2, t2) => {
1688
1691
  const c2 = v((e3) => {
1689
1692
  const { commandButtonProps: t3, commandPopupProps: a3 } = e3, r3 = x(Ir, { ...a3, command: o2.getCommand("formatFontColor"), icon: x(Ho, {}), isSplit: true, panelProps: { disableAlpha: true } }), i3 = x(Ir, { ...a3, command: o2.getCommand("formatFillColor"), icon: x(Wo, {}), isSplit: true, panelProps: { disableAlpha: true, autoColorLabel: "No Fill", autoColorPosition: lr.End } }), s3 = o2.getCommand("undo") ? x(y, { children: x(zr, { ...a3, quickCommand: "undo" }) }) : null, d3 = o2.getCommand("find") ? x(y, { children: x(Pr, { ...a3 }) }) : null;
1690
1693
  let c3 = null;
1691
- l2 && (c3 = b(y, { children: [x(ie, {}), x(Zl, { ...a3 })] }));
1692
- return b(Wl, { parentFloat: n2, children: [s3, null, s3 ? x(ie, {}) : null, x(jr, { ...a3, command: o2.getCommand("paste") }), x(le, { ...t3, command: o2.getCommand("formatPainterToggle"), icon: re(x(zo, {})) }), x(ul, { ...t3, command: o2.getCommand("copy") }), x(ie, {}), x(Vr, { ...a3, command: o2.getCommand("formatFontFamily") }), x(Rr, { ...a3, command: o2.getCommand("formatFontSize") }), x(le, { ...t3, command: o2.getCommand("formatBoldToggle"), icon: x($o, {}) }), x(le, { ...t3, command: o2.getCommand("formatItalicToggle"), icon: x(Oo, {}) }), x(Ur, { ...a3 }), x(Gr, { ...a3 }), r3, x(ie, {}), i3, x(vr, { ...a3 }), x(Tr, { ...a3 }), x(ie, {}), x(tr, { ...a3 }), x(or, { ...a3 }), x(nr, { ...a3 }), x(ar, { ...a3 }), x(ie, {}), x(Fr, { ...a3 }), x(Zr, { command: o2.getCommand("formatCellStyle"), ...a3 }), x(al, { command: o2.getCommand("formatTableStyle"), ...a3 }), x(ie, {}), x(Ar, { ...a3 }), x(Er, { ...a3 }), x(ie, {}), x(Nr, { ...a3 }), null, x(Br, { ...a3 }), x(Hr, { ...a3 }), d3, c3] });
1694
+ l2 && (c3 = b(y, { children: [x(ie, {}), x(Jl, { ...a3 })] }));
1695
+ return b(zl, { parentFloat: n2, children: [s3, null, s3 ? x(ie, {}) : null, x(jr, { ...a3, command: o2.getCommand("paste") }), x(le, { ...t3, command: o2.getCommand("formatPainterToggle"), icon: re(x(zo, {})) }), x(ul, { ...t3, command: o2.getCommand("copy") }), x(ie, {}), x(Vr, { ...a3, command: o2.getCommand("formatFontFamily") }), x(Rr, { ...a3, command: o2.getCommand("formatFontSize") }), x(le, { ...t3, command: o2.getCommand("formatBoldToggle"), icon: x($o, {}) }), x(le, { ...t3, command: o2.getCommand("formatItalicToggle"), icon: x(Oo, {}) }), x(Ur, { ...a3 }), x(Gr, { ...a3 }), r3, x(ie, {}), i3, x(vr, { ...a3 }), x(Tr, { ...a3 }), x(ie, {}), x(tr, { ...a3 }), x(or, { ...a3 }), x(nr, { ...a3 }), x(ar, { ...a3 }), x(ie, {}), x(Fr, { ...a3 }), x(Zr, { command: o2.getCommand("formatCellStyle"), ...a3 }), x(al, { command: o2.getCommand("formatTableStyle"), ...a3 }), x(ie, {}), x(Er, { ...a3 }), x(Ar, { ...a3 }), x(ie, {}), x(Nr, { ...a3 }), null, x(Br, { ...a3 }), x(Hr, { ...a3 }), d3, c3] });
1693
1696
  }, [o2, s2, l2]);
1694
- return x(Eo, { ref: t2, commands: o2, parentFloat: n2, commandButtonProps: a2, createToolbarPalette: c2, ...r2 });
1697
+ return x(Ao, { ref: t2, commands: o2, parentFloat: n2, commandButtonProps: a2, createToolbarPalette: c2, ...r2 });
1695
1698
  }));
1696
- Jl.displayName = "HomeToolbar";
1697
- const Yl = k(S((e2, t2) => {
1699
+ Yl.displayName = "HomeToolbar";
1700
+ const Ql = k(S((e2, t2) => {
1698
1701
  const { commands: o2, parentFloat: n2, commandButtonProps: a2, ...r2 } = e2, l2 = na((e3) => {
1699
1702
  const { commandButtonProps: t3, commandPopupProps: a3 } = e3;
1700
- return b(Wl, { parentFloat: n2, children: [null, x(le, { ...t3, command: o2.getCommand("updateHyperlink"), icon: re(x(Vo, {})) }), x(le, { ...t3, command: o2.getCommand("updateComments"), icon: re(x(Go, {})) }), x(pl, { ...a3 }), x(le, { ...t3, command: o2.getCommand("insertTable"), icon: re(x(So, {})) })] });
1703
+ return b(zl, { parentFloat: n2, children: [null, x(le, { ...t3, command: o2.getCommand("updateHyperlink"), icon: re(x(Vo, {})) }), x(le, { ...t3, command: o2.getCommand("updateComments"), icon: re(x(Go, {})) }), x(pl, { ...a3 }), x(le, { ...t3, command: o2.getCommand("insertTable"), icon: re(x(So, {})) })] });
1701
1704
  }, [o2]);
1702
- return x(Eo, { ref: t2, commands: o2, parentFloat: n2, commandButtonProps: a2, createToolbarPalette: l2, ...r2 });
1705
+ return x(Ao, { ref: t2, commands: o2, parentFloat: n2, commandButtonProps: a2, createToolbarPalette: l2, ...r2 });
1703
1706
  }));
1704
- Yl.displayName = "InsertToolbar";
1705
- const Ql = k(S((e2, t2) => {
1707
+ Ql.displayName = "InsertToolbar";
1708
+ const ei = k(S((e2, t2) => {
1706
1709
  const { commands: o2, parentFloat: n2, commandButtonProps: a2, ...r2 } = e2, l2 = na((e3) => {
1707
1710
  const { commandButtonProps: t3, commandPopupProps: a3 } = e3;
1708
- return b(Wl, { parentFloat: n2, children: [x(Dr, { ...a3 }), x(le, { ...t3, command: o2.getCommand("protectionSheetToggle"), icon: x(Kn, { color: "secondary" }) }), x(ie, {}), x(Lr, { ...a3 }), x(_r, { ...a3 }), x(ie, {}), x(le, { ...t3, command: o2.getCommand("sheetViewToggleFormulaView"), scope: "view", icon: x(ht, { command: o2.getCommand("sheetViewToggleFormulaView"), scope: "view" }) }), x(le, { ...t3, command: o2.getCommand("sheetViewToggleShowZeros"), scope: "view", icon: x(ht, { command: o2.getCommand("sheetViewToggleShowZeros"), scope: "view" }) }), x(ie, {}), x(qr, { ...a3 }), x(dl, { command: o2.getCommand("selectTheme"), ...a3 }), x(ie, {}), x(Zl, { ...a3, scope: "view" }), x(ie, {}), x(le, { ...t3, command: o2.getCommand("fullScreenToggle"), scope: "view", icon: () => re(o2.getCommand("fullScreenToggle").state() ? x(Uo, {}) : x(jo, {})) })] });
1711
+ return b(zl, { parentFloat: n2, children: [x(Dr, { ...a3 }), x(le, { ...t3, command: o2.getCommand("protectionSheetToggle"), icon: x(Kn, { color: "secondary" }) }), x(ie, {}), x(Lr, { ...a3 }), x(_r, { ...a3 }), x(ie, {}), x(le, { ...t3, command: o2.getCommand("sheetViewToggleFormulaView"), scope: "view", icon: x(ht, { command: o2.getCommand("sheetViewToggleFormulaView"), scope: "view" }) }), x(le, { ...t3, command: o2.getCommand("sheetViewToggleShowZeros"), scope: "view", icon: x(ht, { command: o2.getCommand("sheetViewToggleShowZeros"), scope: "view" }) }), x(ie, {}), x(qr, { ...a3 }), x(dl, { command: o2.getCommand("selectTheme"), ...a3 }), x(ie, {}), x(Jl, { ...a3, scope: "view" }), x(ie, {}), x(le, { ...t3, command: o2.getCommand("fullScreenToggle"), scope: "view", icon: () => re(o2.getCommand("fullScreenToggle").state() ? x(Uo, {}) : x(jo, {})) })] });
1709
1712
  }, [o2]);
1710
- return x(Eo, { ref: t2, commands: o2, parentFloat: n2, commandButtonProps: a2, createToolbarPalette: l2, ...r2 });
1713
+ return x(Ao, { ref: t2, commands: o2, parentFloat: n2, commandButtonProps: a2, createToolbarPalette: l2, ...r2 });
1711
1714
  }));
1712
- Ql.displayName = "ViewToolbar";
1713
- const ei = (e2) => x(ai, { ...e2 }), ti = k((e2) => {
1715
+ ei.displayName = "ViewToolbar";
1716
+ const ti = (e2) => x(ri, { ...e2 }), oi = k((e2) => {
1714
1717
  const { sx: t2, ...o2 } = e2;
1715
- return b(E, { sx: { display: "flex", flexDirection: "column", position: "relative", "&:hover:not([disabled]) .indicator": { borderBottom: (e3) => `${ka(e3.palette.primary.main, 0.35)} solid 2px` } }, children: [x(ee, { disableRipple: true, onMouseDown: (e3) => {
1718
+ return b(A, { sx: { display: "flex", flexDirection: "column", position: "relative", "&:hover:not([disabled]) .indicator": { borderBottom: (e3) => `${ka(e3.palette.primary.main, 0.35)} solid 2px` } }, children: [x(ee, { disableRipple: true, onMouseDown: (e3) => {
1716
1719
  0 === e3.button && e3.preventDefault();
1717
- }, sx: { textTransform: "none", flex: "1 1 100%", fontWeight: (e3) => e3.typography.fontWeightRegular, padding: "2px 6px", minHeight: "0px", minWidth: "0px", marginRight: (e3) => e3.spacing(0.5), "&.Mui-selected": {}, "&.Mui-focusVisible": {}, ...t2 }, ...o2 }), x(E, { className: "indicator", sx: { width: "90%", borderRadius: "4px", minWidth: "4px", position: "absolute", bottom: "0", alignSelf: "center", display: "flex" } })] });
1718
- }), oi = k((e2) => {
1720
+ }, sx: { textTransform: "none", flex: "1 1 100%", fontWeight: (e3) => e3.typography.fontWeightRegular, padding: "2px 6px", minHeight: "0px", minWidth: "0px", marginRight: (e3) => e3.spacing(0.5), "&.Mui-selected": {}, "&.Mui-focusVisible": {}, ...t2 }, ...o2 }), x(A, { className: "indicator", sx: { width: "90%", borderRadius: "4px", minWidth: "4px", position: "absolute", bottom: "0", alignSelf: "center", display: "flex" } })] });
1721
+ }), ni = k((e2) => {
1719
1722
  const { toolbars: t2, value: o2, onToolbarChange: n2, sx: a2, ...r2 } = e2, l2 = C(() => {
1720
1723
  const e3 = [];
1721
- for (let o3 = 0; o3 < t2.length; o3++) e3.push(x(ti, { label: t2[o3].label }, t2[o3].label));
1724
+ for (let o3 = 0; o3 < t2.length; o3++) e3.push(x(oi, { label: t2[o3].label }, t2[o3].label));
1722
1725
  return e3;
1723
1726
  }, [t2]);
1724
1727
  return x(Q, { value: o2, onChange: (e3, t3) => {
1725
1728
  n2?.(t3);
1726
1729
  }, variant: "scrollable", scrollButtons: false, sx: { paddingLeft: (e3) => e3.spacing(1.5), paddingRight: (e3) => e3.spacing(1.5), paddingTop: (e3) => e3.spacing(0), paddingBottom: (e3) => e3.spacing(0), minHeight: "26px", alignItems: "center", "& .MuiTabs-indicator": { display: "flex", justifyContent: "center", backgroundColor: "transparent" }, "& .MuiTabs-indicatorSpan": { width: "90%", borderRadius: "4px", minWidth: "4px", backgroundColor: (e3) => e3.palette.primary.main }, "& .MuiTab-root": { marginRight: "0px" }, ...a2 }, TabIndicatorProps: { children: x("span", { className: "MuiTabs-indicatorSpan" }) }, ...r2, children: l2 });
1727
- }), ni = k((e2) => {
1730
+ }), ai = k((e2) => {
1728
1731
  const { toolbars: t2, value: o2, onToolbarChange: n2, selectProps: a2, ...r2 } = e2, l2 = v((e3) => {
1729
1732
  n2?.(e3.target.value);
1730
1733
  }, [n2]), i2 = C(() => {
@@ -1738,26 +1741,26 @@ const ei = (e2) => x(ai, { ...e2 }), ti = k((e2) => {
1738
1741
  return e3;
1739
1742
  }, [t2, o2]);
1740
1743
  return x(j, { sx: { minWidth: "125px", maxWidth: "125px", "& .MuiInputBase-root": { paddingLeft: "0px", paddingRight: "0px" }, "& .MuiSelect-select": { paddingTop: (e3) => e3.spacing(0.5), paddingBottom: (e3) => e3.spacing(0.5), paddingLeft: (e3) => e3.spacing(2), color: (e3) => e3.palette.primary.main }, "& .MuiSelect-icon": { fill: (e3) => e3.palette.text.icon ?? e3.palette.action.active, "&:hover:not(.Mui-disabled)": { color: (e3) => e3.palette.text.icon ?? e3.palette.action.active } }, ...a2 }, size: "small", children: x(Y, { value: o2, onChange: l2, variant: "outlined", sx: { backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` }, ...r2, children: i2 }) });
1741
- }), ai = k(S((e2, t2) => {
1744
+ }), ri = k(S((e2, t2) => {
1742
1745
  const { commands: o2, selectWrapper: n2, selectProps: a2 = {}, renderCompact: r2 = false, paletteWrapper: l2, toolbarsProps: i2, paletteProps: s2 = {}, workbook: d2, sx: c2, ...m2 } = e2, p2 = C(() => {
1743
1746
  const e3 = [], { ref: t3, ...n3 } = i2?.Home || {};
1744
- e3.push({ label: "Home", component: x(Jl, { commands: o2, ...n3 }) });
1747
+ e3.push({ label: "Home", component: x(Yl, { commands: o2, ...n3 }) });
1745
1748
  const { ref: a3, ...r3 } = i2?.Insert || {};
1746
- e3.push({ label: "Insert", component: x(Yl, { commands: o2, ...r3 }) });
1749
+ e3.push({ label: "Insert", component: x(Ql, { commands: o2, ...r3 }) });
1747
1750
  const { ref: l3, ...s3 } = i2?.View || {};
1748
- return e3.push({ label: "View", component: x(Ql, { commands: o2, ...s3 }) }), e3;
1751
+ return e3.push({ label: "View", component: x(ei, { commands: o2, ...s3 }) }), e3;
1749
1752
  }, [o2, d2]), u2 = C(() => {
1750
1753
  const e3 = [];
1751
1754
  for (let t3 = 0; t3 < p2.length; t3++) e3.push(w.cloneElement(p2[t3].component, { ...p2[t3].component.props, key: p2[t3].key ?? p2[t3].label }));
1752
1755
  return e3;
1753
1756
  }, [p2]), [g2, h2] = D(0), f2 = (e3) => {
1754
1757
  h2(e3);
1755
- }, y2 = C(() => x(r2 ? ni : oi, { toolbars: p2, value: g2, onToolbarChange: f2, sx: a2 }), [p2, g2, a2, r2]), { sx: k2, ...S2 } = s2, v2 = x(X, { elevation: 2, tabIndex: 0, sx: { display: "flex", alignItems: "center", userSelect: "none", flexGrow: 1, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, marginLeft: (e3) => e3.spacing(1), marginRight: (e3) => e3.spacing(1), marginTop: (e3) => e3.spacing(0.5), marginBottom: (e3) => e3.spacing(0.5), ...k2 }, ...S2, children: u2[g2] });
1756
- return b(E, { ref: t2, className: "toolbarWrappers", sx: { display: "flex", flexDirection: "column", paddingTop: (e3) => e3.spacing(0.5), "*": { userSelect: "none" }, ...c2 }, ...m2, children: [n2 ? n2(y2) : y2, l2 ? l2(v2) : v2] });
1758
+ }, y2 = C(() => x(r2 ? ai : ni, { toolbars: p2, value: g2, onToolbarChange: f2, sx: a2 }), [p2, g2, a2, r2]), { sx: k2, ...S2 } = s2, v2 = x(X, { elevation: 2, tabIndex: 0, sx: { display: "flex", alignItems: "center", userSelect: "none", flexGrow: 1, backgroundImage: `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})`, marginLeft: (e3) => e3.spacing(1), marginRight: (e3) => e3.spacing(1), marginTop: (e3) => e3.spacing(0.5), marginBottom: (e3) => e3.spacing(0.5), ...k2 }, ...S2, children: u2[g2] });
1759
+ return b(A, { ref: t2, className: "toolbarWrappers", sx: { display: "flex", flexDirection: "column", paddingTop: (e3) => e3.spacing(0.5), "*": { userSelect: "none" }, ...c2 }, ...m2, children: [n2 ? n2(y2) : y2, l2 ? l2(v2) : v2] });
1757
1760
  }));
1758
- ai.displayName = "WorkbookToolbars";
1759
- const ri = (e2) => {
1760
- const { workbook: t2, workbookElement: o2, notifier: n2, target: a2, commands: r2, darkMode: l2, onShowSidebar: i2, onNewWorkbook: s2 = li } = e2, [d2, c2] = D(t2?.getSelectedSheet()), [m2, p2] = D(t2?.getSheets().getItems()), g2 = na(i2, [i2]), h2 = na(s2, [s2]), f2 = C(() => [new ua("workbookStatistics", a2, { label: "Workbook Statistics", description: "Show the workbook statistics.", shortcut: { key: "G", modifiers: [ha.Ctrl, ha.Shift] } }), new ua("showFormat", a2, { label: "Show Format", description: "Open the format pane.", shortcut: { key: "F", modifiers: [ha.Ctrl, ha.Shift] } }), new ga("newCellStyle", a2, { label: "New Cell Style…", scopedLabels: { cellStyle: "New Cell Style" }, description: "Create a new named style can can be quickly used later." }), new ga("deleteCellStyle", a2, { label: "Delete Cell Style", scopedLabels: { cellStyle: "Delete" }, description: "Remove a named style that is no longer needed." }), new ga("modifyCellStyle", a2, { label: "Modify Cell Style", scopedLabels: { cellStyle: "Modify" }, description: "Update a style with the currently style." }), new ua("find", a2, { label: "Find", description: "Open the Find window.", shortcut: [{ key: "F", modifiers: [ha.Ctrl] }, { key: "F5", modifiers: [ha.Shift] }] }), new ua("findReplace", a2, { label: "Find & Replace", description: "Open the Find & Replace window.", shortcut: [{ key: "H", modifiers: [ha.Ctrl] }, { key: "H", modifiers: [ha.Ctrl, ha.Alt] }] }), new ua("goto", a2, { label: "Go To", description: "Open the 'Go To' window.", shortcut: [{ key: "G", modifiers: [ha.Ctrl] }] }), new ua("workbookViewToggleExpandFormulaBar", a2, { label: "Toggle Expand Formula bar", description: "Expand or collapse the formula bar.", shortcut: { key: "U", modifiers: [ha.Ctrl, ha.Shift] } }), new ua("workbookViewToggleShowFormulaBar", a2, { label: "View Formula bar", scopedLabels: { view: "Formula Bar" }, description: "Show or hide the formula bar." }), new ua("workbookViewToggleShowTabs", a2, { label: "View Sheet Tabs", description: "Show or hide the sheet tabs.", scopedLabels: { view: "Sheet Tabs" } }), new ua("workbookViewToggleShowStatusBar", a2, { label: "View Status Bar", description: "Show or hide the status bar.", scopedLabels: { view: "Status Bar" } }), new ua("workbookViewToggleShowHorizontalScrollBar", a2, { label: "View Horizontal Scrollbar", description: "Show or hide the horizontal scrollbar.", scopedLabels: { view: "Horizontal Scrollbar" } }), new ua("workbookViewToggleShowVerticalScrollBar", a2, { label: "View Vertical Scrollbar", description: "Show or hide the vertical scrollbar.", scopedLabels: { view: "Vertical Scrollbar" } }), new ga("hideSheet", a2, { label: "Hide Sheet", scopedLabels: { sheet: "Hide" }, description: "Hide the sheet from appearing in the tabs. This keeps the data but de-clutters the tabs." }), new ga("deleteSheet", a2, { label: "Delete Sheet", scopedLabels: { sheet: "Delete" }, description: "Delete the sheet and all the data." }), new ga("addSheet", a2, { label: "Insert Sheet", scopedLabels: { sheet: "Insert" }, description: "Insert sheet before the current sheet.", shortcut: [{ key: "F11", modifiers: [ha.Shift] }, { key: "F1", modifiers: [ha.Alt, ha.Shift] }] }), new ga("duplicateSheet", a2, { label: "Duplicate Sheet", description: "Duplicate the current sheet.", scopedLabels: { sheet: "Duplicate" } }), new ga("nextSheet", a2, { label: "Next Sheet", scopedLabels: { sheet: "Next" }, description: "Activate the next sheet.", shortcut: [{ key: "PageDown", modifiers: [ha.Ctrl] }] }), new ga("previousSheet", a2, { label: "Previous Sheet", scopedLabels: { sheet: "Previous" }, description: "Activate the previous sheet.", shortcut: [{ key: "PageUp", modifiers: [ha.Ctrl] }] }), new ga("selectNextSheet", a2, { label: "Select Next Sheet", scopedLabels: { sheet: "Select Next" }, description: "Select the next sheet.", shortcut: [{ key: "PageDown", modifiers: [ha.Ctrl, ha.Shift] }] }), new ga("selectPreviousSheet", a2, { label: "Select Previous Sheet", scopedLabels: { sheet: "Select Previous" }, description: "Select the previous sheet.", shortcut: [{ key: "PageUp", modifiers: [ha.Ctrl, ha.Shift] }] }), new ga("selectTheme", a2, { label: "Theme", description: "Select a theme that coveys a style suitable for your data." }), new ga("selectNamed", a2, { label: (e3) => e3?.getName() ?? "Select Named Item", scopedLabels: { namedItem: (e3) => e3?.getName() ?? "Select" }, description: "Select the item." }), new ga("addNamedReference", a2, { label: "Define Named Reference", scopedLabels: { namedItem: "Define Name…" }, description: "Add a new named reference. Names can be used as a substitute for cell references." }), new ga("editNamedReference", a2, { label: "Edit Named Reference…", scopedLabels: { namedItem: "Edit…" }, description: "Add a new named reference. Names can be used as a substitute for cell references." }), new ga("deleteNamedReference", a2, { label: "Delete Named Reference", scopedLabels: { namedItem: "Delete" }, description: "Remove the named reference." }), new ua("activeNameBox", a2, { label: "Activate Name Box", description: "Move the focus to the name box.", shortcut: { key: "F3", modifiers: [ha.Alt] } }), new ua("createNamedReferenceFromSelection", a2, { label: "Create from Selection", description: "Automatically generate names from the selected cells.", shortcut: { key: "F3", modifiers: [ha.Ctrl, ha.Shift] } }), new ua("activeNameManager", a2, { label: "Activate Name Manager", description: "Create, edit, delete, and find all the names used in the workbook.\n\nNames can be used as a substitute for cell references.", shortcut: { key: "F3", modifiers: [ha.Ctrl] } }), new ga("fullScreenToggle", a2, { label: "FullScreen", description: "Toggle showing the workbook using the full screen.", shortcut: { key: "F11" } }), new ga("showScriptEditor", a2, { label: "Scripts", scopedLabels: { scripts: "Script Editor…" }, description: "Show the script editor.", shortcut: [{ key: "F11", modifiers: [ha.Alt] }] }), new ga("executeScript", a2, { label: "Run Script", description: "Run the selected or last executed script.", shortcut: { key: "F8" } }), new ga("executeSelectedScript", a2, { label: "Run Script", description: "Run the selected script.", shortcut: { key: "F8" } }), new ga("saveScripts", a2, { label: "Save Script", description: "Save the current scripts." }), new ga("maximumWorkbookToggle", a2, { label: "Maximize", description: "Toggle showing the workbook maximized.", shortcut: { key: "F10", modifiers: [ha.Ctrl] } }), new ga("spellCheck", a2, { label: "Spell Check", description: "Check the workbook for spelling mistakes.", shortcut: { key: "F7" } }), new ga("calculateAll", a2, { label: "Calculate Now", description: "Recalculate all formulas.", shortcut: { key: "F9" } }), new ua("closeWorkbook", a2, { label: "Close Workbook", description: "Close the workbook.", shortcut: { key: "W", modifiers: [ha.Ctrl] } }), new ua("newWorkbook", a2, { label: "New Workbook", description: "Create a new workbook in another tab." })], []), x2 = C(() => {
1761
+ ri.displayName = "WorkbookToolbars";
1762
+ const li = (e2) => {
1763
+ const { workbook: t2, workbookElement: o2, notifier: n2, target: a2, commands: r2, darkMode: l2, onShowSidebar: i2, onNewWorkbook: s2 = ii } = e2, [d2, c2] = D(t2?.getSelectedSheet()), [m2, p2] = D(t2?.getSheets().getItems()), g2 = na(i2, [i2]), h2 = na(s2, [s2]), f2 = C(() => [new ua("workbookStatistics", a2, { label: "Workbook Statistics", description: "Show the workbook statistics.", shortcut: { key: "G", modifiers: [ha.Ctrl, ha.Shift] } }), new ua("showFormat", a2, { label: "Show Format", description: "Open the format pane.", shortcut: { key: "F", modifiers: [ha.Ctrl, ha.Shift] } }), new ga("newCellStyle", a2, { label: "New Cell Style…", scopedLabels: { cellStyle: "New Cell Style" }, description: "Create a new named style can can be quickly used later." }), new ga("deleteCellStyle", a2, { label: "Delete Cell Style", scopedLabels: { cellStyle: "Delete" }, description: "Remove a named style that is no longer needed." }), new ga("modifyCellStyle", a2, { label: "Modify Cell Style", scopedLabels: { cellStyle: "Modify" }, description: "Update a style with the currently style." }), new ua("find", a2, { label: "Find", description: "Open the Find window.", shortcut: [{ key: "F", modifiers: [ha.Ctrl] }, { key: "F5", modifiers: [ha.Shift] }] }), new ua("findReplace", a2, { label: "Find & Replace", description: "Open the Find & Replace window.", shortcut: [{ key: "H", modifiers: [ha.Ctrl] }, { key: "H", modifiers: [ha.Ctrl, ha.Alt] }] }), new ua("goto", a2, { label: "Go To", description: "Open the 'Go To' window.", shortcut: [{ key: "G", modifiers: [ha.Ctrl] }] }), new ua("workbookViewToggleExpandFormulaBar", a2, { label: "Toggle Expand Formula bar", description: "Expand or collapse the formula bar.", shortcut: { key: "U", modifiers: [ha.Ctrl, ha.Shift] } }), new ua("workbookViewToggleShowFormulaBar", a2, { label: "View Formula bar", scopedLabels: { view: "Formula Bar" }, description: "Show or hide the formula bar." }), new ua("workbookViewToggleShowTabs", a2, { label: "View Sheet Tabs", description: "Show or hide the sheet tabs.", scopedLabels: { view: "Sheet Tabs" } }), new ua("workbookViewToggleShowStatusBar", a2, { label: "View Status Bar", description: "Show or hide the status bar.", scopedLabels: { view: "Status Bar" } }), new ua("workbookViewToggleShowHorizontalScrollBar", a2, { label: "View Horizontal Scrollbar", description: "Show or hide the horizontal scrollbar.", scopedLabels: { view: "Horizontal Scrollbar" } }), new ua("workbookViewToggleShowVerticalScrollBar", a2, { label: "View Vertical Scrollbar", description: "Show or hide the vertical scrollbar.", scopedLabels: { view: "Vertical Scrollbar" } }), new ga("hideSheet", a2, { label: "Hide Sheet", scopedLabels: { sheet: "Hide" }, description: "Hide the sheet from appearing in the tabs. This keeps the data but de-clutters the tabs." }), new ga("deleteSheet", a2, { label: "Delete Sheet", scopedLabels: { sheet: "Delete" }, description: "Delete the sheet and all the data." }), new ga("addSheet", a2, { label: "Insert Sheet", scopedLabels: { sheet: "Insert" }, description: "Insert sheet before the current sheet.", shortcut: [{ key: "F11", modifiers: [ha.Shift] }, { key: "F1", modifiers: [ha.Alt, ha.Shift] }] }), new ga("duplicateSheet", a2, { label: "Duplicate Sheet", description: "Duplicate the current sheet.", scopedLabels: { sheet: "Duplicate" } }), new ga("nextSheet", a2, { label: "Next Sheet", scopedLabels: { sheet: "Next" }, description: "Activate the next sheet.", shortcut: [{ key: "PageDown", modifiers: [ha.Ctrl] }] }), new ga("previousSheet", a2, { label: "Previous Sheet", scopedLabels: { sheet: "Previous" }, description: "Activate the previous sheet.", shortcut: [{ key: "PageUp", modifiers: [ha.Ctrl] }] }), new ga("selectNextSheet", a2, { label: "Select Next Sheet", scopedLabels: { sheet: "Select Next" }, description: "Select the next sheet.", shortcut: [{ key: "PageDown", modifiers: [ha.Ctrl, ha.Shift] }] }), new ga("selectPreviousSheet", a2, { label: "Select Previous Sheet", scopedLabels: { sheet: "Select Previous" }, description: "Select the previous sheet.", shortcut: [{ key: "PageUp", modifiers: [ha.Ctrl, ha.Shift] }] }), new ga("selectTheme", a2, { label: "Theme", description: "Select a theme that coveys a style suitable for your data." }), new ga("selectNamed", a2, { label: (e3) => e3?.getName() ?? "Select Named Item", scopedLabels: { namedItem: (e3) => e3?.getName() ?? "Select" }, description: "Select the item." }), new ga("addNamedReference", a2, { label: "Define Named Reference", scopedLabels: { namedItem: "Define Name…" }, description: "Add a new named reference. Names can be used as a substitute for cell references." }), new ga("editNamedReference", a2, { label: "Edit Named Reference…", scopedLabels: { namedItem: "Edit…" }, description: "Add a new named reference. Names can be used as a substitute for cell references." }), new ga("deleteNamedReference", a2, { label: "Delete Named Reference", scopedLabels: { namedItem: "Delete" }, description: "Remove the named reference." }), new ua("activeNameBox", a2, { label: "Activate Name Box", description: "Move the focus to the name box.", shortcut: { key: "F3", modifiers: [ha.Alt] } }), new ua("createNamedReferenceFromSelection", a2, { label: "Create from Selection", description: "Automatically generate names from the selected cells.", shortcut: { key: "F3", modifiers: [ha.Ctrl, ha.Shift] } }), new ua("activeNameManager", a2, { label: "Activate Name Manager", description: "Create, edit, delete, and find all the names used in the workbook.\n\nNames can be used as a substitute for cell references.", shortcut: { key: "F3", modifiers: [ha.Ctrl] } }), new ga("fullScreenToggle", a2, { label: "FullScreen", description: "Toggle showing the workbook using the full screen.", shortcut: { key: "F11" } }), new ga("showScriptEditor", a2, { label: "Scripts", scopedLabels: { scripts: "Script Editor…" }, description: "Show the script editor.", shortcut: [{ key: "F11", modifiers: [ha.Alt] }] }), new ga("executeScript", a2, { label: "Run Script", description: "Run the selected or last executed script.", shortcut: { key: "F8" } }), new ga("executeSelectedScript", a2, { label: "Run Script", description: "Run the selected script.", shortcut: { key: "F8" } }), new ga("saveScripts", a2, { label: "Save Script", description: "Save the current scripts." }), new ga("maximumWorkbookToggle", a2, { label: "Maximize", description: "Toggle showing the workbook maximized.", shortcut: { key: "F10", modifiers: [ha.Ctrl] } }), new ga("spellCheck", a2, { label: "Spell Check", description: "Check the workbook for spelling mistakes.", shortcut: { key: "F7" } }), new ga("calculateAll", a2, { label: "Calculate Now", description: "Recalculate all formulas.", shortcut: { key: "F9" } }), new ua("closeWorkbook", a2, { label: "Close Workbook", description: "Close the workbook.", shortcut: { key: "W", modifiers: [ha.Ctrl] } }), new ua("newWorkbook", a2, { label: "New Workbook", description: "Create a new workbook in another tab." })], []), x2 = C(() => {
1761
1764
  let e3 = null;
1762
1765
  return e3 = r2 ? r2.createChildGroup(a2, "workbook", false) : new fa(a2, "workbook"), e3.addCommands(f2, true), e3;
1763
1766
  }, [r2, f2]), b2 = ia(), y2 = w.useRef(null), k2 = na(() => {
@@ -1992,14 +1995,14 @@ const ri = (e2) => {
1992
1995
  const e3 = t2.getProtection().isStructureAllowed();
1993
1996
  x2.getCommand("hideSheet").update({ disabled: m2.length <= 1 || !e3 }), x2.getCommand("deleteSheet").update({ disabled: m2.length <= 1 || !e3 });
1994
1997
  }, [m2, d2]), x2;
1995
- }, li = () => {
1998
+ }, ii = () => {
1996
1999
  window.open(window.origin.toString(), "sheetxl-" + n.uuidV4(), "popup=true");
1997
- }, ii = "_sheetxl-theme_4opcr_2", si = "_sheetxl-workbook_1j3lu_5", di = (e2) => x(Ml, { ...e2 }), ci = (e2) => x(Fl, { ...e2 }), mi = (e2) => x(Rl, { ...e2 }), pi = k(S((e2, t2) => {
1998
- const { workbook: o2, commands: n2, onBeforeUserChange: a2, onUserChange: r2, disabled: l2 = false, readOnly: i2 = false, contextMenuProps: s2, renderContextMenu: d2 = di, sheetsAllProps: c2, renderSheetsAll: m2 = ci, sheetTabProps: p2, renderSheetTab: u2, background: g2 = "transparent", className: h2, notifier: f2, sx: y2, borderWidth: w2, borderColor: k2, gridTheme: S2, gridStyle: T2, ...R2 } = e2, [F2, B2] = D(o2?.getSelectedSheetIndex()), [N2, A2] = D(o2?.getSheets().getItems()), [I2, H2] = D(o2?.getProtection());
2000
+ }, si = "_sheetxl-theme_4opcr_2", di = "_sheetxl-workbook_1j3lu_5", ci = (e2) => x(Fl, { ...e2 }), mi = (e2) => x(Bl, { ...e2 }), pi = (e2) => x(Ml, { ...e2 }), ui = k(S((e2, t2) => {
2001
+ const { workbook: o2, commands: n2, onBeforeUserChange: a2, onUserChange: r2, disabled: l2 = false, readOnly: i2 = false, contextMenuProps: s2, renderContextMenu: d2 = ci, sheetsAllProps: c2, renderSheetsAll: m2 = mi, sheetTabProps: p2, renderSheetTab: u2, background: g2 = "transparent", className: h2, notifier: f2, sx: y2, borderWidth: w2, borderColor: k2, gridTheme: S2, gridStyle: T2, ...R2 } = e2, [F2, B2] = D(o2?.getSelectedSheetIndex()), [N2, E2] = D(o2?.getSheets().getItems()), [I2, H2] = D(o2?.getProtection());
1999
2002
  Pa(o2, { onViewChange(e3) {
2000
2003
  B2(e3?.getSelectedSheetIndex());
2001
2004
  }, onSheetsChange: (e3) => {
2002
- A2(e3.getSheets().getItems());
2005
+ E2(e3.getSheets().getItems());
2003
2006
  }, onProtectionChange: (e3) => {
2004
2007
  H2(e3?.getProtection());
2005
2008
  } });
@@ -2036,13 +2039,13 @@ const ri = (e2) => {
2036
2039
  } catch (e4) {
2037
2040
  }
2038
2041
  if (!t3) return null;
2039
- return (u2 ?? mi)({ sheet: t3, gridTheme: S2, onContextMenu: (t4) => {
2042
+ return (u2 ?? pi)({ sheet: t3, gridTheme: S2, onContextMenu: (t4) => {
2040
2043
  $2(e3.index), ne2(t4, e3.index);
2041
2044
  }, ...e3, ...p2 });
2042
2045
  }, [u2, p2, o2, S2]), re2 = C(() => W2 ? null : x(De, { disableInteractive: true, title: "New sheet", children: x(L, { disabled: l2, component: "div", sx: { padding: "0", "&:hover:not([disabled])": { color: (e3) => e3.palette.primary.main }, color: (e3) => e3.palette.text.icon ?? e3.palette.action.active, "& svg": { width: "18px", height: "18px" } }, "aria-label": "addTab", size: "small", onMouseDown: (e3) => {
2043
2046
  0 === e3.button && e3.preventDefault();
2044
2047
  }, onClick: () => G2(), children: x(Yn, {}) }) }), [l2, W2, G2]);
2045
- return b(E, { ref: t2, className: In(h2), sx: { position: "relative", display: "flex", alignItems: "stretch", flex: "1 1 100%", maxWidth: "100%", ...y2 }, ...R2, children: [x(Na, { ref: J2, selectedTabIndex: F2, tabNames: z2, onSelectedTabIndexChange: $2, onTabNameChange: O2, onTabMove: V2, background: g2, borderColor: k2, borderWidth: w2, activeColor: null, disabled: l2, disableDrag: W2, createScrollStartButton: Ko, createScrollEndButton: qo, createScrollEdgeButton: _o, createTabButton: ae2, createTabDivider: (e3) => {
2048
+ return b(A, { ref: t2, className: In(h2), sx: { position: "relative", display: "flex", alignItems: "stretch", flex: "1 1 100%", maxWidth: "100%", ...y2 }, ...R2, children: [x(Na, { ref: J2, selectedTabIndex: F2, tabNames: z2, onSelectedTabIndexChange: $2, onTabNameChange: O2, onTabMove: V2, background: g2, borderColor: k2, borderWidth: w2, activeColor: null, disabled: l2, disableDrag: W2, createScrollStartButton: Ko, createScrollEndButton: qo, createScrollEdgeButton: _o, createTabButton: ae2, createTabDivider: (e3) => {
2046
2049
  const { key: t3, ...o3 } = e3;
2047
2050
  return x(ie, { sx: { marginLeft: "-1px", marginRight: "0px", marginTop: "6px", marginBottom: "6px", background: (e4) => ka(e4.palette.divider, 0.25) }, ...o3 }, t3);
2048
2051
  }, editLabelProps: { readOnly: W2, maxLength: 31, styleHover: { fontWeight: "700" }, onKeyPress: (e3) => {
@@ -2055,8 +2058,8 @@ const ri = (e2) => {
2055
2058
  _2 ? X2.close(0) : X2.open(0);
2056
2059
  }, icon: x(Qn, {}) }) }) }), x("div", { style: { borderTop: `solid ${k2} ${w2}px`, minWidth: "4px" } }), x("div", { style: { borderTop: `solid ${k2} ${w2}px`, flex: "none", display: "flex", alignItems: "center" }, children: re2 }), x("div", { style: { borderTop: `solid ${k2} ${w2}px`, flex: 1, minWidth: "24px" } }), oe2, Z2] });
2057
2060
  }));
2058
- pi.displayName = "WorkbookStrip";
2059
- const ui = k(S((e2, t2) => {
2061
+ ui.displayName = "WorkbookStrip";
2062
+ const gi = k(S((e2, t2) => {
2060
2063
  const { workbook: o2, commands: n2, disabled: a2, sx: r2, floatReference: l2, className: i2, ...s2 } = e2, [d2, c2] = B((e3) => e3 + 1, 0), [m2, p2] = D(o2.getSelectedSheet()), [u2, g2] = D(m2.getSelectedRanges()), [h2, f2] = D(m2.getSelectedCell());
2061
2064
  Pa(o2, { onSheetsChange() {
2062
2065
  p2(o2.getSelectedSheet());
@@ -2071,7 +2074,7 @@ const ui = k(S((e2, t2) => {
2071
2074
  } }, disabled: a2, scope: "contextMenu", parentFloat: l2 }), [a2, l2]), S2 = C(() => ({ ...w2, ...k2, variant: oa.Menuitem }), [w2, k2]), v2 = C(() => ({ commands: n2, variant: oa.Menuitem, parentFloat: l2, ...k2 }), [n2, k2, l2]), T2 = [];
2072
2075
  let P2 = u2.isEntireRows(), R2 = u2.isEntireColumns();
2073
2076
  u2 && (P2 && (T2.push(x(ie, { orientation: "horizontal" }, "context:" + T2.length)), T2.push(F(le, { command: n2.getCommand("hideColumns"), ...S2, icon: re(x(Xo, {})), key: "context:" + T2.length })), T2.push(F(le, { command: n2.getCommand("unhideColumns"), ...S2, icon: re(x(Zo, {})), key: "context:" + T2.length }))), R2 && (T2.push(x(ie, { orientation: "horizontal" }, "context:" + T2.length)), T2.push(F(le, { command: n2.getCommand("hideRows"), ...S2, icon: re(x(Jo, {})), key: "context:" + T2.length })), T2.push(F(le, { command: n2.getCommand("unhideRows"), ...S2, icon: re(x(Yo, {})), key: "context:" + T2.length }))), (P2 || R2) && T2.push(x(ie, { orientation: "horizontal" }, "context:" + T2.length)), P2 && T2.push(F(le, { command: n2.getCommand("autoFitColumns"), ...S2, icon: re(x(Qo, {})), key: "context:" + T2.length })), R2 && T2.push(F(le, { command: n2.getCommand("autoFitRows"), ...S2, icon: re(x(en, {})), key: "context:" + T2.length })));
2074
- const M2 = [], N2 = n2.getCommand("formatTableStyle"), A2 = N2?.context()?.table();
2077
+ const M2 = [], N2 = n2.getCommand("formatTableStyle"), E2 = N2?.context()?.table();
2075
2078
  if (la(N2), !P2 && !R2) {
2076
2079
  if (M2.push(x(ie, { orientation: "horizontal" }, "contextBefore:" + M2.length)), h2?.getHyperlink()) M2.push(F(Jt, { ...v2, popupCommandKeys: ["updateHyperlink", "deleteHyperlink"], popupScope: "hyperlink", key: "contextBefore:action" + M2.length, quickCommand: "openHyperlink", icon: (e3) => "openHyperlink" === e3.key() ? re(x(Vo, {})) : null }));
2077
2080
  else {
@@ -2083,16 +2086,16 @@ const ui = k(S((e2, t2) => {
2083
2086
  const e3 = n2.getCommand("updateComments");
2084
2087
  M2.push(F(le, { command: e3, ...S2, icon: re(x(Go, {})), key: "contextBefore:" + M2.length }));
2085
2088
  }
2086
- A2 ? M2.push(F(Jt, { ...v2, variant: oa.Menuitem, key: "contextBefore:" + M2.length, popupCommandKeys: ["convertTableToRange", "deleteTable"], popupScope: "table", scope: "context", commandState: A2, quickCommand: "editTable", icon: (e3) => {
2089
+ E2 ? M2.push(F(Jt, { ...v2, variant: oa.Menuitem, key: "contextBefore:" + M2.length, popupCommandKeys: ["convertTableToRange", "deleteTable"], popupScope: "table", scope: "context", commandState: E2, quickCommand: "editTable", icon: (e3) => {
2087
2090
  e3.key();
2088
2091
  return re(x(So, {}));
2089
2092
  } })) : M2.push(F(le, { command: n2.getCommand("insertTable"), ...S2, icon: re(x(So, {})), key: "context:" + T2.length })), M2.push(F(pl, { ...v2, key: "contextBefore:" + M2.length }));
2090
2093
  }
2091
- const I2 = b(y, { children: [x(le, { command: n2.getCommand("cut"), ...S2, icon: x(tn, {}) }), x(ul, { command: n2.getCommand("copy"), ...S2 }), x(jr, { command: n2.getCommand("paste"), ...v2, includePasteAllInPopup: false }), x(ie, { orientation: "horizontal" }), x(Hr, { ...v2 }), x(ie, { orientation: "horizontal" }), x(Ar, { commands: n2, ...v2, disableSheet: true }), x(Er, { commands: n2, ...v2, disableSheet: true }), x(Br, { ...v2 }), M2, T2] });
2092
- return x(E, { ref: t2, className: In("menu", i2), sx: { ...r2 }, ...s2, children: I2 });
2094
+ const I2 = b(y, { children: [x(le, { command: n2.getCommand("cut"), ...S2, icon: x(tn, {}) }), x(ul, { command: n2.getCommand("copy"), ...S2 }), x(jr, { command: n2.getCommand("paste"), ...v2, includePasteAllInPopup: false }), x(ie, { orientation: "horizontal" }), x(Hr, { ...v2 }), x(ie, { orientation: "horizontal" }), x(Er, { commands: n2, ...v2, disableSheet: true }), x(Ar, { commands: n2, ...v2, disableSheet: true }), x(Br, { ...v2 }), M2, T2] });
2095
+ return x(A, { ref: t2, className: In("menu", i2), sx: { ...r2 }, ...s2, children: I2 });
2093
2096
  }));
2094
- ui.displayName = "WorkbookContextMenu";
2095
- const gi = k(S((e2, t2) => {
2097
+ gi.displayName = "WorkbookContextMenu";
2098
+ const hi = k(S((e2, t2) => {
2096
2099
  const { movable: o2, commands: n2, disabled: a2, sx: r2, floatReference: l2, ...i2 } = e2;
2097
2100
  Pa(o2, { onAnyChange(e3) {
2098
2101
  } });
@@ -2142,21 +2145,21 @@ const gi = k(S((e2, t2) => {
2142
2145
  const t3 = p2(e3);
2143
2146
  return t3 || re(x(an, {}));
2144
2147
  }, tooltip: "Determine how the drawing size will adjust as the cell sizes adjust." }), []] });
2145
- return x(E, { ref: t2, sx: { paddingTop: "4px", paddingBottom: "4px", ...r2 }, ...i2, children: u2 });
2148
+ return x(A, { ref: t2, sx: { paddingTop: "4px", paddingBottom: "4px", ...r2 }, ...i2, children: u2 });
2146
2149
  }));
2147
- gi.displayName = "MovableContextMenu";
2148
- const hi = (e2) => x(gi, { ...e2 }), fi = (e2) => x(ui, { ...e2 }), xi = (e2) => x(Dl, { ...e2 }), bi = (e2, t2) => x(Tl, { ref: t2, ...e2 }), yi = (e2) => x(Pe, { ...e2 }), wi = (e2, t2) => x(Aa, { ref: t2, ...e2 }), ki = (e2) => x(Sl, { ...e2 }), Si = (e2) => x(pi, { ...e2 }), Ci = { fireOnModelChange: false }, vi = { flex: "1 1 100%", display: "flex" }, Ti = k(S((e2, t2) => {
2149
- const { workbook: o2, createWorkbookOptions: a2, onNewWorkbook: r2, onElementLoad: l2, notifier: i2, autoFocus: s2 = false, sx: d2, style: c2, className: m2, onFocus: p2, onBlur: u2, onKeyDown: g2, onRepeatCommandChange: k2, commands: S2, showFormulaBar: T2, formulaBarProps: R2, renderFormulaBar: F2 = bi, showTabs: N2, tabsProps: L2, renderTabs: H2 = Si, showStatusBar: W2, statusBarProps: z2, renderStatusBar: $2 = ki, toolbarProps: O2, renderToolbar: V2 = ei, contextMenuSx: G2, renderContextMenu: U2 = fi, renderFilterMenu: j2 = xi, renderMovableMenu: _2 = hi, renderLoadingPanel: q2 = yi, loadingPanelProps: K2, sheetProps: Z2, renderSheet: J2 = wi, showHorizontalScrollbar: Y2, showVerticalScrollbar: Q2, gridTheme: ee2, headersTheme: te2, enableDarkImages: oe2, ...ne2 } = e2, ae2 = wa(), re2 = Ba(), le2 = C(() => {
2150
+ hi.displayName = "MovableContextMenu";
2151
+ const fi = (e2) => x(hi, { ...e2 }), xi = (e2) => x(gi, { ...e2 }), bi = (e2) => x(Pl, { ...e2 }), yi = (e2, t2) => x(Dl, { ref: t2, ...e2 }), wi = (e2) => x(Pe, { ...e2 }), ki = (e2, t2) => x(Ea, { ref: t2, ...e2 }), Si = (e2) => x(Cl, { ...e2 }), Ci = (e2) => x(ui, { ...e2 }), vi = { fireOnModelChange: false }, Ti = { flex: "1 1 100%", display: "flex" }, Di = k(S((e2, t2) => {
2152
+ const { workbook: o2, createWorkbookOptions: a2, onNewWorkbook: r2, onElementLoad: l2, notifier: i2, autoFocus: s2 = false, sx: d2, style: c2, className: m2, onFocus: p2, onBlur: u2, onKeyDown: g2, onRepeatCommandChange: k2, commands: S2, showFormulaBar: T2, formulaBarProps: R2, renderFormulaBar: F2 = yi, showTabs: N2, tabsProps: L2, renderTabs: H2 = Ci, showStatusBar: W2, statusBarProps: z2, renderStatusBar: $2 = Si, toolbarProps: O2, renderToolbar: V2 = ti, contextMenuSx: G2, renderContextMenu: U2 = xi, renderFilterMenu: j2 = bi, renderMovableMenu: _2 = fi, renderLoadingPanel: q2 = wi, loadingPanelProps: K2, sheetProps: Z2, renderSheet: J2 = ki, showHorizontalScrollbar: Y2, showVerticalScrollbar: Q2, gridTheme: ee2, headersTheme: te2, enableDarkImages: oe2, ...ne2 } = e2, ae2 = wa(), re2 = Ba(), le2 = C(() => {
2150
2153
  const e3 = { theme: re2.getDefaultTheme(), ...a2 };
2151
2154
  return o2 ?? new h(e3);
2152
- }, [o2]), ie2 = M(null), [se2, de2] = D(false), ce2 = M(null), me2 = C(() => x(E, { className: "sheetxl-viewport", sx: { width: "100%", height: "100%", boxSizing: "border-box", position: "absolute", pointerEvents: "none !important", "& > :first-of-type": { position: "relative" } }, ref: ce2 }), []), [pe2, ue2] = D(false), [ge2, he2] = D(false), fe2 = v(() => {
2155
+ }, [o2]), ie2 = M(null), [se2, de2] = D(false), ce2 = M(null), me2 = C(() => x(A, { className: "sheetxl-viewport", sx: { width: "100%", height: "100%", boxSizing: "border-box", position: "absolute", pointerEvents: "none !important", "& > :first-of-type": { position: "relative" } }, ref: ce2 }), []), [pe2, ue2] = D(false), [ge2, he2] = D(false), fe2 = v(() => {
2153
2156
  ue2(true);
2154
2157
  }, []), xe2 = M(null), be2 = ca(t2, () => ({ isWorkbookElement: () => true, getWorkbook: () => le2, getSheetElement: () => ie2.current, getViewportElement: () => ce2.current, getFormulaBarElement: () => xe2.current, focus() {
2155
2158
  ie2 && ie2.current && ie2.current.focus();
2156
2159
  } }), [le2]), ye2 = M(null);
2157
- A(() => {
2160
+ E(() => {
2158
2161
  pe2 && be2.current && (he2(true), ye2.current !== l2 && (l2?.({ source: be2.current }), ye2.current = l2));
2159
- }, [pe2, be2.current]), El(be2.current);
2162
+ }, [pe2, be2.current]), Il(be2.current);
2160
2163
  const we2 = v((e3) => (ie2.current?.submitEdit(), true), []), ke2 = v(() => {
2161
2164
  requestAnimationFrame(() => {
2162
2165
  ie2?.current?.focus();
@@ -2172,16 +2175,16 @@ const hi = (e2) => x(gi, { ...e2 }), fi = (e2) => x(ui, { ...e2 }), xi = (e2) =>
2172
2175
  ie2.current.getSheet() !== t3 ? ie2.current.getGridElement()?.onViewChangeOnce(() => {
2173
2176
  ie2.current.getSheet() !== t3 && e4(false), e4(true);
2174
2177
  }) : e4(true);
2175
- }) }, Ci);
2178
+ }) }, vi);
2176
2179
  const [Re2, Me2] = B((e3) => e3 + 1, 0), Fe2 = le2?.getView();
2177
2180
  Pa(Fe2, { onViewChange: (e3) => {
2178
2181
  Me2();
2179
2182
  } });
2180
- const Be2 = ee2 ?? ae2, Ne2 = C(() => Hl(ae2, Be2), [ae2, Be2]), Ae2 = te2 ?? ae2, Ee2 = C(() => Hl(ae2, Ae2), [ae2, Ae2]), [Ie2, Le2] = D(null);
2183
+ const Be2 = ee2 ?? ae2, Ne2 = C(() => Wl(ae2, Be2), [ae2, Be2]), Ee2 = te2 ?? ae2, Ae2 = C(() => Wl(ae2, Ee2), [ae2, Ee2]), [Ie2, Le2] = D(null);
2181
2184
  v(() => {
2182
2185
  ie2.current.focus();
2183
2186
  }, []);
2184
- const [He2, We2] = D(false), ze2 = M(null), $e2 = ri({ workbook: le2, workbookElement: be2.current, target: () => ie2.current, notifier: i2, commands: S2, darkMode: Ne2.body.darkMode, onNewWorkbook: r2, onShowSidebar: () => {
2187
+ const [He2, We2] = D(false), ze2 = M(null), $e2 = li({ workbook: le2, workbookElement: be2.current, target: () => ie2.current, notifier: i2, commands: S2, darkMode: Ne2.body.darkMode, onNewWorkbook: r2, onShowSidebar: () => {
2185
2188
  He2 ? ze2.current?.focus() : We2(true);
2186
2189
  } }), Oe2 = M(null), [Ve2, Ge2] = D(false), [Ue2, je2] = D(null), [_e2, qe2] = D(xa.Top), [Ke2, Xe2] = D(f.EmptyBounds), Ze2 = () => {
2187
2190
  Ge2(false), je2(null);
@@ -2194,17 +2197,17 @@ const hi = (e2) => x(gi, { ...e2 }), fi = (e2) => x(ui, { ...e2 }), xi = (e2) =>
2194
2197
  }, [H2, L2, i2, ae2, le2, Be2, ct2, $e2, et2]), pt2 = v((e3) => {
2195
2198
  const t3 = n.getOS() === n.OSType.Firefox;
2196
2199
  let o3 = null, a3 = null, r3 = null;
2197
- if (tt2 && (a3 = x("div", { style: { display: "flex", flex: "1 1 100%", borderTop: `solid ${rt2} 1px`, maxWidth: "100%" }, children: x(Ea, { style: { alignItems: "center", borderTop: (t3 ? 6 : 3) + "px solid transparent", borderBottom: (ct2 ? 6 : 3) + "px solid transparent", borderLeft: (t3 ? 3 : 0) + "px solid transparent", borderRight: (t3 ? 3 : 0) + "px solid transparent" }, ...e3, endGap: 700, sheet: Se2, showCustomScrollButtons: !t3, onShowTooltip: (e4) => {
2200
+ if (tt2 && (a3 = x("div", { style: { display: "flex", flex: "1 1 100%", borderTop: `solid ${rt2} 1px`, maxWidth: "100%" }, children: x(Aa, { style: { alignItems: "center", borderTop: (t3 ? 6 : 3) + "px solid transparent", borderBottom: (ct2 ? 6 : 3) + "px solid transparent", borderLeft: (t3 ? 3 : 0) + "px solid transparent", borderRight: (t3 ? 3 : 0) + "px solid transparent" }, ...e3, endGap: 700, sheet: Se2, showCustomScrollButtons: !t3, onShowTooltip: (e4) => {
2198
2201
  Je2({ x: e4.anchor.x, y: e4.anchor.y, width: 0, height: 0 }, e4.display, e4.placement);
2199
- }, onCloseTooltip: () => Ze2() }) })), et2 && ct2 && (r3 = mt2), et2 && ct2 && !tt2 && (r3 = b(E, { sx: { display: "flex", flex: "1", position: "relative", alignContent: "center" }, children: [r3, x(E, { sx: { borderTop: `solid ${rt2} 1px`, flex: "1" } })] })), r3 && tt2) o3 = x(ma, { position: le2.getView().getTabRatio() / 10 + "%", onPositionChange: ({ percent: e4 }) => {
2202
+ }, onCloseTooltip: () => Ze2() }) })), et2 && ct2 && (r3 = mt2), et2 && ct2 && !tt2 && (r3 = b(A, { sx: { display: "flex", flex: "1", position: "relative", alignContent: "center" }, children: [r3, x(A, { sx: { borderTop: `solid ${rt2} 1px`, flex: "1" } })] })), r3 && tt2) o3 = x(ma, { position: le2.getView().getTabRatio() / 10 + "%", onPositionChange: ({ percent: e4 }) => {
2200
2203
  le2.getView().setTabRatio(Math.round(10 * e4));
2201
2204
  }, minBefore: "200px", minAfter: "180px", resizerProps: { style: { minWidth: "11px", backgroundImage: `url("data:image/svg+xml,%3Csvg width='6.4' height='12' viewBox='0 0 9.6 16' version='1.1' fill='${ae2.palette.text.icon ?? ae2.palette.action.active}' xmlns='http://www.w3.org/2000/svg' xmlns:svg='http://www.w3.org/2000/svg'%3E%3Cpath d='M 9.60008,14.40009 C 9.60008,15.28374 8.88368,16 8.00003,16 7.11639,16 6.40012,15.28374 6.40012,14.40009 c 0,-0.88365 0.71627,-1.60005 1.59991,-1.60005 0.88365,0 1.60005,0.7164 1.60005,1.60005 m 0,-6.40012 c 0,0.88364 -0.7164,1.60004 -1.60005,1.60004 -0.88364,0 -1.59991,-0.7164 -1.59991,-1.60004 0,-0.88365 0.71627,-1.60005 1.59991,-1.60005 0.88365,0 1.60005,0.7164 1.60005,1.60005 m 0,-6.40006 c 0,0.88365 -0.7164,1.60005 -1.60005,1.60005 -0.88364,0 -1.59991,-0.7164 -1.59991,-1.60005 C 6.40012,0.71626 7.11639,0 8.00003,0 8.88368,0 9.60008,0.71626 9.60008,1.59991 M 3.19996,14.40009 C 3.19996,15.28374 2.48369,16 1.60005,16 0.7164,16 0,15.28374 0,14.40009 c 0,-0.88365 0.7164,-1.60005 1.60005,-1.60005 0.88364,0 1.59991,0.7164 1.59991,1.60005 m 0,-6.40012 c 0,0.88364 -0.71627,1.60004 -1.59991,1.60004 C 0.7164,9.60001 0,8.88361 0,7.99997 0,7.11632 0.7164,6.39992 1.60005,6.39992 c 0.88364,0 1.59991,0.7164 1.59991,1.60005 m 0,-6.40006 c 0,0.88365 -0.71627,1.60005 -1.59991,1.60005 C 0.7164,3.19996 0,2.48356 0,1.59991 0,0.71626 0.7164,0 1.60005,0 2.48369,0 3.19996,0.71626 3.19996,1.59991' /%3E%3C/svg%3E%0A")`, backgroundRepeat: "no-repeat", backgroundPosition: "center", borderTop: `solid ${rt2} 1px`, borderBottom: "solid 3px transparent" } }, elementBefore: r3, elementAfter: a3 });
2202
2205
  else if (tt2) o3 = a3;
2203
2206
  else {
2204
- if (!r3) return x(E, { sx: { display: "flex", flex: "1", position: "relative", alignContent: "center", height: "1px", borderTop: nt2 ? null : `solid ${rt2} 1px` } });
2207
+ if (!r3) return x(A, { sx: { display: "flex", flex: "1", position: "relative", alignContent: "center", height: "1px", borderTop: nt2 ? null : `solid ${rt2} 1px` } });
2205
2208
  o3 = r3;
2206
2209
  }
2207
- return x(E, { sx: { display: "flex", flex: "1", position: "relative", alignContent: "center" }, children: o3 });
2210
+ return x(A, { sx: { display: "flex", flex: "1", position: "relative", alignContent: "center" }, children: o3 });
2208
2211
  }, [Se2, we2, le2, Ne2, Be2, $e2, et2, tt2, nt2, ct2]), [ut2, gt2] = w.useState(null), ht2 = C(() => ({ placement: "right-start", ...ut2?.popperProps }), [ut2?.popperProps]), { reference: ft2, component: xt2 } = bo({ label: "contextMenu", popperProps: ht2, anchor: ut2?.anchor ?? { getBoundingClientRect: () => new DOMRect(ut2?.clientX || 0, ut2?.clientY || 0) }, onClose: () => gt2(null), createPopupPanel: ut2?.createPopupPanel });
2209
2212
  P(() => {
2210
2213
  ut2 ? ft2.open(0) : ft2.close(0);
@@ -2245,14 +2248,14 @@ const hi = (e2) => x(gi, { ...e2 }), fi = (e2) => x(ui, { ...e2 }), xi = (e2) =>
2245
2248
  const kt2 = na((e3) => {
2246
2249
  $e2?.dispatchToFocusedCommand(e3);
2247
2250
  }, [$e2]), St2 = na(() => {
2248
- El(be2.current);
2251
+ Il(be2.current);
2249
2252
  }, [le2, be2.current]), Ct2 = v(() => {
2250
2253
  Qe2("sheet");
2251
2254
  }, []), vt2 = v(() => {
2252
2255
  Qe2("formulaBar");
2253
2256
  }, []), Tt2 = na((e3) => {
2254
2257
  const t3 = n.getOS() === n.OSType.Firefox;
2255
- return x(Ea, { style: { borderLeft: "3px solid transparent", borderRight: "0px solid transparent", borderTop: (t3 ? 3 : 0) + "px solid transparent", borderBottom: (t3 ? 3 : 0) + "px solid transparent", width: t3 ? "13px" : void 0 }, ...e3, sheet: Se2, endGap: 700, showCustomScrollButtons: !t3, onShowTooltip: (e4) => {
2258
+ return x(Aa, { style: { borderLeft: "3px solid transparent", borderRight: "0px solid transparent", borderTop: (t3 ? 3 : 0) + "px solid transparent", borderBottom: (t3 ? 3 : 0) + "px solid transparent", width: t3 ? "13px" : void 0 }, ...e3, sheet: Se2, endGap: 700, showCustomScrollButtons: !t3, onShowTooltip: (e4) => {
2256
2259
  Je2(e4.anchor, e4.display, xa.Left);
2257
2260
  }, onCloseTooltip: () => Ze2() });
2258
2261
  }, [Se2]);
@@ -2273,7 +2276,7 @@ const hi = (e2) => x(gi, { ...e2 }), fi = (e2) => x(ui, { ...e2 }), xi = (e2) =>
2273
2276
  $e2?.getCommand("insertImageFromFile")?.execute({ file: t3, options: { bounds: { x: a3.x, y: a3.y } }, goto: { range: { ...r3 } } });
2274
2277
  } else $e2?.getCommand("openWorkbook")?.execute(t3);
2275
2278
  }
2276
- }, [$e2, Dt2]), Ft2 = C(() => Dt2 ? x(E, { sx: { position: "absolute", width: "100%", height: "100%", boxSizing: "border-box", pointerEvents: "none", display: "flex", justifyContent: "center", alignItems: "center", background: (e3) => e3.palette.divider, color: (e3) => e3.palette.primary.dark }, children: x(I, { variant: "h4", children: Dt2 }) }) : null, [Dt2]), Bt2 = M(null), Nt2 = C(() => x(Ka, { in: !ge2, nodeRef: Bt2, timeout: 500, classNames: "animating", unmountOnExit: true, children: x(E, { style: { display: "flex", alignItems: "center", justifyContent: "center", left: "0px", top: "0px", width: "100%", height: "100%", pointerEvents: ge2 ? "none" : d2?.pointerEvents, position: "absolute", boxSizing: "border-box" }, children: q2({ ref: Bt2, transitionDelay: "0", transparentBackground: false, sx: { opacity: ge2 ? 0 : d2?.opacity, pointerEvents: ge2 ? "none" : d2?.pointerEvents, position: "absolute", left: "0px", top: "0px", width: "100%", height: "100%", ...K2 } }) }) }), [ge2, q2, K2]), At2 = C(() => F2({ sx: { marginTop: (e3) => e3.spacing(0.25), marginLeft: (e3) => e3.spacing(1), marginRight: (e3) => e3.spacing(1) }, workbook: le2, sheetElement: ie2.current, gridStyle: Ne2, onFocus: vt2, ...R2, NamedCollectionEditorProps: { restoreFocus: (e3) => ie2.current.focus(e3), notifier: i2, ...R2?.NamedCollectionEditorProps, commandPopupButtonProps: { commands: $e2, ...R2?.NamedCollectionEditorProps?.commandPopupButtonProps } } }, xe2), [F2, R2, le2, Ne2, $e2, ge2]), Et2 = v((e3) => {
2279
+ }, [$e2, Dt2]), Ft2 = C(() => Dt2 ? x(A, { sx: { position: "absolute", width: "100%", height: "100%", boxSizing: "border-box", pointerEvents: "none", display: "flex", justifyContent: "center", alignItems: "center", background: (e3) => e3.palette.divider, color: (e3) => e3.palette.primary.dark }, children: x(I, { variant: "h4", children: Dt2 }) }) : null, [Dt2]), Bt2 = M(null), Nt2 = C(() => x(Ka, { in: !ge2, nodeRef: Bt2, timeout: 500, classNames: "animating", unmountOnExit: true, children: x(A, { style: { display: "flex", alignItems: "center", justifyContent: "center", left: "0px", top: "0px", width: "100%", height: "100%", pointerEvents: ge2 ? "none" : d2?.pointerEvents, position: "absolute", boxSizing: "border-box" }, children: q2({ ref: Bt2, transitionDelay: "0", transparentBackground: false, sx: { opacity: ge2 ? 0 : d2?.opacity, pointerEvents: ge2 ? "none" : d2?.pointerEvents, position: "absolute", left: "0px", top: "0px", width: "100%", height: "100%", ...K2 } }) }) }), [ge2, q2, K2]), Et2 = C(() => F2({ sx: { marginTop: (e3) => e3.spacing(0.25), marginLeft: (e3) => e3.spacing(1), marginRight: (e3) => e3.spacing(1) }, workbook: le2, sheetElement: ie2.current, gridStyle: Ne2, onFocus: vt2, ...R2, NamedCollectionEditorProps: { restoreFocus: (e3) => ie2.current.focus(e3), notifier: i2, ...R2?.NamedCollectionEditorProps, commandPopupButtonProps: { commands: $e2, ...R2?.NamedCollectionEditorProps?.commandPopupButtonProps } } }, xe2), [F2, R2, le2, Ne2, $e2, ge2]), At2 = v((e3) => {
2277
2280
  const { movable: t3, ...o3 } = e3, n2 = { movable: t3, onContextMenuCapture: (e4) => {
2278
2281
  wt2(e4, t3);
2279
2282
  }, ...o3 }, a3 = t3.getContent().getType();
@@ -2288,7 +2291,7 @@ const hi = (e2) => x(gi, { ...e2 }), fi = (e2) => x(ui, { ...e2 }), xi = (e2) =>
2288
2291
  r3 = x(Ha, { ...e4 });
2289
2292
  }
2290
2293
  return x("div", { style: { position: "absolute", clipPath: "inset(0px)", display: "flex", alignItems: "stretch", justifyContent: "stretch", pointerEvents: "all" }, children: r3 }, t3.getUUID());
2291
- }, []), It2 = C(() => J2({ style: vi, onFocus: Ct2, notifier: i2, gridStyle: Ne2, headersStyle: Ee2, sheet: Se2, commands: $e2, onSheetContextMenu: yt2, onViewportChange: (e3) => {
2294
+ }, []), It2 = C(() => J2({ style: Ti, onFocus: Ct2, notifier: i2, gridStyle: Ne2, headersStyle: Ae2, sheet: Se2, commands: $e2, onSheetContextMenu: yt2, onViewportChange: (e3) => {
2292
2295
  Le2(e3);
2293
2296
  }, showScrollbars: false, viewportComponent: me2, onRepeatCommandChange: k2, onElementLoad: fe2, onShowColumnTooltip: (e3) => {
2294
2297
  Je2(e3.anchor, e3.display, xa.Top);
@@ -2296,26 +2299,26 @@ const hi = (e2) => x(gi, { ...e2 }), fi = (e2) => x(ui, { ...e2 }), xi = (e2) =>
2296
2299
  Je2(e3.anchor, e3.display, xa.Right);
2297
2300
  }, onShowTooltip: (e3) => {
2298
2301
  Je2({ x: e3.anchor.x, y: e3.anchor.y, width: 0, height: 0 }, e3.display, e3.placement);
2299
- }, onCloseTooltip: () => Ze2(), renderMovable: Et2, ...Z2, cellRenderProps: { onFilterButtonMouseDown: (e3, t3) => {
2302
+ }, onCloseTooltip: () => Ze2(), renderMovable: At2, ...Z2, cellRenderProps: { onFilterButtonMouseDown: (e3, t3) => {
2300
2303
  Z2?.cellRenderProps?.onFilterButtonMouseDown(e3, t3), bt2(e3, t3);
2301
2304
  }, ...Z2?.cellRenderProps } }, ie2), [J2, $e2, Z2, Se2, Ne2, i2, k2]), Lt2 = C(() => {
2302
2305
  if (!He2) return null;
2303
2306
  const e3 = !ve2.isStructureAllowed();
2304
- return x(Kl, { sx: { marginBottom: (e4) => e4.spacing(0.5), border: (t3) => `solid ${e3 ? t3.palette.action.disabled : ka(t3.palette.divider, 0.2)} 1px`, borderRadius: (e4) => `${e4.shape.borderRadius}px`, overflow: "hidden" }, onClose: () => {
2307
+ return x(Xl, { sx: { marginBottom: (e4) => e4.spacing(0.5), border: (t3) => `solid ${e3 ? t3.palette.action.disabled : ka(t3.palette.divider, 0.2)} 1px`, borderRadius: (e4) => `${e4.shape.borderRadius}px`, overflow: "hidden" }, onClose: () => {
2305
2308
  We2(false), requestAnimationFrame(() => {
2306
2309
  ie2.current.focus();
2307
2310
  });
2308
2311
  }, readOnly: e3, commands: $e2, ref: ze2, scripts: le2.getScripts() });
2309
2312
  }, [He2, $e2, le2, i2, ve2]), Ht2 = C(() => {
2310
- const e3 = x(ba, { style: { ...vi, marginRight: Lt2 && ct2 ? "0px" : "6px" }, viewport: Ie2, touchElement: ie2.current?.getGridElement()?.stage, onScrollViewport: (e4) => {
2313
+ const e3 = x(ba, { style: { ...Ti, marginRight: Lt2 && ct2 ? "0px" : "6px" }, viewport: Ie2, touchElement: ie2.current?.getGridElement()?.stage, onScrollViewport: (e4) => {
2311
2314
  ie2.current?.getGridElement()?.scrollTo(e4);
2312
2315
  }, showHorizontalScrollbar: tt2 || et2, showVerticalScrollbar: at2, createHorizontalScrollbar: pt2, createVerticalScrollbar: Tt2, children: It2 });
2313
2316
  let t3 = e3;
2314
2317
  ct2 || (t3 = b(y, { children: [e3, mt2] }));
2315
2318
  let o3 = null, n2 = 4, a3 = 13;
2316
- return ct2 ? o3 = "m 3.6261898,11.36243 c 0,0.88365 -0.71627,1.59991 -1.59991,1.59991 -0.8836498,0 -1.60004965,-0.71626 -1.60004965,-1.59991 0,-0.88365 0.71639985,-1.6000508 1.60004965,-1.6000508 0.88364,0 1.59991,0.7164008 1.59991,1.6000508 m 0,-4.881294 c 0,0.88364 -0.71627,1.60004 -1.59991,1.60004 -0.8836498,0 -1.60004965,-0.7164 -1.60004965,-1.60004 0,-0.88365 0.71639985,-1.60005 1.60004965,-1.60005 0.88364,0 1.59991,0.7164 1.59991,1.60005 m 0,-4.881226 c 0,0.88365 -0.71627,1.60005 -1.59991,1.60005 C 1.14263,3.19996 0.42623015,2.48356 0.42623015,1.59991 0.42623015,0.71626 1.14263,0 2.0262798,0 c 0.88364,0 1.59991,0.71626 1.59991,1.59991" : (o3 = "M 1.59991,3.62619 C 0.71626,3.62619 0,2.90992 0,2.02628 0,1.1426301 0.71626,0.42623015 1.59991,0.42623015 c 0.88365,0 1.6000508,0.71639995 1.6000508,1.60004985 0,0.88364 -0.7164008,1.59991 -1.6000508,1.59991 m 4.881294,0 c -0.88364,0 -1.60004,-0.71627 -1.60004,-1.59991 0,-0.8836499 0.7164,-1.60004985 1.60004,-1.60004985 0.88365,0 1.60005,0.71639995 1.60005,1.60004985 0,0.88364 -0.7164,1.59991 -1.60005,1.59991 m 4.881226,0 c -0.88365,0 -1.60005,-0.71627 -1.60005,-1.59991 0,-0.8836499 0.7164,-1.60004985 1.60005,-1.60004985 0.88365,0 1.59991,0.71639995 1.59991,1.60004985 0,0.88364 -0.71626,1.59991 -1.59991,1.59991", n2 = 13, a3 = 4), x(ma, { fixedPane: "after", position: "40%", minAfter: ct2 ? "280px" : "120px", splitDirection: ct2 ? "row" : "column", style: vi, ref: st2, resizerProps: { className: "styled-resizer", style: { minWidth: ct2 ? "6px" : void 0, minHeight: ct2 ? void 0 : "6px", maskImage: `url("data:image/svg+xml,%3Csvg width='${n2}' height='${a3}' viewBox='0 0 ${n2} ${a3}' version='1.1' fill='${ae2.palette.text.icon ?? ae2.palette.action.active}' xmlns='http://www.w3.org/2000/svg' xmlns:svg='http://www.w3.org/2000/svg'%3E%3Cpath d='${o3}' /%3E%3C/svg%3E%0A")`, maskRepeat: "no-repeat", maskPosition: ct2 ? "left center" : "top center" } }, elementBefore: t3, paneBeforeProps: { style: { flexDirection: "column" } }, elementAfter: Lt2, paneAfterProps: { style: { marginLeft: ct2 ? "0px" : "4px", marginRight: ct2 ? "8px" : "4px" } } });
2319
+ return ct2 ? o3 = "m 3.6261898,11.36243 c 0,0.88365 -0.71627,1.59991 -1.59991,1.59991 -0.8836498,0 -1.60004965,-0.71626 -1.60004965,-1.59991 0,-0.88365 0.71639985,-1.6000508 1.60004965,-1.6000508 0.88364,0 1.59991,0.7164008 1.59991,1.6000508 m 0,-4.881294 c 0,0.88364 -0.71627,1.60004 -1.59991,1.60004 -0.8836498,0 -1.60004965,-0.7164 -1.60004965,-1.60004 0,-0.88365 0.71639985,-1.60005 1.60004965,-1.60005 0.88364,0 1.59991,0.7164 1.59991,1.60005 m 0,-4.881226 c 0,0.88365 -0.71627,1.60005 -1.59991,1.60005 C 1.14263,3.19996 0.42623015,2.48356 0.42623015,1.59991 0.42623015,0.71626 1.14263,0 2.0262798,0 c 0.88364,0 1.59991,0.71626 1.59991,1.59991" : (o3 = "M 1.59991,3.62619 C 0.71626,3.62619 0,2.90992 0,2.02628 0,1.1426301 0.71626,0.42623015 1.59991,0.42623015 c 0.88365,0 1.6000508,0.71639995 1.6000508,1.60004985 0,0.88364 -0.7164008,1.59991 -1.6000508,1.59991 m 4.881294,0 c -0.88364,0 -1.60004,-0.71627 -1.60004,-1.59991 0,-0.8836499 0.7164,-1.60004985 1.60004,-1.60004985 0.88365,0 1.60005,0.71639995 1.60005,1.60004985 0,0.88364 -0.7164,1.59991 -1.60005,1.59991 m 4.881226,0 c -0.88365,0 -1.60005,-0.71627 -1.60005,-1.59991 0,-0.8836499 0.7164,-1.60004985 1.60005,-1.60004985 0.88365,0 1.59991,0.71639995 1.59991,1.60004985 0,0.88364 -0.71626,1.59991 -1.59991,1.59991", n2 = 13, a3 = 4), x(ma, { fixedPane: "after", position: "40%", minAfter: ct2 ? "280px" : "120px", splitDirection: ct2 ? "row" : "column", style: Ti, ref: st2, resizerProps: { className: "styled-resizer", style: { minWidth: ct2 ? "6px" : void 0, minHeight: ct2 ? void 0 : "6px", maskImage: `url("data:image/svg+xml,%3Csvg width='${n2}' height='${a3}' viewBox='0 0 ${n2} ${a3}' version='1.1' fill='${ae2.palette.text.icon ?? ae2.palette.action.active}' xmlns='http://www.w3.org/2000/svg' xmlns:svg='http://www.w3.org/2000/svg'%3E%3Cpath d='${o3}' /%3E%3C/svg%3E%0A")`, maskRepeat: "no-repeat", maskPosition: ct2 ? "left center" : "top center" } }, elementBefore: t3, paneBeforeProps: { style: { flexDirection: "column" } }, elementAfter: Lt2, paneAfterProps: { style: { marginLeft: ct2 ? "0px" : "4px", marginRight: ct2 ? "8px" : "4px" } } });
2317
2320
  }, [tt2, et2, pt2, at2, Ie2, Lt2, It2, mt2, ae2, ct2]), Wt2 = C(() => ({ boxSizing: "border-box", background: (e3) => "dark" !== e3.palette.mode ? Ne2.header.fill : e3.palette.background.paper, "& *": { ...xn(ae2), fontWeight: 400 }, "&.Mui-focusVisible": {}, "& .viewport-overlay": { borderRight: `solid ${rt2} 1px` }, ...d2 }), [d2, Ne2]);
2318
- return b(X, { className: In("sheetxl-workbook", si, { "Mui-focusVisible": se2 }, ii, m2), sx: Wt2, style: c2, square: false, ...ne2, ref: be2, onFocus: (e3) => {
2321
+ return b(X, { className: In("sheetxl-workbook", di, { "Mui-focusVisible": se2 }, si, m2), sx: Wt2, style: c2, square: false, ...ne2, ref: be2, onFocus: (e3) => {
2319
2322
  de2(true), St2(), p2?.(e3);
2320
2323
  }, onBlur: (e3) => {
2321
2324
  de2(false), u2?.(e3);
@@ -2326,16 +2329,16 @@ const hi = (e2) => x(gi, { ...e2 }), fi = (e2) => x(ui, { ...e2 }), xi = (e2) =>
2326
2329
  const t3 = new Image();
2327
2330
  t3.src = e3.target.src, e3.dataTransfer.setDragImage(t3, 1, 1);
2328
2331
  }
2329
- }, onDragEnter: Rt2, onDragLeave: Rt2, onDragOver: Rt2, onDrop: Mt2, children: [b("div", { className: In(Jr), style: { flex: "1 1 100%", width: "100%", display: "flex", flexDirection: "column", opacity: ge2 ? void 0 : 0, "--sxl-app-color-high-contrast": ae2.palette.primary.main, "--sxl-app-color-primary": ae2.palette.primary.main, "--sxl-app-color-primary-dark": ae2.palette.primary.dark, "--sxl-app-color-primary-light": ae2.palette.primary.light, "--sxl-app-color-info": ae2.palette.info.main, "--sxl-app-color-info-dark": ae2.palette.info.dark, "--sxl-app-color-info-light": ae2.palette.info.light, "--sxl-app-color-secondary": ae2.palette.secondary.main, "--sxl-app-color-secondary-dark": ae2.palette.secondary.dark, "--sxl-app-color-secondary-light": ae2.palette.secondary.light, "--sxl-app-color-success": ae2.palette.success.main, "--sxl-app-color-success-dark": ae2.palette.success.dark, "--sxl-app-color-success-light": ae2.palette.success.light, "--sxl-app-color-warning": ae2.palette.warning.main, "--sxl-app-color-warning-dark": ae2.palette.warning.dark, "--sxl-app-color-warning-light": ae2.palette.warning.light, "--sxl-app-color-error": ae2.palette.error.main, "--sxl-app-color-error-dark": ae2.palette.error.dark, "--sxl-app-color-error-light": ae2.palette.error.light, "--sxl-app-color-text": ae2.palette.text.primary, "--sxl-app-color-text-secondary": ae2.palette.text.secondary, "--sxl-app-color-text-disabled": ae2.palette.text.disabled, "--sxl-app-color-background": ae2.palette.background.paper, "--sxl-app-color-button-surface": ae2.palette.grey[600], "--sxl-app-color-shadow": ae2.palette.action.focus, "--sxl-app-color-grey": ae2.palette.grey[500], "--sxl-app-filter-dark-invert": Ne2.body.darkMode && oe2 ? "hue-rotate(180deg) invert(1) brightness(95%)" : "none", "--sxl-app-image-background": Ne2.body.darkMode ? `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` : void 0 }, children: [it2, ot2 ? At2 : null, x(E, { sx: { marginBottom: (e3) => e3.spacing(0.75) } }), Ht2, lt2, x(De, { arrow: true, disableInteractive: true, open: Ve2, title: x(I, { variant: "subtitle2", component: "div", children: Ue2 }), placement: _e2, TransitionProps: { timeout: { exit: 0 } }, PopperProps: { popperRef: Oe2, sx: { "& .MuiTooltip-tooltip": { padding: "2px 6px", "& .MuiTooltip-arrow": { display: Ve2 ? "visible" : "none" } } }, anchorEl: { getBoundingClientRect: () => new DOMRect(Ke2.x, Ke2.y, Ke2.width, Ke2.height) }, modifiers: [{ name: "offset", options: { offset: [0, 0] } }] }, children: x(E, {}) }), xt2, Ft2] }), Nt2] });
2332
+ }, onDragEnter: Rt2, onDragLeave: Rt2, onDragOver: Rt2, onDrop: Mt2, children: [b("div", { className: In(Jr), style: { flex: "1 1 100%", width: "100%", display: "flex", flexDirection: "column", opacity: ge2 ? void 0 : 0, "--sxl-app-color-high-contrast": ae2.palette.primary.main, "--sxl-app-color-primary": ae2.palette.primary.main, "--sxl-app-color-primary-dark": ae2.palette.primary.dark, "--sxl-app-color-primary-light": ae2.palette.primary.light, "--sxl-app-color-info": ae2.palette.info.main, "--sxl-app-color-info-dark": ae2.palette.info.dark, "--sxl-app-color-info-light": ae2.palette.info.light, "--sxl-app-color-secondary": ae2.palette.secondary.main, "--sxl-app-color-secondary-dark": ae2.palette.secondary.dark, "--sxl-app-color-secondary-light": ae2.palette.secondary.light, "--sxl-app-color-success": ae2.palette.success.main, "--sxl-app-color-success-dark": ae2.palette.success.dark, "--sxl-app-color-success-light": ae2.palette.success.light, "--sxl-app-color-warning": ae2.palette.warning.main, "--sxl-app-color-warning-dark": ae2.palette.warning.dark, "--sxl-app-color-warning-light": ae2.palette.warning.light, "--sxl-app-color-error": ae2.palette.error.main, "--sxl-app-color-error-dark": ae2.palette.error.dark, "--sxl-app-color-error-light": ae2.palette.error.light, "--sxl-app-color-text": ae2.palette.text.primary, "--sxl-app-color-text-secondary": ae2.palette.text.secondary, "--sxl-app-color-text-disabled": ae2.palette.text.disabled, "--sxl-app-color-background": ae2.palette.background.paper, "--sxl-app-color-button-surface": ae2.palette.grey[600], "--sxl-app-color-shadow": ae2.palette.action.focus, "--sxl-app-color-grey": ae2.palette.grey[500], "--sxl-app-filter-dark-invert": Ne2.body.darkMode && oe2 ? "hue-rotate(180deg) invert(1) brightness(95%)" : "none", "--sxl-app-image-background": Ne2.body.darkMode ? `linear-gradient(${ka("#fff", Sa(5))}, ${ka("#fff", Sa(5))})` : void 0 }, children: [it2, ot2 ? Et2 : null, x(A, { sx: { marginBottom: (e3) => e3.spacing(0.75) } }), Ht2, lt2, x(De, { arrow: true, disableInteractive: true, open: Ve2, title: x(I, { variant: "subtitle2", component: "div", children: Ue2 }), placement: _e2, TransitionProps: { timeout: { exit: 0 } }, PopperProps: { popperRef: Oe2, sx: { "& .MuiTooltip-tooltip": { padding: "2px 6px", "& .MuiTooltip-arrow": { display: Ve2 ? "visible" : "none" } } }, anchorEl: { getBoundingClientRect: () => new DOMRect(Ke2.x, Ke2.y, Ke2.width, Ke2.height) }, modifiers: [{ name: "offset", options: { offset: [0, 0] } }] }, children: x(A, {}) }), xt2, Ft2] }), Nt2] });
2330
2333
  }));
2331
- Ti.displayName = "WorkbookElement";
2332
- const Di = (e2 = false, t2 = false) => t2 ? null : { "& input:not(:focus):not(:hover)": { color: (e3) => e3.palette.text.secondary }, backgroundColor: (e3) => ka(e3.palette.background.paper, 0.6), borderRadius: (e3) => `${e3.shape.borderRadius}px`, border: (t3) => `solid ${e2 ? t3.palette.divider : "transparent"} 1px`, "&.Mui-disabled": { border: (t3) => `solid ${e2 ? t3.palette.divider : "transparent"} 1px` }, "&:focus-within:not([disabled])": { backgroundColor: (e3) => e3.palette.background.paper }, "&:hover:not([disabled])": { border: (t3) => `solid ${e2 ? t3.palette.text?.primary : t3.palette.divider} 1px`, backgroundColor: null }, "&.Mui-focusVisible": { outline: (e3) => `solid ${e3.palette.primary.main} 1px !important`, border: (e3) => `1px solid ${e3.palette?.primary?.main} !important` } }, Pi = k(S((e2, t2) => {
2334
+ Di.displayName = "WorkbookElement";
2335
+ const Pi = (e2 = false, t2 = false) => t2 ? null : { "& input:not(:focus):not(:hover)": { color: (e3) => e3.palette.text.secondary }, backgroundColor: (e3) => ka(e3.palette.background.paper, 0.6), borderRadius: (e3) => `${e3.shape.borderRadius}px`, border: (t3) => `solid ${e2 ? t3.palette.divider : "transparent"} 1px`, "&.Mui-disabled": { border: (t3) => `solid ${e2 ? t3.palette.divider : "transparent"} 1px` }, "&:focus-within:not([disabled])": { backgroundColor: (e3) => e3.palette.background.paper }, "&:hover:not([disabled])": { border: (t3) => `solid ${e2 ? t3.palette.text?.primary : t3.palette.divider} 1px`, backgroundColor: null }, "&.Mui-focusVisible": { outline: (e3) => `solid ${e3.palette.primary.main} 1px !important`, border: (e3) => `1px solid ${e3.palette?.primary?.main} !important` } }, Ri = k(S((e2, t2) => {
2333
2336
  const { sx: o2, workbook: n2, title: a2 = "", placeHolder: r2 = "Untitled", onTitleChange: l2, readOnly: i2 = false, hidden: s2, ...d2 } = e2, [c2, m2] = D(false), [p2, u2] = D(false), [g2, h2] = D(a2 ?? ""), [f2, y2] = D(""), [w2, { width: k2 }] = qa(), [S2, { width: C2 }] = qa(), [v2, T2] = D(false), R2 = M(null), F2 = M(null), B2 = ca(t2, () => ({ requestWorkbookTitle: (e3 = null, t3) => {
2334
2337
  F2.current = { onAccept: e3, requestReason: t3?.requestReason }, t3?.selectAll && R2.current?.select(), R2.current?.focus(t3);
2335
2338
  }, focus: (e3) => {
2336
2339
  R2.current?.focus(e3);
2337
2340
  } }), []);
2338
- return A(() => {
2341
+ return E(() => {
2339
2342
  T2(a2 !== g2), y2(a2), h2(a2);
2340
2343
  }, [a2]), P(() => {
2341
2344
  v2 && 0 !== k2 && Ga.debounce(() => {
@@ -2343,7 +2346,7 @@ const Di = (e2 = false, t2 = false) => t2 ? null : { "& input:not(:focus):not(:h
2343
2346
  }, 300)();
2344
2347
  }, [v2, k2]), P(() => {
2345
2348
  u2(g2 && !Za.isValidWindowsFilename(g2));
2346
- }, [g2]), s2 ? null : x(E, { sx: { display: "flex", flexDirection: "column", justifyContent: "center", alignItems: "center", opacity: v2 ? "0" : "1", transition: v2 ? void 0 : "opacity .25s ease-in", "& .tooltip-wrapper": { maxWidth: "100%" } }, ref: Va([B2, S2, t2]), ...d2, children: x(Le, { label: F2.current?.requestReason ?? "Workbook Name", children: b(E, { className: In({ "Mui-focusVisible": c2 }), sx: { visibility: 0 === k2 ? "hidden" : "visible", display: "block", maxWidth: "100%", overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", paddingLeft: "12px", paddingRight: "12px", marginLeft: "2px", marginRight: "2px", paddingTop: "2px", paddingBottom: "1px", ...Di(true, i2), ...o2 }, children: [i2 ? x(I, { variant: "subtitle1", component: "div", sx: { whiteSpace: "nowrap", fontStyle: g2 !== f2 ? "italic" : void 0, userSelect: "none", textOverflow: "ellipsis", lineHeight: "1.4375em", border: "transparent 1px solid", color: (e3) => p2 ? e3.palette.error.dark : void 0 }, children: a2 ?? r2 }) : x(O, { sx: { width: `${Math.min(k2 + 3, Math.max(C2, B2.current?.getBoundingClientRect()?.width))}px`, overflow: "hidden", whiteSpace: "nowrap", fontWeight: "600", maxWidth: "100%", border: "none", padding: "0px", margin: "0px", color: (e3) => p2 ? e3.palette.error.dark : void 0, fontStyle: g2 !== f2 ? "italic" : void 0, "& input": { paddingTop: "0px", paddingBottom: "0px", textOverflow: "ellipsis" } }, disableUnderline: true, fullWidth: false, multiline: false, readOnly: i2, spellCheck: false, placeholder: r2, onFocus: (e3) => {
2349
+ }, [g2]), s2 ? null : x(A, { sx: { display: "flex", flexDirection: "column", justifyContent: "center", alignItems: "center", opacity: v2 ? "0" : "1", transition: v2 ? void 0 : "opacity .25s ease-in", "& .tooltip-wrapper": { maxWidth: "100%" } }, ref: Va([B2, S2, t2]), ...d2, children: x(Le, { label: F2.current?.requestReason ?? "Workbook Name", children: b(A, { className: In({ "Mui-focusVisible": c2 }), sx: { visibility: 0 === k2 ? "hidden" : "visible", display: "block", maxWidth: "100%", overflow: "hidden", textOverflow: "ellipsis", whiteSpace: "nowrap", paddingLeft: "12px", paddingRight: "12px", marginLeft: "2px", marginRight: "2px", paddingTop: "2px", paddingBottom: "1px", ...Pi(true, i2), ...o2 }, children: [i2 ? x(I, { variant: "subtitle1", component: "div", sx: { whiteSpace: "nowrap", fontStyle: g2 !== f2 ? "italic" : void 0, userSelect: "none", textOverflow: "ellipsis", lineHeight: "1.4375em", border: "transparent 1px solid", color: (e3) => p2 ? e3.palette.error.dark : void 0 }, children: a2 ?? r2 }) : x(O, { sx: { width: `${Math.min(k2 + 3, Math.max(C2, B2.current?.getBoundingClientRect()?.width))}px`, overflow: "hidden", whiteSpace: "nowrap", fontWeight: "600", maxWidth: "100%", border: "none", padding: "0px", margin: "0px", color: (e3) => p2 ? e3.palette.error.dark : void 0, fontStyle: g2 !== f2 ? "italic" : void 0, "& input": { paddingTop: "0px", paddingBottom: "0px", textOverflow: "ellipsis" } }, disableUnderline: true, fullWidth: false, multiline: false, readOnly: i2, spellCheck: false, placeholder: r2, onFocus: (e3) => {
2347
2350
  m2(true), e3.target?.select();
2348
2351
  }, inputProps: { name: "input-workbook-title", autoComplete: "off", ref: R2 }, onBlur: () => {
2349
2352
  m2(false), p2 ? h2(f2) : (g2 !== f2 && (l2?.(g2), g2 && F2.current?.onAccept?.(g2, "blur")), F2.current = null);
@@ -2354,22 +2357,22 @@ const Di = (e2 = false, t2 = false) => t2 ? null : { "& input:not(:focus):not(:h
2354
2357
  (Za.WINDOW_FILENAME_CHAR_RESERVED_REGEX.test(e3.key) || e3.target?.value.length > Za.MAX_WORKBOOK_NAME_SIZE) && e3.preventDefault(), e3.which === ra.Enter || e3.which === ra.Tab ? (p2 ? h2(f2) : (l2?.(g2), g2 && (F2.current?.onAccept?.(g2, "keydown"), F2.current = null)), e3.stopPropagation(), e3.preventDefault(), n2?.focus()) : e3.which === ra.Escape && (g2 === f2 ? n2?.focus() : (h2(f2), setTimeout(() => {
2355
2358
  e3.target?.select();
2356
2359
  }, 0)), F2.current = null, e3.stopPropagation(), e3.preventDefault());
2357
- }, value: g2 }), x(E, { ref: w2, sx: { position: "absolute", visibility: "hidden", top: "-9999px", fontWeight: "600 !important", whiteSpace: "pre", fontStyle: g2 !== f2 ? "italic" : void 0, fontFamily: (e3) => e3.typography.fontFamily, letterSpacing: "0.00938em" }, children: g2 || r2 })] }) }) });
2360
+ }, value: g2 }), x(A, { ref: w2, sx: { position: "absolute", visibility: "hidden", top: "-9999px", fontWeight: "600 !important", whiteSpace: "pre", fontStyle: g2 !== f2 ? "italic" : void 0, fontFamily: (e3) => e3.typography.fontFamily, letterSpacing: "0.00938em" }, children: g2 || r2 })] }) }) });
2358
2361
  }));
2359
- Pi.displayName = "WorkbookTitle";
2360
- const Ri = k(S((e2, t2) => {
2362
+ Ri.displayName = "WorkbookTitle";
2363
+ const Mi = k(S((e2, t2) => {
2361
2364
  const { sx: o2, style: n2, className: a2, licenseKey: r2, renderLoadingPanel: l2, ...i2 } = e2;
2362
2365
  r2 && g.setLicenseKey(r2);
2363
2366
  const s2 = C(() => {
2364
2367
  const e3 = { transitionDelay: "160ms", transparentBackground: true };
2365
- return x(E, { sx: o2, style: { width: "100%", height: "100%", position: "absolute", display: "flex", alignItems: "center", justifyContent: "center", ...n2 }, children: l2?.(e3) ?? x(Pe, { ...e3 }) });
2366
- }, [o2, n2, l2]), d2 = C(() => w.lazy(async () => await Promise.resolve().then(() => $i)), []);
2368
+ return x(A, { sx: o2, style: { width: "100%", height: "100%", position: "absolute", display: "flex", alignItems: "center", justifyContent: "center", ...n2 }, children: l2?.(e3) ?? x(Pe, { ...e3 }) });
2369
+ }, [o2, n2, l2]), d2 = C(() => w.lazy(async () => await Promise.resolve().then(() => Oi)), []);
2367
2370
  return x(y, { children: x(R, { fallback: s2, children: x(d2, { ...i2, className: a2, renderLoadingPanel: l2, sx: o2, style: n2, ref: t2 }) }) });
2368
2371
  }));
2369
- Ri.displayName = "Studio";
2370
- const Mi = [{ key: "SheetXL", description: "SheetXL", mimeType: ".sxl", exts: ["sxl"], handler: null, isDefault: true }, { key: "CSV", description: "Comma Delimited", mimeType: "text/csv", exts: ["csv"], handler: null }, { key: "Excel", description: "Excel Workbook", mimeType: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", exts: ["xlsx", "xls", "xlsm"], handler: null }], Fi = [{ key: "SheetXL", mimeType: "application/vnd.sheetxl.sheet", description: "SheetXL", ext: "sxl", handler: null, isDefault: true }, { key: "CSV", mimeType: "text/csv", description: "Comma Delimited", ext: "csv", handler: null }, { key: "Excel", mimeType: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", description: "Excel Workbook", ext: "xlsx", tags: ["SheetJS Pro"], handler: null }];
2371
- class Bi {
2372
- constructor(e2 = Mi, t2 = Fi) {
2372
+ Mi.displayName = "Studio";
2373
+ const Fi = [{ key: "SheetXL", description: "SheetXL", mimeType: ".sxl", exts: ["sxl"], handler: null, isDefault: true }, { key: "CSV", description: "Comma Delimited", mimeType: "text/csv", exts: ["csv"], handler: null }, { key: "Excel", description: "Excel Workbook", mimeType: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", exts: ["xlsx", "xls", "xlsm"], handler: null }], Bi = [{ key: "SheetXL", mimeType: "application/vnd.sheetxl.sheet", description: "SheetXL", ext: "sxl", handler: null, isDefault: true }, { key: "CSV", mimeType: "text/csv", description: "Comma Delimited", ext: "csv", handler: null }, { key: "Excel", mimeType: "application/vnd.openxmlformats-officedocument.spreadsheetml.sheet", description: "Excel Workbook", ext: "xlsx", tags: ["SheetJS Pro"], handler: null }];
2374
+ class Ni {
2375
+ constructor(e2 = Fi, t2 = Bi) {
2373
2376
  this._readFormatType = [], this._writeFormatType = [], this._readFormatType = Object.freeze([...e2]), this._writeFormatType = Object.freeze([...t2]);
2374
2377
  }
2375
2378
  getReadFormats() {
@@ -2410,7 +2413,7 @@ class Bi {
2410
2413
  }
2411
2414
  }
2412
2415
  }
2413
- const Ni = new Bi(), Ai = { card: "_card_1a398_7", actionRoot: "_actionRoot_1a398_11", icons: "_icons_1a398_16", expand: "_expand_1a398_22", expandOpen: "_expandOpen_1a398_29", stackTraceContainer: "_stackTraceContainer_1a398_33" }, Ei = S((e2, t2) => {
2416
+ const Ei = new Ni(), Ai = { card: "_card_1a398_7", actionRoot: "_actionRoot_1a398_11", icons: "_icons_1a398_16", expand: "_expand_1a398_22", expandOpen: "_expandOpen_1a398_29", stackTraceContainer: "_stackTraceContainer_1a398_33" }, Ii = S((e2, t2) => {
2414
2417
  const { id: o2, message: n2, iconVariant: a2, error: r2, hideIconVariant: l2, ...i2 } = e2, { closeSnackbar: s2 } = Ya(), d2 = wa(), [c2, m2] = D(false), p2 = v(() => {
2415
2418
  m2((e3) => !e3);
2416
2419
  }, []), u2 = v(() => {
@@ -2419,12 +2422,12 @@ const Ni = new Bi(), Ai = { card: "_card_1a398_7", actionRoot: "_actionRoot_1a39
2419
2422
  let g2 = r2?.message;
2420
2423
  return !g2 && T(n2) && (g2 = n2), g2 || "string" != typeof n2 || (g2 = n2), g2 || (g2 = `Unknown Error: ${n2}`), x(Qa, { ref: t2, className: In(Ai.root, "error-snackbar"), children: b(te, { className: Ai.card, style: { backgroundColor: d2.palette.error.dark, border: `1px solid ${d2.palette.error.dark}` }, children: [b(oe, { className: Ai.actionRoot, children: [l2 ? null : a2?.error, x(I, { variant: "body2", component: "div", className: Ai.typography, children: g2 }), x("div", { style: { flex: "1 1 auto" } }), b("div", { className: Ai.icons, children: [r2 ? x(L, { "aria-label": "Show more", size: "small", className: In(Ai.expand, { [Ai.expandOpen]: c2 }), onClick: p2, children: x(qn, {}) }) : null, x(L, { size: "small", className: Ai.expand, onClick: u2, children: x(Jn, { fontSize: "small" }) })] })] }), r2 ? x(ne, { in: c2, timeout: "auto", unmountOnExit: true, children: x("div", { className: Ai.stackTraceContainer, style: { backgroundColor: d2.palette.error.light, borderTop: `1px solid ${d2.palette.error.main}` }, children: x(bn, { error: r2, hideLineNumbers: true }) }) }) : null] }) });
2421
2424
  });
2422
- Ei.displayName = "ToastError";
2423
- const Ii = k(S((e2, t2) => {
2425
+ Ii.displayName = "ToastError";
2426
+ const Li = k(S((e2, t2) => {
2424
2427
  const { commands: o2, commandHook: n2, scope: a2 = "workbook", disabled: r2 = false, ...l2 } = e2, i2 = na((e3) => {
2425
2428
  const t3 = { variant: oa.Menuitem, parentFloat: e3.floatReference, commandHook: n2, scope: a2, disabled: r2 }, l3 = b(y, { children: [x(le, { ...t3, command: o2.getCommand("newWorkbook"), icon: re(x(yn, {})) }), x(ie, { orientation: "horizontal" }), x(le, { ...t3, command: o2.getCommand("openWorkbook"), icon: re(x(wn, {})) }), x(me, { ...t3, commands: o2, quickCommand: "saveWorkbook", icon: re(x(Cn, {})), createPopupPanel: (e4) => {
2426
2429
  const n3 = { ...t3, parentFloat: e4.floatReference, scope: "saveWorkbook" }, a3 = [];
2427
- return Ni.getWriteFormats().forEach((e5) => {
2430
+ return Ei.getWriteFormats().forEach((e5) => {
2428
2431
  if (e5.isDefault) return;
2429
2432
  let t4 = null;
2430
2433
  "CSV" === e5.key ? t4 = re(x(kn, {})) : "Excel" === e5.key && (t4 = re(x(Sn, {})));
@@ -2440,33 +2443,33 @@ const Ii = k(S((e2, t2) => {
2440
2443
  }, [r2, o2, n2, a2]), s2 = "File";
2441
2444
  return x(me, { commands: o2, disabled: r2, commandHook: n2, scope: a2, label: s2, tooltip: "Options for saving and loading the workbook.", sx: { paddingBottom: "0px", "& button": { paddingTop: "0px", paddingBottom: "0px", height: (e3) => `calc(1.25rem + ${e3.spacing(2)}px)` } }, ...l2, createPopupPanel: i2, icon: x(ht, { className: "label", icon: null, label: s2 }) });
2442
2445
  }));
2443
- Ii.displayName = "StandaloneFileCommandButton";
2444
- const Li = x(Le, { label: "SheetXL", description: "Visit me at sheetxl.com.", children: x(E, { sx: { width: "24px", height: "24px", marginBottom: "4px", marginLeft: "6px" }, children: x(Wa, { onClick: () => {
2446
+ Li.displayName = "StandaloneFileCommandButton";
2447
+ const Hi = x(Le, { label: "SheetXL", description: "Visit me at sheetxl.com.", children: x(A, { sx: { width: "24px", height: "24px", marginBottom: "4px", marginLeft: "6px" }, children: x(Wa, { onClick: () => {
2445
2448
  window?.open("https://www.sheetxl.com", "_blank");
2446
- }, style: { width: "24px", height: "24px", cursor: "pointer" } }) }) }), Hi = k(S((e2, t2) => {
2447
- const { commands: o2, workbook: n2, logo: a2 = Li, mainElement: r2, showFileMenu: l2 = true, showAppearanceMenu: i2 = true, ...s2 } = e2, { reference: d2 } = bo(), [c2, { width: m2 }] = qa(), p2 = m2 < 530, u2 = l2 ? x(Ii, { commands: o2, commandHook: { beforeExecute() {
2449
+ }, style: { width: "24px", height: "24px", cursor: "pointer" } }) }) }), Wi = k(S((e2, t2) => {
2450
+ const { commands: o2, workbook: n2, logo: a2 = Hi, mainElement: r2, showFileMenu: l2 = true, showAppearanceMenu: i2 = true, ...s2 } = e2, { reference: d2 } = bo(), [c2, { width: m2 }] = qa(), p2 = m2 < 530, u2 = l2 ? x(Li, { commands: o2, commandHook: { beforeExecute() {
2448
2451
  d2?.closeAll();
2449
2452
  }, onError(e3, t3, o3) {
2450
2453
  } } }) : null, g2 = i2 ? x(cl, { commands: o2, commandHook: { beforeExecute() {
2451
2454
  d2?.closeAll();
2452
2455
  }, onError(e3, t3, o3) {
2453
2456
  } } }) : null, h2 = C(() => ({ paddingLeft: (e3) => e3.spacing(1), paddingRight: (e3) => e3.spacing(1) }), []), f2 = M(null);
2454
- return x(E, { ref: Va([f2, c2, t2]), ...s2, children: ei({ commands: o2, renderCompact: p2, workbook: n2, selectWrapper: (e3) => b(E, { sx: { display: "flex", flex: "1", flexDirection: "row", alignItems: "stretch", gap: (e4) => e4.spacing(1), paddingLeft: (e4) => e4.spacing(1), paddingRight: (e4) => e4.spacing(1) }, children: [b(E, { sx: { display: "flex", flexDirection: "row", alignItems: "center", flex: "1 1 100%", gap: (e4) => e4.spacing(0.5) }, children: [a2, b(E, { sx: { display: "flex", flexDirection: "row", alignItems: "center", gap: (e4) => e4.spacing(0.25) }, children: [u2, e3] })] }), x(E, { sx: { display: "flex", flexDirection: "row", flex: "1 1 300%", overflow: "hidden", alignItems: "center", justifyContent: "center" }, children: r2 }), x(E, { sx: { display: "flex", alignItems: "center", justifyContent: "end", flex: p2 && !g2 ? "0 0 auto" : "1 1 100%" }, children: g2 })] }), selectProps: h2, toolbarsProps: { Home: { sx: {} } } }) });
2457
+ return x(A, { ref: Va([f2, c2, t2]), ...s2, children: ti({ commands: o2, renderCompact: p2, workbook: n2, selectWrapper: (e3) => b(A, { sx: { display: "flex", flex: "1", flexDirection: "row", alignItems: "stretch", gap: (e4) => e4.spacing(1), paddingLeft: (e4) => e4.spacing(1), paddingRight: (e4) => e4.spacing(1) }, children: [b(A, { sx: { display: "flex", flexDirection: "row", alignItems: "center", flex: "1 1 100%", gap: (e4) => e4.spacing(0.5) }, children: [a2, b(A, { sx: { display: "flex", flexDirection: "row", alignItems: "center", gap: (e4) => e4.spacing(0.25) }, children: [u2, e3] })] }), x(A, { sx: { display: "flex", flexDirection: "row", flex: "1 1 300%", overflow: "hidden", alignItems: "center", justifyContent: "center" }, children: r2 }), x(A, { sx: { display: "flex", alignItems: "center", justifyContent: "end", flex: p2 && !g2 ? "0 0 auto" : "1 1 100%" }, children: g2 })] }), selectProps: h2, toolbarsProps: { Home: { sx: {} } } }) });
2455
2458
  }));
2456
- Hi.displayName = "StudioToolbar";
2457
- const Wi = k(S((e2, t2) => {
2459
+ Wi.displayName = "StudioToolbar";
2460
+ const zi = k(S((e2, t2) => {
2458
2461
  const { workbook: o2, setWorkbook: n2, refWorkbookTitle: a2, titleWorkbook: r2, setWorkbookTitle: l2, titlePlaceHolder: i2, children: s2, undoManager: d2, commands: c2, importExportDisabled: m2, themeOptions: p2 } = e2, u2 = Ya(), g2 = u2 ? u2.enqueueSnackbar : () => {
2459
2462
  }, h2 = u2 ? u2.closeSnackbar : () => {
2460
2463
  }, [f2, k2] = D({ isMounted: false, label: null, starting: /* @__PURE__ */ new Map(), running: /* @__PURE__ */ new Map() }), S2 = v(() => {
2461
2464
  k2((e3) => ({ ...e3, isMounted: true }));
2462
2465
  }, []), T2 = v(() => {
2463
2466
  k2((e3) => ({ ...e3, isMounted: false }));
2464
- }, []), R2 = {}, F2 = Pn(R2), B2 = Rn(R2), N2 = Mn(R2), A2 = M(/* @__PURE__ */ new Set()), E2 = C(() => {
2467
+ }, []), R2 = {}, F2 = Pn(R2), B2 = Rn(R2), N2 = Mn(R2), E2 = M(/* @__PURE__ */ new Set()), A2 = C(() => {
2465
2468
  const e3 = (e4, t3) => {
2466
2469
  if (t3?.onceKey) {
2467
- if (A2.current.has(t3.onceKey)) return;
2468
- const e5 = new Set(A2.current);
2469
- e5.add(t3.onceKey), A2.current = e5;
2470
+ if (E2.current.has(t3.onceKey)) return;
2471
+ const e5 = new Set(E2.current);
2472
+ e5.add(t3.onceKey), E2.current = e5;
2470
2473
  }
2471
2474
  const o3 = { variant: t3?.type ?? da.Info, anchorOrigin: { vertical: "top", horizontal: "center" }, preventDuplicate: t3?.preventDuplicate, persist: t3?.persist ?? t3?.type === da.Error, action: (e5) => x(L, { onClick: () => h2(e5), children: x(ea, {}) }) };
2472
2475
  t3?.enqueueProps && Object.assign(o3, t3.enqueueProps), e4 || console.log("message is 'null'", t3), g2(e4 ?? "Alert", o3);
@@ -2485,7 +2488,7 @@ const Wi = k(S((e2, t2) => {
2485
2488
  const n3 = { ...t3, onKeyDown: (e5) => {
2486
2489
  c2?.dispatchToFocusedCommand(e5), e5.isDefaultPrevented() || e5.isPropagationStopped() || t3?.onKeyDown?.(e5);
2487
2490
  } };
2488
- return F2(e4, { sort: () => import("./BYoYizxJTZD7MEGg.mjs"), numberFormat: () => import("./BVBW-cMRTjK6KVFg.mjs"), hyperlink: () => import("./cm-ecS0S68xhC_Yj.mjs"), comments: () => import("./D1dqpyBV7ZLrMRVk.mjs"), find: () => import("./BTK5i03GS-FeY98T.mjs"), tableDetails: () => import("./BqgO5jB5pGXA3Hk4.mjs"), tableNew: () => import("./CLc5xV4p8QWx-rjD.mjs"), namedDetails: () => import("./BTkpV3euK14xAUB8.mjs") }[e4], n3, o3);
2491
+ return F2(e4, { sort: () => import("./B-qK-3UHgv6Eg1am.mjs"), numberFormat: () => import("./BrRpZiTdCkp6XLJD.mjs"), hyperlink: () => import("./Bwh9njUvNl0ttDuA.mjs"), comments: () => import("./BwYoiAGrXUMYTT6C.mjs"), find: () => import("./BRvede6q1RS-tV7I.mjs"), tableDetails: () => import("./qQDEISio0hvWk5Ti.mjs"), tableNew: () => import("./DSdhIAo7VPb4M3-Q.mjs"), namedDetails: () => import("./DuwSZB7sC53vsrOv.mjs") }[e4], n3, o3);
2489
2492
  }, showOptions: B2, showInputOptions: N2, showError: (t3) => {
2490
2493
  let o3, n3 = da.Error, a3 = "Unknown Error";
2491
2494
  "string" == typeof t3 ? a3 = t3 : t3 instanceof Error && (o3 = t3, t3.message && (a3 = t3.message)), t3 instanceof ja && (n3 = da.Info), e3(a3, { type: n3, enqueueProps: { error: o3 } });
@@ -2495,21 +2498,21 @@ const Wi = k(S((e2, t2) => {
2495
2498
  const { workbook: t3, setWorkbook: o3, importExportDisabled: n3, workbookTitle: a3 = "export", setWorkbookTitle: r3, notifier: l3, requestWorkbookTitle: i3, themeOptions: s3, undoManager: d3, commands: c3, onExecute: m3 } = e3, p3 = na(s3?.onModeChange, [s3?.onModeChange]), u3 = na(s3?.onEnabledDarkGridChange, [s3?.onEnabledDarkGridChange]), g3 = na(s3?.onEnabledDarkImagesChange, [s3?.onEnabledDarkImagesChange]), h3 = na(async (e4 = null, t4 = null) => {
2496
2499
  const o4 = [];
2497
2500
  let n4, a4 = null, r4 = null;
2498
- if ("string" == typeof e4 ? r4 = e4 : a4 = e4, n4 = a4 ? e4 : await Ga.openFileDialog(r4 ?? Ni.getAllReadFormatTypeAsString().join(",")), !n4) return null;
2501
+ if ("string" == typeof e4 ? r4 = e4 : a4 = e4, n4 = a4 ? e4 : await Ga.openFileDialog(r4 ?? Ei.getAllReadFormatTypeAsString().join(",")), !n4) return null;
2499
2502
  const i4 = { source: n4, createWorkbookOptions: t4, onWarning: (e5) => {
2500
2503
  o4.push(e5);
2501
- } }, s4 = await Ni.read(i4, l3);
2504
+ } }, s4 = await Ei.read(i4, l3);
2502
2505
  return o4.length > 0 && (l3?.showMessage?.("Some elements were not able to be imported. See console for details."), console.warn("Import warnings:\n" + o4.join("\n"))), s4;
2503
2506
  }, [m3, l3, t3]), f3 = na(async (e4, t4, o4) => {
2504
2507
  if (!t4 && i3) {
2505
2508
  const t5 = await i3("Enter Workbook name to " + (o4.isDefault ? "Save." : `Export as ${o4.description}.`));
2506
- return null !== t5 && Ni.writeFile(t5, e4, { formatType: o4.key });
2509
+ return null !== t5 && Ei.writeFile(t5, e4, { formatType: o4.key });
2507
2510
  }
2508
- return Ni.writeFile(t4, e4, { formatType: o4.key });
2511
+ return Ei.writeFile(t4, e4, { formatType: o4.key });
2509
2512
  }, [l3, t3, i3]), x2 = v(() => ({ contains: (e4) => true, focus() {
2510
2513
  } }), []), b2 = C(() => {
2511
2514
  const e4 = [];
2512
- n3 || (Ni.getWriteFormats().forEach((o4) => {
2515
+ n3 || (Ei.getWriteFormats().forEach((o4) => {
2513
2516
  const n4 = o4.isDefault, r4 = { label: n4 ? "Save Workbook" : `Save Workbook as ${o4.description}`, scopedLabels: { workbook: "Save", saveWorkbook: `as ${o4.description}` }, tags: o4.tags, description: `Save the workbook to the desktop${n4 ? "" : ` as ${o4.description}`}.` };
2514
2517
  n4 && (r4.shortcut = { key: "S", modifiers: [ha.Ctrl] }, e4.push(new ga("saveWorkbookAs", x2, { label: "Save Workbook As…", scopedLabels: { workbook: "Save as…", saveWorkbook: "as…" }, shortcut: [{ key: "S", modifiers: [ha.Shift, ha.Ctrl] }, { key: "F12" }], description: "Save the workbook to the desktop with the provided name." }, () => {
2515
2518
  f3(t3, null, o4).catch((e5) => {
@@ -2582,7 +2585,7 @@ const Wi = k(S((e2, t2) => {
2582
2585
  const { showModal: S3 } = Dn();
2583
2586
  return P(() => {
2584
2587
  const e4 = () => new Promise((e5, t4) => {
2585
- const o4 = w.lazy(() => import("./CNeOpyGVrqmfLHyT.mjs")), n4 = S3(o4, { title: "Shortcut Keys Reference", commands: y2, onDone: () => {
2588
+ const o4 = w.lazy(() => import("./BsLOtrgn8geSSe4y.mjs")), n4 = S3(o4, { title: "Shortcut Keys Reference", commands: y2, onDone: () => {
2586
2589
  n4.hide();
2587
2590
  }, TransitionProps: { onExited: () => {
2588
2591
  e5(true);
@@ -2594,7 +2597,7 @@ const Wi = k(S((e2, t2) => {
2594
2597
  a2.current ? a2.current.requestWorkbookTitle((e4, o3) => {
2595
2598
  t3(e4);
2596
2599
  }, { selectAll: true, requestReason: e3 }) : t3(i2);
2597
- }), themeOptions: p2, undoManager: d2, notifier: E2, onExecute: I2 });
2600
+ }), themeOptions: p2, undoManager: d2, notifier: A2, onExecute: I2 });
2598
2601
  P(() => {
2599
2602
  f2.starting.size <= 0 || !f2.isMounted || k2((e3) => {
2600
2603
  const t3 = new Map(e3.running);
@@ -2615,28 +2618,28 @@ const Wi = k(S((e2, t2) => {
2615
2618
  P(() => {
2616
2619
  0 !== f2.starting.size || 0 !== f2.running.size ? z2(x(Pe, { icon: x(Fn, { sx: { transform: "scale(0.7)", marginLeft: "-6px" } }), panel: true, label: f2.label, onMount: S2, onUnmount: T2, sx: { position: "absolute", left: "0", top: "0", width: "100%", height: "100%", zIndex: "9999" } })) : z2(null);
2617
2620
  }, [f2.starting, f2.running]);
2618
- const $2 = C(() => x(ml, { commands: H2, disableHover: true, sx: { padding: "0" }, buttonProps: { sx: { maxHeight: "22px" } } }), [H2]), O2 = { notifier: E2, commands: H2 };
2621
+ const $2 = C(() => x(ml, { commands: H2, disableHover: true, sx: { padding: "0" }, buttonProps: { sx: { maxHeight: "22px" } } }), [H2]), O2 = { notifier: A2, commands: H2 };
2619
2622
  return o2 && (O2.statusBarProps = { childrenEnd: $2 }), b(y, { children: [W2, s2 ? w.cloneElement(s2, O2) : null] });
2620
2623
  }));
2621
- Wi.displayName = "SnackbarAndCommandsWrapper";
2622
- const zi = k(S((e2, t2) => {
2624
+ zi.displayName = "SnackbarAndCommandsWrapper";
2625
+ const $i = k(S((e2, t2) => {
2623
2626
  const { className: o2, sx: n2, style: a2, onElementLoad: r2, onError: l2, undoManager: i2, errorPanel: s2 = Bn, onKeyDown: d2, workbook: c2, createWorkbookOptions: m2, onWorkbookChange: p2, logo: u2, importExportDisabled: g2 = false, themeOptions: f2, autoFocus: y2 = false, commands: w2, title: k2, onTitleChange: S2, titleProps: T2, renderLoadingPanel: R2, ...F2 } = e2, B2 = M(null), N2 = na(p2, [p2]), I2 = na(S2 ?? T2?.onTitleChange, [S2 ?? T2?.onTitleChange]), L2 = T2?.placeHolder ?? "Untitled", H2 = f2?.mode, { themeMode: W2, source: z2 } = vn({ mode: H2 }), O2 = C(() => ({ ...f2, light: Nn(false, Ga.deepMerge(f2?.theme ?? {}, f2?.light ?? {})), dark: Nn(true, Ga.deepMerge(f2?.theme ?? {}, f2?.dark ?? {})) }), [f2]), V2 = W2 === Tn.Dark, [G2, U2] = D(null);
2624
2627
  P(() => {
2625
2628
  U2(i2 ?? new _a());
2626
2629
  }, [i2]);
2627
2630
  const [j2, _2] = D(null), [q2, K2] = D(null), X2 = Ba();
2628
- A(() => {
2631
+ E(() => {
2629
2632
  if (!c2 || 0 === Object.keys(c2).length && !Ga.isPromiseLike(c2)) {
2630
2633
  const e3 = { theme: X2.getDefaultTheme(), ...m2 };
2631
2634
  K2(new h(e3));
2632
2635
  } else K2(c2);
2633
- }, [c2]), A(() => {
2636
+ }, [c2]), E(() => {
2634
2637
  if (!q2) return;
2635
2638
  if (q2 instanceof h) return _2({ workbook: q2 }), void (c2 !== q2 && N2?.(q2));
2636
2639
  (async () => {
2637
2640
  try {
2638
2641
  let e3, t3 = await Promise.resolve(q2);
2639
- t3 && t3.source && (t3 = await Ni.read(t3)), t3.workbook ? (ee2(t3.title), e3 = t3.workbook) : e3 = t3, N2?.(e3), _2({ workbook: e3 });
2642
+ t3 && t3.source && (t3 = await Ei.read(t3)), t3.workbook ? (ee2(t3.title), e3 = t3.workbook) : e3 = t3, N2?.(e3), _2({ workbook: e3 });
2640
2643
  } catch (e3) {
2641
2644
  N2?.(null), _2({ error: e3 });
2642
2645
  }
@@ -2674,9 +2677,9 @@ const zi = k(S((e2, t2) => {
2674
2677
  }, [Z2]);
2675
2678
  const le2 = M(null), ie2 = v((e3) => {
2676
2679
  let t3 = null;
2677
- return T2?.hidden || (t3 = x(Pi, { ...T2, style: { maxWidth: "100%", ...T2?.style }, workbook: B2.current, ref: le2, title: Q2, placeHolder: L2, onTitleChange: (e4) => {
2680
+ return T2?.hidden || (t3 = x(Ri, { ...T2, style: { maxWidth: "100%", ...T2?.style }, workbook: B2.current, ref: le2, title: Q2, placeHolder: L2, onTitleChange: (e4) => {
2678
2681
  ee2(e4);
2679
- } })), x(Hi, { ...e3, logo: u2, mainElement: t3, showFileMenu: !g2, showAppearanceMenu: !!(O2?.onEnabledDarkGridChange || O2?.onEnabledDarkImagesChange || O2?.onModeChange) });
2682
+ } })), x(Wi, { ...e3, logo: u2, mainElement: t3, showFileMenu: !g2, showAppearanceMenu: !!(O2?.onEnabledDarkGridChange || O2?.onEnabledDarkImagesChange || O2?.onModeChange) });
2680
2683
  }, [u2, Q2, T2, O2, g2, ne2]);
2681
2684
  P(() => {
2682
2685
  const e3 = (e4) => e4.preventDefault();
@@ -2686,22 +2689,22 @@ const zi = k(S((e2, t2) => {
2686
2689
  }, []);
2687
2690
  const se2 = C(() => {
2688
2691
  const e3 = { transparentBackground: true };
2689
- return x(E, { sx: n2, style: { position: "absolute", top: 0, left: 0, right: 0, bottom: 0, display: "flex", alignItems: "center", justifyContent: "center", ...a2 }, children: R2?.(e3) ?? x(Pe, { ...e3 }) });
2692
+ return x(A, { sx: n2, style: { position: "absolute", top: 0, left: 0, right: 0, bottom: 0, display: "flex", alignItems: "center", justifyContent: "center", ...a2 }, children: R2?.(e3) ?? x(Pe, { ...e3 }) });
2690
2693
  }, [n2, a2, R2]), de2 = v(({ error: e3 }) => (l2?.(e3), x(s2, { sx: n2, style: a2, error: e3 ?? "Unable to display empty workbook." })), [n2, a2, l2]), ce2 = C(() => ({ ...n2, "& .SnackbarContainer-root": { position: "absolute !important" }, "& .notistack-SnackbarContainer > div": { maxWidth: "100%" }, "& .notistack-Snackbar": { minWidth: "unset" }, "& .notistack-Snackbar > .error-snackbar .MuiTypography-root": { color: (e3) => e3.palette.getContrastText(e3.palette.error.main) }, "& .notistack-Snackbar > .error-snackbar .MuiCardActions-root": { color: (e3) => e3.palette.getContrastText(e3.palette.error.main) }, "& .notistack-Snackbar > .error-snackbar .MuiButtonBase-root": { color: (e3) => e3.palette.getContrastText(e3.palette.error.main) }, "& .notistack-MuiContent *": { fontFamily: (e3) => e3.typography.fontFamily }, "& #notistack-snackbar": { maxWidth: "560px", whiteSpace: "pre-wrap" }, "*": { userSelect: "none" } }), [n2]), me2 = Va([B2, t2]), pe2 = C(() => {
2691
2694
  if (!j2) return se2;
2692
2695
  if (j2.error || !j2.workbook) return de2({ error: j2.error });
2693
2696
  let e3 = null, t3 = null, n3 = false;
2694
- return O2 && (e3 = V2 ? O2.dark : O2.light, t3 = V2 && O2.enableDarkGrid ? O2.dark : O2.light, n3 = O2.enableDarkImages), x(Ti, { sx: ce2, style: a2, tabIndex: 0, autoFocus: true, workbook: j2.workbook, ref: me2, renderToolbar: ie2, onElementLoad: re2, onRepeatCommandChange: Y2, onKeyDown: (e4) => {
2697
+ return O2 && (e3 = V2 ? O2.dark : O2.light, t3 = V2 && O2.enableDarkGrid ? O2.dark : O2.light, n3 = O2.enableDarkImages), x(Di, { sx: ce2, style: a2, tabIndex: 0, autoFocus: true, workbook: j2.workbook, ref: me2, renderToolbar: ie2, onElementLoad: re2, onRepeatCommandChange: Y2, onKeyDown: (e4) => {
2695
2698
  d2?.(e4);
2696
2699
  }, renderLoadingPanel: R2, gridTheme: t3, headersTheme: e3, enableDarkImages: n3, className: In(o2, "sheetxl-workbook"), onContextMenu: (e4) => e4.preventDefault(), ...F2 }, "WorkbookElement");
2697
2700
  }, [j2, Q2, G2, se2, R2, O2, F2, ie2, ce2]);
2698
2701
  let ue2 = x(Ja, { fallbackRender: de2, children: x(er, { maxSnack: 3, domRoot: te2, anchorOrigin: { vertical: "bottom", horizontal: "right" }, autoHideDuration: 3500, onClose: (e3, t3, o3) => {
2699
2702
  B2.current?.focus();
2700
- }, Components: { error: Ei }, iconVariant: { success: x($, { style: { marginRight: "8px" }, children: x("path", { d: "M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z" }) }), error: x(En, { style: { marginRight: "8px" } }) }, children: x(An, { children: x(Wi, { workbook: j2?.workbook, setWorkbook: K2, importExportDisabled: g2, titlePlaceHolder: L2, titleWorkbook: Q2, setWorkbookTitle: ee2, refWorkbookTitle: le2, commands: ne2, undoManager: G2, themeOptions: O2, children: pe2 }) }) }) });
2703
+ }, Components: { error: Ii }, iconVariant: { success: x($, { style: { marginRight: "8px" }, children: x("path", { d: "M20,12A8,8 0 0,1 12,20A8,8 0 0,1 4,12A8,8 0 0,1 12,4C12.76,4 13.5,4.11 14.2, 4.31L15.77,2.74C14.61,2.26 13.34,2 12,2A10,10 0 0,0 2,12A10,10 0 0,0 12,22A10,10 0 0, 0 22,12M7.91,10.08L6.5,11.5L11,16L21,6L19.59,4.58L11,13.17L7.91,10.08Z" }) }), error: x(An, { style: { marginRight: "8px" } }) }, children: x(En, { children: x(zi, { workbook: j2?.workbook, setWorkbook: K2, importExportDisabled: g2, titlePlaceHolder: L2, titleWorkbook: Q2, setWorkbookTitle: ee2, refWorkbookTitle: le2, commands: ne2, undoManager: G2, themeOptions: O2, children: pe2 }) }) }) });
2701
2704
  return O2 && (ue2 = b(Ca, { theme: V2 ? O2.dark : O2.light, children: [O2.cssBaseline ? x(ae, {}) : null, ue2] })), ue2;
2702
2705
  }));
2703
- zi.displayName = "EagerStudio";
2704
- const $i = Object.freeze(Object.defineProperty({ __proto__: null, EagerStudio: zi, default: zi }, Symbol.toStringTag, { value: "Module" }));
2706
+ $i.displayName = "EagerStudio";
2707
+ const Oi = Object.freeze(Object.defineProperty({ __proto__: null, EagerStudio: $i, default: $i }, Symbol.toStringTag, { value: "Module" }));
2705
2708
  export {
2706
2709
  cl as AppearanceCommandButton,
2707
2710
  lr as AutoColorPosition,
@@ -2715,44 +2718,44 @@ export {
2715
2718
  xr as ColorPanel,
2716
2719
  rr as ColorPanelType,
2717
2720
  yr as ColorPopupButton,
2718
- Er as DeleteCellsCommandButton,
2721
+ Ar as DeleteCellsCommandButton,
2719
2722
  dl as DocThemeCommandButton,
2720
- zi as EagerStudio,
2723
+ $i as EagerStudio,
2721
2724
  Nr as FillCommandButton,
2722
- Dl as FilterColumnMenu,
2725
+ Pl as FilterColumnMenu,
2723
2726
  Wr as FilterCommandButton,
2724
- Pl as Filters,
2727
+ Rl as Filters,
2725
2728
  Pr as FindCommandButton,
2726
2729
  Vr as FontFamilyCommandButton,
2727
2730
  Rr as FontSizeCommandButton,
2728
- Tl as FormulaBar,
2731
+ Dl as FormulaBar,
2729
2732
  Dr as FreezeCommandButton,
2730
2733
  ml as HelpCommandButton,
2731
2734
  tr as HorizontalAlignCommandButton,
2732
- Ar as InsertCellsCommandButton,
2733
- fl as InsertFunctionCommandPopupButton,
2735
+ Er as InsertCellsCommandButton,
2736
+ xl as InsertFunctionCommandPopupButton,
2734
2737
  gl as InsertFunctionSumCommandPopupButton,
2735
2738
  pl as InsertImageCommandButton,
2736
- Ul as InsertScriptCommandButton,
2739
+ jl as InsertScriptCommandButton,
2737
2740
  LicenseManager,
2738
2741
  Tr as MergeCommandButton,
2739
- Cl as NamedCollectionEditor,
2740
- bl as NamedInput,
2742
+ vl as NamedCollectionEditor,
2743
+ yl as NamedInput,
2741
2744
  Fr as NumberFormatCommandButton,
2742
2745
  jr as PasteCommandButton,
2743
2746
  Zr as PresetCellStylesCommandButton,
2744
2747
  al as PresetTableStylesCommandButton,
2745
- wl as RangeInput,
2746
- Zl as RunScriptCommandButton,
2747
- jl as ScriptEditorToolbar,
2748
- Kl as ScriptWorkspace,
2749
- Rl as SheetTab,
2750
- Ml as SheetTabMenu,
2751
- kl as SheetZoomScale,
2752
- Fl as SheetsAllMenu,
2748
+ kl as RangeInput,
2749
+ Jl as RunScriptCommandButton,
2750
+ _l as ScriptEditorToolbar,
2751
+ Xl as ScriptWorkspace,
2752
+ Ml as SheetTab,
2753
+ Fl as SheetTabMenu,
2754
+ Sl as SheetZoomScale,
2755
+ Bl as SheetsAllMenu,
2753
2756
  Hr as SortFilterCommandButton,
2754
- Sl as StatusBar,
2755
- Ri as Studio,
2757
+ Cl as StatusBar,
2758
+ Mi as Studio,
2756
2759
  kr as StyledStrokeIcon,
2757
2760
  tl as TableStyleCanvasPreview,
2758
2761
  ol as TableStyleOptionsPanel,
@@ -2769,16 +2772,16 @@ export {
2769
2772
  Lr as ViewGridLinesCommandButton,
2770
2773
  _r as ViewHeadingsCommandButton,
2771
2774
  ul as WalkingCopyCommandButton,
2772
- ui as WorkbookContextMenu,
2773
- Ti as WorkbookElement,
2774
- Ni as WorkbookIO,
2775
- pi as WorkbookStrip,
2776
- Pi as WorkbookTitle,
2775
+ gi as WorkbookContextMenu,
2776
+ Di as WorkbookElement,
2777
+ Ei as WorkbookIO,
2778
+ ui as WorkbookStrip,
2779
+ Ri as WorkbookTitle,
2777
2780
  qr as WorkbookViewCommandButton,
2778
- Bi as _WorkbookIO,
2779
- Hl as createGridStyleFromMUITheme,
2780
- Ri as default,
2781
- li as defaultNewWorkbook,
2782
- Il as setPrintExamplesOnLoad,
2783
- ri as useWorkbookCommands
2781
+ Ni as _WorkbookIO,
2782
+ Wl as createGridStyleFromMUITheme,
2783
+ Mi as default,
2784
+ ii as defaultNewWorkbook,
2785
+ Ll as setPrintExamplesOnLoad,
2786
+ li as useWorkbookCommands
2784
2787
  };