@univerjs/sheets-formula 0.2.12 → 0.2.13

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 (40) hide show
  1. package/lib/cjs/index.js +4 -4
  2. package/lib/es/index.js +328 -236
  3. package/lib/locale/en-US.json +201 -169
  4. package/lib/locale/ru-RU.json +201 -169
  5. package/lib/locale/vi-VN.json +496 -44
  6. package/lib/locale/zh-CN.json +209 -177
  7. package/lib/locale/zh-TW.json +213 -181
  8. package/lib/types/commands/operations/__tests__/create-command-test-bed.d.ts +6 -6
  9. package/lib/types/common/plugin-name.d.ts +1 -1
  10. package/lib/types/controllers/__tests__/create-command-test-bed.d.ts +1 -1
  11. package/lib/types/controllers/prompt.controller.d.ts +7 -6
  12. package/lib/types/controllers/utils/ref-range-formula.d.ts +6 -0
  13. package/lib/types/formula-ui-plugin.d.ts +3 -3
  14. package/lib/types/locale/en-US.d.ts +103 -71
  15. package/lib/types/locale/function-list/logical/en-US.d.ts +22 -10
  16. package/lib/types/locale/function-list/logical/ja-JP.d.ts +22 -10
  17. package/lib/types/locale/function-list/logical/vi-VN.d.ts +22 -10
  18. package/lib/types/locale/function-list/logical/zh-CN.d.ts +22 -10
  19. package/lib/types/locale/function-list/logical/zh-TW.d.ts +22 -10
  20. package/lib/types/locale/function-list/lookup/en-US.d.ts +46 -14
  21. package/lib/types/locale/function-list/lookup/ja-JP.d.ts +46 -14
  22. package/lib/types/locale/function-list/lookup/vi-VN.d.ts +126 -4
  23. package/lib/types/locale/function-list/lookup/zh-CN.d.ts +46 -14
  24. package/lib/types/locale/function-list/lookup/zh-TW.d.ts +46 -14
  25. package/lib/types/locale/function-list/math/en-US.d.ts +35 -47
  26. package/lib/types/locale/function-list/math/ja-JP.d.ts +35 -47
  27. package/lib/types/locale/function-list/math/vi-VN.d.ts +276 -0
  28. package/lib/types/locale/function-list/math/zh-CN.d.ts +35 -47
  29. package/lib/types/locale/function-list/math/zh-TW.d.ts +35 -47
  30. package/lib/types/locale/ru-RU.d.ts +103 -71
  31. package/lib/types/locale/vi-VN.d.ts +424 -14
  32. package/lib/types/locale/zh-CN.d.ts +103 -71
  33. package/lib/types/locale/zh-TW.d.ts +103 -71
  34. package/lib/types/services/description.service.d.ts +1 -1
  35. package/lib/types/services/prompt.service.d.ts +1 -1
  36. package/lib/types/services/register-function.service.d.ts +1 -1
  37. package/lib/types/services/remote/remote-register-function.service.d.ts +1 -1
  38. package/lib/types/views/more-functions/interface.d.ts +1 -1
  39. package/lib/umd/index.js +4 -4
  40. package/package.json +26 -24
package/lib/es/index.js CHANGED
@@ -2,18 +2,19 @@ var __defProp = Object.defineProperty;
2
2
  var __defNormalProp = (obj, key, value) => key in obj ? __defProp(obj, key, { enumerable: !0, configurable: !0, writable: !0, value }) : obj[key] = value;
3
3
  var __name = (target, value) => __defProp(target, "name", { value, configurable: !0 });
4
4
  var __publicField = (obj, key, value) => __defNormalProp(obj, typeof key != "symbol" ? key + "" : key, value);
5
- import { Disposable, ObjectMatrix, Dimension, OnLifecycle, LifecycleStages, Inject, IUniverInstanceService, CellValueType, ThemeService, ICommandService, isFormulaString, isFormulaId, Tools, Direction, UniverInstanceType, Injector, DEFAULT_EMPTY_DOCUMENT_VALUE, toDisposable, ColorKit, Rectangle, ILogService, CommandType, createIdentifier, IContextService, isRealNum, getCellValueType, useDependency, LocaleService, useInjector, IConfigService, FOCUSING_DOC, FOCUSING_UNIVER_EDITOR, FOCUSING_UNIVER_EDITOR_STANDALONE_SINGLE_MODE, connectInjector, throttle, cellToRange, RANGE_TYPE, DisposableCollection, Optional, isICellData, RxDisposable, FORMULA_EDITOR_ACTIVATED, FOCUSING_EDITOR_INPUT_FORMULA, getCellInfoInMergeData, AbsoluteRefType, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, DOCS_NORMAL_EDITOR_UNIT_ID_KEY, Plugin, DependentOn } from "@univerjs/core";
5
+ import { Disposable, ObjectMatrix, Dimension, OnLifecycle, LifecycleStages, Inject, IUniverInstanceService, CellValueType, ThemeService, ICommandService, isFormulaString, isFormulaId, Tools, Direction, UniverInstanceType, Injector, DEFAULT_EMPTY_DOCUMENT_VALUE, toDisposable, ColorKit, Rectangle, ILogService, CommandType, createIdentifier, IContextService, isRealNum, getCellValueType, useDependency, LocaleService, useInjector, IConfigService, FOCUSING_DOC, FOCUSING_UNIVER_EDITOR, FOCUSING_UNIVER_EDITOR_STANDALONE_SINGLE_MODE, connectInjector, throttle, cellToRange, isInternalEditorID, RANGE_TYPE, DisposableCollection, Optional, isICellData, RxDisposable, FORMULA_EDITOR_ACTIVATED, FOCUSING_EDITOR_INPUT_FORMULA, getCellInfoInMergeData, AbsoluteRefType, DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, DOCS_NORMAL_EDITOR_UNIT_ID_KEY, Plugin, DependentOn } from "@univerjs/core";
6
6
  import { IRPCChannelService, fromModule, toModule } from "@univerjs/rpc";
7
7
  import { SetDefinedNameMutation, RemoveDefinedNameMutation, FormulaDataModel, IActiveDirtyManagerService, IDefinedNamesService, SetArrayFormulaDataMutation, stripErrorMargin, LexerTreeBuilder, SetFormulaCalculationResultMutation, ErrorType, sequenceNodeType, serializeRange, FUNCTION_NAMES_COMPATIBILITY, FunctionType, FUNCTION_NAMES_CUBE, FUNCTION_NAMES_DATABASE, FUNCTION_NAMES_DATE, FUNCTION_NAMES_ENGINEERING, FUNCTION_NAMES_FINANCIAL, FUNCTION_NAMES_INFORMATION, FUNCTION_NAMES_LOGICAL, FUNCTION_NAMES_LOOKUP, FUNCTION_NAMES_MATH, FUNCTION_NAMES_STATISTICAL, FUNCTION_NAMES_TEXT, FUNCTION_NAMES_WEB, isReferenceStrings, functionArray, functionCompatibility, functionCube, functionDatabase, functionDate, functionEngineering, functionFinancial, functionInformation, functionLogical, functionLookup, functionMath, functionMeta, functionStatistical, functionText, functionUniver, functionWeb, IFunctionService, ERROR_TYPE_SET, SetFormulaCalculationStartMutation, SetFormulaCalculationStopMutation, SetFormulaCalculationNotificationMutation, FormulaExecuteStageType, FormulaExecutedStateType, SetFormulaDataMutation, initSheetFormulaData, deserializeRangeWithSheet, serializeRangeToRefString, generateStringWithSequence, CustomFunction, serializeRangeWithSpreadsheet, serializeRangeWithSheet, SetOtherFormulaMutation, RemoveOtherFormulaMutation, matchRefDrawToken, matchToken, compareToken, normalizeSheetName, getAbsoluteRefTypeWitString, UniverFormulaEnginePlugin } from "@univerjs/engine-formula";
