@sheetxl/studio-mui 0.7.26 → 0.7.28-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/README.md +2 -2
- package/browser/cjs/BQJKf40kttQWOzLw.cjs +20 -0
- package/browser/cjs/BTZ5uzK0wHzpiZGC.cjs +1 -0
- package/browser/cjs/B_D3JKseVvpRyX-E.cjs +1 -0
- package/browser/cjs/B_WyRpeiesnEiNP4.cjs +11 -0
- package/browser/cjs/BeKpqOx8It0RD0Rf.cjs +2 -0
- package/browser/cjs/Bj-EvSYeDfqmU0V6.cjs +2 -0
- package/browser/cjs/Bo9Kx3L_XQkGPBJ5.cjs +1 -0
- package/browser/cjs/ByIEqNsvj52sihT9.cjs +5 -0
- package/browser/cjs/C3moehR3VOd0LnmM.cjs +1 -0
- package/browser/cjs/C97KHSuikAbr1qVM.cjs +1 -0
- package/browser/cjs/CJLwX_A3y3TQUmzj.cjs +1 -0
- package/browser/cjs/CPSc2VSYZeZ1B9mi.cjs +1 -0
- package/browser/cjs/CPcBvw4ZPwHVTUZF.cjs +1 -0
- package/browser/cjs/CZm1jVZaHQ246prW.cjs +1 -0
- package/browser/cjs/CdDYyAfccXme8w6m.cjs +1 -0
- package/browser/cjs/DBJLJGiCGXesx5n6.cjs +1 -0
- package/browser/cjs/DLScL5AOXhHu9O9H.cjs +7 -0
- package/browser/cjs/Djsiad0Qha1Y-YaS.cjs +1 -0
- package/browser/cjs/IASAYG6qgv7lJY7y.cjs +1 -0
- package/browser/cjs/KZvriGbhEOVkQD0b.cjs +1 -0
- package/browser/cjs/UnMhi28mbvLiOXQe.cjs +1 -0
- package/browser/cjs/Vbigo0kFP3PFfmeA.cjs +1 -0
- package/browser/cjs/iMWEL01eC83oU-YY.cjs +1 -0
- package/browser/cjs/index.cjs +2 -7
- package/browser/cjs/w2GjebPlOFv3pCbm.cjs +1 -0
- package/browser/cjs/zQsyZpeXAvcVXJMs.cjs +1 -0
- package/browser/esm/0EONOhVZ7oT0C_G2.mjs +1150 -0
- package/browser/esm/5x7evORpymnb5SfW.mjs +129 -0
- package/browser/esm/BACBR1jjcpJbhOWA.mjs +191 -0
- package/browser/esm/BPZne8WpzrkWOH6L.mjs +47 -0
- package/browser/esm/BeKa8xVj69hAVKRN.mjs +155 -0
- package/browser/esm/BeQ9bqOvNNP-arFP.mjs +219 -0
- package/browser/esm/Bf3PIOM6U-NmWk2O.mjs +20 -0
- package/browser/esm/C4BPDYeqgN59wMGp.mjs +411 -0
- package/browser/esm/CGbn_xdhgTvk2mvb.mjs +612 -0
- package/browser/esm/CKADOp3hTx0MSNY7.mjs +52 -0
- package/browser/esm/CR2sUEZyRqVv2SNl.mjs +105 -0
- package/browser/esm/CTN8J8c1AneJu3Lu.mjs +2207 -0
- package/browser/esm/Cc5akPEmIwbgKIfc.mjs +516 -0
- package/browser/esm/CePKCTL6D05kDy2E.mjs +82 -0
- package/browser/esm/DBM1blcMTZMAM-eR.mjs +217 -0
- package/browser/esm/DPBnKqhSuJ414Pxx.mjs +99 -0
- package/browser/esm/F51tGfYHocox80zY.mjs +468 -0
- package/browser/esm/SDzKpaiuhQux7tAh.mjs +5391 -0
- package/browser/esm/TDH9XceS8cAkO5d3.mjs +508 -0
- package/browser/esm/XKVlG-x_9q5dbVIW.mjs +8878 -0
- package/browser/esm/fJiwyUQJ18X-cCQz.mjs +1376 -0
- package/browser/esm/fel6EbPAcZOsBmks.mjs +42 -0
- package/browser/esm/flvjZEXrSDrtDzLB.mjs +113 -0
- package/browser/esm/index.mjs +152 -91
- package/licenses/dependencies.txt +137 -627
- package/node/esm/B9-0usA1hSoD0Nk3.mjs +679 -0
- package/node/esm/BO1vNzjGWYdZdbq9.mjs +113 -0
- package/node/esm/BYigefA8bf9FOVib.mjs +47 -0
- package/node/esm/BdrLZp98HQaVMykZ.mjs +82 -0
- package/node/esm/BlubX7gm8wTUNiZ-.mjs +106 -0
- package/node/esm/C8a6QwMGW1tMiWA6.mjs +516 -0
- package/node/esm/CCCnorMn30oUDDIY.mjs +4536 -0
- package/node/esm/CKpik3HRSANKEy4G.mjs +99 -0
- package/node/esm/CTZcfST8pUcLMail.mjs +509 -0
- package/node/esm/D1K9Ji7iQwnOnd1-.mjs +190 -0
- package/node/esm/DuUiuB59bQRPQi-D.mjs +155 -0
- package/node/esm/eKP73GEWmonTXpfv.mjs +470 -0
- package/node/esm/g3y8kxL1Ln214UNr.mjs +129 -0
- package/node/esm/index.mjs +10603 -2832
- package/package.json +27 -27
- package/resources/contents.json +30 -0
- package/resources/locales/contents.json +44 -0
- package/resources/locales/de/groups.cmd.json +219 -0
- package/resources/locales/de/studio.cmd.json +159 -0
- package/resources/locales/de/ui.msg.json +507 -0
- package/resources/locales/en/groups.cmd.json +219 -0
- package/resources/locales/en/studio.cmd.json +159 -0
- package/resources/locales/en/ui.msg.json +508 -0
- package/types/index.d.ts +2 -1761
- package/types/src/anchorItems/AnchorItemsDescriptor.d.ts +131 -0
- package/types/src/anchorItems/AnchorItemsPanel.d.ts +29 -0
- package/types/src/anchorItems/index.d.ts +3 -0
- package/types/src/border/BorderPopupButton.d.ts +30 -0
- package/types/src/border/BorderStylePopupButton.d.ts +40 -0
- package/types/src/border/index.d.ts +3 -0
- package/types/src/chart/command/InsertChartCommandButton.d.ts +10 -0
- package/types/src/chart/command/index.d.ts +2 -0
- package/types/src/color/Alpha.d.ts +36 -0
- package/types/src/color/Checkboard.d.ts +11 -0
- package/types/src/color/CheckboardUtils.d.ts +3 -0
- package/types/src/color/ColorButton.d.ts +21 -0
- package/types/src/color/ColorButtonList.d.ts +17 -0
- package/types/src/color/ColorPanel.d.ts +71 -0
- package/types/src/color/ColorPopupButton.d.ts +29 -0
- package/types/src/color/CustomColorPanel.d.ts +16 -0
- package/types/src/color/EditableInput.d.ts +22 -0
- package/types/src/color/Hue.d.ts +29 -0
- package/types/src/color/Saturation.d.ts +45 -0
- package/types/src/color/SketchFields.d.ts +9 -0
- package/types/src/color/Swatch.d.ts +16 -0
- package/types/src/color/Types.d.ts +11 -0
- package/types/src/color/_Utils.d.ts +4 -0
- package/types/src/color/index.d.ts +7 -0
- package/types/src/command/AccountingStyleCommandButton.d.ts +18 -0
- package/types/src/command/AppearanceCommandButton.d.ts +3 -0
- package/types/src/command/BorderCommandButton.d.ts +20 -0
- package/types/src/command/ColorCommandButton.d.ts +23 -0
- package/types/src/command/DocThemeCommandButton.d.ts +19 -0
- package/types/src/command/FileCommandButton.d.ts +8 -0
- package/types/src/command/FontFamilyCommandButton.d.ts +9 -0
- package/types/src/command/FontSizeCommandButton.d.ts +21 -0
- package/types/src/command/InsertFunctionCommandPopupButton.d.ts +9 -0
- package/types/src/command/InsertFunctionSumCommandPopupButton.d.ts +8 -0
- package/types/src/command/LanguageCommandButton.d.ts +19 -0
- package/types/src/command/LocaleCommandButton.d.ts +17 -0
- package/types/src/command/NumberFormatCommandButton.d.ts +6 -0
- package/types/src/command/PasteCommandButton.d.ts +14 -0
- package/types/src/command/PresetCellStylesCommandButton.d.ts +11 -0
- package/types/src/command/PresetTableStylesCommandButton.d.ts +12 -0
- package/types/src/command/RegisterCatalog.d.ts +3 -0
- package/types/src/command/SheetCommandGroups.d.ts +10 -0
- package/types/src/command/SheetZoomCommandButton.d.ts +9 -0
- package/types/src/command/StudioCommandGroups.d.ts +11 -0
- package/types/src/command/TextEffectsCommandButton.d.ts +6 -0
- package/types/src/command/TextRotateGroupButton.d.ts +14 -0
- package/types/src/command/UndoRedoCommandButton.d.ts +14 -0
- package/types/src/command/WalkingCopyCommandButton.d.ts +6 -0
- package/types/src/command/WorkbookCommandGroups.d.ts +11 -0
- package/types/src/command/index.d.ts +23 -0
- package/types/src/conditionalFormat/ColorScaleRulePanel.d.ts +18 -0
- package/types/src/conditionalFormat/ConditionalFormatDetailsPanel.d.ts +23 -0
- package/types/src/conditionalFormat/ConditionalFormatDetailsTaskPane.d.ts +4 -0
- package/types/src/conditionalFormat/ConditionalFormatEditorPanel.d.ts +20 -0
- package/types/src/conditionalFormat/ConditionalFormatPlugin.d.ts +2 -0
- package/types/src/conditionalFormat/ConditionalFormatRangeField.d.ts +32 -0
- package/types/src/conditionalFormat/ConditionalFormatStylePicker.d.ts +34 -0
- package/types/src/conditionalFormat/ConditionalFormatTitle.d.ts +10 -0
- package/types/src/conditionalFormat/DataBarRulePanel.d.ts +23 -0
- package/types/src/conditionalFormat/IconSetRulePanel.d.ts +23 -0
- package/types/src/conditionalFormat/PresetChip.d.ts +30 -0
- package/types/src/conditionalFormat/PresetScalesCommandButton.d.ts +20 -0
- package/types/src/conditionalFormat/RulePreview.d.ts +23 -0
- package/types/src/conditionalFormat/RuleSection.d.ts +20 -0
- package/types/src/conditionalFormat/ScaleMiniGrid.d.ts +59 -0
- package/types/src/conditionalFormat/ScaleStopRow.d.ts +34 -0
- package/types/src/conditionalFormat/index.d.ts +3 -0
- package/types/src/conditionalFormat/previewColor.d.ts +50 -0
- package/types/src/conditions/AverageOption.d.ts +25 -0
- package/types/src/conditions/BetweenOption.d.ts +25 -0
- package/types/src/conditions/BooleanOption.d.ts +24 -0
- package/types/src/conditions/CombinatorOption.d.ts +41 -0
- package/types/src/conditions/ConditionEditor.d.ts +57 -0
- package/types/src/conditions/ConditionUtils.d.ts +83 -0
- package/types/src/conditions/DateTimeOption.d.ts +43 -0
- package/types/src/conditions/ExpressionOption.d.ts +26 -0
- package/types/src/conditions/InSetOption.d.ts +37 -0
- package/types/src/conditions/NumberOption.d.ts +24 -0
- package/types/src/conditions/OperatorAndParamEditor.d.ts +55 -0
- package/types/src/conditions/OperatorSelect.d.ts +35 -0
- package/types/src/conditions/OperatorSelectPopupButton.d.ts +39 -0
- package/types/src/conditions/ScalarOption.d.ts +29 -0
- package/types/src/conditions/SelectorSelect.d.ts +43 -0
- package/types/src/conditions/StringOption.d.ts +24 -0
- package/types/src/conditions/TimePeriodOption.d.ts +25 -0
- package/types/src/conditions/TopNOption.d.ts +25 -0
- package/types/src/conditions/index.d.ts +13 -0
- package/types/src/dataValidation/DataValidationDetailsPanel.d.ts +16 -0
- package/types/src/dataValidation/DataValidationDetailsTaskPane.d.ts +3 -0
- package/types/src/dataValidation/DataValidationEditorPanel.d.ts +12 -0
- package/types/src/dataValidation/DataValidationPlugin.d.ts +2 -0
- package/types/src/dataValidation/index.d.ts +2 -0
- package/types/src/debug/DebugUtils.d.ts +4 -0
- package/types/src/debug/index.d.ts +2 -0
- package/types/src/dialog/CommentsDialog.d.ts +11 -0
- package/types/src/dialog/FindReplaceWindow.d.ts +13 -0
- package/types/src/dialog/HyperlinkDialog.d.ts +28 -0
- package/types/src/dialog/InsertFunctionDialog.d.ts +25 -0
- package/types/src/dialog/NamedReferenceDialog.d.ts +17 -0
- package/types/src/dialog/NumberFormatDialog.d.ts +12 -0
- package/types/src/dialog/ResizeHeaderDialog.d.ts +15 -0
- package/types/src/dialog/ShortcutKeysDialog.d.ts +9 -0
- package/types/src/dialog/ShortcutKeysPanel.d.ts +28 -0
- package/types/src/dialog/SortDialog.d.ts +9 -0
- package/types/src/dialog/TableNewDialog.d.ts +14 -0
- package/types/src/dialog/WorkbookStatisticsDialog.d.ts +13 -0
- package/types/src/dialog/index.d.ts +10 -0
- package/types/src/filter/ColumnMenu.d.ts +13 -0
- package/types/src/filter/FilterList.d.ts +28 -0
- package/types/src/filter/index.d.ts +3 -0
- package/types/src/form/FormulaField.d.ts +221 -0
- package/types/src/form/InputField.d.ts +89 -0
- package/types/src/form/index.d.ts +3 -0
- package/types/src/formulaBar/FormulaBar.d.ts +8 -0
- package/types/src/formulaBar/IFormulaBar.d.ts +51 -0
- package/types/src/formulaBar/index.d.ts +3 -0
- package/types/src/function/FunctionArgumentsPanel.d.ts +57 -0
- package/types/src/function/FunctionSearchPanel.d.ts +35 -0
- package/types/src/function/InsertFunctionWizard.d.ts +79 -0
- package/types/src/function/index.d.ts +4 -0
- package/types/src/function/paneMetrics.d.ts +33 -0
- package/types/src/index.d.ts +21 -0
- package/types/src/itemsPanel/EditorPanel.d.ts +21 -0
- package/types/src/itemsPanel/ItemCard.d.ts +57 -0
- package/types/src/itemsPanel/ItemsDescriptor.d.ts +215 -0
- package/types/src/itemsPanel/ItemsPanel.d.ts +45 -0
- package/types/src/itemsPanel/SortableCards.d.ts +67 -0
- package/types/src/itemsPanel/index.d.ts +6 -0
- package/types/src/movable/MovableContextMenu.d.ts +13 -0
- package/types/src/movable/index.d.ts +2 -0
- package/types/src/named/INamedCollectionEditor.d.ts +37 -0
- package/types/src/named/NamedCollectionEditor.d.ts +7 -0
- package/types/src/named/NamedDetailsPanel.d.ts +11 -0
- package/types/src/named/NamedDetailsTaskPane.d.ts +3 -0
- package/types/src/named/NamedDraft.d.ts +68 -0
- package/types/src/named/NamedEditorPanel.d.ts +19 -0
- package/types/src/named/NamedPlugin.d.ts +2 -0
- package/types/src/named/index.d.ts +8 -0
- package/types/src/numberFormat/NumberFormatPanel.d.ts +29 -0
- package/types/src/numberFormat/NumberFormatTaskPane.d.ts +12 -0
- package/types/src/numberFormat/index.d.ts +8 -0
- package/types/src/protectedRange/ProtectedRangeDetailsPanel.d.ts +20 -0
- package/types/src/protectedRange/ProtectedRangeDetailsTaskPane.d.ts +3 -0
- package/types/src/protectedRange/ProtectedRangeEditorPanel.d.ts +27 -0
- package/types/src/protectedRange/ProtectedRangePlugin.d.ts +2 -0
- package/types/src/protectedRange/index.d.ts +2 -0
- package/types/src/protection/WorkbookProtectionDialog.d.ts +23 -0
- package/types/src/protection/WorkbookProtectionPanel.d.ts +51 -0
- package/types/src/protection/index.d.ts +3 -0
- package/types/src/sheet/SheetTabMenu.d.ts +21 -0
- package/types/src/sheet/SheetsAllMenu.d.ts +16 -0
- package/types/src/sheet/index.d.ts +3 -0
- package/types/src/statusBar/NumberStats.d.ts +27 -0
- package/types/src/statusBar/SheetZoomScale.d.ts +11 -0
- package/types/src/statusBar/StatusBar.d.ts +35 -0
- package/types/src/statusBar/index.d.ts +4 -0
- package/types/src/studio/CommandsWrapper.d.ts +36 -0
- package/types/src/studio/DefaultLogo.d.ts +3 -0
- package/types/src/studio/EagerStudio.d.ts +5 -0
- package/types/src/studio/Studio.d.ts +26 -0
- package/types/src/studio/StudioCommandProvider.d.ts +26 -0
- package/types/src/studio/StudioCommands.d.ts +115 -0
- package/types/src/studio/StudioNotifierProvider.d.ts +10 -0
- package/types/src/studio/StudioProps.d.ts +372 -0
- package/types/src/studio/StudioSplitPane.d.ts +60 -0
- package/types/src/studio/StudioTaskPaneArea.d.ts +8 -0
- package/types/src/studio/StudioToolbar.d.ts +37 -0
- package/types/src/studio/index.d.ts +4 -0
- package/types/src/studio/useStudioApp.d.ts +51 -0
- package/types/src/table/TableDetailsPanel.d.ts +17 -0
- package/types/src/table/TableDetailsTaskPane.d.ts +3 -0
- package/types/src/table/TablePlugin.d.ts +2 -0
- package/types/src/table/TableStyleCanvasPreview.d.ts +21 -0
- package/types/src/table/TableStyleOptionsPanel.d.ts +38 -0
- package/types/src/table/TableStylePreview.d.ts +43 -0
- package/types/src/table/index.d.ts +7 -0
- package/types/src/theme/ThemeSelectButton.d.ts +23 -0
- package/types/src/theme/ThemeSelectPanel.d.ts +17 -0
- package/types/src/theme/ThemeSelectPopupButton.d.ts +24 -0
- package/types/src/theme/ThemeUtils.d.ts +57 -0
- package/types/src/theme/index.d.ts +5 -0
- package/types/src/toast/ToastError.d.ts +10 -0
- package/types/src/toast/index.d.ts +2 -0
- package/types/src/toolbar/WorkbookToolbars.d.ts +46 -0
- package/types/src/toolbar/index.d.ts +2 -0
- package/types/src/workbook/DefaultRenderers.d.ts +23 -0
- package/types/src/workbook/DocumentTitle.d.ts +69 -0
- package/types/src/workbook/WorkbookContextMenu.d.ts +13 -0
- package/types/src/workbook/WorkbookElement.d.ts +12 -0
- package/types/src/workbook/WorkbookStrip.d.ts +37 -0
- package/types/src/workbook/index.d.ts +7 -0
- package/browser/cjs/52tjAlO48FpZgfzG.cjs +0 -6
- package/browser/cjs/BGu2_YqVJMQjYx4D.cjs +0 -18
- package/browser/cjs/C83Rzj_Jwq-o69wr.cjs +0 -42
- package/browser/cjs/CldYLQnjFC_g8o3t.cjs +0 -6
- package/browser/cjs/Cpv3j_Ra1h-axLRG.cjs +0 -6
- package/browser/cjs/D-5Cg1Y0zALF_JEs.cjs +0 -7
- package/browser/cjs/D58sOTRZwQ59CgOf.cjs +0 -6
- package/browser/cjs/DEd-0xEuUoELRnQb.cjs +0 -6
- package/browser/cjs/DahKlfm68zudpndW.cjs +0 -20
- package/browser/cjs/Dd7t0gfO3bzS0-B8.cjs +0 -6
- package/browser/cjs/DxAU6DV3UCUDVoSH.cjs +0 -6
- package/browser/cjs/uj7GSwDaUyTKEjrN.cjs +0 -6
- package/browser/esm/BLuR1D2n--9QSJL9.mjs +0 -26
- package/browser/esm/BSOhdb74viwmCi54.mjs +0 -2159
- package/browser/esm/BTAhrEfV-DH0-Ldk.mjs +0 -640
- package/browser/esm/BgsyX5QL9OLy0DN3.mjs +0 -4533
- package/browser/esm/CFPGs5_tLGrpkW8L.mjs +0 -25
- package/browser/esm/CbCX3t0hx-h6pV7Q.mjs +0 -46
- package/browser/esm/D3dDP89ml0258MGb.mjs +0 -53
- package/browser/esm/DYk55y6IEOCytW3g.mjs +0 -50
- package/browser/esm/DfUqOxFfhJcaq847.mjs +0 -2411
- package/browser/esm/DhWeeZyxUc-LbP8E.mjs +0 -50
- package/browser/esm/DqLDLUCqiFovdBf0.mjs +0 -155
- package/browser/esm/Dvo0k3olgFuAso_O.mjs +0 -54
- package/node/assets/style.css +0 -1
- package/node/esm/BM_pvbGlgXydGNT3.mjs +0 -52
- package/node/esm/CFBcwLP2q2_EUXvE.mjs +0 -156
- package/node/esm/Cg9JFB8nOnVfR0Uo.mjs +0 -26
- package/node/esm/D3kxA1LpG-PpZvCb.mjs +0 -25
- package/node/esm/D_s6w_GWb8l7uGW3.mjs +0 -53
- package/node/esm/XI3nj4zD7mXOyxSm.mjs +0 -57
- package/node/esm/YXQgUYqP1qsi_MPX.mjs +0 -46
- package/node/esm/m2lejeU-ViEhFj_N.mjs +0 -91
- package/node/esm/sevERUPIPJCb-jYL.mjs +0 -88
- package/node/esm/zdjaq7yEfEvgHrDi.mjs +0 -50
|
@@ -0,0 +1,113 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.7.28-beta.1
|
|
3
|
+
*
|
|
4
|
+
* (C) 2026-present SheetXL Inc. & Michael T. Ford
|
|
5
|
+
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
+
*/
|
|
7
|
+
import { FormulaField as e, InputField as t } from "./index.mjs";
|
|
8
|
+
import { useReferenceMode as a } from "@sheetxl/react";
|
|
9
|
+
import { useCallbackRef as n, useTranslator as l } from "@sheetxl/utils-react";
|
|
10
|
+
import { memo as o, useCallback as i, useMemo as r, useState as s } from "react";
|
|
11
|
+
import { OptionsDialog as p } from "@sheetxl/utils-mui";
|
|
12
|
+
import { jsx as m, jsxs as u } from "react/jsx-runtime";
|
|
13
|
+
import { Box as d } from "@mui/material";
|
|
14
|
+
var c = ["Ok", "Cancel"], g = o((o) => {
|
|
15
|
+
const { initialValue: g = null, context: x, onOption: f, onValidateOption: N, onDone: T, onInput: y, options: h = c, defaultOption: O = h?.[0], cancelOption: V = "Cancel", sx: C, ...v } = o, I = l(), w = r(() => x?.().getNames().findValidName("Range1"), []), F = r(() => {
|
|
16
|
+
if (!g) return !0;
|
|
17
|
+
}, []), [R, E] = s({
|
|
18
|
+
displayText: g?.getName() ?? w,
|
|
19
|
+
errorText: null
|
|
20
|
+
}), [D, M] = s(() => ({
|
|
21
|
+
displayValue: g?.getRanges?.() ?? x?.()?.selection() ?? null,
|
|
22
|
+
errorText: null
|
|
23
|
+
})), [j, k] = s(!1), B = "point" === a().getMode()?.mode, L = i(async (e) => !R.errorText && !D.errorText, []), S = n((e, t, a) => {
|
|
24
|
+
if (!t) {
|
|
25
|
+
const e = R?.displayText ?? "", t = null == (n = D?.displayValue ?? null) ? null : "string" == typeof n ? n : n.isICellRanges ? n.toString() : n.getExpression();
|
|
26
|
+
let a = null;
|
|
27
|
+
if (F || !g) t && (a = x?.()?.getNames().addFormula(e, t, !1) ?? null);
|
|
28
|
+
else {
|
|
29
|
+
const n = g;
|
|
30
|
+
n.setExpression && g.doBatch(() => {
|
|
31
|
+
g.setName(e), t && n.setExpression(t);
|
|
32
|
+
}, I("op.editNamedItem", { name: e })), a = g;
|
|
33
|
+
}
|
|
34
|
+
a && (a.select(), y?.(a));
|
|
35
|
+
}
|
|
36
|
+
var n;
|
|
37
|
+
f?.(e, t, a), T?.();
|
|
38
|
+
}, [
|
|
39
|
+
x,
|
|
40
|
+
R,
|
|
41
|
+
D,
|
|
42
|
+
T,
|
|
43
|
+
f,
|
|
44
|
+
O,
|
|
45
|
+
V,
|
|
46
|
+
y
|
|
47
|
+
]), b = n((e) => {
|
|
48
|
+
let t = null;
|
|
49
|
+
try {
|
|
50
|
+
x?.().getNames().validateName(e);
|
|
51
|
+
} catch (e) {
|
|
52
|
+
const a = e?.message;
|
|
53
|
+
t = a ? I(a) : a;
|
|
54
|
+
}
|
|
55
|
+
E({
|
|
56
|
+
displayText: e,
|
|
57
|
+
errorText: t
|
|
58
|
+
});
|
|
59
|
+
}, []), A = n((e) => {
|
|
60
|
+
g && g.getName().toLowerCase() === e.toLowerCase() || x?.().getNames().validateName(e);
|
|
61
|
+
}, [x, g]), G = i((e) => {
|
|
62
|
+
M({
|
|
63
|
+
displayValue: e ?? null,
|
|
64
|
+
errorText: null
|
|
65
|
+
});
|
|
66
|
+
}, []);
|
|
67
|
+
return m(p, {
|
|
68
|
+
title: I(F ? "namedRange.titleDefine" : "namedRange.titleEdit"),
|
|
69
|
+
options: h,
|
|
70
|
+
onOption: S,
|
|
71
|
+
onValidateOption: L,
|
|
72
|
+
defaultOption: O,
|
|
73
|
+
cancelOption: V,
|
|
74
|
+
autoFocusSel: ".autoFocus",
|
|
75
|
+
suspendModal: B,
|
|
76
|
+
sx: {
|
|
77
|
+
width: "460px",
|
|
78
|
+
...C
|
|
79
|
+
},
|
|
80
|
+
...v,
|
|
81
|
+
children: u(d, {
|
|
82
|
+
sx: {
|
|
83
|
+
paddingTop: (e) => e.spacing(1),
|
|
84
|
+
paddingBottom: (e) => e.spacing(0),
|
|
85
|
+
rowGap: (e) => e.spacing(1),
|
|
86
|
+
range: "flex",
|
|
87
|
+
flexDirection: "column"
|
|
88
|
+
},
|
|
89
|
+
children: [m(t, {
|
|
90
|
+
sx: { paddingTop: (e) => e.spacing(1.5) },
|
|
91
|
+
formName: "name",
|
|
92
|
+
defaultInput: w,
|
|
93
|
+
value: R.displayText,
|
|
94
|
+
onChangeInput: b,
|
|
95
|
+
onValidate: A,
|
|
96
|
+
onFocus: (e) => {
|
|
97
|
+
j || e.target?.select(), k(!0);
|
|
98
|
+
}
|
|
99
|
+
}), m(e, {
|
|
100
|
+
grammar: "reference",
|
|
101
|
+
formName: "range",
|
|
102
|
+
value: D.displayValue,
|
|
103
|
+
onChangeInput: G,
|
|
104
|
+
pickAs: "absolute",
|
|
105
|
+
allowMulti: !0,
|
|
106
|
+
onFocus: (e) => {
|
|
107
|
+
j || e.target?.select(), k(!0);
|
|
108
|
+
}
|
|
109
|
+
})]
|
|
110
|
+
})
|
|
111
|
+
});
|
|
112
|
+
});
|
|
113
|
+
export { g as NamedReferenceDialog, g as default };
|
|
@@ -0,0 +1,47 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.7.28-beta.1
|
|
3
|
+
*
|
|
4
|
+
* (C) 2026-present SheetXL Inc. & Michael T. Ford
|
|
5
|
+
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
+
*/
|
|
7
|
+
import { NumberFormatPanel as t } from "./index.mjs";
|
|
8
|
+
import { useCallbackRef as o, useTranslator as n } from "@sheetxl/utils-react";
|
|
9
|
+
import { memo as e, useCallback as i, useState as a } from "react";
|
|
10
|
+
import { OptionsDialog as l } from "@sheetxl/utils-mui";
|
|
11
|
+
import { jsx as r } from "react/jsx-runtime";
|
|
12
|
+
var p = ["Ok", "Cancel"], s = e((e) => {
|
|
13
|
+
const { initialValue: s, context: c, onOption: m, onValidateOption: u, onInput: x, onDone: d, options: f = p, defaultOption: O = f?.[0], cancelOption: h = "Cancel", sx: v, ...C } = e, g = n(), [y, V] = a(s), j = o(async (t) => {
|
|
14
|
+
const o = t === h;
|
|
15
|
+
o || x?.(y, t), m?.(t, o, t === O), d?.();
|
|
16
|
+
}, [
|
|
17
|
+
y,
|
|
18
|
+
x,
|
|
19
|
+
d,
|
|
20
|
+
m,
|
|
21
|
+
h,
|
|
22
|
+
O
|
|
23
|
+
]), w = i(async (t) => await Promise.resolve(u?.(t)) ?? !0, [u]);
|
|
24
|
+
return r(l, {
|
|
25
|
+
title: g("numberFormat.dialogTitle"),
|
|
26
|
+
options: f,
|
|
27
|
+
onDone: d,
|
|
28
|
+
onOption: (t) => j(t),
|
|
29
|
+
onValidateOption: w,
|
|
30
|
+
defaultOption: O,
|
|
31
|
+
cancelOption: h,
|
|
32
|
+
autoFocusSel: ".sxl-nf-cat-active",
|
|
33
|
+
sx: {
|
|
34
|
+
width: "512px",
|
|
35
|
+
...v
|
|
36
|
+
},
|
|
37
|
+
...C,
|
|
38
|
+
children: r(t, {
|
|
39
|
+
value: y,
|
|
40
|
+
onChange: V,
|
|
41
|
+
onCommit: () => j(O),
|
|
42
|
+
context: c,
|
|
43
|
+
style: { paddingTop: "4px" }
|
|
44
|
+
})
|
|
45
|
+
});
|
|
46
|
+
});
|
|
47
|
+
export { s as NumberFormatDialog, s as default };
|
|
@@ -0,0 +1,82 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.7.28-beta.1
|
|
3
|
+
*
|
|
4
|
+
* (C) 2026-present SheetXL Inc. & Michael T. Ford
|
|
5
|
+
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
+
*/
|
|
7
|
+
import { FormulaField as e } from "./index.mjs";
|
|
8
|
+
import { useReferenceMode as t } from "@sheetxl/react";
|
|
9
|
+
import { useCallbackRef as o, useTranslator as n } from "@sheetxl/utils-react";
|
|
10
|
+
import { memo as a, useCallback as l, useMemo as i, useState as r } from "react";
|
|
11
|
+
import { OptionsDialog as s } from "@sheetxl/utils-mui";
|
|
12
|
+
import { jsx as c, jsxs as p } from "react/jsx-runtime";
|
|
13
|
+
import { Box as m, Checkbox as u, FormControlLabel as d } from "@mui/material";
|
|
14
|
+
var g = ["Ok", "Cancel"], f = a((a) => {
|
|
15
|
+
const { onInput: f, onOption: h, onValidateOption: x, onDone: O, options: w = g, defaultOption: b = w?.[0], cancelOption: C = "Cancel", sx: N, initialValue: v, context: F, ...D } = a, H = n(), [I, M] = r(!1), [S, V] = r(() => v?.hasHeader ?? !1), [j, k] = r(() => v?.ranges ?? null), y = i(() => {
|
|
16
|
+
const e = v?.ranges?.getSheet?.()?.getName();
|
|
17
|
+
return e ? { scope: e } : void 0;
|
|
18
|
+
}, [v]), B = "point" === t().getMode()?.mode, G = o((e) => {
|
|
19
|
+
const t = j ? {
|
|
20
|
+
...v,
|
|
21
|
+
hasHeader: S,
|
|
22
|
+
ranges: j
|
|
23
|
+
} : null, o = e === C || !e;
|
|
24
|
+
f?.(!o && t ? t : void 0), h?.(e ?? C, o, e === b), O?.({
|
|
25
|
+
option: e,
|
|
26
|
+
tableOptions: t
|
|
27
|
+
});
|
|
28
|
+
}, [
|
|
29
|
+
O,
|
|
30
|
+
h,
|
|
31
|
+
b,
|
|
32
|
+
C,
|
|
33
|
+
S,
|
|
34
|
+
j,
|
|
35
|
+
v
|
|
36
|
+
]), P = l(async (e, t) => !0, []);
|
|
37
|
+
return c(s, {
|
|
38
|
+
title: H("tableNew.title"),
|
|
39
|
+
options: w,
|
|
40
|
+
onDone: G,
|
|
41
|
+
onValidateOption: P,
|
|
42
|
+
defaultOption: b,
|
|
43
|
+
cancelOption: C,
|
|
44
|
+
autoFocusSel: ".autoFocus",
|
|
45
|
+
suspendModal: B,
|
|
46
|
+
sx: {
|
|
47
|
+
width: "360px",
|
|
48
|
+
...N
|
|
49
|
+
},
|
|
50
|
+
...D,
|
|
51
|
+
children: p(m, {
|
|
52
|
+
sx: {
|
|
53
|
+
paddingTop: (e) => e.spacing(1),
|
|
54
|
+
paddingBottom: (e) => e.spacing(0),
|
|
55
|
+
rowGap: (e) => e.spacing(1),
|
|
56
|
+
display: "flex",
|
|
57
|
+
flexDirection: "column"
|
|
58
|
+
},
|
|
59
|
+
children: [c(e, {
|
|
60
|
+
grammar: "reference",
|
|
61
|
+
classNameInput: "autoFocus",
|
|
62
|
+
formName: "range",
|
|
63
|
+
value: j,
|
|
64
|
+
allowMulti: !1,
|
|
65
|
+
allowCrossSheet: !1,
|
|
66
|
+
home: y,
|
|
67
|
+
onChangeInput: (e) => k(e?.getReferences() ?? null),
|
|
68
|
+
onFocus: (e) => {
|
|
69
|
+
I || e.target?.select(), M(!0);
|
|
70
|
+
}
|
|
71
|
+
}), c(d, {
|
|
72
|
+
control: c(u, {
|
|
73
|
+
checked: S,
|
|
74
|
+
onChange: () => V(!S)
|
|
75
|
+
}),
|
|
76
|
+
label: H("tableNew.hasHeaders"),
|
|
77
|
+
labelPlacement: "end"
|
|
78
|
+
})]
|
|
79
|
+
})
|
|
80
|
+
});
|
|
81
|
+
});
|
|
82
|
+
export { f as TableNewDialog, f as default };
|
|
@@ -0,0 +1,106 @@
|
|
|
1
|
+
/**
|
|
2
|
+
* @license @sheetxl/studio-mui - Studio - Spreadsheet UI built with SheetXL SDK using React & MUI. - v0.7.28-beta.1
|
|
3
|
+
*
|
|
4
|
+
* (C) 2026-present SheetXL Inc. & Michael T. Ford
|
|
5
|
+
* License: The license can be found at https://www.sheetxl.com/license.
|
|
6
|
+
*/
|
|
7
|
+
import { useCallbackRef as t, useTranslator as n } from "@sheetxl/utils-react";
|
|
8
|
+
import { memo as o, useCallback as e, useMemo as a, useState as i } from "react";
|
|
9
|
+
import { OptionsDialog as l } from "@sheetxl/utils-mui";
|
|
10
|
+
import { jsx as s } from "react/jsx-runtime";
|
|
11
|
+
import { Box as r, FormControl as c, TextField as p } from "@mui/material";
|
|
12
|
+
var m = ["Ok", "Cancel"], u = o((o) => {
|
|
13
|
+
const { initialValue: u = null, onInput: d, context: g, onOption: x, onValidateOption: h, onDone: f, options: O = m, defaultOption: C = O?.[0], cancelOption: w = "Cancel", sx: y, ...v } = o, F = n(), T = a(() => {
|
|
14
|
+
const t = u ?? g?.()?.getComments();
|
|
15
|
+
let n = "";
|
|
16
|
+
if (t && t.content && t.content.runs) {
|
|
17
|
+
const o = t.content.runs;
|
|
18
|
+
for (let t = 0; t < o.length; t++) {
|
|
19
|
+
const e = o[t];
|
|
20
|
+
n += e?.text;
|
|
21
|
+
}
|
|
22
|
+
}
|
|
23
|
+
return n;
|
|
24
|
+
}, []), [b, k] = i(T), [D, I] = i(!1), P = e(async (t, n) => null, []), V = t(async (t) => {
|
|
25
|
+
const n = "" === b ? [] : b.split("\n"), o = t === w;
|
|
26
|
+
if (!o) {
|
|
27
|
+
const t = n.length, o = new Array(t);
|
|
28
|
+
for (let e = 0; e < t; e++) o[e] = { text: n[e] };
|
|
29
|
+
d?.({ content: { runs: o } });
|
|
30
|
+
}
|
|
31
|
+
x?.(t, o, t === C), f?.();
|
|
32
|
+
}, [
|
|
33
|
+
b,
|
|
34
|
+
d,
|
|
35
|
+
f,
|
|
36
|
+
x,
|
|
37
|
+
C,
|
|
38
|
+
w
|
|
39
|
+
]), B = t((t) => {
|
|
40
|
+
k(t.target.value), P(t.target.value);
|
|
41
|
+
}, [h]), M = t(async (t) => {
|
|
42
|
+
let n = await Promise.resolve(h?.(t));
|
|
43
|
+
try {
|
|
44
|
+
!1 !== n && (n = await P(b, t));
|
|
45
|
+
} catch (t) {}
|
|
46
|
+
return n ?? !0;
|
|
47
|
+
}, [h, b]);
|
|
48
|
+
return s(l, {
|
|
49
|
+
title: F(T ? "comments.titleEdit" : "comments.titleInsert"),
|
|
50
|
+
options: O,
|
|
51
|
+
onDone: f,
|
|
52
|
+
onOption: (t) => V(t),
|
|
53
|
+
onValidateOption: M,
|
|
54
|
+
defaultOption: C,
|
|
55
|
+
cancelOption: w,
|
|
56
|
+
autoFocusSel: ".autoFocus",
|
|
57
|
+
sx: {
|
|
58
|
+
width: "480px",
|
|
59
|
+
...y
|
|
60
|
+
},
|
|
61
|
+
...v,
|
|
62
|
+
children: s(r, {
|
|
63
|
+
sx: {
|
|
64
|
+
paddingTop: (t) => t.spacing(1),
|
|
65
|
+
paddingBottom: (t) => t.spacing(0),
|
|
66
|
+
rowGap: (t) => t.spacing(1),
|
|
67
|
+
display: "flex",
|
|
68
|
+
flexDirection: "column"
|
|
69
|
+
},
|
|
70
|
+
children: s(c, {
|
|
71
|
+
sx: {
|
|
72
|
+
paddingTop: (t) => t.spacing(1.5),
|
|
73
|
+
minWidth: 135,
|
|
74
|
+
width: "100%"
|
|
75
|
+
},
|
|
76
|
+
size: "small",
|
|
77
|
+
children: s(p, {
|
|
78
|
+
label: F("comments.label"),
|
|
79
|
+
placeholder: F("comments.placeholder"),
|
|
80
|
+
onFocus: (t) => {
|
|
81
|
+
D || t.target?.select(), I(!0);
|
|
82
|
+
},
|
|
83
|
+
sx: { "& .MuiFormHelperText-root": { marginTop: (t) => t.spacing(.5) } },
|
|
84
|
+
slotProps: {
|
|
85
|
+
inputLabel: { shrink: !0 },
|
|
86
|
+
htmlInput: {
|
|
87
|
+
className: "autoFocus",
|
|
88
|
+
spellCheck: !1,
|
|
89
|
+
autoComplete: "off",
|
|
90
|
+
sx: {
|
|
91
|
+
paddingTop: (t) => t.spacing(1.25),
|
|
92
|
+
paddingBottom: (t) => t.spacing(.75)
|
|
93
|
+
}
|
|
94
|
+
}
|
|
95
|
+
},
|
|
96
|
+
value: b,
|
|
97
|
+
onChange: B,
|
|
98
|
+
onContextMenu: (t) => {
|
|
99
|
+
t.stopPropagation();
|
|
100
|
+
}
|
|
101
|
+
})
|
|
102
|
+
})
|
|
103
|
+
})
|
|
104
|
+
});
|
|
105
|
+
});
|
|
106
|
+
export { u as CommentsDialog, u as default };
|