@univerjs/ui 1.0.0-alpha.5 → 1.0.0-alpha.7

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (109) hide show
  1. package/lib/cjs/index.js +1092 -349
  2. package/lib/cjs/locale/ar-SA.js +12 -0
  3. package/lib/cjs/locale/ca-ES.js +12 -0
  4. package/lib/cjs/locale/de-DE.js +12 -0
  5. package/lib/cjs/locale/en-US.js +12 -0
  6. package/lib/cjs/locale/es-ES.js +12 -0
  7. package/lib/cjs/locale/fa-IR.js +12 -0
  8. package/lib/cjs/locale/fr-FR.js +12 -0
  9. package/lib/cjs/locale/id-ID.js +12 -0
  10. package/lib/cjs/locale/it-IT.js +12 -0
  11. package/lib/cjs/locale/ja-JP.js +12 -0
  12. package/lib/cjs/locale/ko-KR.js +12 -0
  13. package/lib/cjs/locale/pl-PL.js +12 -0
  14. package/lib/cjs/locale/pt-BR.js +12 -0
  15. package/lib/cjs/locale/ru-RU.js +12 -0
  16. package/lib/cjs/locale/sk-SK.js +12 -0
  17. package/lib/cjs/locale/vi-VN.js +12 -0
  18. package/lib/cjs/locale/zh-CN.js +12 -0
  19. package/lib/cjs/locale/zh-HK.js +12 -0
  20. package/lib/cjs/locale/zh-TW.js +12 -0
  21. package/lib/es/index.js +1092 -354
  22. package/lib/es/locale/ar-SA.js +12 -0
  23. package/lib/es/locale/ca-ES.js +12 -0
  24. package/lib/es/locale/de-DE.js +12 -0
  25. package/lib/es/locale/en-US.js +12 -0
  26. package/lib/es/locale/es-ES.js +12 -0
  27. package/lib/es/locale/fa-IR.js +12 -0
  28. package/lib/es/locale/fr-FR.js +12 -0
  29. package/lib/es/locale/id-ID.js +12 -0
  30. package/lib/es/locale/it-IT.js +12 -0
  31. package/lib/es/locale/ja-JP.js +12 -0
  32. package/lib/es/locale/ko-KR.js +12 -0
  33. package/lib/es/locale/pl-PL.js +12 -0
  34. package/lib/es/locale/pt-BR.js +12 -0
  35. package/lib/es/locale/ru-RU.js +12 -0
  36. package/lib/es/locale/sk-SK.js +12 -0
  37. package/lib/es/locale/vi-VN.js +12 -0
  38. package/lib/es/locale/zh-CN.js +12 -0
  39. package/lib/es/locale/zh-HK.js +12 -0
  40. package/lib/es/locale/zh-TW.js +12 -0
  41. package/lib/index.css +176 -6
  42. package/lib/index.js +1092 -354
  43. package/lib/locale/ar-SA.js +12 -0
  44. package/lib/locale/ca-ES.js +12 -0
  45. package/lib/locale/de-DE.js +12 -0
  46. package/lib/locale/en-US.js +12 -0
  47. package/lib/locale/es-ES.js +12 -0
  48. package/lib/locale/fa-IR.js +12 -0
  49. package/lib/locale/fr-FR.js +12 -0
  50. package/lib/locale/id-ID.js +12 -0
  51. package/lib/locale/it-IT.js +12 -0
  52. package/lib/locale/ja-JP.js +12 -0
  53. package/lib/locale/ko-KR.js +12 -0
  54. package/lib/locale/pl-PL.js +12 -0
  55. package/lib/locale/pt-BR.js +12 -0
  56. package/lib/locale/ru-RU.js +12 -0
  57. package/lib/locale/sk-SK.js +12 -0
  58. package/lib/locale/vi-VN.js +12 -0
  59. package/lib/locale/zh-CN.js +12 -0
  60. package/lib/locale/zh-HK.js +12 -0
  61. package/lib/locale/zh-TW.js +12 -0
  62. package/lib/types/commands/operations/open-feature-search.operation.d.ts +17 -0
  63. package/lib/types/controllers/feature-search/feature-search.controller.d.ts +20 -0
  64. package/lib/types/controllers/ui/ui.controller.d.ts +1 -1
  65. package/lib/types/index.d.ts +2 -3
  66. package/lib/types/locale/en-US.d.ts +12 -0
  67. package/lib/types/menu/feature-search.menu.d.ts +18 -0
  68. package/lib/types/{controllers/menus/menus.d.ts → menu/history.menu.d.ts} +2 -2
  69. package/lib/types/{controllers/shortcut-display/menu.d.ts → menu/shortcut-panel.menu.d.ts} +2 -2
  70. package/lib/types/services/contextmenu/contextmenu-host.service.d.ts +5 -1
  71. package/lib/types/services/menu/menu-manager.service.d.ts +11 -0
  72. package/lib/types/services/menu/types.d.ts +1 -0
  73. package/lib/types/services/shortcut/shortcut.service.d.ts +4 -1
  74. package/lib/types/utils/embed-boundary.d.ts +2 -0
  75. package/lib/types/views/components/feature-search/FeatureSearch.d.ts +29 -0
  76. package/lib/types/views/components/ribbon/RibbonGrid.d.ts +23 -0
  77. package/lib/types/views/components/ribbon/ToolbarItem.d.ts +10 -1
  78. package/lib/types/views/components/ribbon/ribbon-grid-layout.d.ts +27 -0
  79. package/lib/types/views/components/ribbon/ribbon-menu/RibbonGridMenu.d.ts +21 -0
  80. package/lib/types/views/components/sidebar/Sidebar.d.ts +0 -2
  81. package/lib/types/views/custom-label/CustomLabel.d.ts +1 -0
  82. package/lib/types/views/emoji-picker/EmojiPicker.d.ts +7 -3
  83. package/lib/types/views/emoji-picker/emoji-picker-utils.d.ts +1 -1
  84. package/lib/types/views/emoji-picker/index.d.ts +0 -1
  85. package/lib/types/views/index.d.ts +1 -0
  86. package/lib/types/views/symbol-picker/SymbolPicker.d.ts +31 -0
  87. package/lib/types/views/symbol-picker/index.d.ts +18 -0
  88. package/lib/types/views/symbol-picker/symbols.d.ts +23 -0
  89. package/lib/umd/index.js +13 -13
  90. package/lib/umd/locale/ar-SA.js +1 -1
  91. package/lib/umd/locale/ca-ES.js +1 -1
  92. package/lib/umd/locale/de-DE.js +1 -1
  93. package/lib/umd/locale/en-US.js +1 -1
  94. package/lib/umd/locale/es-ES.js +1 -1
  95. package/lib/umd/locale/fa-IR.js +1 -1
  96. package/lib/umd/locale/fr-FR.js +1 -1
  97. package/lib/umd/locale/id-ID.js +1 -1
  98. package/lib/umd/locale/it-IT.js +1 -1
  99. package/lib/umd/locale/ja-JP.js +1 -1
  100. package/lib/umd/locale/ko-KR.js +1 -1
  101. package/lib/umd/locale/pl-PL.js +1 -1
  102. package/lib/umd/locale/pt-BR.js +1 -1
  103. package/lib/umd/locale/ru-RU.js +1 -1
  104. package/lib/umd/locale/sk-SK.js +1 -1
  105. package/lib/umd/locale/vi-VN.js +1 -1
  106. package/lib/umd/locale/zh-CN.js +1 -1
  107. package/lib/umd/locale/zh-HK.js +1 -1
  108. package/lib/umd/locale/zh-TW.js +1 -1
  109. package/package.json +7 -7
