@univerjs/docs-ui 0.25.0 → 1.0.0-alpha.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.
- package/lib/cjs/facade.js +23 -183
- package/lib/cjs/index.js +7475 -5364
- package/lib/cjs/locale/ar-SA.js +35 -1
- package/lib/cjs/locale/ca-ES.js +35 -1
- package/lib/cjs/locale/de-DE.js +35 -1
- package/lib/cjs/locale/en-US.js +35 -1
- package/lib/cjs/locale/es-ES.js +35 -1
- package/lib/cjs/locale/fa-IR.js +35 -1
- package/lib/cjs/locale/fr-FR.js +35 -1
- package/lib/cjs/locale/id-ID.js +35 -1
- package/lib/cjs/locale/it-IT.js +35 -1
- package/lib/cjs/locale/ja-JP.js +35 -1
- package/lib/cjs/locale/ko-KR.js +35 -1
- package/lib/cjs/locale/pl-PL.js +35 -1
- package/lib/cjs/locale/pt-BR.js +35 -1
- package/lib/cjs/locale/ru-RU.js +35 -1
- package/lib/cjs/locale/sk-SK.js +35 -1
- package/lib/cjs/locale/vi-VN.js +35 -1
- package/lib/cjs/locale/zh-CN.js +35 -1
- package/lib/cjs/locale/zh-HK.js +35 -1
- package/lib/cjs/locale/zh-TW.js +35 -1
- package/lib/es/facade.js +25 -178
- package/lib/es/index.js +7934 -5853
- package/lib/es/locale/ar-SA.js +35 -1
- package/lib/es/locale/ca-ES.js +35 -1
- package/lib/es/locale/de-DE.js +35 -1
- package/lib/es/locale/en-US.js +35 -1
- package/lib/es/locale/es-ES.js +35 -1
- package/lib/es/locale/fa-IR.js +35 -1
- package/lib/es/locale/fr-FR.js +35 -1
- package/lib/es/locale/id-ID.js +35 -1
- package/lib/es/locale/it-IT.js +35 -1
- package/lib/es/locale/ja-JP.js +35 -1
- package/lib/es/locale/ko-KR.js +35 -1
- package/lib/es/locale/pl-PL.js +35 -1
- package/lib/es/locale/pt-BR.js +35 -1
- package/lib/es/locale/ru-RU.js +35 -1
- package/lib/es/locale/sk-SK.js +35 -1
- package/lib/es/locale/vi-VN.js +35 -1
- package/lib/es/locale/zh-CN.js +35 -1
- package/lib/es/locale/zh-HK.js +35 -1
- package/lib/es/locale/zh-TW.js +35 -1
- package/lib/facade.js +25 -178
- package/lib/index.css +25 -35
- package/lib/index.js +7934 -5853
- package/lib/locale/ar-SA.js +35 -1
- package/lib/locale/ca-ES.js +35 -1
- package/lib/locale/de-DE.js +35 -1
- package/lib/locale/en-US.js +35 -1
- package/lib/locale/es-ES.js +35 -1
- package/lib/locale/fa-IR.js +35 -1
- package/lib/locale/fr-FR.js +35 -1
- package/lib/locale/id-ID.js +35 -1
- package/lib/locale/it-IT.js +35 -1
- package/lib/locale/ja-JP.js +35 -1
- package/lib/locale/ko-KR.js +35 -1
- package/lib/locale/pl-PL.js +35 -1
- package/lib/locale/pt-BR.js +35 -1
- package/lib/locale/ru-RU.js +35 -1
- package/lib/locale/sk-SK.js +35 -1
- package/lib/locale/vi-VN.js +35 -1
- package/lib/locale/zh-CN.js +35 -1
- package/lib/locale/zh-HK.js +35 -1
- package/lib/locale/zh-TW.js +35 -1
- package/lib/types/commands/commands/doc-delete.command.d.ts +1 -1
- package/lib/types/commands/commands/inline-format.command.d.ts +3 -1
- package/lib/types/commands/commands/table/doc-table-create.command.d.ts +31 -1
- package/lib/types/commands/operations/doc-cursor.operation.d.ts +2 -0
- package/lib/types/commands/util.d.ts +1 -2
- package/lib/types/config/config.d.ts +15 -0
- package/lib/types/controllers/components.controller.d.ts +25 -0
- package/lib/types/controllers/doc-header-footer.controller.d.ts +1 -4
- package/lib/types/controllers/doc-move-cursor.controller.d.ts +9 -0
- package/lib/types/controllers/doc-paragraph-setting.controller.d.ts +2 -4
- package/lib/types/controllers/doc-table.controller.d.ts +1 -4
- package/lib/types/controllers/render-controllers/doc-paragraph-placeholder.render-controller.d.ts +51 -0
- package/lib/types/controllers/render-controllers/doc.render-controller.d.ts +5 -2
- package/lib/types/controllers/render-controllers/zoom.render-controller.d.ts +3 -1
- package/lib/types/controllers/{doc-ui.controller.d.ts → ui.controller.d.ts} +2 -4
- package/lib/types/facade/f-document.d.ts +11 -43
- package/lib/types/facade/index.d.ts +2 -3
- package/lib/types/index.d.ts +39 -26
- package/lib/types/locale/en-US.d.ts +34 -0
- package/lib/types/{views/side-menu/index.d.ts → locale/types.d.ts} +3 -1
- package/lib/types/menu/context-menu.d.ts +15 -14
- package/lib/types/menu/menu.d.ts +31 -29
- package/lib/types/menu/paragraph-menu.d.ts +68 -38
- package/lib/types/services/clipboard/html-to-udm/converter.d.ts +1 -0
- package/lib/types/services/doc-event-manager.service.d.ts +15 -0
- package/lib/types/services/doc-ime-state-change-interceptor.service.d.ts +23 -0
- package/lib/types/services/doc-page-layout.service.d.ts +3 -1
- package/lib/types/services/doc-paragraph-menu.service.d.ts +26 -2
- package/lib/types/services/doc-render-background.d.ts +29 -0
- package/lib/types/services/doc-view-scale.d.ts +54 -0
- package/lib/types/services/doc-zoom.d.ts +20 -0
- package/lib/types/services/docs-render.service.d.ts +5 -2
- package/lib/types/services/editor/editor-manager.service.d.ts +8 -1
- package/lib/types/services/index.d.ts +2 -0
- package/lib/types/services/selection/selection-utils.d.ts +0 -15
- package/lib/types/services/{doc-content-insert.service.d.ts → selection/word-boundary.d.ts} +4 -10
- package/lib/types/shortcuts/core-editing.shortcut.d.ts +1 -0
- package/lib/types/shortcuts/cursor.shortcut.d.ts +12 -0
- package/lib/types/shortcuts/heading.shortcut.d.ts +22 -0
- package/lib/types/{types/delete-direction.d.ts → views/DocSideMenu.d.ts} +1 -4
- package/lib/types/views/Icon.d.ts +49 -0
- package/lib/types/views/{page-settings/index.d.ts → PageSettings.d.ts} +1 -1
- package/lib/types/views/ParagraphMenu.d.ts +62 -0
- package/lib/types/views/{rich-text-editor/index.d.ts → RichTextEditor.d.ts} +3 -3
- package/lib/types/{components/side-menu/index.d.ts → views/SideMenu.d.ts} +4 -3
- package/lib/types/views/count-bar/CountBar.d.ts +1 -1
- package/lib/types/views/count-bar/ZoomSlider.d.ts +1 -1
- package/lib/types/views/doc-footer/DocFooter.d.ts +1 -1
- package/lib/types/views/float-toolbar/FloatToolbar.d.ts +25 -0
- package/lib/types/{components → views}/float-toolbar/FloatToolbar.stories.d.ts +1 -1
- package/lib/types/views/header-footer/panel/DocHeaderFooterOptions.d.ts +1 -1
- package/lib/types/views/header-footer/panel/DocHeaderFooterPanel.d.ts +1 -1
- package/lib/types/{components → views}/list-type-picker/Picker.d.ts +3 -3
- package/lib/types/{components/float-toolbar/FloatToolbar.d.ts → views/paragraph-menu/component-keys.d.ts} +2 -5
- package/lib/types/views/paragraph-menu/theme-color.d.ts +17 -0
- package/lib/types/views/paragraph-setting/Setting.d.ts +1 -1
- package/lib/types/views/paragraph-setting/index.d.ts +1 -1
- package/lib/types/views/paragraph-setting/line-spacing.d.ts +51 -0
- package/lib/types/views/rich-text-editor/hooks/editor-undo-redo-keyboard.d.ts +32 -0
- package/lib/types/views/rich-text-editor/hooks/index.d.ts +1 -0
- package/lib/types/views/rich-text-editor/hooks/use-editor-click-outside.d.ts +2 -1
- package/lib/types/{components → views}/side-menu/SideMenu.stories.d.ts +5 -5
- package/lib/types/views/table/create/TableCreate.d.ts +1 -1
- package/lib/umd/facade.js +1 -5
- package/lib/umd/index.js +11 -26
- package/lib/umd/locale/ar-SA.js +1 -1
- package/lib/umd/locale/ca-ES.js +1 -1
- package/lib/umd/locale/de-DE.js +1 -1
- package/lib/umd/locale/en-US.js +1 -1
- package/lib/umd/locale/es-ES.js +1 -1
- package/lib/umd/locale/fa-IR.js +1 -1
- package/lib/umd/locale/fr-FR.js +1 -1
- package/lib/umd/locale/id-ID.js +1 -1
- package/lib/umd/locale/it-IT.js +1 -1
- package/lib/umd/locale/ja-JP.js +1 -1
- package/lib/umd/locale/ko-KR.js +1 -1
- package/lib/umd/locale/pl-PL.js +1 -1
- package/lib/umd/locale/pt-BR.js +1 -1
- package/lib/umd/locale/ru-RU.js +1 -1
- package/lib/umd/locale/sk-SK.js +1 -1
- package/lib/umd/locale/vi-VN.js +1 -1
- package/lib/umd/locale/zh-CN.js +1 -1
- package/lib/umd/locale/zh-HK.js +1 -1
- package/lib/umd/locale/zh-TW.js +1 -1
- package/package.json +12 -12
- package/lib/types/commands/commands/core-editing.command.d.ts +0 -58
- package/lib/types/components/paragraph-menu/index.d.ts +0 -41
- package/lib/types/facade/f-univer.d.ts +0 -52
- package/lib/types/services/doc-state-change-manager.service.d.ts +0 -50
- /package/lib/types/{components → views}/const.d.ts +0 -0
- /package/lib/types/{components → views}/editor/utils.d.ts +0 -0
- /package/lib/types/{components → views}/list-type-picker/index.d.ts +0 -0
|
@@ -27,6 +27,15 @@ export declare class DocMoveCursorController extends Disposable {
|
|
|
27
27
|
private _commandExecutedListener;
|
|
28
28
|
private _handleShiftMoveSelection;
|
|
29
29
|
private _handleMoveCursor;
|
|
30
|
+
private _getCursorOffsetByGranularity;
|
|
31
|
+
private _getWordBoundaryOffset;
|
|
32
|
+
private _getLineBoundaryOffset;
|
|
33
|
+
private _getFirstCursorGlyphInLine;
|
|
34
|
+
private _getLastCursorGlyphInLine;
|
|
35
|
+
private _isCursorAddressableGlyph;
|
|
36
|
+
private _normalizeCursorOffset;
|
|
37
|
+
private _normalizeWholeEntityRanges;
|
|
38
|
+
private _getCursorSkipTokens;
|
|
30
39
|
private _getTopOrBottomPosition;
|
|
31
40
|
private _getGlyphLeftOffsetInLine;
|
|
32
41
|
private _matchPositionByLeftOffset;
|
|
@@ -14,14 +14,12 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
import { Disposable, ICommandService } from '@univerjs/core';
|
|
17
|
-
import {
|
|
17
|
+
import { ISidebarService } from '@univerjs/ui';
|
|
18
18
|
export declare class DocParagraphSettingController extends Disposable {
|
|
19
19
|
private readonly _commandService;
|
|
20
|
-
private readonly _componentManager;
|
|
21
20
|
private _sidebarService;
|
|
22
21
|
private _id;
|
|
23
|
-
constructor(_commandService: ICommandService,
|
|
24
|
-
private _init;
|
|
22
|
+
constructor(_commandService: ICommandService, _sidebarService: ISidebarService);
|
|
25
23
|
openPanel(): void;
|
|
26
24
|
closePanel(): void;
|
|
27
25
|
}
|
|
@@ -14,13 +14,10 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
import { Disposable, ICommandService } from '@univerjs/core';
|
|
17
|
-
import { ComponentManager } from '@univerjs/ui';
|
|
18
17
|
export declare class DocTableController extends Disposable {
|
|
19
18
|
private readonly _commandService;
|
|
20
|
-
|
|
21
|
-
constructor(_commandService: ICommandService, _componentManager: ComponentManager);
|
|
19
|
+
constructor(_commandService: ICommandService);
|
|
22
20
|
private _initialize;
|
|
23
21
|
private _registerCommands;
|
|
24
|
-
private _initCustomComponents;
|
|
25
22
|
private _init;
|
|
26
23
|
}
|
package/lib/types/controllers/render-controllers/doc-paragraph-placeholder.render-controller.d.ts
ADDED
|
@@ -0,0 +1,51 @@
|
|
|
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 { DocumentDataModel, IDocumentBody, Nullable } from '@univerjs/core';
|
|
17
|
+
import type { IDocumentSkeletonPage, IRenderContext, IRenderModule } from '@univerjs/engine-render';
|
|
18
|
+
import type { IUniverDocsUIConfig } from '../../config/config';
|
|
19
|
+
import { Disposable, IConfigService, LocaleService } from '@univerjs/core';
|
|
20
|
+
import { DocSelectionManagerService } from '@univerjs/docs';
|
|
21
|
+
export interface IParagraphPlaceholderLayout {
|
|
22
|
+
fontFamily: string;
|
|
23
|
+
fontSize: number;
|
|
24
|
+
fontWeight: string;
|
|
25
|
+
maxWidth: number;
|
|
26
|
+
text: string;
|
|
27
|
+
x: number;
|
|
28
|
+
y: number;
|
|
29
|
+
}
|
|
30
|
+
interface IParagraphPlaceholderLocale {
|
|
31
|
+
heading1: string;
|
|
32
|
+
heading2: string;
|
|
33
|
+
heading3: string;
|
|
34
|
+
heading4: string;
|
|
35
|
+
heading5: string;
|
|
36
|
+
listItem: string;
|
|
37
|
+
normalText: string;
|
|
38
|
+
}
|
|
39
|
+
export declare class DocParagraphPlaceholderRenderController extends Disposable implements IRenderModule {
|
|
40
|
+
private readonly _context;
|
|
41
|
+
private readonly _localeService;
|
|
42
|
+
private readonly _docSelectionManagerService;
|
|
43
|
+
private readonly _configService;
|
|
44
|
+
constructor(_context: IRenderContext<DocumentDataModel>, _localeService: LocaleService, _docSelectionManagerService: DocSelectionManagerService, _configService: IConfigService);
|
|
45
|
+
private _initParagraphPlaceholderRender;
|
|
46
|
+
private _drawPagePlaceholders;
|
|
47
|
+
private _getLocale;
|
|
48
|
+
}
|
|
49
|
+
export declare function shouldRenderParagraphPlaceholder(documentModel: DocumentDataModel, unitId: string, config?: Nullable<IUniverDocsUIConfig>): boolean;
|
|
50
|
+
export declare function getParagraphPlaceholderLayouts(page: IDocumentSkeletonPage, body: IDocumentBody, locale: IParagraphPlaceholderLocale, pageLeft?: number, pageTop?: number, activeOffset?: number): IParagraphPlaceholderLayout[];
|
|
51
|
+
export {};
|
|
@@ -15,7 +15,7 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { DocumentDataModel } from '@univerjs/core';
|
|
17
17
|
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
|
|
18
|
-
import { ICommandService, IUniverInstanceService, RxDisposable } from '@univerjs/core';
|
|
18
|
+
import { ICommandService, IUniverInstanceService, RxDisposable, ThemeService } from '@univerjs/core';
|
|
19
19
|
import { DocSelectionManagerService, DocSkeletonManagerService } from '@univerjs/docs';
|
|
20
20
|
import { IRenderManagerService } from '@univerjs/engine-render';
|
|
21
21
|
import { DocPageLayoutService } from '../../services/doc-page-layout.service';
|
|
@@ -31,15 +31,18 @@ export declare class DocRenderController extends RxDisposable implements IRender
|
|
|
31
31
|
private readonly _univerInstanceService;
|
|
32
32
|
private readonly _docPageLayoutService;
|
|
33
33
|
private readonly _textSelectionManagerService;
|
|
34
|
-
|
|
34
|
+
private readonly _themeService;
|
|
35
|
+
constructor(_context: IRenderContext<DocumentDataModel>, _commandService: ICommandService, _docSelectionRenderService: DocSelectionRenderService, _docSkeletonManagerService: DocSkeletonManagerService, _editorService: IEditorService, _renderManagerService: IRenderManagerService, _univerInstanceService: IUniverInstanceService, _docPageLayoutService: DocPageLayoutService, _textSelectionManagerService: DocSelectionManagerService, _themeService: ThemeService);
|
|
35
36
|
reRender(unitId: string): void;
|
|
36
37
|
private _addNewRender;
|
|
37
38
|
private _addComponent;
|
|
38
39
|
private _initRenderRefresh;
|
|
39
40
|
private _create;
|
|
40
41
|
private _initCommandListener;
|
|
42
|
+
private _initThemeListener;
|
|
41
43
|
private _refreshPagePositionAndSelection;
|
|
42
44
|
private _recalculateSizeBySkeleton;
|
|
43
45
|
private _syncCanvasBackground;
|
|
44
46
|
private _getEditorBackgroundConfig;
|
|
47
|
+
private _isEditorRenderUnit;
|
|
45
48
|
}
|
|
@@ -19,6 +19,7 @@ import { Disposable, DocumentFlavor, ICommandService, IContextService, IUniverIn
|
|
|
19
19
|
import { DocSelectionManagerService, DocSkeletonManagerService } from '@univerjs/docs';
|
|
20
20
|
import { IRenderManagerService } from '@univerjs/engine-render';
|
|
21
21
|
import { DocPageLayoutService } from '../../services/doc-page-layout.service';
|
|
22
|
+
import { DocViewScaleService } from '../../services/doc-view-scale';
|
|
22
23
|
import { IEditorService } from '../../services/editor/editor-manager.service';
|
|
23
24
|
export declare function shouldHandleDocWheelZoom(event: Pick<IWheelEvent, 'ctrlKey' | 'metaKey'>, focusingDoc: boolean, _documentFlavor?: DocumentFlavor): boolean;
|
|
24
25
|
export declare class DocZoomRenderController extends Disposable implements IRenderModule {
|
|
@@ -31,10 +32,11 @@ export declare class DocZoomRenderController extends Disposable implements IRend
|
|
|
31
32
|
private readonly _editorService;
|
|
32
33
|
private readonly _docPageLayoutService;
|
|
33
34
|
private readonly _renderManagerService;
|
|
35
|
+
private readonly _docViewScaleService;
|
|
34
36
|
private _isSheetEditor;
|
|
35
37
|
private _initTimer;
|
|
36
38
|
private _updateTimer;
|
|
37
|
-
constructor(_context: IRenderContext<DocumentDataModel>, _contextService: IContextService, _docSkeletonManagerService: DocSkeletonManagerService, _univerInstanceService: IUniverInstanceService, _commandService: ICommandService, _textSelectionManagerService: DocSelectionManagerService, _editorService: IEditorService, _docPageLayoutService: DocPageLayoutService, _renderManagerService: IRenderManagerService);
|
|
39
|
+
constructor(_context: IRenderContext<DocumentDataModel>, _contextService: IContextService, _docSkeletonManagerService: DocSkeletonManagerService, _univerInstanceService: IUniverInstanceService, _commandService: ICommandService, _textSelectionManagerService: DocSelectionManagerService, _editorService: IEditorService, _docPageLayoutService: DocPageLayoutService, _renderManagerService: IRenderManagerService, _docViewScaleService: DocViewScaleService);
|
|
38
40
|
dispose(): void;
|
|
39
41
|
private _initSkeletonListener;
|
|
40
42
|
private _initCommandExecutedListener;
|
|
@@ -14,10 +14,9 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
import { Disposable, ICommandService, IConfigService, Injector, IUniverInstanceService } from '@univerjs/core';
|
|
17
|
-
import {
|
|
17
|
+
import { ILayoutService, IMenuManagerService, IShortcutService, IUIPartsService } from '@univerjs/ui';
|
|
18
18
|
export declare class DocUIController extends Disposable {
|
|
19
19
|
protected readonly _injector: Injector;
|
|
20
|
-
protected readonly _componentManager: ComponentManager;
|
|
21
20
|
protected readonly _commandService: ICommandService;
|
|
22
21
|
protected readonly _layoutService: ILayoutService;
|
|
23
22
|
protected readonly _menuManagerService: IMenuManagerService;
|
|
@@ -25,8 +24,7 @@ export declare class DocUIController extends Disposable {
|
|
|
25
24
|
protected readonly _univerInstanceService: IUniverInstanceService;
|
|
26
25
|
protected readonly _shortcutService: IShortcutService;
|
|
27
26
|
protected readonly _configService: IConfigService;
|
|
28
|
-
constructor(_injector: Injector,
|
|
29
|
-
private _initCustomComponents;
|
|
27
|
+
constructor(_injector: Injector, _commandService: ICommandService, _layoutService: ILayoutService, _menuManagerService: IMenuManagerService, _uiPartsService: IUIPartsService, _univerInstanceService: IUniverInstanceService, _shortcutService: IShortcutService, _configService: IConfigService);
|
|
30
28
|
private _initUiParts;
|
|
31
29
|
private _initMenus;
|
|
32
30
|
private _initShortCut;
|
|
@@ -13,57 +13,25 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import
|
|
17
|
-
|
|
18
|
-
|
|
19
|
-
export interface IDocumentInsertTextFacadeOptions {
|
|
20
|
-
startOffset?: number;
|
|
21
|
-
endOffset?: number;
|
|
22
|
-
segmentId?: string;
|
|
23
|
-
cursorOffset?: number;
|
|
16
|
+
import { FDocument } from '@univerjs/docs/facade';
|
|
17
|
+
interface IFDocumentUIMixin {
|
|
18
|
+
setSelection(startOffset: number, endOffset: number): void;
|
|
24
19
|
}
|
|
25
|
-
|
|
26
|
-
* @hideconstructor
|
|
27
|
-
*/
|
|
28
|
-
export declare class FDocument {
|
|
29
|
-
private readonly _documentDataModel;
|
|
30
|
-
protected readonly _injector: Injector;
|
|
31
|
-
private readonly _univerInstanceService;
|
|
32
|
-
private readonly _commandService;
|
|
33
|
-
private readonly _resourceManagerService;
|
|
34
|
-
private readonly _renderManagerService;
|
|
35
|
-
readonly id: string;
|
|
36
|
-
constructor(_documentDataModel: DocumentDataModel, _injector: Injector, _univerInstanceService: IUniverInstanceService, _commandService: ICommandService, _resourceManagerService: IResourceManagerService, _renderManagerService: IRenderManagerService);
|
|
37
|
-
getId(): string;
|
|
38
|
-
getName(): string;
|
|
39
|
-
getSnapshot(): IDocumentData;
|
|
40
|
-
undo(): Promise<boolean>;
|
|
41
|
-
redo(): Promise<boolean>;
|
|
42
|
-
/**
|
|
43
|
-
* Adds the specified text to the end of this text region.
|
|
44
|
-
* @param text - The text to be added to the end of this text region.
|
|
45
|
-
*/
|
|
46
|
-
appendText(text: string): Promise<boolean>;
|
|
47
|
-
/**
|
|
48
|
-
* Inserts text at the provided document range. Defaults to appending before the final section break.
|
|
49
|
-
* @param text - The text to insert.
|
|
50
|
-
* @param options - Optional target range, segment id, and cursor offset.
|
|
51
|
-
*/
|
|
52
|
-
insertText(text: string, options?: IDocumentInsertTextFacadeOptions): Promise<boolean>;
|
|
53
|
-
/**
|
|
54
|
-
* Inserts one or more plain-text paragraphs at the provided document range.
|
|
55
|
-
* @param text - Paragraph text. Newlines are normalized to document paragraph separators.
|
|
56
|
-
* @param options - Optional target range, segment id, and cursor offset.
|
|
57
|
-
*/
|
|
58
|
-
insertParagraph(text?: string, options?: IDocumentInsertTextFacadeOptions): Promise<boolean>;
|
|
20
|
+
export declare class FDocumentUIMixin extends FDocument implements IFDocumentUIMixin {
|
|
59
21
|
/**
|
|
60
22
|
* Sets the selection to a specified text range in the document.
|
|
61
23
|
* @param startOffset - The starting offset of the selection in the document.
|
|
62
24
|
* @param endOffset - The ending offset of the selection in the document.
|
|
63
25
|
* @example
|
|
64
26
|
* ```typescript
|
|
65
|
-
*
|
|
27
|
+
* const fDocument = univerAPI.getActiveDocument();
|
|
28
|
+
* fDocument.setSelection(10, 20);
|
|
66
29
|
* ```
|
|
67
30
|
*/
|
|
68
31
|
setSelection(startOffset: number, endOffset: number): void;
|
|
69
32
|
}
|
|
33
|
+
declare module '@univerjs/docs/facade' {
|
|
34
|
+
interface FDocument extends IFDocumentUIMixin {
|
|
35
|
+
}
|
|
36
|
+
}
|
|
37
|
+
export {};
|
|
@@ -13,6 +13,5 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import './f-
|
|
17
|
-
export
|
|
18
|
-
export type * from './f-univer';
|
|
16
|
+
import './f-document';
|
|
17
|
+
export type * from './f-document';
|
package/lib/types/index.d.ts
CHANGED
|
@@ -16,36 +16,43 @@
|
|
|
16
16
|
import './global.css';
|
|
17
17
|
export type { IDocObjectParam } from './basics/component-tools';
|
|
18
18
|
export { getDocObject, getDocObjectById, neoGetDocObject } from './basics/component-tools';
|
|
19
|
-
export { addCustomDecorationBySelectionFactory, addCustomDecorationFactory, deleteCustomDecorationFactory } from './basics/custom-decoration-factory';
|
|
19
|
+
export { addCustomDecorationBySelectionFactory, addCustomDecorationFactory, deleteCustomDecorationFactory, } from './basics/custom-decoration-factory';
|
|
20
20
|
export * from './basics/docs-view-key';
|
|
21
21
|
export { hasParagraphInTable } from './basics/paragraph';
|
|
22
22
|
export { docDrawingPositionToTransform, transformToDocDrawingPosition } from './basics/transform-position';
|
|
23
|
-
export { AfterSpaceCommand, EnterCommand,
|
|
23
|
+
export { AfterSpaceCommand, EnterCommand, TabCommand } from './commands/commands/auto-format.command';
|
|
24
|
+
export type { ITabCommandParams } from './commands/commands/auto-format.command';
|
|
24
25
|
export { BreakLineCommand } from './commands/commands/break-line.command';
|
|
25
26
|
export { generateParagraphs } from './commands/commands/break-line.command';
|
|
26
27
|
export { DocCopyCommand, DocCutCommand, DocPasteCommand } from './commands/commands/clipboard.command';
|
|
27
|
-
export { CutContentCommand,
|
|
28
|
+
export { CutContentCommand, InnerPasteCommand } from './commands/commands/clipboard.inner.command';
|
|
29
|
+
export type { IInnerPasteCommandParams } from './commands/commands/clipboard.inner.command';
|
|
28
30
|
export type { IInnerCutCommandParams } from './commands/commands/clipboard.inner.command';
|
|
29
31
|
export { getCustomBlockIdsInSelections, getCutActionsFromDocRanges } from './commands/commands/clipboard.inner.command';
|
|
30
|
-
export {
|
|
31
|
-
export {
|
|
32
|
-
export { DeleteCustomBlockCommand, DeleteLeftCommand, DeleteRightCommand,
|
|
32
|
+
export { buildMoveDocBlockActions, MoveDocBlockCommand } from './commands/commands/doc-block-move.command';
|
|
33
|
+
export type { IMoveDocBlockCommandParams } from './commands/commands/doc-block-move.command';
|
|
34
|
+
export { DeleteCustomBlockCommand, DeleteLeftCommand, DeleteRightCommand, MergeTwoParagraphCommand, } from './commands/commands/doc-delete.command';
|
|
35
|
+
export type { IDeleteCustomBlockParams } from './commands/commands/doc-delete.command';
|
|
33
36
|
export { getCursorWhenDelete } from './commands/commands/doc-delete.command';
|
|
34
37
|
export { HorizontalLineCommand } from './commands/commands/doc-horizontal-line.command';
|
|
35
38
|
export { DocSelectAllCommand } from './commands/commands/doc-select-all.command';
|
|
36
|
-
export {
|
|
37
|
-
export {
|
|
38
|
-
export {
|
|
39
|
+
export { IMEInputCommand } from './commands/commands/ime-input.command';
|
|
40
|
+
export type { IIMEInputCommandParams } from './commands/commands/ime-input.command';
|
|
41
|
+
export { getStyleInTextRange, ResetInlineFormatTextBackgroundColorCommand, ResetInlineFormatTextColorCommand, SetInlineFormatBoldCommand, SetInlineFormatCommand, SetInlineFormatFontFamilyCommand, SetInlineFormatFontSizeCommand, SetInlineFormatItalicCommand, SetInlineFormatStrikethroughCommand, SetInlineFormatSubscriptCommand, SetInlineFormatSuperscriptCommand, SetInlineFormatTextBackgroundColorCommand, SetInlineFormatTextColorCommand, SetInlineFormatTextFillCommand, SetInlineFormatUnderlineCommand, } from './commands/commands/inline-format.command';
|
|
42
|
+
export { InsertCustomRangeCommand } from './commands/commands/insert-custom-range.command';
|
|
43
|
+
export type { IInsertCustomRangeCommandParams } from './commands/commands/insert-custom-range.command';
|
|
39
44
|
export { BulletListCommand, ChangeListNestingLevelCommand, ChangeListTypeCommand, CheckListCommand, ListOperationCommand, OrderListCommand, QuickListCommand, ToggleCheckListCommand, } from './commands/commands/list.command';
|
|
40
45
|
export { ChangeListNestingLevelType } from './commands/commands/list.command';
|
|
41
46
|
export { AlignCenterCommand, AlignJustifyCommand, AlignLeftCommand, AlignOperationCommand, AlignRightCommand, } from './commands/commands/paragraph-align.command';
|
|
42
47
|
export { ReplaceTextRunsCommand } from './commands/commands/replace-content.command';
|
|
43
|
-
export { CoverContentCommand,
|
|
48
|
+
export { CoverContentCommand, ReplaceContentCommand, ReplaceSelectionCommand, ReplaceSnapshotCommand, } from './commands/commands/replace-content.command';
|
|
49
|
+
export type { IReplaceSelectionCommandParams, IReplaceSnapshotCommandParams, } from './commands/commands/replace-content.command';
|
|
44
50
|
export { SetDocZoomRatioCommand } from './commands/commands/set-doc-zoom-ratio.command';
|
|
45
51
|
export { SetParagraphNamedStyleCommand } from './commands/commands/set-heading.command';
|
|
46
52
|
export { SwitchDocModeCommand } from './commands/commands/switch-doc-mode.command';
|
|
47
|
-
export { CreateDocTableCommand
|
|
48
|
-
export {
|
|
53
|
+
export { CreateDocTableCommand } from './commands/commands/table/doc-table-create.command';
|
|
54
|
+
export type { ICreateDocTableCommandParams } from './commands/commands/table/doc-table-create.command';
|
|
55
|
+
export { DocTableDeleteColumnsCommand, DocTableDeleteRowsCommand, DocTableDeleteTableCommand, } from './commands/commands/table/doc-table-delete.command';
|
|
49
56
|
export type { IDocTableDeleteColumnsCommandParams, IDocTableDeleteRowsCommandParams, IDocTableDeleteTableCommandParams, } from './commands/commands/table/doc-table-delete.command';
|
|
50
57
|
export type { IDocTableInsertColumnCommandParams, IDocTableInsertColumnLeftCommandParams, IDocTableInsertColumnRightCommandParams, IDocTableInsertRowAboveCommandParams, IDocTableInsertRowBellowCommandParams, IDocTableInsertRowCommandParams, } from './commands/commands/table/doc-table-insert.command';
|
|
51
58
|
export { DocTableInsertColumnCommand, DocTableInsertColumnLeftCommand, DocTableInsertColumnRightCommand, DocTableInsertRowAboveCommand, DocTableInsertRowBellowCommand, DocTableInsertRowCommand, } from './commands/commands/table/doc-table-insert.command';
|
|
@@ -53,33 +60,37 @@ export type { IDocTableTabCommandParams } from './commands/commands/table/doc-ta
|
|
|
53
60
|
export { DocTableTabCommand } from './commands/commands/table/doc-table-tab.command';
|
|
54
61
|
export { genTableSource, getEmptyTableCell, getEmptyTableRow, getTableColumn } from './commands/commands/table/table';
|
|
55
62
|
export { DocCreateTableOperation } from './commands/operations/doc-create-table.operation';
|
|
56
|
-
export {
|
|
63
|
+
export { MoveSelectionOperation } from './commands/operations/doc-cursor.operation';
|
|
64
|
+
export type { IMoveCursorOperationParams } from './commands/operations/doc-cursor.operation';
|
|
57
65
|
export { MoveCursorOperation } from './commands/operations/doc-cursor.operation';
|
|
58
|
-
export {
|
|
59
|
-
export {
|
|
60
|
-
export
|
|
61
|
-
export {
|
|
66
|
+
export { SetDocZoomRatioOperation } from './commands/operations/set-doc-zoom-ratio.operation';
|
|
67
|
+
export type { ISetDocZoomRatioOperationParams } from './commands/operations/set-doc-zoom-ratio.operation';
|
|
68
|
+
export { getCommandSkeleton } from './commands/util';
|
|
69
|
+
export type { DocFitAlign, DocFitMode, DocFitTarget, IDocFitToWidthOptions, IUniverDocsUIConfig } from './config/config';
|
|
70
|
+
export { DEFAULT_DOC_FIT_TO_WIDTH_OPTIONS } from './config/config';
|
|
62
71
|
export { DocBackScrollRenderController } from './controllers/render-controllers/back-scroll.render-controller';
|
|
72
|
+
export { DocParagraphPlaceholderRenderController, } from './controllers/render-controllers/doc-paragraph-placeholder.render-controller';
|
|
63
73
|
export { DocRenderController } from './controllers/render-controllers/doc.render-controller';
|
|
64
|
-
export {
|
|
65
|
-
export {
|
|
74
|
+
export { DocUIController } from './controllers/ui.controller';
|
|
75
|
+
export { AlignMenuItemFactory, BackgroundColorSelectorMenuItemFactory, BoldMenuItemFactory, FLOAT_TEXT_STYLE_MENU_ID, FLOAT_TOOLBAR_MENU_POSITION, FloatTextStyleMenuItemFactory, FontFamilySelectorMenuItemFactory, FontSizeSelectorMenuItemFactory, hideMenuWhenSelectionInBlockRange, isTextRangeInAnyBlockRange, ItalicMenuItemFactory, StrikeThroughMenuItemFactory, TextColorSelectorMenuItemFactory, UnderlineMenuItemFactory, } from './menu/menu';
|
|
76
|
+
export { DOC_CONTENT_INSERT_MENU_ID, DOC_PARAGRAPH_T_ALIGN_MENU_ID, DOC_PARAGRAPH_T_COLORS_MENU_ID, DOC_PARAGRAPH_T_DIVIDER_MENU_ID, DOC_PARAGRAPH_T_EDIT_MENU_ID, DOC_PARAGRAPH_T_INSERT_BELOW_MENU_ID, DOC_PARAGRAPH_T_INSERT_MENU_ID, DOC_TABLE_BLOCK_MENU_ID, EMPTY_PARAGRAPH_MENU_ID, getDocBlockRangeMenuId, INSERT_BELLOW_MENU_ID, ParagraphMenuInsertBelowSubmenuItemFactory, } from './menu/paragraph-menu';
|
|
66
77
|
export { menuSchema as DocsUIMenuSchema } from './menu/schema';
|
|
67
78
|
export { UniverDocsUIPlugin } from './plugin';
|
|
68
79
|
export * from './services';
|
|
69
80
|
export { IDocClipboardService } from './services/clipboard/clipboard.service';
|
|
70
81
|
export { convertBodyToHtml } from './services/clipboard/udm-to-html/convertor';
|
|
71
82
|
export { DocAutoFormatService } from './services/doc-auto-format.service';
|
|
72
|
-
export {
|
|
73
|
-
export {
|
|
83
|
+
export { DocEventManagerService, getListMarkerFallbackBound, getListParagraphContextMenuHit, } from './services/doc-event-manager.service';
|
|
84
|
+
export type { IBulletBound, IMutiPageParagraphBound } from './services/doc-event-manager.service';
|
|
74
85
|
export { DocIMEInputManagerService } from './services/doc-ime-input-manager.service';
|
|
75
86
|
export { DocParagraphMenuService } from './services/doc-paragraph-menu.service';
|
|
76
87
|
export { calcDocRangePositions, DocCanvasPopManagerService } from './services/doc-popup-manager.service';
|
|
77
|
-
export { DocPrintInterceptorService
|
|
78
|
-
export {
|
|
88
|
+
export { DocPrintInterceptorService } from './services/doc-print-interceptor.service';
|
|
89
|
+
export type { IDocPrintComponentContext, IDocPrintContext } from './services/doc-print-interceptor.service';
|
|
79
90
|
export { DocsRenderService } from './services/docs-render.service';
|
|
80
91
|
export { Editor } from './services/editor/editor';
|
|
81
92
|
export { EditorService, IEditorService } from './services/editor/editor-manager.service';
|
|
82
|
-
export { isInSameTableCell, isValidRectRange, NodePositionConvertToRectRange } from './services/selection/convert-rect-range';
|
|
93
|
+
export { isInSameTableCell, isValidRectRange, NodePositionConvertToRectRange, } from './services/selection/convert-rect-range';
|
|
83
94
|
export { NodePositionConvertToCursor } from './services/selection/convert-text-range';
|
|
84
95
|
export { getOneTextSelectionRange } from './services/selection/convert-text-range';
|
|
85
96
|
export type { IEditorInputConfig } from './services/selection/doc-selection-render.service';
|
|
@@ -90,5 +101,7 @@ export { getCanvasOffsetByEngine } from './services/selection/selection-utils';
|
|
|
90
101
|
export { getAnchorBounding, getLineBounding, TEXT_RANGE_LAYER_INDEX, TextRange } from './services/selection/text-range';
|
|
91
102
|
export { whenDocAndEditorFocused } from './shortcuts/utils';
|
|
92
103
|
export { DOC_VERTICAL_PADDING } from './types/const/padding';
|
|
93
|
-
export {
|
|
94
|
-
export
|
|
104
|
+
export { createEditorUndoRedoKeyboardConfig, executeEditorUndoRedoCommand, useEditor, useEditorClickOutside, useIsFocusing, useKeyboardEvent, useLeftAndRightArrow, useOnChange, useResize, } from './views/rich-text-editor/hooks';
|
|
105
|
+
export type { ICreateEditorUndoRedoKeyboardConfigOptions, IExecuteEditorUndoRedoCommandOptions, IKeyboardEventConfig, } from './views/rich-text-editor/hooks';
|
|
106
|
+
export { RichTextEditor } from './views/RichTextEditor';
|
|
107
|
+
export type { IRichTextEditorProps } from './views/RichTextEditor';
|
|
@@ -50,6 +50,17 @@ declare const locale: {
|
|
|
50
50
|
horizontalLine: string;
|
|
51
51
|
headerFooter: string;
|
|
52
52
|
pageSetup: string;
|
|
53
|
+
heading: {
|
|
54
|
+
tooltip: string;
|
|
55
|
+
normal: string;
|
|
56
|
+
leading1: string;
|
|
57
|
+
leading2: string;
|
|
58
|
+
leading3: string;
|
|
59
|
+
leading4: string;
|
|
60
|
+
leading5: string;
|
|
61
|
+
title: string;
|
|
62
|
+
subTitle: string;
|
|
63
|
+
};
|
|
53
64
|
};
|
|
54
65
|
table: {
|
|
55
66
|
insert: string;
|
|
@@ -73,6 +84,15 @@ declare const locale: {
|
|
|
73
84
|
closeHeaderFooter: string;
|
|
74
85
|
disableText: string;
|
|
75
86
|
};
|
|
87
|
+
placeholder: {
|
|
88
|
+
heading1: string;
|
|
89
|
+
heading2: string;
|
|
90
|
+
heading3: string;
|
|
91
|
+
heading4: string;
|
|
92
|
+
heading5: string;
|
|
93
|
+
normalText: string;
|
|
94
|
+
listItem: string;
|
|
95
|
+
};
|
|
76
96
|
doc: {
|
|
77
97
|
menu: {
|
|
78
98
|
paragraphSetting: string;
|
|
@@ -92,6 +112,8 @@ declare const locale: {
|
|
|
92
112
|
after: string;
|
|
93
113
|
lineSpace: string;
|
|
94
114
|
multiSpace: string;
|
|
115
|
+
atLeast: string;
|
|
116
|
+
exactly: string;
|
|
95
117
|
fixedValue: string;
|
|
96
118
|
};
|
|
97
119
|
};
|
|
@@ -105,6 +127,18 @@ declare const locale: {
|
|
|
105
127
|
checkList: string;
|
|
106
128
|
insertBellow: string;
|
|
107
129
|
};
|
|
130
|
+
paragraphMenu: {
|
|
131
|
+
alignAndIndent: string;
|
|
132
|
+
align: string;
|
|
133
|
+
indent: string;
|
|
134
|
+
color: string;
|
|
135
|
+
increase: string;
|
|
136
|
+
decrease: string;
|
|
137
|
+
increaseIndent: string;
|
|
138
|
+
decreaseIndent: string;
|
|
139
|
+
defaultTextColor: string;
|
|
140
|
+
noBackground: string;
|
|
141
|
+
};
|
|
108
142
|
'page-settings': {
|
|
109
143
|
'document-setting': string;
|
|
110
144
|
mode: string;
|
|
@@ -13,4 +13,6 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
|
|
16
|
+
import type { LocaleLeafKeys } from '@univerjs/core';
|
|
17
|
+
import type enUS from './en-US';
|
|
18
|
+
export type LocaleKey = LocaleLeafKeys<typeof enUS>;
|
|
@@ -15,19 +15,20 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { IAccessor } from '@univerjs/core';
|
|
17
17
|
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
|
|
18
|
-
|
|
19
|
-
export declare
|
|
20
|
-
export declare
|
|
21
|
-
export declare
|
|
22
|
-
export declare
|
|
18
|
+
import type { LocaleKey } from '../locale/types';
|
|
19
|
+
export declare function CopyMenuFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
20
|
+
export declare function ParagraphSettingMenuFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
21
|
+
export declare function CutMenuFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
22
|
+
export declare function PasteMenuFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
23
|
+
export declare function DeleteMenuFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
23
24
|
export declare const TABLE_INSERT_MENU_ID = "doc.menu.table-insert";
|
|
24
|
-
export declare function TableInsertMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<
|
|
25
|
-
export declare function InsertRowBeforeMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
26
|
-
export declare function InsertRowAfterMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
27
|
-
export declare function InsertColumnLeftMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
28
|
-
export declare function InsertColumnRightMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
25
|
+
export declare function TableInsertMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey>;
|
|
26
|
+
export declare function InsertRowBeforeMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
27
|
+
export declare function InsertRowAfterMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
28
|
+
export declare function InsertColumnLeftMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
29
|
+
export declare function InsertColumnRightMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
29
30
|
export declare const TABLE_DELETE_MENU_ID = "doc.menu.table-delete";
|
|
30
|
-
export declare function TableDeleteMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<
|
|
31
|
-
export declare function DeleteRowsMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
32
|
-
export declare function DeleteColumnsMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
33
|
-
export declare function DeleteTableMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
31
|
+
export declare function TableDeleteMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey>;
|
|
32
|
+
export declare function DeleteRowsMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
33
|
+
export declare function DeleteColumnsMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
34
|
+
export declare function DeleteTableMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
package/lib/types/menu/menu.d.ts
CHANGED
|
@@ -15,41 +15,43 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { DocumentDataModel, IAccessor, ITextRangeParam, Nullable } from '@univerjs/core';
|
|
17
17
|
import type { IMenuButtonItem, IMenuItem, IMenuSelectorItem } from '@univerjs/ui';
|
|
18
|
-
import {
|
|
18
|
+
import type { LocaleKey } from '../locale/types';
|
|
19
|
+
import { HorizontalAlign, NamedStyleType, PresetListType } from '@univerjs/core';
|
|
19
20
|
import { Observable } from 'rxjs';
|
|
20
21
|
export declare function disableMenuWhenNoDocRange(accessor: IAccessor): Observable<boolean>;
|
|
21
22
|
export declare function isTextRangeInAnyBlockRange(document: Nullable<DocumentDataModel>, range: ITextRangeParam): boolean;
|
|
22
23
|
export declare function hideMenuWhenSelectionInBlockRange(accessor: IAccessor): Observable<boolean>;
|
|
23
|
-
export declare function BoldMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
24
|
-
export declare function ItalicMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
25
|
-
export declare function UnderlineMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
26
|
-
export declare function StrikeThroughMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
27
|
-
export declare function SubscriptMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
28
|
-
export declare function SuperscriptMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
29
|
-
export declare function FontFamilySelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<string>;
|
|
30
|
-
export declare function FontSizeSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<number>;
|
|
31
|
-
export declare function HeadingSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<
|
|
24
|
+
export declare function BoldMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
25
|
+
export declare function ItalicMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
26
|
+
export declare function UnderlineMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
27
|
+
export declare function StrikeThroughMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
28
|
+
export declare function SubscriptMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
29
|
+
export declare function SuperscriptMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
30
|
+
export declare function FontFamilySelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, string, string>;
|
|
31
|
+
export declare function FontSizeSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, number>;
|
|
32
|
+
export declare function HeadingSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, NamedStyleType>;
|
|
32
33
|
export declare const FLOAT_TEXT_STYLE_MENU_ID = "doc.menu.float-text-style";
|
|
33
34
|
export declare const FLOAT_TOOLBAR_MENU_POSITION = "doc.menu.float-toolbar";
|
|
34
|
-
export declare function FloatTextStyleMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<string | number>;
|
|
35
|
-
export declare function TextColorSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<string, string | undefined>;
|
|
36
|
-
export declare function HeaderFooterMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
35
|
+
export declare function FloatTextStyleMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, string | number>;
|
|
36
|
+
export declare function TextColorSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, string, string | undefined>;
|
|
37
|
+
export declare function HeaderFooterMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
37
38
|
export declare const TableIcon = "GridIcon";
|
|
38
39
|
export declare const TABLE_MENU_ID = "doc.menu.table";
|
|
39
|
-
export declare function TableMenuFactory(accessor: IAccessor): IMenuItem
|
|
40
|
-
export declare function InsertTableMenuFactory(_accessor: IAccessor): IMenuButtonItem
|
|
41
|
-
export declare function InsertDefaultTableMenuFactory(_accessor: IAccessor): IMenuButtonItem
|
|
42
|
-
export declare function AlignLeftMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
43
|
-
export declare function AlignCenterMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
44
|
-
export declare function AlignRightMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
45
|
-
export declare function AlignJustifyMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
46
|
-
export declare function AlignMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<HorizontalAlign, HorizontalAlign>;
|
|
47
|
-
export declare function HorizontalLineFactory(accessor: IAccessor): IMenuButtonItem
|
|
48
|
-
export declare function OrderListMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<PresetListType, PresetListType | undefined>;
|
|
49
|
-
export declare function BulletListMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<PresetListType, PresetListType | undefined>;
|
|
50
|
-
export declare function CheckListMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
51
|
-
export declare function DocSwitchModeMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
52
|
-
export declare function
|
|
53
|
-
export declare function
|
|
40
|
+
export declare function TableMenuFactory(accessor: IAccessor): IMenuItem<LocaleKey>;
|
|
41
|
+
export declare function InsertTableMenuFactory(_accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
42
|
+
export declare function InsertDefaultTableMenuFactory(_accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
43
|
+
export declare function AlignLeftMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
44
|
+
export declare function AlignCenterMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
45
|
+
export declare function AlignRightMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
46
|
+
export declare function AlignJustifyMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
47
|
+
export declare function AlignMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, HorizontalAlign, HorizontalAlign>;
|
|
48
|
+
export declare function HorizontalLineFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
49
|
+
export declare function OrderListMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, PresetListType | undefined, PresetListType | undefined>;
|
|
50
|
+
export declare function BulletListMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, PresetListType | undefined, PresetListType | undefined>;
|
|
51
|
+
export declare function CheckListMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
52
|
+
export declare function DocSwitchModeMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
53
|
+
export declare function ResetTextColorMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
54
|
+
export declare function ResetBackgroundColorMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
55
|
+
export declare function BackgroundColorSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, string, string | undefined>;
|
|
54
56
|
export declare function getParagraphStyleAtCursor(accessor: IAccessor): import("@univerjs/core").IParagraph | null | undefined;
|
|
55
|
-
export declare function PageSettingMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
57
|
+
export declare function PageSettingMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|