@univerjs/sheets-numfmt-ui 0.24.0 → 0.25.0

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 (90) hide show
  1. package/lib/cjs/index.js +65 -65
  2. package/lib/cjs/locale/ar-SA.js +44 -0
  3. package/lib/cjs/locale/ca-ES.js +7 -3
  4. package/lib/cjs/locale/de-DE.js +44 -0
  5. package/lib/cjs/locale/en-US.js +7 -3
  6. package/lib/cjs/locale/es-ES.js +7 -3
  7. package/lib/cjs/locale/fa-IR.js +7 -3
  8. package/lib/cjs/locale/fr-FR.js +7 -3
  9. package/lib/cjs/locale/id-ID.js +44 -0
  10. package/lib/cjs/locale/it-IT.js +44 -0
  11. package/lib/cjs/locale/ja-JP.js +7 -3
  12. package/lib/cjs/locale/ko-KR.js +7 -3
  13. package/lib/cjs/locale/pl-PL.js +44 -0
  14. package/lib/cjs/locale/pt-BR.js +44 -0
  15. package/lib/cjs/locale/ru-RU.js +7 -3
  16. package/lib/cjs/locale/sk-SK.js +7 -3
  17. package/lib/cjs/locale/vi-VN.js +7 -3
  18. package/lib/cjs/locale/zh-CN.js +7 -3
  19. package/lib/cjs/locale/zh-HK.js +44 -0
  20. package/lib/cjs/locale/zh-TW.js +7 -3
  21. package/lib/es/index.js +65 -65
  22. package/lib/es/locale/ar-SA.js +43 -0
  23. package/lib/es/locale/ca-ES.js +7 -3
  24. package/lib/es/locale/de-DE.js +43 -0
  25. package/lib/es/locale/en-US.js +7 -3
  26. package/lib/es/locale/es-ES.js +7 -3
  27. package/lib/es/locale/fa-IR.js +7 -3
  28. package/lib/es/locale/fr-FR.js +7 -3
  29. package/lib/es/locale/id-ID.js +43 -0
  30. package/lib/es/locale/it-IT.js +43 -0
  31. package/lib/es/locale/ja-JP.js +7 -3
  32. package/lib/es/locale/ko-KR.js +7 -3
  33. package/lib/es/locale/pl-PL.js +43 -0
  34. package/lib/es/locale/pt-BR.js +43 -0
  35. package/lib/es/locale/ru-RU.js +7 -3
  36. package/lib/es/locale/sk-SK.js +7 -3
  37. package/lib/es/locale/vi-VN.js +7 -3
  38. package/lib/es/locale/zh-CN.js +7 -3
  39. package/lib/es/locale/zh-HK.js +43 -0
  40. package/lib/es/locale/zh-TW.js +7 -3
  41. package/lib/index.js +65 -65
  42. package/lib/locale/ar-SA.js +43 -0
  43. package/lib/locale/ca-ES.js +7 -3
  44. package/lib/locale/de-DE.js +43 -0
  45. package/lib/locale/en-US.js +7 -3
  46. package/lib/locale/es-ES.js +7 -3
  47. package/lib/locale/fa-IR.js +7 -3
  48. package/lib/locale/fr-FR.js +7 -3
  49. package/lib/locale/id-ID.js +43 -0
  50. package/lib/locale/it-IT.js +43 -0
  51. package/lib/locale/ja-JP.js +7 -3
  52. package/lib/locale/ko-KR.js +7 -3
  53. package/lib/locale/pl-PL.js +43 -0
  54. package/lib/locale/pt-BR.js +43 -0
  55. package/lib/locale/ru-RU.js +7 -3
  56. package/lib/locale/sk-SK.js +7 -3
  57. package/lib/locale/vi-VN.js +7 -3
  58. package/lib/locale/zh-CN.js +7 -3
  59. package/lib/locale/zh-HK.js +43 -0
  60. package/lib/locale/zh-TW.js +7 -3
  61. package/lib/types/locale/ar-SA.d.ts +18 -0
  62. package/lib/types/locale/de-DE.d.ts +18 -0
  63. package/lib/types/locale/en-US.d.ts +37 -35
  64. package/lib/types/locale/id-ID.d.ts +18 -0
  65. package/lib/types/locale/it-IT.d.ts +18 -0
  66. package/lib/types/locale/pl-PL.d.ts +18 -0
  67. package/lib/types/locale/pt-BR.d.ts +18 -0
  68. package/lib/types/locale/zh-HK.d.ts +18 -0
  69. package/lib/types/views/components/MoreNumfmtType.d.ts +2 -2
  70. package/lib/umd/index.js +1 -1
  71. package/lib/umd/locale/ar-SA.js +1 -0
  72. package/lib/umd/locale/ca-ES.js +1 -1
  73. package/lib/umd/locale/de-DE.js +1 -0
  74. package/lib/umd/locale/en-US.js +1 -1
  75. package/lib/umd/locale/es-ES.js +1 -1
  76. package/lib/umd/locale/fa-IR.js +1 -1
  77. package/lib/umd/locale/fr-FR.js +1 -1
  78. package/lib/umd/locale/id-ID.js +1 -0
  79. package/lib/umd/locale/it-IT.js +1 -0
  80. package/lib/umd/locale/ja-JP.js +1 -1
  81. package/lib/umd/locale/ko-KR.js +1 -1
  82. package/lib/umd/locale/pl-PL.js +1 -0
  83. package/lib/umd/locale/pt-BR.js +1 -0
  84. package/lib/umd/locale/ru-RU.js +1 -1
  85. package/lib/umd/locale/sk-SK.js +1 -1
  86. package/lib/umd/locale/vi-VN.js +1 -1
  87. package/lib/umd/locale/zh-CN.js +1 -1
  88. package/lib/umd/locale/zh-HK.js +1 -0
  89. package/lib/umd/locale/zh-TW.js +1 -1
  90. package/package.json +12 -12