@@ -21,6 +21,15 @@ import { Subject } from 'rxjs';
21
21
  export declare const IMenuManagerService: import("@wendellhu/redi").IdentifierDecorator<IMenuManagerService>;
22
22
  export type ContextMenuQuickLayout = 'icon' | 'tile';
23
23
  export type ContextMenuQuickLayoutVariant = 'default' | 'compact';
24
+ export interface IRibbonGridLayout {
25
+ row: number;
26
+ column: number;
27
+ rowSpan?: number;
28
+ columnSpan?: number;
29
+ showLabel?: boolean;
30
+ width?: number;
31
+ iconSize?: number;
32
+ }
24
33
  export interface IMenuSchema {
25
34
  key: string;
26
35
  order: number;
@@ -33,6 +42,7 @@ export interface IMenuSchema {
33
42
  quickColumns?: number;
34
43
  quickLayoutVariant?: ContextMenuQuickLayoutVariant;
35
44
  tiny?: boolean;
45
+ gridLayout?: IRibbonGridLayout;
36
46
  }
37
47
  export interface IMenuManagerService {
38
48
  readonly menuChanged$: Observable<void>;
@@ -52,6 +62,7 @@ export type MenuSchemaType = {
52
62
  quickColumns?: number;
53
63
  quickLayoutVariant?: ContextMenuQuickLayoutVariant;
54
64
  tiny?: boolean;
65
+ gridLayout?: IRibbonGridLayout;
55
66
  } | {
56
67
  [key: string]: MenuSchemaType;
57
68
  };
@@ -29,6 +29,7 @@ export declare enum RibbonStartGroup {
29
29
  HISTORY = "ribbon.start.history",
30
30
  FORMAT = "ribbon.start.format",
31
31
  LAYOUT = "ribbon.start.layout",
32
+ NUMBER = "ribbon.start.number",
32
33
  OTHERS = "ribbon.start.others"
33
34
  }
34
35
  export declare enum RibbonInsertGroup {
@@ -18,6 +18,7 @@ import type { Observable } from 'rxjs';
18
18
  import { Disposable, ICommandService, IContextService } from '@univerjs/core';
19
19
  import { ILayoutService } from '../layout/layout.service';
20
20
  import { IPlatformService } from '../platform/platform.service';
21
+ import { IUIRuntimeScopeService } from '../runtime-scope/ui-runtime-scope.service';
21
22
  import { KeyCode } from './keycode';
22
23
  /**
23
24
  * A shortcut item that could be registered to the {@link IShortcutService}.
@@ -135,6 +136,7 @@ export declare class ShortcutService extends Disposable implements IShortcutServ
135
136
  private readonly _commandService;
136
137
  private readonly _platformService;
137
138
  private readonly _contextService;
139
+ private readonly _runtimeScopeService;
138
140
  private readonly _layoutService?;
139
141
  private readonly _shortCutMapping;
140
142
  private readonly _commandIDMapping;
@@ -142,7 +144,7 @@ export declare class ShortcutService extends Disposable implements IShortcutServ
142
144
  readonly shortcutChanged$: Observable<void>;
143
145
  private _forceEscaped;
144
146
  private _forceDisabled;
145
- constructor(_commandService: ICommandService, _platformService: IPlatformService, _contextService: IContextService, _layoutService?: ILayoutService | undefined);
147
+ constructor(_commandService: ICommandService, _platformService: IPlatformService, _contextService: IContextService, _runtimeScopeService: IUIRuntimeScopeService, _layoutService?: ILayoutService | undefined);
146
148
  getAllShortcuts(): IShortcutItem[];
147
149
  registerShortcut(shortcut: IShortcutItem): IDisposable;
148
150
  getShortcutDisplayOfCommand(id: string): string | null;
@@ -155,4 +157,5 @@ export declare class ShortcutService extends Disposable implements IShortcutServ
155
157
  private _getBindingFromItem;
156
158
  private _deriveBindingFromEvent;
157
159
  private _shouldLetEmbedTextEditorHandleNativeShortcut;
160
+ private _getRuntimeService;
158
161
  }
@@ -14,8 +14,10 @@
14
14
  * limitations under the License.
15
15
  */
16
16
  export declare const EMBED_INTERACTION_BOUNDARY_OWNER_ATTRIBUTE = "data-embed-interaction-boundary-owner";
17
+ export declare const EMBED_CHILD_UNIT_ID_ATTRIBUTE = "data-embed-child-unit-id";
17
18
  export declare function getEmbedBoundaryOwner(target: EventTarget | null): string | undefined;
18
19
  export declare function isEmbedBoundaryTarget(target: EventTarget | null): boolean;
20
+ export declare function getEmbedChildUnitId(target: EventTarget | null): string | undefined;
19
21
  export declare function keepInteractionInsideSameEmbedBoundary(event: {
20
22
  currentTarget: EventTarget | null;
21
23
  target: EventTarget | null;
@@ -0,0 +1,29 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { IMenuCommandParams } from '../../../services/menu/menu';
17
+ export declare const FEATURE_SEARCH_COMPONENT = "FeatureSearch";
18
+ export declare const FEATURE_SEARCH_DIALOG_ID = "FEATURE_SEARCH_DIALOG";
19
+ export interface IFeatureSearchItem {
20
+ key: string;
21
+ title: string;
22
+ parentTitle?: string;
23
+ description: string;
24
+ path: string;
25
+ commandId: string;
26
+ params?: IMenuCommandParams;
27
+ getParams: () => IMenuCommandParams | undefined;
28
+ }
29
+ export declare function FeatureSearch(): import("react").JSX.Element;
@@ -0,0 +1,23 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { HTMLAttributes } from 'react';
17
+ import type { IMenuSchema } from '../../../services/menu/menu-manager.service';
18
+ interface IRibbonGridProps extends Omit<HTMLAttributes<HTMLDivElement>, 'title'> {
19
+ groups: IMenuSchema[];
20
+ title: string;
21
+ }
22
+ export declare function RibbonGrid({ groups, title, className, ...props }: IRibbonGridProps): import("react").JSX.Element;
23
+ export {};
@@ -15,4 +15,13 @@
15
15
  */
16
16
  import type { IDisplayMenuItem, IMenuItem } from '../../../services/menu/menu';
17
17
  import type { ITooltipWrapperRef } from './TooltipButtonWrapper';
18
- export declare const ToolbarItem: import("react").ForwardRefExoticComponent<IDisplayMenuItem<IMenuItem> & import("react").RefAttributes<ITooltipWrapperRef>>;
18
+ type IToolbarItemProps = IDisplayMenuItem<IMenuItem> & {
19
+ grid?: boolean;
20
+ large?: boolean;
21
+ showLabel?: boolean;
22
+ iconSize?: number;
23
+ iconColor?: string;
24
+ fullWidth?: boolean;
25
+ };
26
+ export declare const ToolbarItem: import("react").ForwardRefExoticComponent<IToolbarItemProps & import("react").RefAttributes<ITooltipWrapperRef>>;
27
+ export {};
@@ -0,0 +1,27 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { IMenuSchema } from '../../../services/menu/menu-manager.service';
17
+ export interface IRibbonGridPlacement {
18
+ item: IMenuSchema;
19
+ row: number;
20
+ column: number;
21
+ rowSpan: number;
22
+ columnSpan: number;
23
+ showLabel: boolean;
24
+ width?: number;
25
+ iconSize?: number;
26
+ }
27
+ export declare function placeRibbonGridItems(items: IMenuSchema[]): IRibbonGridPlacement[];
@@ -0,0 +1,21 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { IMenuSchema } from '../../../../services/menu/menu-manager.service';
17
+ export declare function RibbonGridMenu({ ribbon, activatedTab, onSelectTab, }: {
18
+ ribbon: IMenuSchema[];
19
+ activatedTab: string;
20
+ onSelectTab: (tab: IMenuSchema) => void;
21
+ }): import("react").JSX.Element;
@@ -13,13 +13,11 @@
13
13
  * See the License for the specific language governing permissions and
14
14
  * limitations under the License.
15
15
  */
16
- import type { CSSProperties } from 'react';
17
16
  import type { ICustomLabelProps } from '../../custom-label/CustomLabel';
18
17
  export interface ISidebarMethodOptions {
19
18
  id?: string;
20
19
  header?: ICustomLabelProps;
21
20
  children?: ICustomLabelProps;
22
- bodyStyle?: CSSProperties;
23
21
  footer?: ICustomLabelProps;
24
22
  visible?: boolean;
25
23
  width?: number | string;
@@ -18,6 +18,7 @@ import type { Observable } from 'rxjs';
18
18
  import type { IMenuSelectorItem } from '../../services/menu/menu';
19
19
  export type ICustomLabelProps<T = undefined> = {
20
20
  className?: string;
21
+ iconSize?: number;
21
22
  value?: string | number | undefined;
22
23
  value$?: Observable<T>;
23
24
  onChange?(v: string | number): void;
@@ -15,13 +15,17 @@
15
15
  */
16
16
  import type { IPopup } from '../../services/popup/canvas-popup.service';
17
17
  export declare const EMOJI_PICKER_COMPONENT = "ui.emoji-picker";
18
- export interface IEmojiPickerPopupProps {
18
+ interface IEmojiPickerPopupProps {
19
19
  activeEmoji?: string;
20
20
  onSelect?: (emoji: string, options?: {
21
21
  keepOpen?: boolean;
22
22
  }) => void;
23
23
  recentStorageKey?: string;
24
24
  }
25
- export declare function EmojiPicker(props: {
25
+ interface IEmojiPickerProps {
26
+ embedded?: boolean;
27
+ onChange?: (emoji: string) => void;
26
28
  popup?: IPopup<IEmojiPickerPopupProps>;
27
- }): import("react").JSX.Element;
29
+ }
30
+ export declare function EmojiPicker(props: IEmojiPickerProps): import("react").JSX.Element;
31
+ export {};
@@ -27,7 +27,7 @@ export type EmojiCategory = Exclude<keyof typeof emojis, 'frequent'>;
27
27
  export declare const EMOJI_RECENT_LIMIT = 11;
28
28
  export declare const EMOJI_CATEGORIES: {
29
29
  key: EmojiCategory;
30
- titleKey: "ui.row" | "ui.column" | "ui.common-edit" | "ui.toggle-shortcut-panel" | "ui.global-shortcut" | "ui.fontFamily.not-supported" | "ui.fontFamily.arial" | "ui.fontFamily.times-new-roman" | "ui.fontFamily.tahoma" | "ui.fontFamily.verdana" | "ui.fontFamily.microsoft-yahei" | "ui.fontFamily.simsun" | "ui.fontFamily.simhei" | "ui.fontFamily.kaiti" | "ui.fontFamily.fangsong" | "ui.fontFamily.nsimsun" | "ui.fontFamily.stxinwei" | "ui.fontFamily.stxingkai" | "ui.fontFamily.stliti" | "ui.ribbon.start" | "ui.ribbon.view" | "ui.ribbon.insert" | "ui.ribbon.data" | "ui.ribbon.startDesc" | "ui.ribbon.insertDesc" | "ui.ribbon.formulas" | "ui.ribbon.formulasDesc" | "ui.ribbon.dataDesc" | "ui.ribbon.viewDesc" | "ui.ribbon.others" | "ui.ribbon.othersDesc" | "ui.ribbon.more" | "ui.clipboard.authentication.title" | "ui.clipboard.authentication.content" | "ui.emojiPicker.search" | "ui.emojiPicker.objects" | "ui.emojiPicker.random" | "ui.emojiPicker.recents" | "ui.emojiPicker.emojis" | "ui.emojiPicker.animals" | "ui.emojiPicker.food" | "ui.emojiPicker.activities" | "ui.emojiPicker.places" | "ui.emojiPicker.symbols" | "ui.emojiPicker.searchResults" | "ui.emojiPicker.noResults" | `ui.emojiPicker.emojiSearchIndex.${string}` | `ui.emojiPicker.emojiTitles.${string}` | "ui.toolbar.heading.title" | "ui.toolbar.heading.normal" | "ui.toolbar.heading.subTitle" | "ui.toolbar.heading.tooltip" | "ui.shortcut-panel.title" | "ui.shortcut.copy" | "ui.shortcut.cut" | "ui.shortcut.paste" | "ui.shortcut.shortcut-panel" | "ui.shortcut.undo" | "ui.shortcut.redo" | "ui.navigation.next" | "ui.navigation.back" | "ui.navigation.previous" | "ui.sidebar.close" | "ui.sidebar.resize" | "ui.sidebar.panel" | "ui.beforeClose.title" | "ui.textEditor.formulaError" | "ui.textEditor.rangeError" | "ui.rangeSelector.title" | "ui.rangeSelector.cancel" | "ui.rangeSelector.addAnotherRange" | "ui.rangeSelector.buttonTooltip" | "ui.rangeSelector.placeHolder" | "ui.rangeSelector.confirm" | "ui.zoom-slider.resetTo";
30
+ titleKey: "ui.row" | "ui.column" | "ui.common-edit" | "ui.toggle-shortcut-panel" | "ui.global-shortcut" | "ui.fontFamily.not-supported" | "ui.fontFamily.arial" | "ui.fontFamily.times-new-roman" | "ui.fontFamily.tahoma" | "ui.fontFamily.verdana" | "ui.fontFamily.microsoft-yahei" | "ui.fontFamily.simsun" | "ui.fontFamily.simhei" | "ui.fontFamily.kaiti" | "ui.fontFamily.fangsong" | "ui.fontFamily.nsimsun" | "ui.fontFamily.stxinwei" | "ui.fontFamily.stxingkai" | "ui.fontFamily.stliti" | "ui.ribbon.start" | "ui.ribbon.view" | "ui.ribbon.insert" | "ui.ribbon.data" | "ui.ribbon.startDesc" | "ui.ribbon.insertDesc" | "ui.ribbon.formulas" | "ui.ribbon.formulasDesc" | "ui.ribbon.dataDesc" | "ui.ribbon.viewDesc" | "ui.ribbon.others" | "ui.ribbon.othersDesc" | "ui.ribbon.more" | "ui.clipboard.authentication.title" | "ui.clipboard.authentication.content" | "ui.featureSearch.title" | "ui.featureSearch.empty" | "ui.featureSearch.placeholder" | "ui.featureSearch.ribbon" | "ui.featureSearch.contextMenu" | "ui.emojiPicker.search" | "ui.emojiPicker.objects" | "ui.emojiPicker.random" | "ui.emojiPicker.recents" | "ui.emojiPicker.emojis" | "ui.emojiPicker.animals" | "ui.emojiPicker.food" | "ui.emojiPicker.activities" | "ui.emojiPicker.places" | "ui.emojiPicker.symbols" | "ui.emojiPicker.searchResults" | "ui.emojiPicker.noResults" | `ui.emojiPicker.emojiSearchIndex.${string}` | `ui.emojiPicker.emojiTitles.${string}` | "ui.symbolPicker.mathematics" | "ui.symbolPicker.greek" | "ui.symbolPicker.common" | "ui.toolbar.heading.title" | "ui.toolbar.heading.normal" | "ui.toolbar.heading.subTitle" | "ui.toolbar.heading.tooltip" | "ui.shortcut-panel.title" | "ui.shortcut.copy" | "ui.shortcut.cut" | "ui.shortcut.paste" | "ui.shortcut.shortcut-panel" | "ui.shortcut.undo" | "ui.shortcut.redo" | "ui.navigation.next" | "ui.navigation.back" | "ui.navigation.previous" | "ui.sidebar.close" | "ui.sidebar.resize" | "ui.sidebar.panel" | "ui.beforeClose.title" | "ui.textEditor.formulaError" | "ui.textEditor.rangeError" | "ui.rangeSelector.title" | "ui.rangeSelector.cancel" | "ui.rangeSelector.addAnotherRange" | "ui.rangeSelector.buttonTooltip" | "ui.rangeSelector.placeHolder" | "ui.rangeSelector.confirm" | "ui.zoom-slider.resetTo";
31
31
  }[];
32
32
  export declare function getDefaultRecentEmojis(): IEmojiItem[];
33
33
  export declare function getAllEmojis(): IEmojiItem[];
@@ -16,4 +16,3 @@
16
16
  export { EMOJI_CATEGORIES, EMOJI_RECENT_LIMIT, getAllEmojis, getDefaultRecentEmojis, getEmojiLocaleData, getLocalizedEmojiTitle, getRandomEmoji, parseStoredRecentEmojis, promoteRecentEmoji, searchEmojis, } from './emoji-picker-utils';
17
17
  export type { EmojiCategory, IEmojiItem, IEmojiLocaleData } from './emoji-picker-utils';
18
18
  export { EMOJI_PICKER_COMPONENT, EmojiPicker } from './EmojiPicker';
19
- export type { IEmojiPickerPopupProps } from './EmojiPicker';
@@ -19,3 +19,4 @@ export * from './emoji-picker/index';
19
19
  export * from './HeadingItem';
20
20
  export { useScrollYOverContainer } from './hooks/layout';
21
21
  export { type ISliderProps, type IZoomInputProps, Slider, ZoomInput } from './slider/index';
22
+ export * from './symbol-picker/index';
@@ -0,0 +1,31 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { IPopup } from '../../services/popup/canvas-popup.service';
17
+ export declare const SYMBOL_PICKER_COMPONENT = "ui.symbol-picker";
18
+ interface ISymbolPickerPopupProps {
19
+ activeSymbol?: string;
20
+ onSelect?: (symbol: string, options?: {
21
+ keepOpen?: boolean;
22
+ }) => void;
23
+ }
24
+ interface ISymbolPickerProps {
25
+ className?: string;
26
+ embedded?: boolean;
27
+ onChange?: (symbol: string) => void;
28
+ popup?: IPopup<ISymbolPickerPopupProps>;
29
+ }
30
+ export declare function SymbolPicker(props: ISymbolPickerProps): import("react").JSX.Element;
31
+ export {};
@@ -0,0 +1,18 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ export { SYMBOL_PICKER_COMPONENT, SymbolPicker } from './SymbolPicker';
17
+ export { SYMBOL_CATEGORIES } from './symbols';
18
+ export type { ISymbolCategory, SymbolCategory } from './symbols';
@@ -0,0 +1,23 @@
1
+ /**
2
+ * Copyright 2023-present DreamNum Co., Ltd.
3
+ *
4
+ * Licensed under the Apache License, Version 2.0 (the "License");
5
+ * you may not use this file except in compliance with the License.
6
+ * You may obtain a copy of the License at
7
+ *
8
+ * http://www.apache.org/licenses/LICENSE-2.0
9
+ *
10
+ * Unless required by applicable law or agreed to in writing, software
11
+ * distributed under the License is distributed on an "AS IS" BASIS,
12
+ * WITHOUT WARRANTIES OR CONDITIONS OF ANY KIND, either express or implied.
13
+ * See the License for the specific language governing permissions and
14
+ * limitations under the License.
15
+ */
16
+ import type { LocaleKey } from '../../locale/types';
17
+ export type SymbolCategory = 'mathematics' | 'greek' | 'common';
18
+ export interface ISymbolCategory {
19
+ key: SymbolCategory;
20
+ symbols: string[];
21
+ titleKey: LocaleKey;
22
+ }
23
+ export declare const SYMBOL_CATEGORIES: ISymbolCategory[];