@univerjs-pro/boards-ui 1.0.0-beta.0 → 1.0.0-beta.1
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/lib/cjs/facade.js +1 -1
- package/lib/cjs/index.js +1 -1
- package/lib/cjs/locale/ar-SA.js +1 -1
- package/lib/cjs/locale/ca-ES.js +1 -1
- package/lib/cjs/locale/de-DE.js +1 -1
- package/lib/cjs/locale/en-US.js +1 -1
- package/lib/cjs/locale/es-ES.js +1 -1
- package/lib/cjs/locale/fa-IR.js +1 -1
- package/lib/cjs/locale/fr-FR.js +1 -1
- package/lib/cjs/locale/id-ID.js +1 -1
- package/lib/cjs/locale/it-IT.js +1 -1
- package/lib/cjs/locale/ja-JP.js +1 -1
- package/lib/cjs/locale/ko-KR.js +1 -1
- package/lib/cjs/locale/pl-PL.js +1 -1
- package/lib/cjs/locale/pt-BR.js +1 -1
- package/lib/cjs/locale/ru-RU.js +1 -1
- package/lib/cjs/locale/sk-SK.js +1 -1
- package/lib/cjs/locale/vi-VN.js +1 -1
- package/lib/cjs/locale/zh-CN.js +1 -1
- package/lib/cjs/locale/zh-HK.js +1 -1
- package/lib/cjs/locale/zh-TW.js +1 -1
- package/lib/cjs/shape-preset-labels-C4G0G9GI.js +1 -1
- package/lib/es/facade.js +1 -1
- package/lib/es/index.js +1 -1
- package/lib/es/locale/ar-SA.js +1 -1
- package/lib/es/locale/ca-ES.js +1 -1
- package/lib/es/locale/de-DE.js +1 -1
- package/lib/es/locale/en-US.js +1 -1
- package/lib/es/locale/es-ES.js +1 -1
- package/lib/es/locale/fa-IR.js +1 -1
- package/lib/es/locale/fr-FR.js +1 -1
- package/lib/es/locale/id-ID.js +1 -1
- package/lib/es/locale/it-IT.js +1 -1
- package/lib/es/locale/ja-JP.js +1 -1
- package/lib/es/locale/ko-KR.js +1 -1
- package/lib/es/locale/pl-PL.js +1 -1
- package/lib/es/locale/pt-BR.js +1 -1
- package/lib/es/locale/ru-RU.js +1 -1
- package/lib/es/locale/sk-SK.js +1 -1
- package/lib/es/locale/vi-VN.js +1 -1
- package/lib/es/locale/zh-CN.js +1 -1
- package/lib/es/locale/zh-HK.js +1 -1
- package/lib/es/locale/zh-TW.js +1 -1
- package/lib/es/shape-preset-labels-092BdVw3.js +1 -1
- package/lib/facade.js +1 -1
- package/lib/index.css +32 -40
- package/lib/index.js +1 -1
- package/lib/locale/ar-SA.js +1 -1
- package/lib/locale/ca-ES.js +1 -1
- package/lib/locale/de-DE.js +1 -1
- package/lib/locale/en-US.js +1 -1
- package/lib/locale/es-ES.js +1 -1
- package/lib/locale/fa-IR.js +1 -1
- package/lib/locale/fr-FR.js +1 -1
- package/lib/locale/id-ID.js +1 -1
- package/lib/locale/it-IT.js +1 -1
- package/lib/locale/ja-JP.js +1 -1
- package/lib/locale/ko-KR.js +1 -1
- package/lib/locale/pl-PL.js +1 -1
- package/lib/locale/pt-BR.js +1 -1
- package/lib/locale/ru-RU.js +1 -1
- package/lib/locale/sk-SK.js +1 -1
- package/lib/locale/vi-VN.js +1 -1
- package/lib/locale/zh-CN.js +1 -1
- package/lib/locale/zh-HK.js +1 -1
- package/lib/locale/zh-TW.js +1 -1
- package/lib/shape-preset-labels-092BdVw3.js +1 -1
- package/lib/types/commands/commands/analyze-board-rendered-layout.command.d.ts +2 -1
- package/lib/types/commands/operations/board-chart-dialog.operation.d.ts +2 -2
- package/lib/types/commands/operations/board-pointer.operation.d.ts +8 -0
- package/lib/types/commands/operations/board-selection.operation.d.ts +4 -2
- package/lib/types/commands/operations/board-ui-control.operation.d.ts +30 -0
- package/lib/types/common/board-shortcuts.d.ts +1 -3
- package/lib/types/config/config.d.ts +29 -2
- package/lib/types/const.d.ts +2 -0
- package/lib/types/controllers/board-clipboard-shortcut.controller.d.ts +2 -21
- package/lib/types/controllers/board-connector-interaction.render-controller.d.ts +1 -0
- package/lib/types/controllers/board-element-selection.controller.d.ts +1 -0
- package/lib/types/controllers/board-element-transform.controller.d.ts +3 -0
- package/lib/types/controllers/board-element-transformer-config.util.d.ts +1 -0
- package/lib/types/controllers/board-grouping-shortcut.controller.d.ts +2 -14
- package/lib/types/controllers/board-history-shortcut.controller.d.ts +2 -8
- package/lib/types/controllers/board-layout-shortcut.controller.d.ts +2 -14
- package/lib/types/controllers/board-order-shortcut.controller.d.ts +2 -10
- package/lib/types/controllers/board-render.controller.d.ts +1 -0
- package/lib/types/controllers/board-selection-shortcut.controller.d.ts +2 -14
- package/lib/types/controllers/board-settings-shortcut.controller.d.ts +2 -14
- package/lib/types/controllers/board-swimlane-lane-shortcut.controller.d.ts +5 -17
- package/lib/types/controllers/board-tool-shortcut.controller.d.ts +5 -16
- package/lib/types/controllers/board-unit-presence.controller.d.ts +6 -0
- package/lib/types/controllers/board-unit-presence.render-controller.d.ts +37 -0
- package/lib/types/controllers/board-view-shortcut.controller.d.ts +2 -23
- package/lib/types/controllers/board-viewport-bar.render-controller.d.ts +41 -0
- package/lib/types/facade/f-board-ui.d.ts +19 -0
- package/lib/types/facade/index.d.ts +1 -0
- package/lib/types/index.d.ts +7 -4
- package/lib/types/locale/en-US.d.ts +1 -0
- package/lib/types/plugin.d.ts +6 -0
- package/lib/types/render-objects/board-connector-object.d.ts +17 -5
- package/lib/types/render-objects/board-viewport-bar-object.d.ts +33 -0
- package/lib/types/services/board-canvas-pop-manager.service.d.ts +3 -1
- package/lib/types/services/board-clipboard.service.d.ts +10 -3
- package/lib/types/services/board-element-edit.service.d.ts +2 -0
- package/lib/types/services/board-embed-integration.service.d.ts +9 -0
- package/lib/types/services/board-find.service.d.ts +1 -0
- package/lib/types/services/board-image-insert.service.d.ts +3 -1
- package/lib/types/services/board-pointer-state.service.d.ts +21 -0
- package/lib/types/services/board-settings.service.d.ts +3 -5
- package/lib/types/services/board-shortcut-runtime.service.d.ts +32 -0
- package/lib/types/services/board-text-editing.service.d.ts +9 -4
- package/lib/types/services/board-ui-state.service.d.ts +2 -1
- package/lib/types/services/board-unit-presence-ui-adapter.service.d.ts +32 -0
- package/lib/types/services/board-viewport.service.d.ts +2 -1
- package/lib/types/utils/board-connector-hit-test.util.d.ts +2 -0
- package/lib/types/utils/board-connector-marker-anchor.util.d.ts +0 -1
- package/lib/types/utils/board-connector-marker.util.d.ts +21 -0
- package/lib/types/utils/board-connector-quick-connect.util.d.ts +1 -0
- package/lib/types/utils/board-connector-render-bounds.util.d.ts +0 -1
- package/lib/types/utils/board-connector-render-geometry.util.d.ts +33 -0
- package/lib/types/utils/board-connector-routing.util.d.ts +13 -1
- package/lib/types/utils/board-page-background-image.util.d.ts +15 -0
- package/lib/types/utils/board-render-page.util.d.ts +10 -5
- package/lib/types/utils/board-shortcut-preconditions.util.d.ts +4 -2
- package/lib/types/utils/board-viewport-bar.util.d.ts +55 -0
- package/lib/types/utils/board-viewport.util.d.ts +1 -0
- package/lib/types/views/BoardConnectorFloatingToolbarControls.d.ts +8 -2
- package/lib/types/views/BoardFloatingToolPanel.d.ts +1 -0
- package/lib/types/views/BoardPageBackgroundView.d.ts +8 -0
- package/lib/types/views/BoardSettingsMenu.d.ts +14 -0
- package/lib/types/views/BoardShapeFloatingToolbar.d.ts +2 -3
- package/lib/umd/facade.js +1 -1
- package/lib/umd/index.js +1 -1
- 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 +17 -17
package/lib/types/const.d.ts
CHANGED
|
@@ -13,6 +13,7 @@ export declare const BOARD_RENDER_LAYER_INDEX: {
|
|
|
13
13
|
readonly connectorAffordance: 5;
|
|
14
14
|
readonly connectorHandle: 6;
|
|
15
15
|
readonly connectorSnap: 7;
|
|
16
|
+
readonly viewportBar: 8;
|
|
16
17
|
};
|
|
17
18
|
export declare const BOARD_RENDER_OBJECT_Z_INDEX: {
|
|
18
19
|
readonly background: -1;
|
|
@@ -25,4 +26,5 @@ export declare const BOARD_RENDER_OBJECT_Z_INDEX: {
|
|
|
25
26
|
readonly transientEditHandle: 10003;
|
|
26
27
|
readonly transientSnap: 10004;
|
|
27
28
|
readonly transientResize: 10005;
|
|
29
|
+
readonly transientNavigation: 10006;
|
|
28
30
|
};
|
|
@@ -1,27 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { ICommandService, IConfigService, IUniverInstanceService, RxDisposable } from '@univerjs/core';
|
|
3
|
-
import { IRenderManagerService } from '@univerjs/engine-render';
|
|
1
|
+
import { ICommandService, RxDisposable } from '@univerjs/core';
|
|
4
2
|
import { IShortcutService } from '@univerjs/ui';
|
|
5
|
-
import { BoardClipboardService } from '../services/board-clipboard.service';
|
|
6
|
-
import { BoardElementEditService } from '../services/board-element-edit.service';
|
|
7
|
-
import { IBoardElementStateService } from '../services/board-element-state.service';
|
|
8
|
-
import { IBoardUIStateService } from '../services/board-ui-state.service';
|
|
9
3
|
export declare const BOARD_CLIPBOARD_SHORTCUT_OPERATION_ID = "board.operation.clipboard-shortcut";
|
|
10
4
|
export declare class BoardClipboardShortcutController extends RxDisposable {
|
|
11
|
-
private readonly _instanceService;
|
|
12
|
-
private readonly _configService;
|
|
13
|
-
private readonly _renderManagerService;
|
|
14
|
-
private readonly _elementStateService;
|
|
15
|
-
private readonly _stateService;
|
|
16
|
-
private readonly _clipboardService;
|
|
17
|
-
private readonly _elementEditService;
|
|
18
5
|
private readonly _commandService;
|
|
19
6
|
private readonly _shortcutService;
|
|
20
|
-
|
|
21
|
-
constructor(_instanceService: IUniverInstanceService, _configService: IConfigService, _renderManagerService: IRenderManagerService, _elementStateService: IBoardElementStateService, _stateService: IBoardUIStateService, _clipboardService: BoardClipboardService, _elementEditService: BoardElementEditService, _commandService: ICommandService, _shortcutService: IShortcutService, _boardElementService: IBoardElementService);
|
|
22
|
-
private _init;
|
|
23
|
-
private _createClipboardShortcutOperation;
|
|
24
|
-
private _createShortcutItem;
|
|
25
|
-
private _handleShortcut;
|
|
26
|
-
private _getCurrentBoardModel;
|
|
7
|
+
constructor(_commandService: ICommandService, _shortcutService: IShortcutService);
|
|
27
8
|
}
|
|
@@ -93,6 +93,7 @@ export declare class BoardConnectorInteractionRenderController extends RxDisposa
|
|
|
93
93
|
private _syncConnectorEditHandles;
|
|
94
94
|
private _commitConnectorPreviewUpdate;
|
|
95
95
|
private _activateConnectorDrag;
|
|
96
|
+
private _hasActiveConnectorDrag;
|
|
96
97
|
private _finishFreePolylineDraft;
|
|
97
98
|
private _clearQuickShapePopup;
|
|
98
99
|
private _insertQuickConnectedShape;
|
|
@@ -33,6 +33,7 @@ export declare class BoardElementSelectionController extends RxDisposable implem
|
|
|
33
33
|
private _selectionDraft;
|
|
34
34
|
constructor(_renderContext: IRenderContext<UnitModel>, _instanceSrv: IUniverInstanceService, _boardElementService: IBoardElementService, _stateSrv: IBoardElementStateService, _selectionService: BoardSelectionService, _selectionOverlayService: BoardSelectionOverlayService, _uiStateService: IBoardUIStateService, _contextMenuService: IContextMenuService, _platformService: IPlatformService, _inkStateService: IInkUIStateService, _inkEditService: IBoardInkEditService, _boardTextEditingService: BoardTextEditingService);
|
|
35
35
|
private _init;
|
|
36
|
+
private _subscribeToTransformerSelection;
|
|
36
37
|
private _subscribeToTextEditing;
|
|
37
38
|
private _wireScenePointerSelection;
|
|
38
39
|
private _startSelectionGesture;
|
|
@@ -23,6 +23,7 @@ export declare class BoardElementTransformController extends RxDisposable implem
|
|
|
23
23
|
private _isForceCaptureModifierActive;
|
|
24
24
|
private _shiftTransformStartRects;
|
|
25
25
|
private _areTransformerControlsHiddenForTransform;
|
|
26
|
+
private _previewConnectorIds;
|
|
26
27
|
private _xSnapSession;
|
|
27
28
|
private _ySnapSession;
|
|
28
29
|
constructor(_renderContext: IRenderContext<UnitModel>, _instanceSrv: IUniverInstanceService, _boardElementService: IBoardElementService, _stateSrv: IBoardElementStateService, _editService: BoardElementEditService, _domLayerService: BoardDomLayerService, _uiStateService?: IBoardUIStateService | undefined);
|
|
@@ -46,9 +47,11 @@ export declare class BoardElementTransformController extends RxDisposable implem
|
|
|
46
47
|
private _applyRealtimeTransformModifiers;
|
|
47
48
|
private _applyProportionalResize;
|
|
48
49
|
private _syncRealtimeTransformPreview;
|
|
50
|
+
private _updateRealtimeConnectorPreview;
|
|
49
51
|
private _syncContainerDescendantPreviews;
|
|
50
52
|
private _createRealtimePreviewElementData;
|
|
51
53
|
private _syncShapeBoundConnectorPreviews;
|
|
54
|
+
private _restoreConnectorPreviewsFromModel;
|
|
52
55
|
private _withPreviewConnectorTransform;
|
|
53
56
|
private _syncTransformToData;
|
|
54
57
|
private _subscribeToForceCaptureModifier;
|
|
@@ -1,20 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { ICommandService, IUniverInstanceService, RxDisposable } from '@univerjs/core';
|
|
1
|
+
import { ICommandService, RxDisposable } from '@univerjs/core';
|
|
3
2
|
import { IShortcutService } from '@univerjs/ui';
|
|
4
|
-
import { BoardElementEditService } from '../services/board-element-edit.service';
|
|
5
|
-
import { IBoardElementStateService } from '../services/board-element-state.service';
|
|
6
3
|
export declare const BOARD_GROUPING_SHORTCUT_OPERATION_ID = "board.operation.grouping-shortcut";
|
|
7
4
|
export declare class BoardGroupingShortcutController extends RxDisposable {
|
|
8
|
-
private readonly _instanceService;
|
|
9
|
-
private readonly _boardElementService;
|
|
10
|
-
private readonly _elementStateService;
|
|
11
|
-
private readonly _elementEditService;
|
|
12
5
|
private readonly _commandService;
|
|
13
6
|
private readonly _shortcutService;
|
|
14
|
-
constructor(
|
|
15
|
-
private _init;
|
|
16
|
-
private _createGroupingShortcutOperation;
|
|
17
|
-
private _createShortcutItem;
|
|
18
|
-
private _handleShortcut;
|
|
19
|
-
private _getCurrentBoardModel;
|
|
7
|
+
constructor(_commandService: ICommandService, _shortcutService: IShortcutService);
|
|
20
8
|
}
|
|
@@ -1,12 +1,6 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { RxDisposable } from '@univerjs/core';
|
|
2
2
|
import { IShortcutService } from '@univerjs/ui';
|
|
3
|
-
import { IBoardElementStateService } from '../services/board-element-state.service';
|
|
4
3
|
export declare class BoardHistoryShortcutController extends RxDisposable {
|
|
5
|
-
private readonly _instanceService;
|
|
6
|
-
private readonly _elementStateService;
|
|
7
4
|
private readonly _shortcutService;
|
|
8
|
-
constructor(
|
|
9
|
-
private _init;
|
|
10
|
-
private _createShortcutItem;
|
|
11
|
-
private _getCurrentBoardModel;
|
|
5
|
+
constructor(_shortcutService: IShortcutService);
|
|
12
6
|
}
|
|
@@ -1,20 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { ICommandService, IUniverInstanceService, RxDisposable } from '@univerjs/core';
|
|
1
|
+
import { ICommandService, RxDisposable } from '@univerjs/core';
|
|
3
2
|
import { IShortcutService } from '@univerjs/ui';
|
|
4
|
-
import { BoardElementEditService } from '../services/board-element-edit.service';
|
|
5
|
-
import { IBoardElementStateService } from '../services/board-element-state.service';
|
|
6
3
|
export declare const BOARD_LAYOUT_SHORTCUT_OPERATION_ID = "board.operation.layout-shortcut";
|
|
7
4
|
export declare class BoardLayoutShortcutController extends RxDisposable {
|
|
8
|
-
private readonly _instanceService;
|
|
9
|
-
private readonly _boardElementService;
|
|
10
|
-
private readonly _elementStateService;
|
|
11
|
-
private readonly _elementEditService;
|
|
12
5
|
private readonly _commandService;
|
|
13
6
|
private readonly _shortcutService;
|
|
14
|
-
constructor(
|
|
15
|
-
private _init;
|
|
16
|
-
private _createLayoutShortcutOperation;
|
|
17
|
-
private _createShortcutItem;
|
|
18
|
-
private _handleShortcut;
|
|
19
|
-
private _getCurrentBoardModel;
|
|
7
|
+
constructor(_commandService: ICommandService, _shortcutService: IShortcutService);
|
|
20
8
|
}
|
|
@@ -1,16 +1,8 @@
|
|
|
1
|
-
import { ICommandService,
|
|
1
|
+
import { ICommandService, RxDisposable } from '@univerjs/core';
|
|
2
2
|
import { IShortcutService } from '@univerjs/ui';
|
|
3
|
-
import { IBoardElementStateService } from '../services/board-element-state.service';
|
|
4
3
|
export declare const BOARD_ORDER_SHORTCUT_OPERATION_ID = "board.operation.order-shortcut";
|
|
5
4
|
export declare class BoardOrderShortcutController extends RxDisposable {
|
|
6
|
-
private readonly _instanceService;
|
|
7
|
-
private readonly _elementStateService;
|
|
8
5
|
private readonly _commandService;
|
|
9
6
|
private readonly _shortcutService;
|
|
10
|
-
constructor(
|
|
11
|
-
private _init;
|
|
12
|
-
private _createOrderShortcutOperation;
|
|
13
|
-
private _createShortcutItem;
|
|
14
|
-
private _handleShortcut;
|
|
15
|
-
private _getCurrentBoardModel;
|
|
7
|
+
constructor(_commandService: ICommandService, _shortcutService: IShortcutService);
|
|
16
8
|
}
|
|
@@ -35,6 +35,7 @@ export declare class BoardRenderController extends RxDisposable implements IRend
|
|
|
35
35
|
private _renderBoardElements;
|
|
36
36
|
private _resolveAddedElementDirtyIds;
|
|
37
37
|
private _syncRenderedObjectZIndexes;
|
|
38
|
+
private _syncRenderedElementOrder;
|
|
38
39
|
private _getBoardRenderObject;
|
|
39
40
|
private _resolveExistingBoardElementObjectLayerIndex;
|
|
40
41
|
private _resolveBoardElementObjectLayerIndex;
|
|
@@ -1,20 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { ICommandService, IUniverInstanceService, RxDisposable } from '@univerjs/core';
|
|
1
|
+
import { ICommandService, RxDisposable } from '@univerjs/core';
|
|
3
2
|
import { IShortcutService } from '@univerjs/ui';
|
|
4
|
-
import { BoardElementEditService } from '../services/board-element-edit.service';
|
|
5
|
-
import { IBoardElementStateService } from '../services/board-element-state.service';
|
|
6
3
|
export declare const BOARD_SELECTION_SHORTCUT_OPERATION_ID = "board.operation.selection-shortcut";
|
|
7
4
|
export declare class BoardSelectionShortcutController extends RxDisposable {
|
|
8
|
-
private readonly _instanceService;
|
|
9
|
-
private readonly _boardElementService;
|
|
10
|
-
private readonly _elementStateService;
|
|
11
|
-
private readonly _elementEditService;
|
|
12
5
|
private readonly _commandService;
|
|
13
6
|
private readonly _shortcutService;
|
|
14
|
-
constructor(
|
|
15
|
-
private _init;
|
|
16
|
-
private _createSelectionShortcutOperation;
|
|
17
|
-
private _createShortcutItem;
|
|
18
|
-
private _handleShortcut;
|
|
19
|
-
private _getCurrentBoardModel;
|
|
7
|
+
constructor(_commandService: ICommandService, _shortcutService: IShortcutService);
|
|
20
8
|
}
|
|
@@ -1,20 +1,8 @@
|
|
|
1
|
-
import { ICommandService,
|
|
1
|
+
import { ICommandService, RxDisposable } from '@univerjs/core';
|
|
2
2
|
import { IShortcutService } from '@univerjs/ui';
|
|
3
|
-
import { IBoardElementStateService } from '../services/board-element-state.service';
|
|
4
|
-
import { BoardSettingsService } from '../services/board-settings.service';
|
|
5
|
-
import { IBoardUIStateService } from '../services/board-ui-state.service';
|
|
6
3
|
export declare const BOARD_SETTINGS_SHORTCUT_OPERATION_ID = "board.operation.settings-shortcut";
|
|
7
4
|
export declare class BoardSettingsShortcutController extends RxDisposable {
|
|
8
|
-
private readonly _instanceService;
|
|
9
|
-
private readonly _elementStateService;
|
|
10
|
-
private readonly _stateService;
|
|
11
|
-
private readonly _settingsService;
|
|
12
5
|
private readonly _commandService;
|
|
13
6
|
private readonly _shortcutService;
|
|
14
|
-
constructor(
|
|
15
|
-
private _init;
|
|
16
|
-
private _createSettingsShortcutOperation;
|
|
17
|
-
private _createShortcutItem;
|
|
18
|
-
private _handleShortcut;
|
|
19
|
-
private _getCurrentBoardModel;
|
|
7
|
+
constructor(_commandService: ICommandService, _shortcutService: IShortcutService);
|
|
20
8
|
}
|
|
@@ -1,23 +1,11 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
1
|
+
import type { BoardSwimlaneLaneShortcutAction } from '../common/board-shortcuts';
|
|
2
|
+
import type { BoardShortcutRuntimeService } from '../services/board-shortcut-runtime.service';
|
|
3
|
+
import { ICommandService, RxDisposable } from '@univerjs/core';
|
|
3
4
|
import { IShortcutService } from '@univerjs/ui';
|
|
4
|
-
import { BoardElementEditService } from '../services/board-element-edit.service';
|
|
5
|
-
import { IBoardElementStateService } from '../services/board-element-state.service';
|
|
6
|
-
import { BoardSwimlaneLaneRenameService } from '../services/board-swimlane-lane-rename.service';
|
|
7
5
|
export declare const BOARD_SWIMLANE_LANE_SHORTCUT_OPERATION_ID = "board.operation.swimlane-lane-shortcut";
|
|
6
|
+
export declare function handleSwimlaneLaneShortcut(runtime: BoardShortcutRuntimeService, action: BoardSwimlaneLaneShortcutAction | undefined): Promise<boolean>;
|
|
8
7
|
export declare class BoardSwimlaneLaneShortcutController extends RxDisposable {
|
|
9
|
-
private readonly _instanceService;
|
|
10
|
-
private readonly _boardElementService;
|
|
11
|
-
private readonly _elementStateService;
|
|
12
|
-
private readonly _editService;
|
|
13
|
-
private readonly _renameService;
|
|
14
8
|
private readonly _commandService;
|
|
15
9
|
private readonly _shortcutService;
|
|
16
|
-
constructor(
|
|
17
|
-
private _init;
|
|
18
|
-
private _createShortcutOperation;
|
|
19
|
-
private _createShortcutItem;
|
|
20
|
-
private _canHandleFocusedLane;
|
|
21
|
-
private _handleShortcut;
|
|
22
|
-
private _getCurrentBoardModel;
|
|
10
|
+
constructor(_commandService: ICommandService, _shortcutService: IShortcutService);
|
|
23
11
|
}
|
|
@@ -1,22 +1,11 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import type { BoardToolShortcutAction } from '../common/board-shortcuts';
|
|
2
|
+
import type { BoardShortcutRuntimeService } from '../services/board-shortcut-runtime.service';
|
|
3
|
+
import { ICommandService, RxDisposable } from '@univerjs/core';
|
|
2
4
|
import { IShortcutService } from '@univerjs/ui';
|
|
3
|
-
import { IBoardElementStateService } from '../services/board-element-state.service';
|
|
4
|
-
import { BoardToolService } from '../services/board-tool.service';
|
|
5
|
-
import { IBoardUIStateService } from '../services/board-ui-state.service';
|
|
6
5
|
export declare const BOARD_TOOL_SHORTCUT_OPERATION_ID = "board.operation.tool-shortcut";
|
|
6
|
+
export declare function handleToolShortcut(runtime: BoardShortcutRuntimeService, action: BoardToolShortcutAction | undefined): boolean;
|
|
7
7
|
export declare class BoardToolShortcutController extends RxDisposable {
|
|
8
|
-
private readonly _instanceService;
|
|
9
|
-
private readonly _configService;
|
|
10
|
-
private readonly _elementStateService;
|
|
11
|
-
private readonly _stateService;
|
|
12
|
-
private readonly _toolService;
|
|
13
8
|
private readonly _commandService;
|
|
14
9
|
private readonly _shortcutService;
|
|
15
|
-
constructor(
|
|
16
|
-
private _init;
|
|
17
|
-
private _createToolShortcutOperation;
|
|
18
|
-
private _createShortcutItem;
|
|
19
|
-
private _handleShortcut;
|
|
20
|
-
private _canCancelTool;
|
|
21
|
-
private _getCurrentBoardModel;
|
|
10
|
+
constructor(_commandService: ICommandService, _shortcutService: IShortcutService);
|
|
22
11
|
}
|
|
@@ -0,0 +1,6 @@
|
|
|
1
|
+
import { Disposable } from '@univerjs/core';
|
|
2
|
+
import { IUnitPresenceUIAdapterRegistry } from '@univerjs/ui';
|
|
3
|
+
import { BoardUnitPresenceUIAdapter } from '../services/board-unit-presence-ui-adapter.service';
|
|
4
|
+
export declare class BoardUnitPresenceController extends Disposable {
|
|
5
|
+
constructor(adapterRegistry: IUnitPresenceUIAdapterRegistry, adapter: BoardUnitPresenceUIAdapter);
|
|
6
|
+
}
|
|
@@ -0,0 +1,37 @@
|
|
|
1
|
+
import type { BoardModel } from '@univerjs-pro/boards';
|
|
2
|
+
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
|
|
3
|
+
import { IBoardElementService } from '@univerjs-pro/boards';
|
|
4
|
+
import { ICommandService, RxDisposable, ThemeService } from '@univerjs/core';
|
|
5
|
+
import { IBoardUIStateService } from '../services/board-ui-state.service';
|
|
6
|
+
import { BoardUnitPresenceUIAdapter } from '../services/board-unit-presence-ui-adapter.service';
|
|
7
|
+
export declare class BoardUnitPresenceRenderController extends RxDisposable implements IRenderModule {
|
|
8
|
+
private readonly _context;
|
|
9
|
+
private readonly _presenceAdapter;
|
|
10
|
+
private readonly _commandService;
|
|
11
|
+
private readonly _boardElementService;
|
|
12
|
+
private readonly _boardUIStateService;
|
|
13
|
+
private readonly _themeService;
|
|
14
|
+
private readonly _selectionShapes;
|
|
15
|
+
private readonly _pointerAnimations;
|
|
16
|
+
private _animationFrameId;
|
|
17
|
+
private _renderScheduled;
|
|
18
|
+
private _isApplyingOverlays;
|
|
19
|
+
private _pointersVisible;
|
|
20
|
+
private _latestPresences;
|
|
21
|
+
constructor(_context: IRenderContext<BoardModel>, _presenceAdapter: BoardUnitPresenceUIAdapter, _commandService: ICommandService, _boardElementService: IBoardElementService, _boardUIStateService: IBoardUIStateService, _themeService: ThemeService);
|
|
22
|
+
dispose(): void;
|
|
23
|
+
private _init;
|
|
24
|
+
private _scheduleRender;
|
|
25
|
+
private _render;
|
|
26
|
+
private _publishLocalPointer;
|
|
27
|
+
private _clearLocalPointer;
|
|
28
|
+
private _clearLocalPointerIfActive;
|
|
29
|
+
private _syncPointers;
|
|
30
|
+
private _startAnimation;
|
|
31
|
+
private _animate;
|
|
32
|
+
private _cancelAnimation;
|
|
33
|
+
private _removePointer;
|
|
34
|
+
private _removeAllPointers;
|
|
35
|
+
private _removeSelectionShapes;
|
|
36
|
+
private _getSceneObjectByKey;
|
|
37
|
+
}
|
|
@@ -1,29 +1,8 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import { ICommandService, IConfigService, IUniverInstanceService, RxDisposable } from '@univerjs/core';
|
|
3
|
-
import { IRenderManagerService } from '@univerjs/engine-render';
|
|
1
|
+
import { ICommandService, RxDisposable } from '@univerjs/core';
|
|
4
2
|
import { IShortcutService } from '@univerjs/ui';
|
|
5
|
-
import { IBoardElementStateService } from '../services/board-element-state.service';
|
|
6
|
-
import { IBoardUIStateService } from '../services/board-ui-state.service';
|
|
7
|
-
import { BoardViewportService } from '../services/board-viewport.service';
|
|
8
3
|
export declare const BOARD_VIEW_SHORTCUT_OPERATION_ID = "board.operation.view-shortcut";
|
|
9
4
|
export declare class BoardViewShortcutController extends RxDisposable {
|
|
10
|
-
private readonly _instanceService;
|
|
11
|
-
private readonly _configService;
|
|
12
|
-
private readonly _renderManagerService;
|
|
13
|
-
private readonly _boardElementService;
|
|
14
|
-
private readonly _elementStateService;
|
|
15
|
-
private readonly _stateService;
|
|
16
|
-
private readonly _viewportService;
|
|
17
5
|
private readonly _commandService;
|
|
18
6
|
private readonly _shortcutService;
|
|
19
|
-
constructor(
|
|
20
|
-
private _init;
|
|
21
|
-
private _createViewShortcutOperation;
|
|
22
|
-
private _createShortcutItem;
|
|
23
|
-
private _handleShortcut;
|
|
24
|
-
private _getCurrentBoardModel;
|
|
25
|
-
private _getCanvasElement;
|
|
26
|
-
private _resolveViewportSize;
|
|
27
|
-
private _resolveViewportCenterPoint;
|
|
28
|
-
private _resolveFullscreenTarget;
|
|
7
|
+
constructor(_commandService: ICommandService, _shortcutService: IShortcutService);
|
|
29
8
|
}
|
|
@@ -0,0 +1,41 @@
|
|
|
1
|
+
import type { UnitModel } from '@univerjs/core';
|
|
2
|
+
import type { IRenderContext, IRenderModule } from '@univerjs/engine-render';
|
|
3
|
+
import { IBoardElementService } from '@univerjs-pro/boards';
|
|
4
|
+
import { IConfigService, IUniverInstanceService, RxDisposable, ThemeService } from '@univerjs/core';
|
|
5
|
+
import { IBoardUIStateService } from '../services/board-ui-state.service';
|
|
6
|
+
export declare class BoardViewportBarRenderController extends RxDisposable implements IRenderModule {
|
|
7
|
+
private readonly _renderContext;
|
|
8
|
+
private readonly _instanceSrv;
|
|
9
|
+
private readonly _boardElementService;
|
|
10
|
+
private readonly _configService;
|
|
11
|
+
private readonly _stateService;
|
|
12
|
+
private readonly _themeService;
|
|
13
|
+
private _barObject;
|
|
14
|
+
private _contentBounds;
|
|
15
|
+
private _drag;
|
|
16
|
+
private _layout;
|
|
17
|
+
private _navigationBounds;
|
|
18
|
+
private _ownsCursor;
|
|
19
|
+
private _pendingContentRefresh;
|
|
20
|
+
private _scheduledFrameId;
|
|
21
|
+
private _viewportPointerActive;
|
|
22
|
+
private _horizontalEnabled;
|
|
23
|
+
private _verticalEnabled;
|
|
24
|
+
constructor(_renderContext: IRenderContext<UnitModel>, _instanceSrv: IUniverInstanceService, _boardElementService: IBoardElementService, _configService: IConfigService, _stateService: IBoardUIStateService, _themeService: ThemeService);
|
|
25
|
+
dispose(): void;
|
|
26
|
+
private _init;
|
|
27
|
+
private _createInitialObjectState;
|
|
28
|
+
private _syncTheme;
|
|
29
|
+
private _handleElementChanges;
|
|
30
|
+
private _scheduleLayoutSync;
|
|
31
|
+
private _syncLayout;
|
|
32
|
+
private _resolveViewportPixelSize;
|
|
33
|
+
private _resolveContentBounds;
|
|
34
|
+
private _toWorldRect;
|
|
35
|
+
private _resolveSafeArea;
|
|
36
|
+
private _handleBarPointerDown;
|
|
37
|
+
private _handlePointerMove;
|
|
38
|
+
private _handlePointerEnd;
|
|
39
|
+
private _getBoardPoint;
|
|
40
|
+
private _setCursor;
|
|
41
|
+
}
|
|
@@ -0,0 +1,19 @@
|
|
|
1
|
+
import type { IBoardElementFindResult, IBoardSettings, IBoardViewportPoint } from '@univerjs-pro/boards-ui';
|
|
2
|
+
declare module '@univerjs-pro/boards/facade' {
|
|
3
|
+
interface FBoard {
|
|
4
|
+
/** Returns the effective settings for the current Board UI runtime. */
|
|
5
|
+
getSettings(): Required<IBoardSettings>;
|
|
6
|
+
/** Updates local settings for the current Board UI runtime. */
|
|
7
|
+
setSettings(settings: Partial<IBoardSettings>): boolean;
|
|
8
|
+
/** Returns whether the object-list panel is open for the active Board UI. */
|
|
9
|
+
getObjectListPanelOpen(): boolean;
|
|
10
|
+
/** Opens or closes the object-list panel after focusing this Board. */
|
|
11
|
+
setObjectListPanelOpen(open: boolean): boolean;
|
|
12
|
+
/** Searches the active page using the same text index as the top-right Find panel. */
|
|
13
|
+
findElementsByText(query: string): IBoardElementFindResult[];
|
|
14
|
+
/** Selects an element and pans the viewport so its center reaches the requested viewport point. */
|
|
15
|
+
focusElement(elementId: string, viewportPoint: IBoardViewportPoint): boolean;
|
|
16
|
+
/** Returns the element center in the current Board viewport coordinate system. */
|
|
17
|
+
getElementViewportPoint(elementId: string): IBoardViewportPoint | null;
|
|
18
|
+
}
|
|
19
|
+
}
|
package/lib/types/index.d.ts
CHANGED
|
@@ -6,10 +6,10 @@ export type { ICaptureBoardScreenshotCommandParams } from './commands/commands/c
|
|
|
6
6
|
export { BOARD_INSERT_CHART_DIALOG_ID, BOARD_INSERT_CHART_PANEL_COMPONENT, OpenBoardInsertChartDialogOperation, } from './commands/operations/board-chart-dialog.operation';
|
|
7
7
|
export type { IOpenBoardInsertChartDialogOperationParams } from './commands/operations/board-chart-dialog.operation';
|
|
8
8
|
export { BoardCopySelectionOperation, BoardCutSelectionOperation, BoardDeleteSelectionOperation, } from './commands/operations/board-selection.operation';
|
|
9
|
+
export { FindBoardElementsByTextOperation, FocusBoardElementOperation, GetBoardElementViewportPointOperation, GetBoardObjectListPanelOpenOperation, GetBoardSettingsOperation, SetBoardObjectListPanelOpenOperation, SetBoardSettingsOperation, } from './commands/operations/board-ui-control.operation';
|
|
9
10
|
export { BOARD_SHORTCUT_BINDINGS } from './common/board-shortcuts';
|
|
10
|
-
export { BOARDS_UI_PLUGIN_CONFIG_KEY } from './config/config';
|
|
11
|
-
export {
|
|
12
|
-
export type { BoardToolbarToolConfig, IUniverBoardsUIConfig, } from './config/config';
|
|
11
|
+
export { BOARDS_UI_PLUGIN_CONFIG_KEY, DEFAULT_BOARD_COLLABORATOR_CURSOR_SHARE_INTERVAL, DEFAULT_BOARD_SETTINGS, resolveBoardCollaboratorCursorShareInterval, resolveBoardRenderAdapters, } from './config/config';
|
|
12
|
+
export type { BoardToolbarToolConfig, IBoardSettings, IBoardViewportBarConfig, IBoardViewportBarPadding, IUniverBoardsUIConfig, } from './config/config';
|
|
13
13
|
export { BOARD_RENDER_LAYER_INDEX, BOARD_RENDER_OBJECT_Z_INDEX, } from './const';
|
|
14
14
|
export { BOARD_MAIN_VIEWPORT_KEY } from './controllers/board-render.controller';
|
|
15
15
|
export { UniverBoardsUIPlugin } from './plugin';
|
|
@@ -38,18 +38,21 @@ export { BoardShapeIntrinsicSizeService } from './services/board-shape-intrinsic
|
|
|
38
38
|
export type { IBoardShapeIntrinsicSizeHostUpdateContext, IBoardShapeIntrinsicSizeProvider, } from './services/board-shape-intrinsic-size.service';
|
|
39
39
|
export { BoardSidePanelService, IBoardSidePanelService } from './services/board-side-panel.service';
|
|
40
40
|
export type { BoardSidePanelCloseReason, IBoardSidePanelComponentDescriptor, IBoardSidePanelDescriptor, } from './services/board-side-panel.service';
|
|
41
|
-
export { BoardTextEditingService } from './services/board-text-editing.service';
|
|
41
|
+
export { areBoardShapeTextValuesEquivalent, BoardTextEditingService } from './services/board-text-editing.service';
|
|
42
42
|
export { BoardToolService } from './services/board-tool.service';
|
|
43
43
|
export { BoardToolbarContributionService, IBoardToolbarContributionService, } from './services/board-toolbar-contribution.service';
|
|
44
44
|
export type { BoardToolbarContributionGroup, IBoardToolbarContribution, } from './services/board-toolbar-contribution.service';
|
|
45
45
|
export { BoardUIStateService, IBoardUIStateService } from './services/board-ui-state.service';
|
|
46
46
|
export { BoardViewportService } from './services/board-viewport.service';
|
|
47
|
+
export type { IBoardElementFindResult } from './utils/board-find.util';
|
|
47
48
|
export { resolveRotatedBoardObjectAnchorBound } from './utils/board-floating-toolbar-anchor.util';
|
|
48
49
|
export { resolveBoardFloatingToolbarSelection } from './utils/board-floating-toolbar-selection.util';
|
|
49
50
|
export type { BoardFloatingToolbarOwner, IBoardFloatingToolbarSelection, IResolveBoardFloatingToolbarSelectionOptions, } from './utils/board-floating-toolbar-selection.util';
|
|
50
51
|
export { resolveBoardInteractionConfig } from './utils/board-interaction-config.util';
|
|
51
52
|
export { resolveBoardElementBounds } from './utils/board-selection-geometry.util';
|
|
53
|
+
export { resolveBoardWheelViewportAction } from './utils/board-viewport-input.util';
|
|
52
54
|
export { getBoardPointFromClient } from './utils/board-viewport.util';
|
|
55
|
+
export type { IBoardViewportPoint } from './utils/board-viewport.util';
|
|
53
56
|
export { BOARD_SETTINGS_MENU_ACTIONS_PART, BOARD_TOP_RIGHT_MENU_LEADING_PART } from './views/BoardSettingsMenu';
|
|
54
57
|
export { BoardShapeTextEditorContainer } from './views/BoardShapeTextEditorContainer';
|
|
55
58
|
export { BoardWorkbench } from './views/BoardWorkbench';
|
package/lib/types/plugin.d.ts
CHANGED
|
@@ -1,3 +1,4 @@
|
|
|
1
|
+
import type { Dependency } from '@univerjs/core';
|
|
1
2
|
import type { IUniverBoardsUIConfig } from './config/config';
|
|
2
3
|
import { ICommandService, IConfigService, Injector, Plugin, UniverInstanceType } from '@univerjs/core';
|
|
3
4
|
import { IRenderManagerService } from '@univerjs/engine-render';
|
|
@@ -15,7 +16,12 @@ export declare class UniverBoardsUIPlugin extends Plugin {
|
|
|
15
16
|
static packageName: string;
|
|
16
17
|
static version: string;
|
|
17
18
|
static type: UniverInstanceType;
|
|
19
|
+
private static readonly _runtimeScopedDependencies;
|
|
20
|
+
private static _getRuntimeScopedDependencies;
|
|
21
|
+
static getRuntimeScopedDependencies(injector: Injector): readonly Dependency[];
|
|
22
|
+
static registerRuntimeScopedDependencies(injector: Injector, dependencies: readonly Dependency[]): void;
|
|
18
23
|
constructor(_config: Partial<IUniverBoardsUIConfig> | undefined, _injector: Injector, _renderManagerService: IRenderManagerService, _uiPartsService: IUIPartsService, _commandService: ICommandService, _menuManagerService: IMenuManagerService, _configService: IConfigService);
|
|
19
24
|
onStarting(): void;
|
|
20
25
|
onReady(): void;
|
|
26
|
+
private _registerRenderModules;
|
|
21
27
|
}
|
|
@@ -2,7 +2,8 @@ import type { IBoardConnectorElement, IBoardConnectorPoint, IBoardElementData }
|
|
|
2
2
|
import type { IDocumentData, LocaleService } from '@univerjs/core';
|
|
3
3
|
import type { IObjectFullState, IViewportInfo, UniverRenderingContext, Vector2 } from '@univerjs/engine-render';
|
|
4
4
|
import type { IBoardConnectorLabelRect } from '../utils/board-connector-label.util';
|
|
5
|
-
import type {
|
|
5
|
+
import type { IBoardConnectorRenderGeometry } from '../utils/board-connector-render-geometry.util';
|
|
6
|
+
import type { BoardConnectorPathCommand, BoardConnectorRoutingCache } from '../utils/board-connector-routing.util';
|
|
6
7
|
import { BaseObject } from '@univerjs/engine-render';
|
|
7
8
|
import { resolveBoardConnectorPathBounds, resolveBoardConnectorPathCommands, resolveBoardConnectorRoutePoints } from '../utils/board-connector-routing.util';
|
|
8
9
|
export interface IBoardConnectorObjectProps {
|
|
@@ -24,6 +25,12 @@ export interface IBoardConnectorRouteCache {
|
|
|
24
25
|
routePoints: ReturnType<typeof resolveBoardConnectorRoutePoints>;
|
|
25
26
|
pathCommands: ReturnType<typeof resolveBoardConnectorPathCommands>;
|
|
26
27
|
bounds: ReturnType<typeof resolveBoardConnectorPathBounds>;
|
|
28
|
+
renderGeometry: IBoardConnectorRenderGeometry | null;
|
|
29
|
+
}
|
|
30
|
+
export interface IBoardConnectorObjectUpdateOptions {
|
|
31
|
+
preserveLineJumpCache?: boolean;
|
|
32
|
+
routeCache?: IBoardConnectorRouteCache;
|
|
33
|
+
skipLineJumps?: boolean;
|
|
27
34
|
}
|
|
28
35
|
interface IBoardConnectorLineJump {
|
|
29
36
|
x: number;
|
|
@@ -37,7 +44,9 @@ export declare class BoardConnectorLineJumpCache {
|
|
|
37
44
|
private readonly _routePointsByConnectorId;
|
|
38
45
|
private readonly _lineJumpsByConnectorId;
|
|
39
46
|
constructor(_resolveRoutePoints?: BoardConnectorRouteResolver);
|
|
40
|
-
invalidate(elementData?: Record<string, IBoardElementData
|
|
47
|
+
invalidate(elementData?: Record<string, IBoardElementData>, options?: {
|
|
48
|
+
force?: boolean;
|
|
49
|
+
}): void;
|
|
41
50
|
resolveLineJumpsForRoute(connectorId: string, routePoints: readonly IBoardConnectorPoint[]): readonly IBoardConnectorLineJump[][];
|
|
42
51
|
private _clear;
|
|
43
52
|
private _getRoutePoints;
|
|
@@ -51,28 +60,32 @@ export declare class BoardConnectorObject extends BaseObject {
|
|
|
51
60
|
private readonly _routingCache?;
|
|
52
61
|
private readonly _documentTextRenderCache;
|
|
53
62
|
private _routeCache;
|
|
63
|
+
private _labelGeometryCache;
|
|
54
64
|
private _routeStabilityHint;
|
|
55
65
|
private _isEditingLabel;
|
|
66
|
+
private _skipLineJumps;
|
|
56
67
|
isDrawingObject: boolean;
|
|
57
68
|
constructor(key: string, props: IBoardConnectorObjectProps);
|
|
58
|
-
updateElement(element: IBoardConnectorElement, elementData?: Record<string, IBoardElementData
|
|
69
|
+
updateElement(element: IBoardConnectorElement, elementData?: Record<string, IBoardElementData>, options?: IBoardConnectorObjectUpdateOptions): void;
|
|
59
70
|
getElement(): IBoardConnectorElement;
|
|
60
71
|
setEditing(isEditing: boolean): void;
|
|
61
72
|
getRoutePoints(): IBoardConnectorPoint[];
|
|
62
73
|
getCachedRoutePoints(): readonly IBoardConnectorPoint[] | null;
|
|
63
|
-
getPathCommands():
|
|
74
|
+
getPathCommands(): BoardConnectorPathCommand[];
|
|
64
75
|
getRenderBounds(): ReturnType<typeof resolveBoardConnectorPathBounds>;
|
|
65
76
|
getLabelPathPoints(): IBoardConnectorPoint[];
|
|
66
77
|
getLabelRect(): IBoardConnectorLabelRect | null;
|
|
67
78
|
measureLabelNaturalHeight(width: number, documentData?: IDocumentData): number | null;
|
|
68
79
|
isLabelHit(point: IBoardConnectorPoint): boolean;
|
|
69
80
|
private _getRouteCache;
|
|
81
|
+
private _getLabelGeometry;
|
|
70
82
|
private _getRenderBounds;
|
|
71
83
|
private _getCurrentRouteStabilityHint;
|
|
72
84
|
private _shouldUseRouteStabilityHint;
|
|
73
85
|
transformByState(option: IObjectFullState): this;
|
|
74
86
|
isHit(coord: Vector2): boolean;
|
|
75
87
|
hitTest(point: IBoardConnectorPoint): boolean;
|
|
88
|
+
getRenderGeometry(): IBoardConnectorRenderGeometry | null;
|
|
76
89
|
render(ctx: UniverRenderingContext, _bounds: IViewportInfo): this;
|
|
77
90
|
private _clipRouteAroundLabel;
|
|
78
91
|
private _drawRoute;
|
|
@@ -80,7 +93,6 @@ export declare class BoardConnectorObject extends BaseObject {
|
|
|
80
93
|
private _drawRouteWithLineJumps;
|
|
81
94
|
private _drawPathCommands;
|
|
82
95
|
private _drawMarkers;
|
|
83
|
-
private _resolveEndpointVisualGap;
|
|
84
96
|
private _drawLabel;
|
|
85
97
|
private _drawLabelFrame;
|
|
86
98
|
}
|
|
@@ -0,0 +1,33 @@
|
|
|
1
|
+
import type { IViewportInfo, UniverRenderingContext, Vector2 } from '@univerjs/engine-render';
|
|
2
|
+
import type { IBoardViewportBarRect } from '../utils/board-viewport-bar.util';
|
|
3
|
+
import { BaseObject } from '@univerjs/engine-render';
|
|
4
|
+
export type BoardViewportBarAxis = 'horizontal' | 'vertical';
|
|
5
|
+
export interface IBoardViewportBarObjectState {
|
|
6
|
+
activeAxis: BoardViewportBarAxis | null;
|
|
7
|
+
activeColor: string;
|
|
8
|
+
activeOpacity: number;
|
|
9
|
+
barSize: number;
|
|
10
|
+
hitSize: number;
|
|
11
|
+
horizontalRect: IBoardViewportBarRect | null;
|
|
12
|
+
hoverAxis: BoardViewportBarAxis | null;
|
|
13
|
+
hoverColor: string;
|
|
14
|
+
hoverOpacity: number;
|
|
15
|
+
idleColor: string;
|
|
16
|
+
idleOpacity: number;
|
|
17
|
+
verticalRect: IBoardViewportBarRect | null;
|
|
18
|
+
zoomRatio: number;
|
|
19
|
+
}
|
|
20
|
+
export declare const BOARD_VIEWPORT_BAR_OBJECT_KEY = "board-viewport-bar-object";
|
|
21
|
+
export declare const BOARD_VIEWPORT_BAR_OBJECT_LAYER_INDEX: 8;
|
|
22
|
+
type BoardViewportBarPoint = Pick<Vector2, 'x' | 'y'>;
|
|
23
|
+
export declare class BoardViewportBarObject extends BaseObject {
|
|
24
|
+
private _state;
|
|
25
|
+
constructor(key: string | undefined, state: IBoardViewportBarObjectState);
|
|
26
|
+
getBarState(): IBoardViewportBarObjectState;
|
|
27
|
+
updateState(state: Partial<IBoardViewportBarObjectState>): void;
|
|
28
|
+
resolveHitAxis(coord: BoardViewportBarPoint): BoardViewportBarAxis | null;
|
|
29
|
+
isHit(coord: Vector2): boolean;
|
|
30
|
+
render(ctx: UniverRenderingContext, _bounds: IViewportInfo): this;
|
|
31
|
+
private _syncVisibility;
|
|
32
|
+
}
|
|
33
|
+
export {};
|