package/lib/es/index.js CHANGED
@@ -1,6 +1,6 @@
1
- import { CellValueType, CommandType, DEFAULT_TEXT_FORMAT_EXCEL, DependentOn, Disposable, DisposableCollection, ICommandService, IConfigService, ILocalStorageService, IUniverInstanceService, Inject, Injector, InterceptorEffectEnum, LocaleService, Optional, Plugin, Range, ThemeService, Tools, UniverInstanceType, fromCallback, getNumfmtParseValueFilter, isDefaultFormat, isPatternEqualWithoutDecimal, isRealNum, isTextFormat, merge, numfmt, registerDependencies, toDisposable, touchDependencies, willLoseNumericPrecision } from "@univerjs/core";
1
+ import { CellValueType, CommandType, DEFAULT_TEXT_FORMAT_EXCEL, DependentOn, Disposable, DisposableCollection, ICommandService, IConfigService, ILocalStorageService, IUniverInstanceService, Inject, Injector, InterceptorEffectEnum, LocaleService, Optional, Plugin, Range, ThemeService, Tools, UniverInstanceType, currencySymbols, fromCallback, getNumfmtParseValueFilter, isDefaultFormat, isPatternEqualWithoutDecimal, isRealNum, isTextFormat, merge, numfmt, registerDependencies, toDisposable, touchDependencies, willLoseNumericPrecision } from "@univerjs/core";
2
2
  import { IRenderManagerService } from "@univerjs/engine-render";
3
- import { AddDecimalCommand, CURRENCYFORMAT, DATEFMTLISG, NUMBERFORMAT, SHEETS_NUMFMT_PLUGIN_CONFIG_KEY, SetCurrencyCommand, SetNumfmtCommand, SetPercentCommand, SheetsNumfmtCellContentController, SubtractDecimalCommand, UniverSheetsNumfmtPlugin, currencySymbols, getCurrencyFormatOptions, getCurrencySymbolByLocale, getCurrencySymbolIconByLocale, getCurrencyType, getDateFormatOptions, getDecimalFromPattern, getNumberFormatOptions, getPatternPreview, getPatternPreviewIgnoreGeneral, getPatternType, isPatternHasDecimal, localeCurrencySymbolMap, setPatternDecimal } from "@univerjs/sheets-numfmt";
3
+ import { AddDecimalCommand, CURRENCYFORMAT, DATEFMTLISG, NUMBERFORMAT, SHEETS_NUMFMT_PLUGIN_CONFIG_KEY, SetCurrencyCommand, SetNumfmtCommand, SetPercentCommand, SheetsNumfmtCellContentController, SubtractDecimalCommand, UniverSheetsNumfmtPlugin, getCurrencyFormatOptions, getCurrencySymbolByLocale, getCurrencySymbolIconByLocale, getCurrencyType, getDateFormatOptions, getDecimalFromPattern, getNumberFormatOptions, getPatternPreview, getPatternPreviewIgnoreGeneral, getPatternType, isPatternHasDecimal, localeCurrencySymbolMap, setPatternDecimal } from "@univerjs/sheets-numfmt";
4
4
  import { CellAlertManagerService, CellAlertType, HoverManagerService, IEditorBridgeService, IRepeatLastActionService, RepeatLastActionPermission, SheetSkeletonManagerService, UniverSheetsUIPlugin, deriveStateFromActiveSheet$, getCurrentRangeDisable$ } from "@univerjs/sheets-ui";
5
5
  import { AFTER_CELL_EDIT, BEFORE_CELL_EDIT, INTERCEPTOR_POINT, INumfmtService, RangeProtectionPermissionEditPoint, RemoveNumfmtMutation, SetNumfmtMutation, SetRangeValuesCommand, SheetInterceptorService, SheetsSelectionsService, WorkbookEditablePermission, WorksheetEditPermission, WorksheetSetCellStylePermission, factoryRemoveNumfmtUndoMutation, factorySetNumfmtUndoMutation, transformCellsToRange } from "@univerjs/sheets";
6
6
  import { ComponentManager, ILayoutService, IMenuManagerService, ISidebarService, IZenZoneService, MenuItemType, RibbonStartGroup, getMenuHiddenObservable, useDependency } from "@univerjs/ui";
@@ -14,7 +14,7 @@ import { stripErrorMargin } from "@univerjs/engine-formula";
14
14
 
15
15
  //#region package.json
16
16
  var name = "@univerjs/sheets-numfmt-ui";
17
- var version = "0.24.0";
17
+ var version = "0.25.0";
18
18
 
19
19
  //#endregion
20
20
  //#region src/config/config.ts
@@ -23,7 +23,7 @@ const configSymbol = Symbol(SHEETS_NUMFMT_UI_PLUGIN_CONFIG_KEY);
23
23
  const defaultPluginConfig = {};
24
24
 
25
25
  //#endregion