8
- import { IRenderManagerService, ITextSelectionRenderManager, DeviceInputEventType, ScrollTimerType, SHEET_VIEWPORT_KEY, Vector2 } from "@univerjs/engine-render";
8
+ import { IRenderManagerService, DeviceInputEventType, ScrollTimerType, SHEET_VIEWPORT_KEY, Vector2 } from "@univerjs/engine-render";
9
9
  import { SetRangeValuesMutation, SetStyleCommand, MoveRangeMutation, MoveRowsMutation, MoveColsMutation, ReorderRangeMutation, RemoveRowMutation, RemoveColMutation, RemoveSheetMutation, InsertSheetMutation, SetDefinedNameCommand, INTERCEPTOR_POINT, SheetInterceptorService, SetRangeValuesUndoMutationFactory, SetWorksheetRowHeightMutation, SetWorksheetColWidthMutation, SetColHiddenMutation, SetColVisibleMutation, SetRowHiddenMutation, SetRowVisibleMutation, SetWorksheetRowAutoHeightMutation, SetRangeValuesCommand, SheetsSelectionsService, getSheetCommandTarget, getCellAtRowCol, SetSelectionsOperation, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetCellValuePermission, RangeProtectionPermissionEditPoint, SetBorderCommand, ClearSelectionFormatCommand, INumfmtService, handleMoveRange, EffectRefRangId, runRefRangeMutations, handleMoveRows, handleMoveCols, handleInsertRow, handleInsertCol, handleIRemoveRow, handleIRemoveCol, handleDeleteRangeMoveLeft, handleDeleteRangeMoveUp, handleInsertRangeMoveDown, handleInsertRangeMoveRight, RemoveSheetCommand, SetWorksheetNameCommand, DeleteRangeMoveLeftCommand, DeleteRangeMoveUpCommand, RemoveColCommand, RemoveRowCommand, InsertRangeMoveDownCommand, InsertRangeMoveRightCommand, InsertColCommand, InsertRowCommand, MoveColsCommand, MoveRowsCommand, MoveRangeCommand, SetWorksheetActiveOperation, InsertDefinedNameCommand, RemoveDefinedNameCommand, RefRangeService, handleDefaultRangeChangeWithEffectRefCommands, SelectionMoveType, convertSelectionDataToRange, getNormalSelectionStyle, IRefSelectionsService, DISABLE_NORMAL_SELECTIONS, setEndForRange, getPrimaryForRange, RefSelectionsService } from "@univerjs/sheets";
10
10
  import { DATA_TYPE, APPLY_TYPE, IAutoFillService, PREDEFINED_HOOK_NAME, COPY_TYPE, ISheetClipboardService, ISheetSelectionRenderService, SelectionShape, SELECTION_SHAPE_DEPTH, IEditorBridgeService, SheetSkeletonManagerService, SheetPasteCommand, useActiveWorkbook, whenFormulaEditorActivated, getCurrentRangeDisable$, PASTE_SPECIAL_MENU_ID, CellAlertType, HoverManagerService, CellAlertManagerService, BaseSelectionRenderService, getCoordByOffset, checkInHeaderRanges, getAllSelection, attachSelectionWithCoord, getSheetObject, getEditorObject, MoveSelectionCommand, JumpOver, ExpandSelectionCommand } from "@univerjs/sheets-ui";
11
- import { IEditorService, ISidebarService, KeyCode, MetaKeys, MenuItemType, getMenuHiddenObservable, IClipboardInterfaceService, RibbonStartGroup, BuiltInUIPart, ComponentManager, IMenuManagerService, IShortcutService, IUIPartsService, IProgressService, UNI_DISABLE_CHANGING_FOCUS_KEY, SetEditorResizeOperation, IContextMenuService } from "@univerjs/ui";
11
+ import { IEditorService, ISidebarService, ILayoutService, KeyCode, MetaKeys, MenuItemType, getMenuHiddenObservable, IClipboardInterfaceService, RibbonStartGroup, BuiltInUIPart, ComponentManager, IMenuManagerService, IShortcutService, IUIPartsService, IProgressService, UNI_DISABLE_CHANGING_FOCUS_KEY, SetEditorResizeOperation, IContextMenuService } from "@univerjs/ui";
12
12
  import { Subject, throttleTime, combineLatestWith, map, switchMap, of, Observable, merge, filter, bufferTime, distinctUntilKeyChanged, distinctUntilChanged } from "rxjs";
13
13
  import require$$0, { forwardRef, useRef, createElement, useEffect, useState } from "react";
14
14
  import { Popup, Select, Input, Button } from "@univerjs/design";
15
- import { ReplaceContentCommand, DocSkeletonManagerService, MoveCursorOperation, TextSelectionManagerService } from "@univerjs/docs";
16
- const FORMULA_UI_PLUGIN_NAME = "formula-ui";
15
+ import { DocSkeletonManagerService, DocSelectionManagerService } from "@univerjs/docs";
16
+ import { DocSelectionRenderService, ReplaceContentCommand, MoveCursorOperation } from "@univerjs/docs-ui";
17
+ const FORMULA_UI_PLUGIN_NAME = "SHEET_FORMULA_UI_PLUGIN";
17
18
  var __defProp$j = Object.defineProperty, __getOwnPropDesc$j = Object.getOwnPropertyDescriptor, __decorateClass$j = /* @__PURE__ */ __name((decorators, target, key, kind) => {
18
19
  for (var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc$j(target, key) : target, i = decorators.length - 1, decorator; i >= 0; i--)
19
20
  (decorator = decorators[i]) && (result = (kind ? decorator(target, key, result) : decorator(result)) || result);
@@ -1342,7 +1343,7 @@ function HelpFunction() {
1342
1343
  }
1343
1344
  __name(handleSwitchActive, "handleSwitchActive");
1344
1345
  function handleClose() {
1345
- setHelpVisible(!helpVisible), injector.get(ITextSelectionRenderManager).focus();
1346
+ setHelpVisible(!helpVisible), injector.get(ILayoutService).focus();
1346
1347
  }
1347
1348
  return __name(handleClose, "handleClose"), /* @__PURE__ */ jsxRuntimeExports.jsx(jsxRuntimeExports.Fragment, { children: helpVisible ? /* @__PURE__ */ jsxRuntimeExports.jsx(Popup, { visible, offset, children: functionInfo ? /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: styles$5.formulaHelpFunction, children: [
1348
1349
  /* @__PURE__ */ jsxRuntimeExports.jsxs("div", { className: styles$5.formulaHelpFunctionTitle, children: [
@@ -7056,16 +7057,16 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
7056
7057
  abstract: "formula.functionList.BYCOL.abstract",
7057
7058
  functionParameter: [
7058
7059
  {
7059
- name: "formula.functionList.BYCOL.functionParameter.number1.name",
7060
- detail: "formula.functionList.BYCOL.functionParameter.number1.detail",
7061
- example: "A1:A20",
7060
+ name: "formula.functionList.BYCOL.functionParameter.array.name",
7061
+ detail: "formula.functionList.BYCOL.functionParameter.array.detail",
7062
+ example: "A1:C2",
7062
7063
  require: 1,
7063
7064
  repeat: 0
7064
7065
  },
7065
7066
  {
7066
- name: "formula.functionList.BYCOL.functionParameter.number2.name",
7067
- detail: "formula.functionList.BYCOL.functionParameter.number2.detail",
7068
- example: "A1:A20",
7067
+ name: "formula.functionList.BYCOL.functionParameter.lambda.name",
7068
+ detail: "formula.functionList.BYCOL.functionParameter.lambda.detail",
7069
+ example: "LAMBDA(array, MAX(array))",
7069
7070
  require: 1,
7070
7071
  repeat: 0
7071
7072
  }
@@ -7078,16 +7079,16 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
7078
7079
  abstract: "formula.functionList.BYROW.abstract",
7079
7080
  functionParameter: [
7080
7081
  {
7081
- name: "formula.functionList.BYROW.functionParameter.number1.name",
7082
- detail: "formula.functionList.BYROW.functionParameter.number1.detail",
7083
- example: "A1:A20",
7082
+ name: "formula.functionList.BYROW.functionParameter.array.name",
7083
+ detail: "formula.functionList.BYROW.functionParameter.array.detail",
7084
+ example: "A1:C2",
7084
7085
  require: 1,
7085
7086
  repeat: 0
7086
7087
  },
7087
7088
  {
7088
- name: "formula.functionList.BYROW.functionParameter.number2.name",
7089
- detail: "formula.functionList.BYROW.functionParameter.number2.detail",
7090
- example: "A1:A20",
7089
+ name: "formula.functionList.BYROW.functionParameter.lambda.name",
7090
+ detail: "formula.functionList.BYROW.functionParameter.lambda.detail",
7091
+ example: "LAMBDA(array, MAX(array))",
7091
7092
  require: 1,
7092
7093
  repeat: 0
7093
7094
  }
@@ -7311,16 +7312,23 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
7311
7312
  abstract: "formula.functionList.MAP.abstract",
7312
7313
  functionParameter: [
7313
7314
  {
7314
- name: "formula.functionList.MAP.functionParameter.number1.name",
7315
- detail: "formula.functionList.MAP.functionParameter.number1.detail",
7316
- example: "A1:A20",
7315
+ name: "formula.functionList.MAP.functionParameter.array1.name",
7316
+ detail: "formula.functionList.MAP.functionParameter.array1.detail",
7317
+ example: "D2:D11",
7317
7318
  require: 1,
7318
7319
  repeat: 0
7319
7320
  },
7320
7321
  {
7321
- name: "formula.functionList.MAP.functionParameter.number2.name",
7322
- detail: "formula.functionList.MAP.functionParameter.number2.detail",
7323
- example: "A1:A20",
7322
+ name: "formula.functionList.MAP.functionParameter.array2.name",
7323
+ detail: "formula.functionList.MAP.functionParameter.array2.detail",
7324
+ example: "E2:E11",
7325
+ require: 0,
7326
+ repeat: 1
7327
+ },
7328
+ {
7329
+ name: "formula.functionList.MAP.functionParameter.lambda.name",
7330
+ detail: "formula.functionList.MAP.functionParameter.lambda.detail",
7331
+ example: 'LAMBDA(s,c,AND(s="Large",c="Red"))',
7324
7332
  require: 1,
7325
7333
  repeat: 0
7326
7334
  }
@@ -7370,16 +7378,23 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
7370
7378
  abstract: "formula.functionList.REDUCE.abstract",
7371
7379
  functionParameter: [
7372
7380
  {
7373
- name: "formula.functionList.REDUCE.functionParameter.number1.name",
7374
- detail: "formula.functionList.REDUCE.functionParameter.number1.detail",
7375
- example: "A1:A20",
7381
+ name: "formula.functionList.REDUCE.functionParameter.initialValue.name",
7382
+ detail: "formula.functionList.REDUCE.functionParameter.initialValue.detail",
7383
+ example: "1",
7376
7384
  require: 1,
7377
7385
  repeat: 0
7378
7386
  },
7379
7387
  {
7380
- name: "formula.functionList.REDUCE.functionParameter.number2.name",
7381
- detail: "formula.functionList.REDUCE.functionParameter.number2.detail",
7382
- example: "A1:A20",
7388
+ name: "formula.functionList.REDUCE.functionParameter.array.name",
7389
+ detail: "formula.functionList.REDUCE.functionParameter.array.detail",
7390
+ example: "A1:C2",
7391
+ require: 1,
7392
+ repeat: 0
7393
+ },
7394
+ {
7395
+ name: "formula.functionList.REDUCE.functionParameter.lambda.name",
7396
+ detail: "formula.functionList.REDUCE.functionParameter.lambda.detail",
7397
+ example: "LAMBDA(a,b,a+b^2)",
7383
7398
  require: 1,
7384
7399
  repeat: 0
7385
7400
  }
@@ -7392,16 +7407,23 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
7392
7407
  abstract: "formula.functionList.SCAN.abstract",
7393
7408
  functionParameter: [
7394
7409
  {
7395
- name: "formula.functionList.SCAN.functionParameter.number1.name",
7396
- detail: "formula.functionList.SCAN.functionParameter.number1.detail",
7397
- example: "A1:A20",
7410
+ name: "formula.functionList.SCAN.functionParameter.initialValue.name",
7411
+ detail: "formula.functionList.SCAN.functionParameter.initialValue.detail",
7412
+ example: "1",
7398
7413
  require: 1,
7399
7414
  repeat: 0
7400
7415
  },
7401
7416
  {
7402
- name: "formula.functionList.SCAN.functionParameter.number2.name",
7403
- detail: "formula.functionList.SCAN.functionParameter.number2.detail",
7404
- example: "A1:A20",
7417
+ name: "formula.functionList.SCAN.functionParameter.array.name",
7418
+ detail: "formula.functionList.SCAN.functionParameter.array.detail",
7419
+ example: "A1:C2",
7420
+ require: 1,
7421
+ repeat: 0
7422
+ },
7423
+ {
7424
+ name: "formula.functionList.SCAN.functionParameter.lambda.name",
7425
+ detail: "formula.functionList.SCAN.functionParameter.lambda.detail",
7426
+ example: "LAMBDA(a,b,a+b^2)",
7405
7427
  require: 1,
7406
7428
  repeat: 0
7407
7429
  }
@@ -7662,18 +7684,25 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
7662
7684
  abstract: "formula.functionList.DROP.abstract",
7663
7685
  functionParameter: [
7664
7686
  {
7665
- name: "formula.functionList.DROP.functionParameter.number1.name",
7666
- detail: "formula.functionList.DROP.functionParameter.number1.detail",
7667
- example: "A1:A20",
7687
+ name: "formula.functionList.DROP.functionParameter.array.name",
7688
+ detail: "formula.functionList.DROP.functionParameter.array.detail",
7689
+ example: "A2:C4",
7668
7690
  require: 1,
7669
7691
  repeat: 0
7670
7692
  },
7671
7693
  {
7672
- name: "formula.functionList.DROP.functionParameter.number2.name",
7673
- detail: "formula.functionList.DROP.functionParameter.number2.detail",
7674
- example: "A1:A20",
7694
+ name: "formula.functionList.DROP.functionParameter.rows.name",
7695
+ detail: "formula.functionList.DROP.functionParameter.rows.detail",
7696
+ example: "2",
7675
7697
  require: 1,
7676
7698
  repeat: 0
7699
+ },
7700
+ {
7701
+ name: "formula.functionList.DROP.functionParameter.columns.name",
7702
+ detail: "formula.functionList.DROP.functionParameter.columns.detail",
7703
+ example: "2",
7704
+ require: 0,
7705
+ repeat: 0
7677
7706
  }
7678
7707
  ]
7679
7708
  },
@@ -7684,18 +7713,32 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
7684
7713
  abstract: "formula.functionList.EXPAND.abstract",
7685
7714
  functionParameter: [
7686
7715
  {
7687
- name: "formula.functionList.EXPAND.functionParameter.number1.name",
7688
- detail: "formula.functionList.EXPAND.functionParameter.number1.detail",
7689
- example: "A1:A20",
7716
+ name: "formula.functionList.EXPAND.functionParameter.array.name",
7717
+ detail: "formula.functionList.EXPAND.functionParameter.array.detail",
7718
+ example: "A2",
7690
7719
  require: 1,
7691
7720
  repeat: 0
7692
7721
  },
7693
7722
  {
7694
- name: "formula.functionList.EXPAND.functionParameter.number2.name",
7695
- detail: "formula.functionList.EXPAND.functionParameter.number2.detail",
7696
- example: "A1:A20",
7723
+ name: "formula.functionList.EXPAND.functionParameter.rows.name",
7724
+ detail: "formula.functionList.EXPAND.functionParameter.rows.detail",
7725
+ example: "3",
7697
7726
  require: 1,
7698
7727
  repeat: 0
7728
+ },
7729
+ {
7730
+ name: "formula.functionList.EXPAND.functionParameter.columns.name",
7731
+ detail: "formula.functionList.EXPAND.functionParameter.columns.detail",
7732
+ example: "3",
7733
+ require: 0,
7734
+ repeat: 0
7735
+ },
7736
+ {
7737
+ name: "formula.functionList.EXPAND.functionParameter.padWith.name",
7738
+ detail: "formula.functionList.EXPAND.functionParameter.padWith.detail",
7739
+ example: '"-"',
7740
+ require: 0,
7741
+ repeat: 0
7699
7742
  }
7700
7743
  ]
7701
7744
  },
@@ -8171,18 +8214,25 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
8171
8214
  abstract: "formula.functionList.TAKE.abstract",
8172
8215
  functionParameter: [
8173
8216
  {
8174
- name: "formula.functionList.TAKE.functionParameter.number1.name",
8175
- detail: "formula.functionList.TAKE.functionParameter.number1.detail",
8176
- example: "A1:A20",
8217
+ name: "formula.functionList.TAKE.functionParameter.array.name",
8218
+ detail: "formula.functionList.TAKE.functionParameter.array.detail",
8219
+ example: "A2:C4",
8177
8220
  require: 1,
8178
8221
  repeat: 0
8179
8222
  },
8180
8223
  {
8181
- name: "formula.functionList.TAKE.functionParameter.number2.name",
8182
- detail: "formula.functionList.TAKE.functionParameter.number2.detail",
8183
- example: "A1:A20",
8224
+ name: "formula.functionList.TAKE.functionParameter.rows.name",
8225
+ detail: "formula.functionList.TAKE.functionParameter.rows.detail",
8226
+ example: "2",
8184
8227
  require: 1,
8185
8228
  repeat: 0
8229
+ },
8230
+ {
8231
+ name: "formula.functionList.TAKE.functionParameter.columns.name",
8232
+ detail: "formula.functionList.TAKE.functionParameter.columns.detail",
8233
+ example: "2",
8234
+ require: 0,
8235
+ repeat: 0
8186
8236
  }
8187
8237
  ]
8188
8238
  },
@@ -8193,17 +8243,24 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
8193
8243
  abstract: "formula.functionList.TOCOL.abstract",
8194
8244
  functionParameter: [
8195
8245
  {
8196
- name: "formula.functionList.TOCOL.functionParameter.number1.name",
8197
- detail: "formula.functionList.TOCOL.functionParameter.number1.detail",
8198
- example: "A1:A20",
8246
+ name: "formula.functionList.TOCOL.functionParameter.array.name",
8247
+ detail: "formula.functionList.TOCOL.functionParameter.array.detail",
8248
+ example: "A2:D4",
8199
8249
  require: 1,
8200
8250
  repeat: 0
8201
8251
  },
8202
8252
  {
8203
- name: "formula.functionList.TOCOL.functionParameter.number2.name",
8204
- detail: "formula.functionList.TOCOL.functionParameter.number2.detail",
8205
- example: "A1:A20",
8206
- require: 1,
8253
+ name: "formula.functionList.TOCOL.functionParameter.ignore.name",
8254
+ detail: "formula.functionList.TOCOL.functionParameter.ignore.detail",
8255
+ example: "1",
8256
+ require: 0,
8257
+ repeat: 0
8258
+ },
8259
+ {
8260
+ name: "formula.functionList.TOCOL.functionParameter.scanByColumn.name",
8261
+ detail: "formula.functionList.TOCOL.functionParameter.scanByColumn.detail",
8262
+ example: "TRUE",
8263
+ require: 0,
8207
8264
  repeat: 0
8208
8265
  }
8209
8266
  ]
@@ -8215,17 +8272,24 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
8215
8272
  abstract: "formula.functionList.TOROW.abstract",
8216
8273
  functionParameter: [
8217
8274
  {
8218
- name: "formula.functionList.TOROW.functionParameter.number1.name",
8219
- detail: "formula.functionList.TOROW.functionParameter.number1.detail",
8220
- example: "A1:A20",
8275
+ name: "formula.functionList.TOROW.functionParameter.array.name",
8276
+ detail: "formula.functionList.TOROW.functionParameter.array.detail",
8277
+ example: "A2:D4",
8221
8278
  require: 1,
8222
8279
  repeat: 0
8223
8280
  },
8224
8281
  {
8225
- name: "formula.functionList.TOROW.functionParameter.number2.name",
8226
- detail: "formula.functionList.TOROW.functionParameter.number2.detail",
8227
- example: "A1:A20",
8228
- require: 1,
8282
+ name: "formula.functionList.TOROW.functionParameter.ignore.name",
8283
+ detail: "formula.functionList.TOROW.functionParameter.ignore.detail",
8284
+ example: "1",
8285
+ require: 0,
8286
+ repeat: 0
8287
+ },
8288
+ {
8289
+ name: "formula.functionList.TOROW.functionParameter.scanByColumn.name",
8290
+ detail: "formula.functionList.TOROW.functionParameter.scanByColumn.detail",
8291
+ example: "TRUE",
8292
+ require: 0,
8229
8293
  repeat: 0
8230
8294
  }
8231
8295
  ]
@@ -8339,18 +8403,25 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
8339
8403
  abstract: "formula.functionList.WRAPCOLS.abstract",
8340
8404
  functionParameter: [
8341
8405
  {
8342
- name: "formula.functionList.WRAPCOLS.functionParameter.number1.name",
8343
- detail: "formula.functionList.WRAPCOLS.functionParameter.number1.detail",
8344
- example: "A1:A20",
8406
+ name: "formula.functionList.WRAPCOLS.functionParameter.vector.name",
8407
+ detail: "formula.functionList.WRAPCOLS.functionParameter.vector.detail",
8408
+ example: "A2:G2",
8345
8409
  require: 1,
8346
8410
  repeat: 0
8347
8411
  },
8348
8412
  {
8349
- name: "formula.functionList.WRAPCOLS.functionParameter.number2.name",
8350
- detail: "formula.functionList.WRAPCOLS.functionParameter.number2.detail",
8351
- example: "A1:A20",
8413
+ name: "formula.functionList.WRAPCOLS.functionParameter.wrapCount.name",
8414
+ detail: "formula.functionList.WRAPCOLS.functionParameter.wrapCount.detail",
8415
+ example: "3",
8352
8416
  require: 1,
8353
8417
  repeat: 0
8418
+ },
8419
+ {
8420
+ name: "formula.functionList.WRAPCOLS.functionParameter.padWith.name",
8421
+ detail: "formula.functionList.WRAPCOLS.functionParameter.padWith.detail",
8422
+ example: '"x"',
8423
+ require: 0,
8424
+ repeat: 0
8354
8425
  }
8355
8426
  ]
8356
8427
  },
@@ -8361,18 +8432,25 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
8361
8432
  abstract: "formula.functionList.WRAPROWS.abstract",
8362
8433
  functionParameter: [
8363
8434
  {
8364
- name: "formula.functionList.WRAPROWS.functionParameter.number1.name",
8365
- detail: "formula.functionList.WRAPROWS.functionParameter.number1.detail",
8366
- example: "A1:A20",
8435
+ name: "formula.functionList.WRAPROWS.functionParameter.vector.name",
8436
+ detail: "formula.functionList.WRAPROWS.functionParameter.vector.detail",
8437
+ example: "A2:G2",
8367
8438
  require: 1,
8368
8439
  repeat: 0
8369
8440
  },
8370
8441
  {
8371
- name: "formula.functionList.WRAPROWS.functionParameter.number2.name",
8372
- detail: "formula.functionList.WRAPROWS.functionParameter.number2.detail",
8373
- example: "A1:A20",
8442
+ name: "formula.functionList.WRAPROWS.functionParameter.wrapCount.name",
8443
+ detail: "formula.functionList.WRAPROWS.functionParameter.wrapCount.detail",
8444
+ example: "3",
8374
8445
  require: 1,
8375
8446
  repeat: 0
8447
+ },
8448
+ {
8449
+ name: "formula.functionList.WRAPROWS.functionParameter.padWith.name",
8450
+ detail: "formula.functionList.WRAPROWS.functionParameter.padWith.detail",
8451
+ example: '"x"',
8452
+ require: 0,
8453
+ repeat: 0
8376
8454
  }
8377
8455
  ]
8378
8456
  },
@@ -8773,16 +8851,16 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
8773
8851
  abstract: "formula.functionList.COMBIN.abstract",
8774
8852
  functionParameter: [
8775
8853
  {
8776
- name: "formula.functionList.COMBIN.functionParameter.number1.name",
8777
- detail: "formula.functionList.COMBIN.functionParameter.number1.detail",
8778
- example: "A1:A20",
8854
+ name: "formula.functionList.COMBIN.functionParameter.number.name",
8855
+ detail: "formula.functionList.COMBIN.functionParameter.number.detail",
8856
+ example: "8",
8779
8857
  require: 1,
8780
8858
  repeat: 0
8781
8859
  },
8782
8860
  {
8783
- name: "formula.functionList.COMBIN.functionParameter.number2.name",
8784
- detail: "formula.functionList.COMBIN.functionParameter.number2.detail",
8785
- example: "A1:A20",
8861
+ name: "formula.functionList.COMBIN.functionParameter.numberChosen.name",
8862
+ detail: "formula.functionList.COMBIN.functionParameter.numberChosen.detail",
8863
+ example: "2",
8786
8864
  require: 1,
8787
8865
  repeat: 0
8788
8866
  }
@@ -8795,16 +8873,16 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
8795
8873
  abstract: "formula.functionList.COMBINA.abstract",
8796
8874
  functionParameter: [
8797
8875
  {
8798
- name: "formula.functionList.COMBINA.functionParameter.number1.name",
8799
- detail: "formula.functionList.COMBINA.functionParameter.number1.detail",
8800
- example: "A1:A20",
8876
+ name: "formula.functionList.COMBINA.functionParameter.number.name",
8877
+ detail: "formula.functionList.COMBINA.functionParameter.number.detail",
8878
+ example: "8",
8801
8879
  require: 1,
8802
8880
  repeat: 0
8803
8881
  },
8804
8882
  {
8805
- name: "formula.functionList.COMBINA.functionParameter.number2.name",
8806
- detail: "formula.functionList.COMBINA.functionParameter.number2.detail",
8807
- example: "A1:A20",
8883
+ name: "formula.functionList.COMBINA.functionParameter.numberChosen.name",
8884
+ detail: "formula.functionList.COMBINA.functionParameter.numberChosen.detail",
8885
+ example: "2",
8808
8886
  require: 1,
8809
8887
  repeat: 0
8810
8888
  }
@@ -8974,16 +9052,9 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
8974
9052
  abstract: "formula.functionList.FACT.abstract",
8975
9053
  functionParameter: [
8976
9054
  {
8977
- name: "formula.functionList.FACT.functionParameter.number1.name",
8978
- detail: "formula.functionList.FACT.functionParameter.number1.detail",
8979
- example: "A1:A20",
8980
- require: 1,
8981
- repeat: 0
8982
- },
8983
- {
8984
- name: "formula.functionList.FACT.functionParameter.number2.name",
8985
- detail: "formula.functionList.FACT.functionParameter.number2.detail",
8986
- example: "A1:A20",
9055
+ name: "formula.functionList.FACT.functionParameter.number.name",
9056
+ detail: "formula.functionList.FACT.functionParameter.number.detail",
9057
+ example: "5",
8987
9058
  require: 1,
8988
9059
  repeat: 0
8989
9060
  }
@@ -8996,16 +9067,9 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
8996
9067
  abstract: "formula.functionList.FACTDOUBLE.abstract",
8997
9068
  functionParameter: [
8998
9069
  {
8999
- name: "formula.functionList.FACTDOUBLE.functionParameter.number1.name",
9000
- detail: "formula.functionList.FACTDOUBLE.functionParameter.number1.detail",
9001
- example: "A1:A20",
9002
- require: 1,
9003
- repeat: 0
9004
- },
9005
- {
9006
- name: "formula.functionList.FACTDOUBLE.functionParameter.number2.name",
9007
- detail: "formula.functionList.FACTDOUBLE.functionParameter.number2.detail",
9008
- example: "A1:A20",
9070
+ name: "formula.functionList.FACTDOUBLE.functionParameter.number.name",
9071
+ detail: "formula.functionList.FACTDOUBLE.functionParameter.number.detail",
9072
+ example: "6",
9009
9073
  require: 1,
9010
9074
  repeat: 0
9011
9075
  }
@@ -9093,16 +9157,16 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9093
9157
  {
9094
9158
  name: "formula.functionList.GCD.functionParameter.number1.name",
9095
9159
  detail: "formula.functionList.GCD.functionParameter.number1.detail",
9096
- example: "A1:A20",
9160
+ example: "5",
9097
9161
  require: 1,
9098
9162
  repeat: 0
9099
9163
  },
9100
9164
  {
9101
9165
  name: "formula.functionList.GCD.functionParameter.number2.name",
9102
9166
  detail: "formula.functionList.GCD.functionParameter.number2.detail",
9103
- example: "A1:A20",
9104
- require: 1,
9105
- repeat: 0
9167
+ example: "2",
9168
+ require: 0,
9169
+ repeat: 1
9106
9170
  }
9107
9171
  ]
9108
9172
  },
@@ -9113,16 +9177,9 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9113
9177
  abstract: "formula.functionList.INT.abstract",
9114
9178
  functionParameter: [
9115
9179
  {
9116
- name: "formula.functionList.INT.functionParameter.number1.name",
9117
- detail: "formula.functionList.INT.functionParameter.number1.detail",
9118
- example: "A1:A20",
9119
- require: 1,
9120
- repeat: 0
9121
- },
9122
- {
9123
- name: "formula.functionList.INT.functionParameter.number2.name",
9124
- detail: "formula.functionList.INT.functionParameter.number2.detail",
9125
- example: "A1:A20",
9180
+ name: "formula.functionList.INT.functionParameter.number.name",
9181
+ detail: "formula.functionList.INT.functionParameter.number.detail",
9182
+ example: "8.9",
9126
9183
  require: 1,
9127
9184
  repeat: 0
9128
9185
  }
@@ -9159,16 +9216,16 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9159
9216
  {
9160
9217
  name: "formula.functionList.LCM.functionParameter.number1.name",
9161
9218
  detail: "formula.functionList.LCM.functionParameter.number1.detail",
9162
- example: "A1:A20",
9219
+ example: "5",
9163
9220
  require: 1,
9164
9221
  repeat: 0
9165
9222
  },
9166
9223
  {
9167
9224
  name: "formula.functionList.LCM.functionParameter.number2.name",
9168
9225
  detail: "formula.functionList.LCM.functionParameter.number2.detail",
9169
- example: "A1:A20",
9170
- require: 1,
9171
- repeat: 0
9226
+ example: "2",
9227
+ require: 0,
9228
+ repeat: 1
9172
9229
  }
9173
9230
  ]
9174
9231
  },
@@ -9253,16 +9310,9 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9253
9310
  abstract: "formula.functionList.MDETERM.abstract",
9254
9311
  functionParameter: [
9255
9312
  {
9256
- name: "formula.functionList.MDETERM.functionParameter.number1.name",
9257
- detail: "formula.functionList.MDETERM.functionParameter.number1.detail",
9258
- example: "A1:A20",
9259
- require: 1,
9260
- repeat: 0
9261
- },
9262
- {
9263
- name: "formula.functionList.MDETERM.functionParameter.number2.name",
9264
- detail: "formula.functionList.MDETERM.functionParameter.number2.detail",
9265
- example: "A1:A20",
9313
+ name: "formula.functionList.MDETERM.functionParameter.array.name",
9314
+ detail: "formula.functionList.MDETERM.functionParameter.array.detail",
9315
+ example: "{3,6,1;1,1,0;3,10,2}",
9266
9316
  require: 1,
9267
9317
  repeat: 0
9268
9318
  }
@@ -9275,16 +9325,9 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9275
9325
  abstract: "formula.functionList.MINVERSE.abstract",
9276
9326
  functionParameter: [
9277
9327
  {
9278
- name: "formula.functionList.MINVERSE.functionParameter.number1.name",
9279
- detail: "formula.functionList.MINVERSE.functionParameter.number1.detail",
9280
- example: "A1:A20",
9281
- require: 1,
9282
- repeat: 0
9283
- },
9284
- {
9285
- name: "formula.functionList.MINVERSE.functionParameter.number2.name",
9286
- detail: "formula.functionList.MINVERSE.functionParameter.number2.detail",
9287
- example: "A1:A20",
9328
+ name: "formula.functionList.MINVERSE.functionParameter.array.name",
9329
+ detail: "formula.functionList.MINVERSE.functionParameter.array.detail",
9330
+ example: "{3,6,1;1,1,0;3,10,2}",
9288
9331
  require: 1,
9289
9332
  repeat: 0
9290
9333
  }
@@ -9297,16 +9340,16 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9297
9340
  abstract: "formula.functionList.MMULT.abstract",
9298
9341
  functionParameter: [
9299
9342
  {
9300
- name: "formula.functionList.MMULT.functionParameter.number1.name",
9301
- detail: "formula.functionList.MMULT.functionParameter.number1.detail",
9302
- example: "A1:A20",
9343
+ name: "formula.functionList.MMULT.functionParameter.array1.name",
9344
+ detail: "formula.functionList.MMULT.functionParameter.array1.detail",
9345
+ example: "A2:B3",
9303
9346
  require: 1,
9304
9347
  repeat: 0
9305
9348
  },
9306
9349
  {
9307
- name: "formula.functionList.MMULT.functionParameter.number2.name",
9308
- detail: "formula.functionList.MMULT.functionParameter.number2.detail",
9309
- example: "A1:A20",
9350
+ name: "formula.functionList.MMULT.functionParameter.array2.name",
9351
+ detail: "formula.functionList.MMULT.functionParameter.array2.detail",
9352
+ example: "A5:B6",
9310
9353
  require: 1,
9311
9354
  repeat: 0
9312
9355
  }
@@ -9365,16 +9408,16 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9365
9408
  {
9366
9409
  name: "formula.functionList.MULTINOMIAL.functionParameter.number1.name",
9367
9410
  detail: "formula.functionList.MULTINOMIAL.functionParameter.number1.detail",
9368
- example: "A1:A20",
9411
+ example: "5",
9369
9412
  require: 1,
9370
9413
  repeat: 0
9371
9414
  },
9372
9415
  {
9373
9416
  name: "formula.functionList.MULTINOMIAL.functionParameter.number2.name",
9374
9417
  detail: "formula.functionList.MULTINOMIAL.functionParameter.number2.detail",
9375
- example: "A1:A20",
9376
- require: 1,
9377
- repeat: 0
9418
+ example: "2",
9419
+ require: 0,
9420
+ repeat: 1
9378
9421
  }
9379
9422
  ]
9380
9423
  },
@@ -9385,16 +9428,9 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9385
9428
  abstract: "formula.functionList.MUNIT.abstract",
9386
9429
  functionParameter: [
9387
9430
  {
9388
- name: "formula.functionList.MUNIT.functionParameter.number1.name",
9389
- detail: "formula.functionList.MUNIT.functionParameter.number1.detail",
9390
- example: "A1:A20",
9391
- require: 1,
9392
- repeat: 0
9393
- },
9394
- {
9395
- name: "formula.functionList.MUNIT.functionParameter.number2.name",
9396
- detail: "formula.functionList.MUNIT.functionParameter.number2.detail",
9397
- example: "A1:A20",
9431
+ name: "formula.functionList.MUNIT.functionParameter.dimension.name",
9432
+ detail: "formula.functionList.MUNIT.functionParameter.dimension.detail",
9433
+ example: "3",
9398
9434
  require: 1,
9399
9435
  repeat: 0
9400
9436
  }
@@ -9473,16 +9509,16 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9473
9509
  abstract: "formula.functionList.QUOTIENT.abstract",
9474
9510
  functionParameter: [
9475
9511
  {
9476
- name: "formula.functionList.QUOTIENT.functionParameter.number1.name",
9477
- detail: "formula.functionList.QUOTIENT.functionParameter.number1.detail",
9478
- example: "A1:A20",
9512
+ name: "formula.functionList.QUOTIENT.functionParameter.numerator.name",
9513
+ detail: "formula.functionList.QUOTIENT.functionParameter.numerator.detail",
9514
+ example: "5",
9479
9515
  require: 1,
9480
9516
  repeat: 0
9481
9517
  },
9482
9518
  {
9483
- name: "formula.functionList.QUOTIENT.functionParameter.number2.name",
9484
- detail: "formula.functionList.QUOTIENT.functionParameter.number2.detail",
9485
- example: "A1:A20",
9519
+ name: "formula.functionList.QUOTIENT.functionParameter.denominator.name",
9520
+ detail: "formula.functionList.QUOTIENT.functionParameter.denominator.detail",
9521
+ example: "2",
9486
9522
  require: 1,
9487
9523
  repeat: 0
9488
9524
  }
@@ -9700,16 +9736,30 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9700
9736
  abstract: "formula.functionList.SERIESSUM.abstract",
9701
9737
  functionParameter: [
9702
9738
  {
9703
- name: "formula.functionList.SERIESSUM.functionParameter.number1.name",
9704
- detail: "formula.functionList.SERIESSUM.functionParameter.number1.detail",
9705
- example: "A1:A20",
9739
+ name: "formula.functionList.SERIESSUM.functionParameter.x.name",
9740
+ detail: "formula.functionList.SERIESSUM.functionParameter.x.detail",
9741
+ example: "0.785398163",
9706
9742
  require: 1,
9707
9743
  repeat: 0
9708
9744
  },
9709
9745
  {
9710
- name: "formula.functionList.SERIESSUM.functionParameter.number2.name",
9711
- detail: "formula.functionList.SERIESSUM.functionParameter.number2.detail",
9712
- example: "A1:A20",
9746
+ name: "formula.functionList.SERIESSUM.functionParameter.n.name",
9747
+ detail: "formula.functionList.SERIESSUM.functionParameter.n.detail",
9748
+ example: "0",
9749
+ require: 1,
9750
+ repeat: 0
9751
+ },
9752
+ {
9753
+ name: "formula.functionList.SERIESSUM.functionParameter.m.name",
9754
+ detail: "formula.functionList.SERIESSUM.functionParameter.m.detail",
9755
+ example: "2",
9756
+ require: 1,
9757
+ repeat: 0
9758
+ },
9759
+ {
9760
+ name: "formula.functionList.SERIESSUM.functionParameter.coefficients.name",
9761
+ detail: "formula.functionList.SERIESSUM.functionParameter.coefficients.detail",
9762
+ example: "{1,-0.5,0.041666667,-0.001388889}",
9713
9763
  require: 1,
9714
9764
  repeat: 0
9715
9765
  }
@@ -9722,17 +9772,31 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9722
9772
  abstract: "formula.functionList.SEQUENCE.abstract",
9723
9773
  functionParameter: [
9724
9774
  {
9725
- name: "formula.functionList.SEQUENCE.functionParameter.number1.name",
9726
- detail: "formula.functionList.SEQUENCE.functionParameter.number1.detail",
9727
- example: "A1:A20",
9775
+ name: "formula.functionList.SEQUENCE.functionParameter.rows.name",
9776
+ detail: "formula.functionList.SEQUENCE.functionParameter.rows.detail",
9777
+ example: "4",
9728
9778
  require: 1,
9729
9779
  repeat: 0
9730
9780
  },
9731
9781
  {
9732
- name: "formula.functionList.SEQUENCE.functionParameter.number2.name",
9733
- detail: "formula.functionList.SEQUENCE.functionParameter.number2.detail",
9734
- example: "A1:A20",
9735
- require: 1,
9782
+ name: "formula.functionList.SEQUENCE.functionParameter.columns.name",
9783
+ detail: "formula.functionList.SEQUENCE.functionParameter.columns.detail",
9784
+ example: "5",
9785
+ require: 0,
9786
+ repeat: 0
9787
+ },
9788
+ {
9789
+ name: "formula.functionList.SEQUENCE.functionParameter.start.name",
9790
+ detail: "formula.functionList.SEQUENCE.functionParameter.start.detail",
9791
+ example: "1",
9792
+ require: 0,
9793
+ repeat: 0
9794
+ },
9795
+ {
9796
+ name: "formula.functionList.SEQUENCE.functionParameter.step.name",
9797
+ detail: "formula.functionList.SEQUENCE.functionParameter.step.detail",
9798
+ example: "1",
9799
+ require: 0,
9736
9800
  repeat: 0
9737
9801
  }
9738
9802
  ]
@@ -9744,16 +9808,9 @@ const PLUGIN_CONFIG_KEY_BASE = "sheets-formula.base.config", defaultPluginBaseCo
9744
9808
  abstract: "formula.functionList.SIGN.abstract",
9745
9809
  functionParameter: [
9746
9810
  {
9747
- name: "formula.functionList.SIGN.functionParameter.number1.name",
9748
- detail: "formula.functionList.SIGN.functionParameter.number1.detail",
9749
- example: "A1:A20",
9750
- require: 1,
9751
- repeat: 0
9752
- },
9753
- {
9754
- name: "formula.functionList.SIGN.functionParameter.number2.name",
9755
- detail: "formula.functionList.SIGN.functionParameter.number2.detail",
9756
- example: "A1:A20",
9811
+ name: "formula.functionList.SIGN.functionParameter.number.name",
9812
+ detail: "formula.functionList.SIGN.functionParameter.number.detail",
9813
+ example: "10",
9757
9814
  require: 1,
9758
9815
  repeat: 0
9759
9816
  }
@@ -14877,6 +14934,14 @@ function formulaDataItemToCellData(formulaDataItem) {
14877
14934
  return checkFormulaId && (cellData.si = si), checkFormulaString && x === 0 && y === 0 && (cellData.f = f2), cellData.f === void 0 && (cellData.f = null), cellData.si === void 0 && (cellData.si = null), cellData;
14878
14935
  }
14879
14936
  __name(formulaDataItemToCellData, "formulaDataItemToCellData");
14937
+ function formulaDataToCellData(formulaData) {
14938
+ const cellData = new ObjectMatrix({});
14939
+ return new ObjectMatrix(formulaData).forValue((r, c, formulaDataItem) => {
14940
+ const cellDataItem = formulaDataItemToCellData(formulaDataItem);
14941
+ cellData.setValue(r, c, cellDataItem);
14942
+ }), cellData.clone();
14943
+ }
14944
+ __name(formulaDataToCellData, "formulaDataToCellData");
14880
14945
  function isFormulaDataItem(cell) {
14881
14946
  const formulaString = (cell == null ? void 0 : cell.f) || "", formulaId = (cell == null ? void 0 : cell.si) || "", checkFormulaString = isFormulaString(formulaString), checkFormulaId = isFormulaId(formulaId);
14882
14947
  return !!(checkFormulaString || checkFormulaId);
@@ -14919,7 +14984,8 @@ let UpdateFormulaController = (_a10 = class extends Disposable {
14919
14984
  this._univerInstanceService.getTypeOfUnitAdded$(UniverInstanceType.UNIVER_DOC),
14920
14985
  this._univerInstanceService.getTypeOfUnitAdded$(UniverInstanceType.UNIVER_SLIDE)
14921
14986
  ).pipe(
14922
- filter((unit) => this._editorService.getEditor(unit.getUnitId()) == null)
14987
+ filter((unit) => this._editorService.getEditor(unit.getUnitId()) == null),
14988
+ filter((unit) => !isInternalEditorID(unit.getUnitId()))
14923
14989
  ).subscribe((unit) => this._handleUnitAdded(unit))
14924
14990
  )
14925
14991
  ), this.disposeWithMe(
@@ -14943,7 +15009,18 @@ let UpdateFormulaController = (_a10 = class extends Disposable {
14943
15009
  [sheetId]: newSheetFormulaData
14944
15010
  }
14945
15011
  };
14946
- this._formulaDataModel.updateArrayFormulaCellData(unitId, sheetId, cellValue), this._formulaDataModel.updateArrayFormulaRange(unitId, sheetId, cellValue), this._commandService.executeCommand(
15012
+ this._commandService.executeCommand(
15013
+ SetRangeValuesMutation.id,
15014
+ {
15015
+ unitId,
15016
+ subUnitId: sheetId,
15017
+ cellValue: formulaDataToCellData(newSheetFormulaData)
15018
+ },
15019
+ {
15020
+ onlyLocal: !0,
15021
+ fromFormula: !0
15022
+ }
15023
+ ), this._formulaDataModel.updateArrayFormulaCellData(unitId, sheetId, cellValue), this._formulaDataModel.updateArrayFormulaRange(unitId, sheetId, cellValue), this._commandService.executeCommand(
14947
15024
  SetFormulaDataMutation.id,
14948
15025
  {
14949
15026
  formulaData: newFormulaData
@@ -15013,6 +15090,15 @@ let UpdateFormulaController = (_a10 = class extends Disposable {
15013
15090
  {
15014
15091
  onlyLocal: !0
15015
15092
  }
15093
+ ), this._commandService.executeCommand(
15094
+ SetFormulaCalculationStartMutation.id,
15095
+ {
15096
+ commands: [],
15097
+ forceCalculation: !0
15098
+ },
15099
+ {
15100
+ onlyLocal: !0
15101
+ }
15016
15102
  );
15017
15103
  }
15018
15104
  _getUpdateFormula(command) {
@@ -16297,8 +16383,9 @@ var __defProp$1 = Object.defineProperty, __getOwnPropDesc$1 = Object.getOwnPrope
16297
16383
  const sheetEditorUnitIds = [DOCS_FORMULA_BAR_EDITOR_UNIT_ID_KEY, DOCS_NORMAL_EDITOR_UNIT_ID_KEY];
16298
16384
  var _a19;
16299
16385
  let PromptController = (_a19 = class extends Disposable {
16300
- constructor(_commandService, _contextService, _textSelectionRenderManager, _editorBridgeService, _formulaPromptService, _lexerTreeBuilder, _renderManagerService, _themeService, _sheetsSelectionsService, _refSelectionsService, _univerInstanceService, _descriptionService, _textSelectionManagerService, _contextMenuService, _editorService) {
16386
+ constructor(_commandService, _contextService, _editorBridgeService, _formulaPromptService, _lexerTreeBuilder, _renderManagerService, _themeService, _sheetsSelectionsService, _refSelectionsService, _univerInstanceService, _descriptionService, _docSelectionManagerService, _contextMenuService, _editorService, _layoutService) {
16301
16387
  super();
16388
+ __publicField(this, "_listenInputCache", /* @__PURE__ */ new Set());
16302
16389
  __publicField(this, "_formulaRefColors", []);
16303
16390
  __publicField(this, "_previousSequenceNodes");
16304
16391
  __publicField(this, "_previousRangesCount", 0);
@@ -16316,7 +16403,7 @@ let PromptController = (_a19 = class extends Disposable {
16316
16403
  __publicField(this, "_currentlyWorkingRefRenderer", null);
16317
16404
  __publicField(this, "_selectionsChangeDisposables");
16318
16405
  __publicField(this, "_isSelectingMode", !1);
16319
- this._commandService = _commandService, this._contextService = _contextService, this._textSelectionRenderManager = _textSelectionRenderManager, this._editorBridgeService = _editorBridgeService, this._formulaPromptService = _formulaPromptService, this._lexerTreeBuilder = _lexerTreeBuilder, this._renderManagerService = _renderManagerService, this._themeService = _themeService, this._sheetsSelectionsService = _sheetsSelectionsService, this._refSelectionsService = _refSelectionsService, this._univerInstanceService = _univerInstanceService, this._descriptionService = _descriptionService, this._textSelectionManagerService = _textSelectionManagerService, this._contextMenuService = _contextMenuService, this._editorService = _editorService, this._initialize();
16406
+ this._commandService = _commandService, this._contextService = _contextService, this._editorBridgeService = _editorBridgeService, this._formulaPromptService = _formulaPromptService, this._lexerTreeBuilder = _lexerTreeBuilder, this._renderManagerService = _renderManagerService, this._themeService = _themeService, this._sheetsSelectionsService = _sheetsSelectionsService, this._refSelectionsService = _refSelectionsService, this._univerInstanceService = _univerInstanceService, this._descriptionService = _descriptionService, this._docSelectionManagerService = _docSelectionManagerService, this._contextMenuService = _contextMenuService, this._editorService = _editorService, this._layoutService = _layoutService, this._initialize();
16320
16407
  }
16321
16408
  // TODO@wzhudev: selection render service would be a render unit, we we cannot
16322
16409
  // easily access it here.
@@ -16359,7 +16446,7 @@ let PromptController = (_a19 = class extends Disposable {
16359
16446
  }
16360
16447
  _initialCursorSync() {
16361
16448
  this.disposeWithMe(
16362
- this._textSelectionManagerService.textSelection$.subscribe((params) => {
16449
+ this._docSelectionManagerService.textSelection$.subscribe((params) => {
16363
16450
  var _a23;
16364
16451
  if ((params == null ? void 0 : params.unitId) == null)
16365
16452
  return;
@@ -16373,13 +16460,20 @@ let PromptController = (_a19 = class extends Disposable {
16373
16460
  }
16374
16461
  _initialEditorInputChange() {
16375
16462
  const arrows = [KeyCode.ARROW_DOWN, KeyCode.ARROW_UP, KeyCode.ARROW_LEFT, KeyCode.ARROW_RIGHT, KeyCode.CTRL, KeyCode.SHIFT];
16376
- this.disposeWithMe(
16377
- this._textSelectionRenderManager.onInputBefore$.subscribe((param) => {
16378
- this._previousSequenceNodes = null, this._previousInsertRefStringIndex = null, this._selectionRenderService.setSkipLastEnabled(!0);
16379
- const event = param == null ? void 0 : param.event;
16380
- event && (arrows.includes(event.which) ? this._inputPanelState = 2 : (this._arrowMoveActionState !== 1 && (this._arrowMoveActionState = 2), this._inputPanelState = 1), event.which !== KeyCode.F4 && (this._userCursorMove = !1));
16381
- })
16382
- );
16463
+ this._univerInstanceService.getCurrentTypeOfUnit$(UniverInstanceType.UNIVER_DOC).subscribe((documentDataModel) => {
16464
+ var _a23;
16465
+ const unitId = documentDataModel == null ? void 0 : documentDataModel.getUnitId();
16466
+ if (unitId == null || this._listenInputCache.has(unitId) || this._editorService.getEditor(unitId) == null)
16467
+ return;
16468
+ const docSelectionRenderService = (_a23 = this._renderManagerService.getRenderById(unitId)) == null ? void 0 : _a23.with(DocSelectionRenderService);
16469
+ docSelectionRenderService && this.disposeWithMe(
16470
+ docSelectionRenderService.onInputBefore$.subscribe((param) => {
16471
+ this._previousSequenceNodes = null, this._previousInsertRefStringIndex = null, this._selectionRenderService.setSkipLastEnabled(!0);
16472
+ const event = param == null ? void 0 : param.event;
16473
+ event && (arrows.includes(event.which) ? this._inputPanelState = 2 : (this._arrowMoveActionState !== 1 && (this._arrowMoveActionState = 2), this._inputPanelState = 1), event.which !== KeyCode.F4 && (this._userCursorMove = !1));
16474
+ })
16475
+ ), this._listenInputCache.add(unitId);
16476
+ });
16383
16477
  }
16384
16478
  _closeRangePromptWhenEditorInvisible() {
16385
16479
  this.disposeWithMe(
@@ -16460,7 +16554,7 @@ let PromptController = (_a19 = class extends Disposable {
16460
16554
  _initAcceptFormula() {
16461
16555
  this.disposeWithMe(
16462
16556
  this._formulaPromptService.acceptFormulaName$.subscribe((formulaString) => {
16463
- const activeRange = this._textSelectionManagerService.getActiveTextRangeWithStyle();
16557
+ const activeRange = this._docSelectionManagerService.getActiveTextRange();
16464
16558
  if (activeRange == null) {
16465
16559
  this._hideFunctionPanel();
16466
16560
  return;
@@ -16487,7 +16581,7 @@ let PromptController = (_a19 = class extends Disposable {
16487
16581
  );
16488
16582
  }
16489
16583
  _changeFunctionPanelState() {
16490
- const activeRange = this._textSelectionManagerService.getActiveTextRangeWithStyle();
16584
+ const activeRange = this._docSelectionManagerService.getActiveTextRange();
16491
16585
  if (activeRange == null) {
16492
16586
  this._hideFunctionPanel();
16493
16587
  return;
@@ -16550,7 +16644,7 @@ let PromptController = (_a19 = class extends Disposable {
16550
16644
  * @returns Return the character under the current cursor in the editor.
16551
16645
  */
16552
16646
  _getCurrentChar() {
16553
- const activeRange = this._textSelectionManagerService.getActiveTextRangeWithStyle();
16647
+ const activeRange = this._docSelectionManagerService.getActiveTextRange();
16554
16648
  if (activeRange == null)
16555
16649
  return;
16556
16650
  const { startOffset } = activeRange, config = this._getCurrentBodyDataStreamAndOffset();
@@ -16600,7 +16694,7 @@ let PromptController = (_a19 = class extends Disposable {
16600
16694
  this._contextService.setContextValue(FOCUSING_EDITOR_INPUT_FORMULA, !0), this._contextService.setContextValue(DISABLE_NORMAL_SELECTIONS, !0), this._contextService.setContextValue(UNI_DISABLE_CHANGING_FOCUS_KEY, !0);
16601
16695
  const lastSequenceNodes = this._lexerTreeBuilder.sequenceNodesBuilder(config.dataStream) || [];
16602
16696
  this._formulaPromptService.setSequenceNodes(lastSequenceNodes);
16603
- const activeRange = this._textSelectionManagerService.getActiveTextRangeWithStyle();
16697
+ const activeRange = this._docSelectionManagerService.getActiveTextRange();
16604
16698
  if (activeRange == null)
16605
16699
  return;
16606
16700
  const { startOffset } = activeRange;
@@ -16803,7 +16897,7 @@ let PromptController = (_a19 = class extends Disposable {
16803
16897
  let dataStream = generateStringWithSequence(sequenceNodes);
16804
16898
  const { textRuns, refSelections } = this._buildTextRuns(sequenceNodes);
16805
16899
  this._isSelectionMovingRefSelections = refSelections, this._allSelectionRenderServices.forEach((r) => this._updateRefSelectionStyle(r, this._isSelectionMovingRefSelections));
16806
- const activeRange = this._textSelectionManagerService.getActiveTextRangeWithStyle();
16900
+ const activeRange = this._docSelectionManagerService.getActiveTextRange();
16807
16901
  if (activeRange == null)
16808
16902
  return;
16809
16903
  this._currentInsertRefStringIndex = textSelectionOffset, editorUnitId == null && (editorUnitId = this._univerInstanceService.getCurrentUniverDocInstance().getUnitId()), this._fitEditorSize();
@@ -16828,22 +16922,20 @@ let PromptController = (_a19 = class extends Disposable {
16828
16922
  ],
16829
16923
  segmentId: null,
16830
16924
  options: { fromSelection }
16831
- }), this._textSelectionManagerService.replaceTextRanges([
16925
+ }), this._docSelectionManagerService.replaceTextRanges([
16832
16926
  {
16833
16927
  startOffset: textSelectionOffset + 1 - offset,
16834
16928
  endOffset: textSelectionOffset + 1 - offset,
16835
16929
  style
16836
16930
  }
16837
16931
  ], !0, { fromSelection })) : (this._updateEditorModel(`${formulaString}\r
16838
- `, textRuns), this._textSelectionManagerService.replaceTextRanges([
16932
+ `, textRuns), this._docSelectionManagerService.replaceTextRanges([
16839
16933
  {
16840
16934
  startOffset: textSelectionOffset + 1 - offset,
16841
16935
  endOffset: textSelectionOffset + 1 - offset,
16842
16936
  style
16843
16937
  }
16844
- ], !0, { fromSelection })), setTimeout(() => {
16845
- this._textSelectionRenderManager.focus();
16846
- }, 0);
16938
+ ], !0, { fromSelection })), this._layoutService.focus();
16847
16939
  }
16848
16940
  _fitEditorSize() {
16849
16941
  const editorUnitId = this._univerInstanceService.getCurrentUniverDocInstance().getUnitId();
@@ -17129,7 +17221,7 @@ let PromptController = (_a19 = class extends Disposable {
17129
17221
  * Absolute range, triggered by F4
17130
17222
  */
17131
17223
  _changeRefString() {
17132
- const activeRange = this._textSelectionManagerService.getActiveTextRangeWithStyle();
17224
+ const activeRange = this._docSelectionManagerService.getActiveTextRange();
17133
17225
  if (activeRange == null)
17134
17226
  return;
17135
17227
  const { startOffset } = activeRange, strIndex = startOffset - 2, nodeIndex = this._formulaPromptService.getCurrentSequenceNodeIndex(strIndex), node = this._formulaPromptService.getCurrentSequenceNodeByIndex(nodeIndex);
@@ -17180,19 +17272,19 @@ PromptController = __decorateClass$1([
17180
17272
  OnLifecycle(LifecycleStages.Steady, PromptController),
17181
17273
  __decorateParam$1(0, ICommandService),
17182
17274
  __decorateParam$1(1, IContextService),
17183
- __decorateParam$1(2, ITextSelectionRenderManager),
17184
- __decorateParam$1(3, Inject(IEditorBridgeService)),
17185
- __decorateParam$1(4, Inject(IFormulaPromptService)),
17186
- __decorateParam$1(5, Inject(LexerTreeBuilder)),
17187
- __decorateParam$1(6, IRenderManagerService),
17188
- __decorateParam$1(7, Inject(ThemeService)),
17189
- __decorateParam$1(8, Inject(SheetsSelectionsService)),
17190
- __decorateParam$1(9, IRefSelectionsService),
17191
- __decorateParam$1(10, IUniverInstanceService),
17192
- __decorateParam$1(11, Inject(IDescriptionService)),
17193
- __decorateParam$1(12, Inject(TextSelectionManagerService)),
17194
- __decorateParam$1(13, IContextMenuService),
17195
- __decorateParam$1(14, IEditorService)
17275
+ __decorateParam$1(2, Inject(IEditorBridgeService)),
17276
+ __decorateParam$1(3, Inject(IFormulaPromptService)),
17277
+ __decorateParam$1(4, Inject(LexerTreeBuilder)),
17278
+ __decorateParam$1(5, IRenderManagerService),
17279
+ __decorateParam$1(6, Inject(ThemeService)),
17280
+ __decorateParam$1(7, Inject(SheetsSelectionsService)),
17281
+ __decorateParam$1(8, IRefSelectionsService),
17282
+ __decorateParam$1(9, IUniverInstanceService),
17283
+ __decorateParam$1(10, Inject(IDescriptionService)),
17284
+ __decorateParam$1(11, Inject(DocSelectionManagerService)),
17285
+ __decorateParam$1(12, IContextMenuService),
17286
+ __decorateParam$1(13, IEditorService),
17287
+ __decorateParam$1(14, ILayoutService)
17196
17288
  ], PromptController);
17197
17289
  var __defProp2 = Object.defineProperty, __getOwnPropDesc = Object.getOwnPropertyDescriptor, __defNormalProp2 = /* @__PURE__ */ __name((obj, key, value) => key in obj ? __defProp2(obj, key, { enumerable: !0, configurable: !0, writable: !0, value }) : obj[key] = value, "__defNormalProp"), __decorateClass = /* @__PURE__ */ __name((decorators, target, key, kind) => {
17198
17290
  for (var result = kind > 1 ? void 0 : kind ? __getOwnPropDesc(target, key) : target, i = decorators.length - 1, decorator; i >= 0; i--)
@@ -17212,7 +17304,7 @@ let UniverRemoteSheetsFormulaPlugin = (_a20 = class extends Plugin {
17212
17304
  );
17213
17305
  }
17214
17306
  }, __name(_a20, "UniverRemoteSheetsFormulaPlugin"), _a20);
17215
- __publicField2(UniverRemoteSheetsFormulaPlugin, "pluginName", "SHEETS_FORMULA_REMOTE_PLUGIN");
17307
+ __publicField2(UniverRemoteSheetsFormulaPlugin, "pluginName", "SHEET_FORMULA_REMOTE_PLUGIN");
17216
17308
  __publicField2(UniverRemoteSheetsFormulaPlugin, "type", UniverInstanceType.UNIVER_SHEET);
17217
17309
  UniverRemoteSheetsFormulaPlugin = __decorateClass([
17218
17310
  DependentOn(UniverFormulaEnginePlugin),