26
- //#region \0@oxc-project+runtime@0.129.0/helpers/decorateParam.js
26
+ //#region \0@oxc-project+runtime@0.133.0/helpers/esm/decorateParam.js
27
27
  function __decorateParam(paramIndex, decorator) {
28
28
  return function(target, key) {
29
29
  decorator(target, key, paramIndex);
@@ -31,7 +31,7 @@ function __decorateParam(paramIndex, decorator) {
31
31
  }
32
32
 
33
33
  //#endregion
34
- //#region \0@oxc-project+runtime@0.129.0/helpers/decorate.js
34
+ //#region \0@oxc-project+runtime@0.133.0/helpers/esm/decorate.js
35
35
  function __decorate(decorators, target, key, desc) {
36
36
  var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
37
37
  if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
@@ -89,8 +89,8 @@ let NumfmtAlertRenderController = class NumfmtAlertRenderController extends Disp
89
89
  }
90
90
  this._cellAlertManagerService.showAlert({
91
91
  type: CellAlertType.ERROR,
92
- title: this._localeService.t("info.error"),
93
- message: this._localeService.t("info.forceStringInfo"),
92
+ title: this._localeService.t("sheets-numfmt-ui.info.error"),
93
+ message: this._localeService.t("sheets-numfmt-ui.info.forceStringInfo"),
94
94
  location,
95
95
  width: 200,
96
96
  height: 74,
@@ -349,7 +349,7 @@ const AccountingPanel = (props) => {
349
349
  className: "option",
350
350
  children: [/* @__PURE__ */ jsx("div", {
351
351
  className: "univer-text-sm univer-text-gray-400",
352
- children: t("sheet.numfmt.decimalLength")
352
+ children: t("sheets-numfmt-ui.decimalLength")
353
353
  }), /* @__PURE__ */ jsx("div", {
354
354
  className: "univer-mt-2 univer-w-32",
355
355
  children: /* @__PURE__ */ jsx(InputNumber, {
@@ -365,7 +365,7 @@ const AccountingPanel = (props) => {
365
365
  className: "option",
366
366
  children: [/* @__PURE__ */ jsx("div", {
367
367
  className: "univer-text-sm univer-text-gray-400",
368
- children: t("sheet.numfmt.currencyType")
368
+ children: t("sheets-numfmt-ui.currencyType")
369
369
  }), /* @__PURE__ */ jsx("div", {
370
370
  className: "univer-mt-2 univer-w-36",
371
371
  children: /* @__PURE__ */ jsx(Select, {
@@ -377,7 +377,7 @@ const AccountingPanel = (props) => {
377
377
  })]
378
378
  }), /* @__PURE__ */ jsx("div", {
379
379
  className: "univer-mt-4 univer-text-sm univer-text-gray-400",
380
- children: t("sheet.numfmt.accountingDes")
380
+ children: t("sheets-numfmt-ui.accountingDes")
381
381
  })] });
382
382
  };
383
383
 
@@ -425,7 +425,7 @@ const CurrencyPanel = (props) => {
425
425
  className: "option",
426
426
  children: [/* @__PURE__ */ jsx("div", {
427
427
  className: "univer-text-sm univer-text-gray-400",
428
- children: t("sheet.numfmt.decimalLength")
428
+ children: t("sheets-numfmt-ui.decimalLength")
429
429
  }), /* @__PURE__ */ jsx("div", {
430
430
  className: "univer-mt-2 univer-w-32",
431
431
  children: /* @__PURE__ */ jsx(InputNumber, {
@@ -439,7 +439,7 @@ const CurrencyPanel = (props) => {
439
439
  className: "option",
440
440
  children: [/* @__PURE__ */ jsx("div", {
441
441
  className: "univer-text-sm univer-text-gray-400",
442
- children: t("sheet.numfmt.currencyType")
442
+ children: t("sheets-numfmt-ui.currencyType")
443
443
  }), /* @__PURE__ */ jsx("div", {
444
444
  className: "univer-mt-2 univer-w-36",
445
445
  children: /* @__PURE__ */ jsx(Select, {
@@ -452,7 +452,7 @@ const CurrencyPanel = (props) => {
452
452
  }),
453
453
  /* @__PURE__ */ jsx("div", {
454
454
  className: "label univer-mt-4",
455
- children: t("sheet.numfmt.negType")
455
+ children: t("sheets-numfmt-ui.negType")
456
456
  }),
457
457
  /* @__PURE__ */ jsx("div", {
458
458
  className: "univer-mt-2",
@@ -464,7 +464,7 @@ const CurrencyPanel = (props) => {
464
464
  }),
465
465
  /* @__PURE__ */ jsx("div", {
466
466
  className: "univer-mt-4 univer-text-sm univer-text-gray-400",
467
- children: t("sheet.numfmt.currencyDes")
467
+ children: t("sheets-numfmt-ui.currencyDes")
468
468
  })
469
469
  ] });
470
470
  };
@@ -513,10 +513,10 @@ function CustomFormat(props) {
513
513
  return /* @__PURE__ */ jsxs("div", { children: [
514
514
  /* @__PURE__ */ jsx("div", {
515
515
  className: "univer-mt-4 univer-text-sm univer-text-gray-400",
516
- children: localeService.t("sheet.numfmt.customFormat")
516
+ children: localeService.t("sheets-numfmt-ui.customFormat")
517
517
  }),
518
518
  /* @__PURE__ */ jsx(Input, {
519
- placeholder: localeService.t("sheet.numfmt.customFormat"),
519
+ placeholder: localeService.t("sheets-numfmt-ui.customFormat"),
520
520
  onBlur: handleBlur,
521
521
  value: pattern,
522
522
  onChange: setPattern,
@@ -535,7 +535,7 @@ function CustomFormat(props) {
535
535
  }),
536
536
  /* @__PURE__ */ jsx("div", {
537
537
  className: "univer-mt-3 univer-text-sm univer-text-gray-600 dark:!univer-text-gray-200",
538
- children: localeService.t("sheet.numfmt.customFormatDes")
538
+ children: localeService.t("sheets-numfmt-ui.customFormatDes")
539
539
  })
540
540
  ] });
541
541
  }
@@ -570,7 +570,7 @@ function DatePanel(props) {
570
570
  return /* @__PURE__ */ jsxs("div", { children: [
571
571
  /* @__PURE__ */ jsx("div", {
572
572
  className: "univer-mt-4 univer-text-sm univer-text-gray-400",
573
- children: localeService.t("sheet.numfmt.dateType")
573
+ children: localeService.t("sheets-numfmt-ui.dateType")
574
574
  }),
575
575
  /* @__PURE__ */ jsx("div", {
576
576
  className: "univer-mt-2",
@@ -582,7 +582,7 @@ function DatePanel(props) {
582
582
  }),
583
583
  /* @__PURE__ */ jsx("div", {
584
584
  className: "univer-mt-3.5 univer-text-sm/5 univer-text-gray-600 dark:!univer-text-gray-200",
585
- children: localeService.t("sheet.numfmt.dateDes")
585
+ children: localeService.t("sheets-numfmt-ui.dateDes")
586
586
  })
587
587
  ] });
588
588
  }
@@ -595,7 +595,7 @@ const GeneralPanel = (props) => {
595
595
  props.action.current = () => "";
596
596
  return /* @__PURE__ */ jsx("div", { children: /* @__PURE__ */ jsx("div", {
597
597
  className: "univer-mt-3.5 univer-text-sm/5 univer-text-gray-600 dark:!univer-text-gray-200",
598
- children: t("sheet.numfmt.generalDes")
598
+ children: t("sheets-numfmt-ui.generalDes")
599
599
  }) });
600
600
  };
601
601
 
@@ -626,7 +626,7 @@ function ThousandthPercentilePanel(props) {
626
626
  return /* @__PURE__ */ jsxs("div", { children: [
627
627
  /* @__PURE__ */ jsx("div", {
628
628
  className: "univer-mt-4 univer-text-sm univer-text-gray-400",
629
- children: localeService.t("sheet.numfmt.decimalLength")
629
+ children: localeService.t("sheets-numfmt-ui.decimalLength")
630
630
  }),
631
631
  /* @__PURE__ */ jsx("div", {
632
632
  className: "univer-mt-2",
@@ -640,7 +640,7 @@ function ThousandthPercentilePanel(props) {
640
640
  }),
641
641
  /* @__PURE__ */ jsxs("div", {
642
642
  className: "univer-mt-4 univer-text-sm univer-text-gray-400",
643
- children: [" ", localeService.t("sheet.numfmt.negType")]
643
+ children: [" ", localeService.t("sheets-numfmt-ui.negType")]
644
644
  }),
645
645
  /* @__PURE__ */ jsx("div", {
646
646
  className: "univer-mt-2",
@@ -652,7 +652,7 @@ function ThousandthPercentilePanel(props) {
652
652
  }),
653
653
  /* @__PURE__ */ jsx("div", {
654
654
  className: "univer-mt-3.5 univer-text-sm/5 univer-text-gray-600 dark:!univer-text-gray-200",
655
- children: localeService.t("sheet.numfmt.thousandthPercentileDes")
655
+ children: localeService.t("sheets-numfmt-ui.thousandthPercentileDes")
656
656
  })
657
657
  ] });
658
658
  }
@@ -667,27 +667,27 @@ const SheetNumfmtPanel = (props) => {
667
667
  const nextTick = useNextTick();
668
668
  const typeOptions = useMemo(() => [
669
669
  {
670
- label: "sheet.numfmt.general",
670
+ label: "sheets-numfmt-ui.general",
671
671
  component: GeneralPanel
672
672
  },
673
673
  {
674
- label: "sheet.numfmt.accounting",
674
+ label: "sheets-numfmt-ui.accounting",
675
675
  component: AccountingPanel
676
676
  },
677
677
  {
678
- label: "sheet.numfmt.currency",
678
+ label: "sheets-numfmt-ui.currency",
679
679
  component: CurrencyPanel
680
680
  },
681
681
  {
682
- label: "sheet.numfmt.date",
682
+ label: "sheets-numfmt-ui.date",
683
683
  component: DatePanel
684
684
  },
685
685
  {
686
- label: "sheet.numfmt.thousandthPercentile",
686
+ label: "sheets-numfmt-ui.thousandthPercentile",
687
687
  component: ThousandthPercentilePanel
688
688
  },
689
689
  {
690
- label: "sheet.numfmt.customFormat",
690
+ label: "sheets-numfmt-ui.customFormat",
691
691
  component: CustomFormat
692
692
  }
693
693
  ].map((item) => ({
@@ -757,7 +757,7 @@ const SheetNumfmtPanel = (props) => {
757
757
  children: [/* @__PURE__ */ jsxs("div", { children: [
758
758
  /* @__PURE__ */ jsx("div", {
759
759
  className: "univer-mt-3.5 univer-text-sm univer-text-gray-400",
760
- children: t("sheet.numfmt.numfmtType")
760
+ children: t("sheets-numfmt-ui.numfmtType")
761
761
  }),
762
762
  /* @__PURE__ */ jsx("div", {
763
763
  className: "univer-mt-2",
@@ -780,18 +780,18 @@ const SheetNumfmtPanel = (props) => {
780
780
  children: [/* @__PURE__ */ jsx(Button, {
781
781
  onClick: handleCancel,
782
782
  className: "univer-mr-3",
783
- children: t("sheet.numfmt.cancel")
783
+ children: t("sheets-numfmt-ui.cancel")
784
784
  }), /* @__PURE__ */ jsx(Button, {
785
785
  variant: "primary",
786
786
  onClick: handleConfirm,
787
- children: t("sheet.numfmt.confirm")
787
+ children: t("sheets-numfmt-ui.confirm")
788
788
  })]
789
789
  })]
790
790
  });
791
791
  };
792
792
 
793
793
  //#endregion
794
- //#region \0@oxc-project+runtime@0.129.0/helpers/typeof.js
794
+ //#region \0@oxc-project+runtime@0.133.0/helpers/esm/typeof.js
795
795
  function _typeof(o) {
796
796
  "@babel/helpers - typeof";
797
797
  return _typeof = "function" == typeof Symbol && "symbol" == typeof Symbol.iterator ? function(o) {
@@ -802,7 +802,7 @@ function _typeof(o) {
802
802
  }
803
803
 
804
804
  //#endregion
805
- //#region \0@oxc-project+runtime@0.129.0/helpers/toPrimitive.js
805
+ //#region \0@oxc-project+runtime@0.133.0/helpers/esm/toPrimitive.js
806
806
  function toPrimitive(t, r) {
807
807
  if ("object" != _typeof(t) || !t) return t;
808
808
  var e = t[Symbol.toPrimitive];
@@ -815,14 +815,14 @@ function toPrimitive(t, r) {
815
815
  }
816
816
 
817
817
  //#endregion
818
- //#region \0@oxc-project+runtime@0.129.0/helpers/toPropertyKey.js
818
+ //#region \0@oxc-project+runtime@0.133.0/helpers/esm/toPropertyKey.js
819
819
  function toPropertyKey(t) {
820
820
  var i = toPrimitive(t, "string");
821
821
  return "symbol" == _typeof(i) ? i : i + "";
822
822
  }
823
823
 
824
824
  //#endregion
825
- //#region \0@oxc-project+runtime@0.129.0/helpers/defineProperty.js
825
+ //#region \0@oxc-project+runtime@0.133.0/helpers/esm/defineProperty.js
826
826
  function _defineProperty(e, r, t) {
827
827
  return (r = toPropertyKey(r)) in e ? Object.defineProperty(e, r, {
828
828
  value: t,
@@ -913,7 +913,7 @@ let SheetNumfmtUIController = class SheetNumfmtUIController extends Disposable {
913
913
  }
914
914
  };
915
915
  this._sidebarDisposable = sidebarService.open({
916
- header: { title: localeService.t("sheet.numfmt.title") },
916
+ header: { title: localeService.t("sheets-numfmt-ui.title") },
917
917
  children: {
918
918
  label: SHEET_NUMFMT_PANEL,
919
919
  ...props
@@ -1248,63 +1248,63 @@ function canConvertRichTextToNumfmt(body) {
1248
1248
  const MENU_OPTIONS = (currencySymbol) => {
1249
1249
  return [
1250
1250
  {
1251
- label: "sheet.numfmt.general",
1251
+ label: "sheets-numfmt-ui.general",
1252
1252
  pattern: null
1253
1253
  },
1254
1254
  {
1255
- label: "sheet.numfmt.text",
1255
+ label: "sheets-numfmt-ui.text",
1256
1256
  pattern: DEFAULT_TEXT_FORMAT_EXCEL
1257
1257
  },
1258
1258
  "|",
1259
1259
  {
1260
- label: "sheet.numfmt.number",
1260
+ label: "sheets-numfmt-ui.number",
1261
1261
  pattern: "0"
1262
1262
  },
1263
1263
  {
1264
- label: "sheet.numfmt.percent",
1264
+ label: "sheets-numfmt-ui.percent",
1265
1265
  pattern: "0.00%"
1266
1266
  },
1267
1267
  {
1268
- label: "sheet.numfmt.scientific",
1268
+ label: "sheets-numfmt-ui.scientific",
1269
1269
  pattern: "0.00E+00"
1270
1270
  },
1271
1271
  "|",
1272
1272
  {
1273
- label: "sheet.numfmt.accounting",
1273
+ label: "sheets-numfmt-ui.accounting",
1274
1274
  pattern: `"${currencySymbol}" #,##0.00_);[Red]("${currencySymbol}"#,##0.00)`
1275
1275
  },
1276
1276
  {
1277
- label: "sheet.numfmt.financialValue",
1277
+ label: "sheets-numfmt-ui.financialValue",
1278
1278
  pattern: "#,##0.00;[Red]#,##0.00"
1279
1279
  },
1280
1280
  {
1281
- label: "sheet.numfmt.currency",
1281
+ label: "sheets-numfmt-ui.currency",
1282
1282
  pattern: `"${currencySymbol}"#,##0.00_);[Red]("${currencySymbol}"#,##0.00)`
1283
1283
  },
1284
1284
  {
1285
- label: "sheet.numfmt.roundingCurrency",
1285
+ label: "sheets-numfmt-ui.roundingCurrency",
1286
1286
  pattern: `"${currencySymbol}"#,##0;[Red]"${currencySymbol}"#,##0`
1287
1287
  },
1288
1288
  "|",
1289
1289
  {
1290
- label: "sheet.numfmt.date",
1290
+ label: "sheets-numfmt-ui.date",
1291
1291
  pattern: "yyyy-mm-dd;@"
1292
1292
  },
1293
1293
  {
1294
- label: "sheet.numfmt.time",
1294
+ label: "sheets-numfmt-ui.time",
1295
1295
  pattern: "am/pm h\":\"mm\":\"ss"
1296
1296
  },
1297
1297
  {
1298
- label: "sheet.numfmt.dateTime",
1298
+ label: "sheets-numfmt-ui.dateTime",
1299
1299
  pattern: "yyyy-m-d am/pm h:mm"
1300
1300
  },
1301
1301
  {
1302
- label: "sheet.numfmt.timeDuration",
1302
+ label: "sheets-numfmt-ui.timeDuration",
1303
1303
  pattern: "h:mm:ss"
1304
1304
  },
1305
1305
  "|",
1306
1306
  {
1307
- label: "sheet.numfmt.moreFmt",
1307
+ label: "sheets-numfmt-ui.moreFmt",
1308
1308
  pattern: ""
1309
1309
  }
1310
1310
  ];
@@ -1319,8 +1319,8 @@ const CurrencySymbolIconMenuItem = (accessor) => {
1319
1319
  });
1320
1320
  }),
1321
1321
  id: SetCurrencyCommand.id,
1322
- title: "sheet.numfmt.currency",
1323
- tooltip: "sheet.numfmt.currency",
1322
+ title: "sheets-numfmt-ui.currency",
1323
+ tooltip: "sheets-numfmt-ui.currency",
1324
1324
  type: MenuItemType.BUTTON,
1325
1325
  hidden$: getMenuHiddenObservable(accessor, UniverInstanceType.UNIVER_SHEET),
1326
1326
  disabled$: getCurrentRangeDisable$(accessor, {
@@ -1334,8 +1334,8 @@ const AddDecimalMenuItem = (accessor) => {
1334
1334
  return {
1335
1335
  icon: "AddDigitsIcon",
1336
1336
  id: AddDecimalCommand.id,
1337
- title: "sheet.numfmt.addDecimal",
1338
- tooltip: "sheet.numfmt.addDecimal",
1337
+ title: "sheets-numfmt-ui.addDecimal",
1338
+ tooltip: "sheets-numfmt-ui.addDecimal",
1339
1339
  type: MenuItemType.BUTTON,
1340
1340
  hidden$: getMenuHiddenObservable(accessor, UniverInstanceType.UNIVER_SHEET),
1341
1341
  disabled$: getCurrentRangeDisable$(accessor, {
@@ -1349,8 +1349,8 @@ const SubtractDecimalMenuItem = (accessor) => {
1349
1349
  return {
1350
1350
  icon: "ReduceDigitsIcon",
1351
1351
  id: SubtractDecimalCommand.id,
1352
- title: "sheet.numfmt.subtractDecimal",
1353
- tooltip: "sheet.numfmt.subtractDecimal",
1352
+ title: "sheets-numfmt-ui.subtractDecimal",
1353
+ tooltip: "sheets-numfmt-ui.subtractDecimal",
1354
1354
  type: MenuItemType.BUTTON,
1355
1355
  hidden$: getMenuHiddenObservable(accessor, UniverInstanceType.UNIVER_SHEET),
1356
1356
  disabled$: getCurrentRangeDisable$(accessor, {
@@ -1364,8 +1364,8 @@ const PercentMenuItem = (accessor) => {
1364
1364
  return {
1365
1365
  icon: "PercentIcon",
1366
1366
  id: SetPercentCommand.id,
1367
- title: "sheet.numfmt.percent",
1368
- tooltip: "sheet.numfmt.percent",
1367
+ title: "sheets-numfmt-ui.percent",
1368
+ tooltip: "sheets-numfmt-ui.percent",
1369
1369
  type: MenuItemType.BUTTON,
1370
1370
  hidden$: getMenuHiddenObservable(accessor, UniverInstanceType.UNIVER_SHEET),
1371
1371
  disabled$: getCurrentRangeDisable$(accessor, {
@@ -1391,7 +1391,7 @@ const FactoryOtherMenuItem = (accessor) => {
1391
1391
  const numfmtValue = (_workbook$getStyles$g = workbook.getStyles().get((_worksheet$getCell = worksheet.getCell(row, col)) === null || _worksheet$getCell === void 0 ? void 0 : _worksheet$getCell.s)) === null || _workbook$getStyles$g === void 0 ? void 0 : _workbook$getStyles$g.n;
1392
1392
  const pattern = numfmtValue === null || numfmtValue === void 0 ? void 0 : numfmtValue.pattern;
1393
1393
  const currencySymbol = getCurrencySymbolByLocale(localeService.getCurrentLocale());
1394
- let value = localeService.t("sheet.numfmt.general");
1394
+ let value = localeService.t("sheets-numfmt-ui.general");
1395
1395
  if (isDefaultFormat(pattern)) {
1396
1396
  subscribe.next(value);
1397
1397
  return;
@@ -1399,7 +1399,7 @@ const FactoryOtherMenuItem = (accessor) => {
1399
1399
  if (pattern) {
1400
1400
  const item = MENU_OPTIONS(currencySymbol).filter((item) => typeof item === "object" && item.pattern).find((item) => isPatternEqualWithoutDecimal(pattern, item.pattern));
1401
1401
  if (item && typeof item === "object" && item.pattern) value = localeService.t(item.label);
1402
- else value = localeService.t("sheet.numfmt.moreFmt");
1402
+ else value = localeService.t("sheets-numfmt-ui.moreFmt");
1403
1403
  }
1404
1404
  subscribe.next(value);
1405
1405
  }
@@ -1407,7 +1407,7 @@ const FactoryOtherMenuItem = (accessor) => {
1407
1407
  return {
1408
1408
  label: MORE_NUMFMT_TYPE_KEY,
1409
1409
  id: OpenNumfmtPanelOperator.id,
1410
- tooltip: "sheet.numfmt.title",
1410
+ tooltip: "sheets-numfmt-ui.title",
1411
1411
  type: MenuItemType.SELECTOR,
1412
1412
  slot: true,
1413
1413
  selections: [{ label: {
@@ -1427,14 +1427,14 @@ const FactoryOtherMenuItem = (accessor) => {
1427
1427
 
1428
1428
  //#endregion
1429
1429
  //#region src/views/components/MoreNumfmtType.tsx
1430
- const MORE_NUMFMT_TYPE_KEY = "sheet.numfmt.moreNumfmtType";
1431
- const OPTIONS_KEY = "sheet.numfmt.moreNumfmtType.options";
1430
+ const MORE_NUMFMT_TYPE_KEY = "sheets-numfmt-ui.moreNumfmtType";
1431
+ const OPTIONS_KEY = "sheets-numfmt-ui.moreNumfmtType.options";
1432
1432
  function MoreNumfmtType(props) {
1433
1433
  const { value } = props;
1434
1434
  const localeService = useDependency(LocaleService);
1435
1435
  return /* @__PURE__ */ jsx("span", {
1436
1436
  className: "univer-text-sm",
1437
- children: value !== null && value !== void 0 ? value : localeService.t("sheet.numfmt.general")
1437
+ children: value !== null && value !== void 0 ? value : localeService.t("sheets-numfmt-ui.general")
1438
1438
  });
1439
1439
  }
1440
1440
  function Options() {
@@ -0,0 +1,43 @@
1
+ //#region src/locale/ar-SA.ts
2
+ const locale = { "sheets-numfmt-ui": {
3
+ title: "تنسيق الأرقام",
4
+ numfmtType: "أنواع التنسيق",
5
+ cancel: "إلغاء",
6
+ confirm: "تأكيد",
7
+ general: "عام",
8
+ accounting: "محاسبة",
9
+ text: "نص",
10
+ number: "رقم",
11
+ percent: "نسبة مئوية",
12
+ scientific: "علمي",
13
+ currency: "عملة",
14
+ date: "تاريخ",
15
+ time: "وقت",
16
+ thousandthPercentile: "فاصل الألوف",
17
+ preview: "معاينة",
18
+ dateTime: "التاريخ والوقت",
19
+ decimalLength: "المنازل العشرية",
20
+ currencyType: "رمز العملة",
21
+ moreFmt: "التنسيقات",
22
+ financialValue: "قيمة مالية",
23
+ roundingCurrency: "تقريب العملة",
24
+ timeDuration: "المدة الزمنية",
25
+ currencyDes: "يُستخدم تنسيق العملة لتمثيل قيم العملة العامة. يقوم تنسيق المحاسبة بمحاذاة عمود من القيم مع النقاط العشرية",
26
+ accountingDes: "يقوم تنسيق الأرقام المحاسبي بمحاذاة عمود من القيم مع رموز العملة والنقاط العشرية",
27
+ dateType: "نوع التاريخ",
28
+ dateDes: "يعرض تنسيق التاريخ قيم سلسلة التاريخ والوقت كقيم تاريخ.",
29
+ negType: "نوع العدد السالب",
30
+ generalDes: "لا يحتوي التنسيق العام على أي تنسيق رقم محدد.",
31
+ thousandthPercentileDes: "يُستخدم تنسيق النسبة المئوية لتمثيل الأرقام العادية. توفر تنسيقات العملة والمحاسبة تنسيقًا متخصصًا لحسابات قيم العملة.",
32
+ addDecimal: "زيادة المنازل العشرية",
33
+ subtractDecimal: "تقليل المنازل العشرية",
34
+ customFormat: "تنسيق مخصص",
35
+ customFormatDes: "إنشاء تنسيقات أرقام مخصصة استنادًا إلى التنسيقات الموجودة.",
36
+ info: {
37
+ error: "خطأ",
38
+ forceStringInfo: "رقم مخزن كنص"
39
+ }
40
+ } };
41
+
42
+ //#endregion
43
+ export { locale as default };
@@ -1,5 +1,5 @@
1
1
  //#region src/locale/ca-ES.ts
2
- const locale = { sheet: { numfmt: {
2
+ const locale = { "sheets-numfmt-ui": {
3
3
  title: "Format de nombre",
4
4
  numfmtType: "Tipus de format",
5
5
  cancel: "Cancel·lar",
@@ -32,8 +32,12 @@ const locale = { sheet: { numfmt: {
32
32
  addDecimal: "Augmentar decimals",
33
33
  subtractDecimal: "Disminuir decimals",
34
34
  customFormat: "Format personalitzat",
35
- customFormatDes: "Genera formats de nombre personalitzats basats en els existents."
36
- } } };
35
+ customFormatDes: "Genera formats de nombre personalitzats basats en els existents.",
36
+ info: {
37
+ error: "Error",
38
+ forceStringInfo: "Número emmagatzemat com a text"
39
+ }
40
+ } };
37
41
 
38
42
  //#endregion
39
43
  export { locale as default };
@@ -0,0 +1,43 @@
1
+ //#region src/locale/de-DE.ts
2
+ const locale = { "sheets-numfmt-ui": {
3
+ title: "Zahlenformat",
4
+ numfmtType: "Formattypen",
5
+ cancel: "Abbrechen",
6
+ confirm: "Bestätigen",
7
+ general: "Allgemein",
8
+ accounting: "Buchhaltung",
9
+ text: "Text",
10
+ number: "Zahl",
11
+ percent: "Prozent",
12
+ scientific: "Wissenschaftlich",
13
+ currency: "Währung",
14
+ date: "Datum",
15
+ time: "Zeit",
16
+ thousandthPercentile: "Tausendertrennzeichen",
17
+ preview: "Vorschau",
18
+ dateTime: "Datum und Uhrzeit",
19
+ decimalLength: "Dezimalstellen",
20
+ currencyType: "Währungssymbol",
21
+ moreFmt: "Formate",
22
+ financialValue: "Finanzwert",
23
+ roundingCurrency: "Währung aufrunden",
24
+ timeDuration: "Dauer",
25
+ currencyDes: "Das Währungsformat wird verwendet, um allgemeine Währungswerte darzustellen. Das Buchhaltungsformat richtet eine Spalte von Werten an Dezimalpunkten aus",
26
+ accountingDes: "Das Buchhaltungszahlenformat richtet eine Spalte von Werten an Währungssymbolen und Dezimalpunkten aus",
27
+ dateType: "Datumstyp",
28
+ dateDes: "Das Datumsformat stellt Datums- und Zeitserienwerte als Datumswerte dar.",
29
+ negType: "Negativer Zahlentyp",
30
+ generalDes: "Das allgemeine Format enthält kein spezifisches Zahlenformat.",
31
+ thousandthPercentileDes: "Das Tausendertrennzeichenformat wird für die Darstellung gewöhnlicher Zahlen verwendet. Währungs- und Buchhaltungsformate bieten ein spezialisiertes Format für Währungswertberechnungen.",
32
+ addDecimal: "Dezimalstellen erhöhen",
33
+ subtractDecimal: "Dezimalstellen verringern",
34
+ customFormat: "Benutzerdefiniertes Format",
35
+ customFormatDes: "Benutzerdefinierte Zahlenformate basierend auf vorhandenen Formaten erstellen.",
36
+ info: {
37
+ error: "Fehler",
38
+ forceStringInfo: "Zahl als Text gespeichert"
39
+ }
40
+ } };
41
+
42
+ //#endregion
43
+ export { locale as default };
@@ -14,7 +14,7 @@
14
14
  * See the License for the specific language governing permissions and
15
15
  * limitations under the License.
16
16
  */
17
- const locale = { sheet: { numfmt: {
17
+ const locale = { "sheets-numfmt-ui": {
18
18
  title: "Number format",
19
19
  numfmtType: "Format types",
20
20
  cancel: "Cancel",
@@ -47,8 +47,12 @@ const locale = { sheet: { numfmt: {
47
47
  addDecimal: "Increase decimal places",
48
48
  subtractDecimal: "Decreasing decimal places",
49
49
  customFormat: "Custom Format",
50
- customFormatDes: "Generate custom number formats based on existing formats."
51
- } } };
50
+ customFormatDes: "Generate custom number formats based on existing formats.",
51
+ info: {
52
+ error: "Error",
53
+ forceStringInfo: "Number stored as text"
54
+ }
55
+ } };
52
56
 
53
57
  //#endregion
54
58
  export { locale as default };
@@ -1,5 +1,5 @@
1
1
  //#region src/locale/es-ES.ts
2
- const locale = { sheet: { numfmt: {
2
+ const locale = { "sheets-numfmt-ui": {
3
3
  title: "Formato de número",
4
4
  numfmtType: "Tipos de formato",
5
5
  cancel: "Cancelar",
@@ -32,8 +32,12 @@ const locale = { sheet: { numfmt: {
32
32
  addDecimal: "Aumentar decimales",
33
33
  subtractDecimal: "Disminuir decimales",
34
34
  customFormat: "Formato personalizado",
35
- customFormatDes: "Generar formatos de número personalizados basados en los existentes."
36
- } } };
35
+ customFormatDes: "Generar formatos de número personalizados basados en los existentes.",
36
+ info: {
37
+ error: "Error",
38
+ forceStringInfo: "Número almacenado como texto"
39
+ }
40
+ } };
37
41
 
38
42
  //#endregion
39
43
  export { locale as default };
@@ -1,5 +1,5 @@
1
1
  //#region src/locale/fa-IR.ts
2
- const locale = { sheet: { numfmt: {
2
+ const locale = { "sheets-numfmt-ui": {
3
3
  title: "قالب‌بندی عدد",
4
4
  numfmtType: "انواع قالب‌بندی",
5
5
  cancel: "انصراف",
@@ -32,8 +32,12 @@ const locale = { sheet: { numfmt: {
32
32
  addDecimal: "افزایش اعشار",
33
33
  subtractDecimal: "کاهش اعشار",
34
34
  customFormat: "قالب‌بندی سفارشی",
35
- customFormatDes: "ایجاد قالب‌بندی‌های عددی سفارشی بر اساس قالب‌بندی‌های موجود."
36
- } } };
35
+ customFormatDes: "ایجاد قالب‌بندی‌های عددی سفارشی بر اساس قالب‌بندی‌های موجود.",
36
+ info: {
37
+ error: "خطا",
38
+ forceStringInfo: "عدد به عنوان متن ذخیره شده"
39
+ }
40
+ } };
37
41
 
38
42
  //#endregion
39
43
  export { locale as default };
@@ -1,5 +1,5 @@
1
1
  //#region src/locale/fr-FR.ts
2
- const locale = { sheet: { numfmt: {
2
+ const locale = { "sheets-numfmt-ui": {
3
3
  title: "Format de nombre",
4
4
  numfmtType: "Types de format",
5
5
  cancel: "Annuler",
@@ -32,8 +32,12 @@ const locale = { sheet: { numfmt: {
32
32
  addDecimal: "Augmenter les décimales",
33
33
  subtractDecimal: "Diminuer les décimales",
34
34
  customFormat: "Format personnalisé",
35
- customFormatDes: "Générer des formats de nombre personnalisés basés sur des formats existants."
36
- } } };
35
+ customFormatDes: "Générer des formats de nombre personnalisés basés sur des formats existants.",
36
+ info: {
37
+ error: "Erreur",
38
+ forceStringInfo: "Nombre stocké en tant que texte"
39
+ }
40
+ } };
37
41
 
38
42
  //#endregion
39
43
  export { locale as default };