@univerjs/sheets-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 +210 -265
- package/lib/cjs/index.js +8701 -8639
- package/lib/cjs/locale/ar-SA.js +4 -1
- package/lib/cjs/locale/ca-ES.js +4 -1
- package/lib/cjs/locale/de-DE.js +4 -1
- package/lib/cjs/locale/en-US.js +4 -1
- package/lib/cjs/locale/es-ES.js +4 -1
- package/lib/cjs/locale/fa-IR.js +4 -1
- package/lib/cjs/locale/fr-FR.js +4 -1
- package/lib/cjs/locale/id-ID.js +4 -1
- package/lib/cjs/locale/it-IT.js +4 -1
- package/lib/cjs/locale/ja-JP.js +4 -1
- package/lib/cjs/locale/ko-KR.js +4 -1
- package/lib/cjs/locale/pl-PL.js +4 -1
- package/lib/cjs/locale/pt-BR.js +4 -1
- package/lib/cjs/locale/ru-RU.js +4 -1
- package/lib/cjs/locale/sk-SK.js +4 -1
- package/lib/cjs/locale/vi-VN.js +4 -1
- package/lib/cjs/locale/zh-CN.js +4 -1
- package/lib/cjs/locale/zh-HK.js +4 -1
- package/lib/cjs/locale/zh-TW.js +4 -1
- package/lib/es/facade.js +211 -266
- package/lib/es/index.js +9031 -8951
- package/lib/es/locale/ar-SA.js +4 -1
- package/lib/es/locale/ca-ES.js +4 -1
- package/lib/es/locale/de-DE.js +4 -1
- package/lib/es/locale/en-US.js +4 -1
- package/lib/es/locale/es-ES.js +4 -1
- package/lib/es/locale/fa-IR.js +4 -1
- package/lib/es/locale/fr-FR.js +4 -1
- package/lib/es/locale/id-ID.js +4 -1
- package/lib/es/locale/it-IT.js +4 -1
- package/lib/es/locale/ja-JP.js +4 -1
- package/lib/es/locale/ko-KR.js +4 -1
- package/lib/es/locale/pl-PL.js +4 -1
- package/lib/es/locale/pt-BR.js +4 -1
- package/lib/es/locale/ru-RU.js +4 -1
- package/lib/es/locale/sk-SK.js +4 -1
- package/lib/es/locale/vi-VN.js +4 -1
- package/lib/es/locale/zh-CN.js +4 -1
- package/lib/es/locale/zh-HK.js +4 -1
- package/lib/es/locale/zh-TW.js +4 -1
- package/lib/facade.js +211 -266
- package/lib/index.css +0 -8
- package/lib/index.js +9031 -8951
- package/lib/locale/ar-SA.js +4 -1
- package/lib/locale/ca-ES.js +4 -1
- package/lib/locale/de-DE.js +4 -1
- package/lib/locale/en-US.js +4 -1
- package/lib/locale/es-ES.js +4 -1
- package/lib/locale/fa-IR.js +4 -1
- package/lib/locale/fr-FR.js +4 -1
- package/lib/locale/id-ID.js +4 -1
- package/lib/locale/it-IT.js +4 -1
- package/lib/locale/ja-JP.js +4 -1
- package/lib/locale/ko-KR.js +4 -1
- package/lib/locale/pl-PL.js +4 -1
- package/lib/locale/pt-BR.js +4 -1
- package/lib/locale/ru-RU.js +4 -1
- package/lib/locale/sk-SK.js +4 -1
- package/lib/locale/vi-VN.js +4 -1
- package/lib/locale/zh-CN.js +4 -1
- package/lib/locale/zh-HK.js +4 -1
- package/lib/locale/zh-TW.js +4 -1
- package/lib/types/basics/editor/range.d.ts +2 -1
- package/lib/types/consts/permission.d.ts +0 -5
- package/lib/types/controllers/cell-alert.controller.d.ts +0 -1
- package/lib/types/controllers/clipboard/utils.d.ts +17 -64
- package/lib/types/controllers/components.controller.d.ts +26 -0
- package/lib/types/controllers/editor/editing.render-controller.d.ts +6 -0
- package/lib/types/controllers/force-string-alert-render.controller.d.ts +1 -4
- package/lib/types/controllers/mobile/{mobile-sheet-ui.controller.d.ts → ui-mobile.controller.d.ts} +2 -6
- package/lib/types/controllers/permission/sheet-permission-render.controller.d.ts +3 -4
- package/lib/types/controllers/shortcuts/style.shortcut.d.ts +2 -0
- package/lib/types/controllers/{sheet-ui.controller.d.ts → ui.controller.d.ts} +2 -4
- package/lib/types/facade/f-event.d.ts +9 -19
- package/lib/types/facade/f-univer.d.ts +9 -20
- package/lib/types/facade/f-workbook.d.ts +3 -54
- package/lib/types/facade/f-worksheet.d.ts +1 -6
- package/lib/types/facade/index.d.ts +0 -4
- package/lib/types/index.d.ts +43 -36
- package/lib/types/locale/en-US.d.ts +3 -0
- package/lib/types/locale/types.d.ts +18 -0
- package/lib/types/menu/border.menu.d.ts +2 -1
- package/lib/types/menu/clear.menu.d.ts +6 -5
- package/lib/types/menu/delete.menu.d.ts +6 -5
- package/lib/types/menu/font.menu.d.ts +3 -2
- package/lib/types/menu/frozen.menu.d.ts +10 -9
- package/lib/types/menu/gridlines.menu.d.ts +2 -1
- package/lib/types/menu/insert.menu.d.ts +16 -15
- package/lib/types/menu/menu.d.ts +32 -31
- package/lib/types/menu/merge.menu.d.ts +6 -5
- package/lib/types/menu/permission.menu.d.ts +11 -10
- package/lib/types/menu/sheet.menu.d.ts +8 -7
- package/lib/types/menu/text-to-number.menu.d.ts +3 -2
- package/lib/types/mobile-plugin.d.ts +1 -3
- package/lib/types/plugin.d.ts +1 -3
- package/lib/types/services/cell-alert-manager.service.d.ts +3 -2
- package/lib/types/services/cell-dropdown-manager.service.d.ts +2 -3
- package/lib/types/services/clipboard/html-to-usm/converter.d.ts +6 -0
- package/lib/types/services/sheet-bar/sheet-bar.service.d.ts +1 -1
- package/lib/types/{views/permission/permission-dialog/index.d.ts → services/sheet-bar/type.d.ts} +4 -1
- package/lib/types/views/{cell-popup/index.d.ts → CellPopup.d.ts} +1 -1
- package/lib/types/views/auto-fill-popup-menu/AutoFillPopupMenu.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/BorderPanel.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/BorderLine.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderDashDot.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderDashDotDot.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderDashed.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderDotted.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderDouble.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderHair.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderMedium.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderMediumDashDot.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderMediumDashDotDot.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderMediumDashed.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderThick.d.ts +1 -1
- package/lib/types/{components → views}/border-panel/border-line/icons/BorderThin.d.ts +1 -1
- package/lib/types/views/cell-alert/CellAlertPopup.d.ts +1 -1
- package/lib/types/views/clipboard/ClipboardPopupMenu.d.ts +1 -1
- package/lib/types/views/defined-name/DefinedName.d.ts +1 -1
- package/lib/types/views/defined-name/DefinedNameContainer.d.ts +1 -1
- package/lib/types/views/defined-name/DefinedNameInput.d.ts +1 -1
- package/lib/types/views/defined-name/DefinedNameOverlay.d.ts +1 -1
- package/lib/types/views/dropdown/{cascader-dropdown/index.d.ts → CascaderDropdown.d.ts} +2 -2
- package/lib/types/views/dropdown/{color-dropdown/index.d.ts → ColorDropdown.d.ts} +2 -2
- package/lib/types/views/dropdown/{date-dropdown/index.d.ts → DateDropdown.d.ts} +2 -2
- package/lib/types/views/dropdown/{list-dropdown/index.d.ts → ListDropDown.d.ts} +2 -2
- package/lib/types/views/dropdown/index.d.ts +12 -12
- package/lib/types/views/editor-container/EditorContainer.d.ts +1 -1
- package/lib/types/views/editor-container/hooks.d.ts +1 -1
- package/lib/types/views/formula-bar/FormulaBar.d.ts +1 -1
- package/lib/types/{components → views}/menu-item-frozen/MenuItemFrozen.d.ts +1 -1
- package/lib/types/{components → views}/menu-item-input/MenuItemInput.d.ts +1 -1
- package/lib/types/views/mobile/sheet-bar/MobileSheetBar.d.ts +1 -1
- package/lib/types/views/permission/{error-msg-dialog/index.d.ts → AlertDialog.d.ts} +1 -1
- package/lib/types/views/permission/SheetPermissionDialog.d.ts +16 -0
- package/lib/types/views/permission/{panel/index.d.ts → SheetPermissionPanel.d.ts} +2 -2
- package/lib/types/views/permission/{panel-list/index.d.ts → SheetPermissionPanelList.d.ts} +1 -1
- package/lib/types/views/permission/{user-dialog/index.d.ts → SheetPermissionUserDialog.d.ts} +1 -1
- package/lib/types/views/permission/{spin/index.d.ts → Spin.d.ts} +1 -1
- package/lib/types/views/permission/index.d.ts +4 -4
- package/lib/types/views/permission/panel-detail/PermissionDetailFooterPart.d.ts +1 -1
- package/lib/types/views/permission/panel-detail/PermissionDetailMainPart.d.ts +1 -1
- package/lib/types/views/permission/panel-detail/PermissionDetailPanel.d.ts +1 -1
- package/lib/types/views/permission/panel-detail/PermissionDetailUserPart.d.ts +1 -1
- package/lib/types/views/permission/util.d.ts +2 -1
- package/lib/types/views/sheet-bar/SheetBar.d.ts +1 -1
- package/lib/types/views/sheet-bar/sheet-bar-button/SheetBarButton.d.ts +1 -1
- package/lib/types/views/sheet-bar/sheet-bar-menu/SheetBarMenu.d.ts +1 -1
- package/lib/types/views/sheet-bar/sheet-bar-tabs/SheetBarItem.d.ts +1 -1
- package/lib/types/views/sheet-bar/sheet-bar-tabs/SheetBarTabs.d.ts +1 -1
- package/lib/types/views/sheet-bar/sheet-bar-tabs/SheetBarTabsContextMenu.d.ts +1 -1
- package/lib/types/views/sheet-bar/sheet-bar-tabs/utils/animate.d.ts +3 -3
- package/lib/types/views/sheet-bar/sheet-bar-tabs/utils/sheet-tab-drag-sort.d.ts +26 -0
- package/lib/types/views/sheet-bar/sheet-bar-tabs/utils/sheet-tab-name-editor.d.ts +26 -0
- package/lib/types/views/sheet-bar/sheet-bar-tabs/utils/slide-tab-bar.d.ts +6 -8
- package/lib/types/views/sheet-container/SheetContainer.d.ts +3 -3
- package/lib/types/views/sheet-slider/CountBar.d.ts +1 -1
- package/lib/types/views/sheet-slider/ZoomSlider.d.ts +1 -1
- package/lib/types/views/status-bar/StatusBar.d.ts +1 -1
- package/lib/umd/facade.js +1 -1
- package/lib/umd/index.js +12 -15
- 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 +15 -15
- package/lib/types/facade/f-sheet-hooks.d.ts +0 -125
- package/lib/types/facade/f-workbook-permission.d.ts +0 -39
- /package/lib/types/{components → views}/border-panel/interface.d.ts +0 -0
- /package/lib/types/{components → views}/const.d.ts +0 -0
- /package/lib/types/{components → views}/hook.d.ts +0 -0
- /package/lib/types/{components → views}/menu-item-frozen/index.d.ts +0 -0
- /package/lib/types/{components → views}/menu-item-frozen/interface.d.ts +0 -0
- /package/lib/types/{components → views}/menu-item-input/index.d.ts +0 -0
- /package/lib/types/{components → views}/menu-item-input/interface.d.ts +0 -0
|
@@ -14,19 +14,17 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
import { Disposable, ICommandService, IConfigService, Injector } from '@univerjs/core';
|
|
17
|
-
import {
|
|
17
|
+
import { ILayoutService, IMenuManagerService, IShortcutService, IUIPartsService } from '@univerjs/ui';
|
|
18
18
|
export declare class SheetUIController extends Disposable {
|
|
19
19
|
protected readonly _injector: Injector;
|
|
20
|
-
protected readonly _componentManager: ComponentManager;
|
|
21
20
|
protected readonly _layoutService: ILayoutService;
|
|
22
21
|
protected readonly _commandService: ICommandService;
|
|
23
22
|
protected readonly _shortcutService: IShortcutService;
|
|
24
23
|
protected readonly _menuManagerService: IMenuManagerService;
|
|
25
24
|
protected readonly _uiPartsService: IUIPartsService;
|
|
26
25
|
protected readonly _configService: IConfigService;
|
|
27
|
-
constructor(_injector: Injector,
|
|
26
|
+
constructor(_injector: Injector, _layoutService: ILayoutService, _commandService: ICommandService, _shortcutService: IShortcutService, _menuManagerService: IMenuManagerService, _uiPartsService: IUIPartsService, _configService: IConfigService);
|
|
28
27
|
private _init;
|
|
29
|
-
private _initComponents;
|
|
30
28
|
private _initCommands;
|
|
31
29
|
private _initMenus;
|
|
32
30
|
private _initShortcuts;
|
|
@@ -94,11 +94,9 @@ export interface IBeforeSheetEditStartEventParams extends IEventBase {
|
|
|
94
94
|
/** Column index of the cell to be edited */
|
|
95
95
|
column: number;
|
|
96
96
|
/** Type of input device event triggering the edit */
|
|
97
|
-
eventType
|
|
97
|
+
eventType?: DeviceInputEventType;
|
|
98
98
|
/** Optional keycode triggering the edit */
|
|
99
99
|
keycode?: KeyCode;
|
|
100
|
-
/** Whether the edit will happen in zen editor mode */
|
|
101
|
-
isZenEditor: boolean;
|
|
102
100
|
}
|
|
103
101
|
/**
|
|
104
102
|
* Event interface triggered when cell editing starts
|
|
@@ -113,11 +111,9 @@ export interface ISheetEditStartedEventParams extends IEventBase {
|
|
|
113
111
|
/** Column index of the editing cell */
|
|
114
112
|
column: number;
|
|
115
113
|
/** Type of input device event that triggered the edit */
|
|
116
|
-
eventType
|
|
114
|
+
eventType?: DeviceInputEventType;
|
|
117
115
|
/** Optional keycode that triggered the edit */
|
|
118
116
|
keycode?: KeyCode;
|
|
119
|
-
/** Whether the edit is happening in zen editor mode */
|
|
120
|
-
isZenEditor: boolean;
|
|
121
117
|
}
|
|
122
118
|
/**
|
|
123
119
|
* Event interface triggered while cell content is being changed
|
|
@@ -133,8 +129,6 @@ export interface ISheetEditChangingEventParams extends IEventBase {
|
|
|
133
129
|
column: number;
|
|
134
130
|
/** Current value being edited */
|
|
135
131
|
value: RichTextValue;
|
|
136
|
-
/** Whether the edit is happening in zen editor mode */
|
|
137
|
-
isZenEditor: boolean;
|
|
138
132
|
}
|
|
139
133
|
/**
|
|
140
134
|
* Event interface triggered before cell editing ends
|
|
@@ -151,11 +145,9 @@ export interface IBeforeSheetEditEndEventParams extends IEventBase {
|
|
|
151
145
|
/** Current value being edited */
|
|
152
146
|
value: RichTextValue;
|
|
153
147
|
/** Type of input device event triggering the edit end */
|
|
154
|
-
eventType
|
|
148
|
+
eventType?: DeviceInputEventType;
|
|
155
149
|
/** Optional keycode triggering the edit end */
|
|
156
150
|
keycode?: KeyCode;
|
|
157
|
-
/** Whether the edit is happening in zen editor mode */
|
|
158
|
-
isZenEditor: boolean;
|
|
159
151
|
/** Whether the edit will be confirmed or cancelled */
|
|
160
152
|
isConfirm: boolean;
|
|
161
153
|
}
|
|
@@ -172,11 +164,9 @@ export interface ISheetEditEndedEventParams extends IEventBase {
|
|
|
172
164
|
/** Column index of the edited cell */
|
|
173
165
|
column: number;
|
|
174
166
|
/** Type of input device event that triggered the edit end */
|
|
175
|
-
eventType
|
|
167
|
+
eventType?: DeviceInputEventType;
|
|
176
168
|
/** Optional keycode that triggered the edit end */
|
|
177
169
|
keycode?: KeyCode;
|
|
178
|
-
/** Whether the edit happened in zen editor mode */
|
|
179
|
-
isZenEditor: boolean;
|
|
180
170
|
/** Whether the edit was confirmed or cancelled */
|
|
181
171
|
isConfirm: boolean;
|
|
182
172
|
}
|
|
@@ -327,7 +317,7 @@ export interface IFSheetsUIEventNameMixin {
|
|
|
327
317
|
* @example
|
|
328
318
|
* ```ts
|
|
329
319
|
* const disposable = univerAPI.addEvent(univerAPI.Event.BeforeSheetEditStart, (params) => {
|
|
330
|
-
* const { worksheet, workbook, row, column, eventType, keycode
|
|
320
|
+
* const { worksheet, workbook, row, column, eventType, keycode } = params;
|
|
331
321
|
* console.log(params);
|
|
332
322
|
*
|
|
333
323
|
* // Cancel the cell edit start operation
|
|
@@ -344,7 +334,7 @@ export interface IFSheetsUIEventNameMixin {
|
|
|
344
334
|
* @example
|
|
345
335
|
* ```ts
|
|
346
336
|
* const disposable = univerAPI.addEvent(univerAPI.Event.SheetEditStarted, (params) => {
|
|
347
|
-
* const { worksheet, workbook, row, column, eventType, keycode
|
|
337
|
+
* const { worksheet, workbook, row, column, eventType, keycode } = params;
|
|
348
338
|
* console.log(params);
|
|
349
339
|
* });
|
|
350
340
|
*
|
|
@@ -358,7 +348,7 @@ export interface IFSheetsUIEventNameMixin {
|
|
|
358
348
|
* @example
|
|
359
349
|
* ```ts
|
|
360
350
|
* const disposable = univerAPI.addEvent(univerAPI.Event.SheetEditChanging, (params) => {
|
|
361
|
-
* const { worksheet, workbook, row, column, value
|
|
351
|
+
* const { worksheet, workbook, row, column, value } = params;
|
|
362
352
|
* console.log(params);
|
|
363
353
|
* });
|
|
364
354
|
*
|
|
@@ -372,7 +362,7 @@ export interface IFSheetsUIEventNameMixin {
|
|
|
372
362
|
* @example
|
|
373
363
|
* ```ts
|
|
374
364
|
* const disposable = univerAPI.addEvent(univerAPI.Event.BeforeSheetEditEnd, (params) => {
|
|
375
|
-
* const { worksheet, workbook, row, column, value, eventType, keycode,
|
|
365
|
+
* const { worksheet, workbook, row, column, value, eventType, keycode, isConfirm } = params;
|
|
376
366
|
* console.log(params);
|
|
377
367
|
*
|
|
378
368
|
* // Cancel the cell edit end operation
|
|
@@ -389,7 +379,7 @@ export interface IFSheetsUIEventNameMixin {
|
|
|
389
379
|
* @example
|
|
390
380
|
* ```ts
|
|
391
381
|
* const disposable = univerAPI.addEvent(univerAPI.Event.SheetEditEnded, (params) => {
|
|
392
|
-
* const { worksheet, workbook, row, column, eventType, keycode,
|
|
382
|
+
* const { worksheet, workbook, row, column, eventType, keycode, isConfirm } = params;
|
|
393
383
|
* console.log(params);
|
|
394
384
|
* });
|
|
395
385
|
*
|
|
@@ -13,23 +13,15 @@
|
|
|
13
13
|
* See the License for the specific language governing permissions and
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
|
-
import type { IDisposable, Injector } from '@univerjs/core';
|
|
17
|
-
import type {
|
|
16
|
+
import type { ICellCustomRender, IDisposable, Injector, Nullable } from '@univerjs/core';
|
|
17
|
+
import type { SheetExtension } from '@univerjs/engine-render';
|
|
18
18
|
import type { Observable } from 'rxjs';
|
|
19
|
+
import { InterceptorEffectEnum } from '@univerjs/core';
|
|
19
20
|
import { FUniver } from '@univerjs/core/facade';
|
|
20
|
-
import { FSheetHooks } from '@univerjs/sheets/facade';
|
|
21
21
|
/**
|
|
22
22
|
* @ignore
|
|
23
23
|
*/
|
|
24
24
|
export interface IFUniverSheetsUIMixin {
|
|
25
|
-
/**
|
|
26
|
-
* @deprecated use same API in FWorkbook and FWorkSheet.
|
|
27
|
-
*/
|
|
28
|
-
customizeColumnHeader(cfg: IColumnsHeaderCfgParam): void;
|
|
29
|
-
/**
|
|
30
|
-
* @deprecated use same API in FWorkbook and FWorkSheet.
|
|
31
|
-
*/
|
|
32
|
-
customizeRowHeader(cfg: IRowsHeaderCfgParam): void;
|
|
33
25
|
/**
|
|
34
26
|
* Register sheet row header render extensions.
|
|
35
27
|
* @param {string} unitId The unit id of the spreadsheet.
|
|
@@ -52,9 +44,12 @@ export interface IFUniverSheetsUIMixin {
|
|
|
52
44
|
*/
|
|
53
45
|
registerSheetMainExtension(unitId: string, ...extensions: SheetExtension[]): IDisposable;
|
|
54
46
|
/**
|
|
55
|
-
*
|
|
47
|
+
* Register cell custom render.
|
|
48
|
+
* @param {Nullable<ICellCustomRender[]>} customRender Custom render function.
|
|
49
|
+
* @param {InterceptorEffectEnum} [effect] The effect of the interceptor, style or value.
|
|
50
|
+
* @param {number} [priority] The priority of the interceptor.
|
|
56
51
|
*/
|
|
57
|
-
|
|
52
|
+
registerCellCustomRender(customRender: Nullable<ICellCustomRender[]>, effect?: InterceptorEffectEnum, priority?: number): IDisposable;
|
|
58
53
|
/**
|
|
59
54
|
* Paste clipboard data or custom data into the active sheet at the current selection position.
|
|
60
55
|
* @param {string} [htmlContent] - The HTML content from the clipboard or custom data.
|
|
@@ -155,11 +150,10 @@ export declare class FUniverSheetsUIMixin extends FUniver implements IFUniverShe
|
|
|
155
150
|
private _clipboardPaste;
|
|
156
151
|
private _beforeClipboardPasteAsync;
|
|
157
152
|
private _clipboardPasteAsync;
|
|
158
|
-
customizeColumnHeader(cfg: IColumnsHeaderCfgParam): void;
|
|
159
|
-
customizeRowHeader(cfg: IRowsHeaderCfgParam): void;
|
|
160
153
|
registerSheetRowHeaderExtension(unitId: string, ...extensions: SheetExtension[]): IDisposable;
|
|
161
154
|
registerSheetColumnHeaderExtension(unitId: string, ...extensions: SheetExtension[]): IDisposable;
|
|
162
155
|
registerSheetMainExtension(unitId: string, ...extensions: SheetExtension[]): IDisposable;
|
|
156
|
+
registerCellCustomRender(customRender: Nullable<ICellCustomRender[]>, effect?: InterceptorEffectEnum, priority?: number): IDisposable;
|
|
163
157
|
/**
|
|
164
158
|
* Get sheet render component from render by unitId and view key.
|
|
165
159
|
* @private
|
|
@@ -168,11 +162,6 @@ export declare class FUniverSheetsUIMixin extends FUniver implements IFUniverShe
|
|
|
168
162
|
* @returns {Nullable<RenderComponentType>} The render component.
|
|
169
163
|
*/
|
|
170
164
|
private _getSheetRenderComponent;
|
|
171
|
-
/**
|
|
172
|
-
* Get sheet hooks.
|
|
173
|
-
* @returns {FSheetHooks} FSheetHooks instance
|
|
174
|
-
*/
|
|
175
|
-
getSheetHooks(): FSheetHooks;
|
|
176
165
|
pasteIntoSheet(htmlContent?: string, textContent?: string, files?: File[]): Promise<boolean>;
|
|
177
166
|
setProtectedRangeShadowStrategy(strategy: 'always' | 'non-editable' | 'non-viewable' | 'none'): void;
|
|
178
167
|
getProtectedRangeShadowStrategy(): 'always' | 'non-editable' | 'non-viewable' | 'none';
|
|
@@ -14,8 +14,8 @@
|
|
|
14
14
|
* limitations under the License.
|
|
15
15
|
*/
|
|
16
16
|
import type { IDisposable, Nullable } from '@univerjs/core';
|
|
17
|
-
import type { IColumnsHeaderCfgParam,
|
|
18
|
-
import type {
|
|
17
|
+
import type { IColumnsHeaderCfgParam, IRowsHeaderCfgParam } from '@univerjs/engine-render';
|
|
18
|
+
import type { IScrollState } from '@univerjs/sheets-ui';
|
|
19
19
|
import type { IDialogPartMethodOptions, ISidebarMethodOptions } from '@univerjs/ui';
|
|
20
20
|
import { FWorkbook } from '@univerjs/sheets/facade';
|
|
21
21
|
/**
|
|
@@ -131,34 +131,6 @@ export interface IFWorkbookSheetsUIMixin {
|
|
|
131
131
|
* ```
|
|
132
132
|
*/
|
|
133
133
|
customizeRowHeader(cfg: IRowsHeaderCfgParam): void;
|
|
134
|
-
/**
|
|
135
|
-
* @deprecated use `univerAPI.addEvent(univerAPI.Event.CellClicked, (params) => {})` instead
|
|
136
|
-
*/
|
|
137
|
-
onCellClick(callback: (cell: IHoverRichTextInfo) => void): IDisposable;
|
|
138
|
-
/**
|
|
139
|
-
* @deprecated use `univerAPI.addEvent(univerAPI.Event.CellHover, (params) => {})` instead
|
|
140
|
-
*/
|
|
141
|
-
onCellHover(callback: (cell: IHoverRichTextPosition) => void): IDisposable;
|
|
142
|
-
/**
|
|
143
|
-
* @deprecated use `univerAPI.addEvent(univerAPI.Event.CellPointerMove, (params) => {})` instead
|
|
144
|
-
*/
|
|
145
|
-
onCellPointerMove(callback: (cell: ICellPosWithEvent, event: IPointerEvent | IMouseEvent) => void): IDisposable;
|
|
146
|
-
/**
|
|
147
|
-
* @deprecated use `univerAPI.addEvent(univerAPI.Event.CellPointerDown, (params) => {})` instead
|
|
148
|
-
*/
|
|
149
|
-
onCellPointerDown(callback: (cell: ICellPosWithEvent) => void): IDisposable;
|
|
150
|
-
/**
|
|
151
|
-
* @deprecated use `univerAPI.addEvent(univerAPI.Event.CellPointerUp, (params) => {})` instead
|
|
152
|
-
*/
|
|
153
|
-
onCellPointerUp(callback: (cell: ICellPosWithEvent) => void): IDisposable;
|
|
154
|
-
/**
|
|
155
|
-
* @deprecated use `univerAPI.addEvent(univerAPI.Event.DragOver, (params) => {})` instead
|
|
156
|
-
*/
|
|
157
|
-
onDragOver(callback: (cell: IDragCellPosition) => void): IDisposable;
|
|
158
|
-
/**
|
|
159
|
-
* @deprecated use `univerAPI.addEvent(univerAPI.Event.Drop, (params) => {})` instead
|
|
160
|
-
*/
|
|
161
|
-
onDrop(callback: (cell: IDragCellPosition) => void): IDisposable;
|
|
162
134
|
/**
|
|
163
135
|
* Start the editing process of the current active cell
|
|
164
136
|
* @returns {boolean} Whether the editing process is started successfully
|
|
@@ -170,11 +142,6 @@ export interface IFWorkbookSheetsUIMixin {
|
|
|
170
142
|
*/
|
|
171
143
|
startEditing(): boolean;
|
|
172
144
|
/**
|
|
173
|
-
* @deprecated Use `endEditingAsync` as instead
|
|
174
|
-
*/
|
|
175
|
-
endEditing(save?: boolean): Promise<boolean>;
|
|
176
|
-
/**
|
|
177
|
-
* @async
|
|
178
145
|
* End the editing process of the current active cell
|
|
179
146
|
* @param {boolean} save - Whether to save the changes, default is true
|
|
180
147
|
* @returns {Promise<boolean>} Whether the editing process is ended successfully
|
|
@@ -186,8 +153,7 @@ export interface IFWorkbookSheetsUIMixin {
|
|
|
186
153
|
*/
|
|
187
154
|
endEditingAsync(save?: boolean): Promise<boolean>;
|
|
188
155
|
/**
|
|
189
|
-
*
|
|
190
|
-
* End the editing process of the current active cell
|
|
156
|
+
* End the editing process of the current active cell, and discard the changes.
|
|
191
157
|
* @returns {Promise<boolean>} Whether the editing process is ended successfully
|
|
192
158
|
* @example
|
|
193
159
|
* ```ts
|
|
@@ -282,27 +248,10 @@ export declare class FWorkbookSheetsUIMixin extends FWorkbook implements IFWorkb
|
|
|
282
248
|
*/
|
|
283
249
|
private _getSheetRenderComponent;
|
|
284
250
|
private _logDeprecation;
|
|
285
|
-
onCellClick(callback: (cell: IHoverRichTextInfo) => void): IDisposable;
|
|
286
|
-
onCellHover(callback: (cell: IHoverRichTextPosition) => void): IDisposable;
|
|
287
|
-
onCellPointerDown(callback: (cell: ICellPosWithEvent) => void): IDisposable;
|
|
288
|
-
onCellPointerUp(callback: (cell: ICellPosWithEvent) => void): IDisposable;
|
|
289
|
-
onCellPointerMove(callback: (cell: ICellPosWithEvent, event: IPointerEvent | IMouseEvent) => void): IDisposable;
|
|
290
|
-
onDragOver(callback: (cell: IDragCellPosition) => void): IDisposable;
|
|
291
|
-
onDrop(callback: (cell: IDragCellPosition) => void): IDisposable;
|
|
292
251
|
startEditing(): boolean;
|
|
293
|
-
endEditing(save?: boolean): Promise<boolean>;
|
|
294
252
|
endEditingAsync(save?: boolean): Promise<boolean>;
|
|
295
253
|
abortEditingAsync(): Promise<boolean>;
|
|
296
254
|
isCellEditing(): boolean;
|
|
297
|
-
/**
|
|
298
|
-
* Get scroll state of specified sheet.
|
|
299
|
-
* @param {string} sheetId - sheet id
|
|
300
|
-
* @returns {IScrollState} scroll state
|
|
301
|
-
* @example
|
|
302
|
-
* ``` ts
|
|
303
|
-
* univerAPI.getActiveWorkbook().getScrollStateBySheetId($sheetId)
|
|
304
|
-
* ```
|
|
305
|
-
*/
|
|
306
255
|
getScrollStateBySheetId(sheetId: string): Nullable<IScrollState>;
|
|
307
256
|
disableSelection(): FWorkbook;
|
|
308
257
|
enableSelection(): FWorkbook;
|
|
@@ -16,7 +16,7 @@
|
|
|
16
16
|
import type { IDisposable, IRange, ISelectionCell, Nullable } from '@univerjs/core';
|
|
17
17
|
import type { IColumnsHeaderCfgParam, IRowsHeaderCfgParam, SpreadsheetSkeleton } from '@univerjs/engine-render';
|
|
18
18
|
import type { ISelectionStyle } from '@univerjs/sheets';
|
|
19
|
-
import type { IScrollState
|
|
19
|
+
import type { IScrollState } from '@univerjs/sheets-ui';
|
|
20
20
|
import type { FRange } from '@univerjs/sheets/facade';
|
|
21
21
|
import { SHEET_VIEWPORT_KEY } from '@univerjs/engine-render';
|
|
22
22
|
import { FWorksheet } from '@univerjs/sheets/facade';
|
|
@@ -309,10 +309,6 @@ export interface IFWorksheetUIMixin {
|
|
|
309
309
|
* ```
|
|
310
310
|
*/
|
|
311
311
|
setRowHeaderWidth(width: number): FWorksheet;
|
|
312
|
-
/**
|
|
313
|
-
* @deprecated use `univerAPI.addEvent(univerAPI.Event.Scroll, (params) => {})` instead
|
|
314
|
-
*/
|
|
315
|
-
onScroll(callback: (params: Nullable<IViewportScrollState>) => void): IDisposable;
|
|
316
312
|
}
|
|
317
313
|
export declare class FWorksheetUIMixin extends FWorksheet implements IFWorksheetUIMixin {
|
|
318
314
|
refreshCanvas(): FWorksheet;
|
|
@@ -323,7 +319,6 @@ export declare class FWorksheetUIMixin extends FWorksheet implements IFWorksheet
|
|
|
323
319
|
getVisibleRangesOfAllViewports(): Map<SHEET_VIEWPORT_KEY, IRange> | null;
|
|
324
320
|
scrollToCell(row: number, column: number, duration?: number): FWorksheet;
|
|
325
321
|
getScrollState(): IScrollState;
|
|
326
|
-
onScroll(callback: (params: Nullable<IViewportScrollState>) => void): IDisposable;
|
|
327
322
|
getSkeleton(): Nullable<SpreadsheetSkeleton>;
|
|
328
323
|
autoResizeColumn(columnPosition: number): FWorksheet;
|
|
329
324
|
autoResizeColumns(startColumn: number, numColumns: number): FWorksheet;
|
|
@@ -16,14 +16,10 @@
|
|
|
16
16
|
import './f-univer';
|
|
17
17
|
import './f-workbook';
|
|
18
18
|
import './f-worksheet';
|
|
19
|
-
import './f-workbook-permission';
|
|
20
|
-
import './f-sheet-hooks';
|
|
21
19
|
import './f-event';
|
|
22
20
|
export * from './f-enum';
|
|
23
21
|
export type * from './f-event';
|
|
24
22
|
export { type IFComponentKey, transformComponentKey } from './f-range';
|
|
25
|
-
export type * from './f-sheet-hooks';
|
|
26
23
|
export type * from './f-univer';
|
|
27
24
|
export type * from './f-workbook';
|
|
28
|
-
export type * from './f-workbook-permission';
|
|
29
25
|
export type * from './f-worksheet';
|
package/lib/types/index.d.ts
CHANGED
|
@@ -15,7 +15,8 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import './global.css';
|
|
17
17
|
export { getEditorObject } from './basics/editor/get-editor-object';
|
|
18
|
-
export {
|
|
18
|
+
export { SheetCopyCommand, SheetCutCommand, SheetPasteBesidesBorderCommand, SheetPasteColWidthCommand, SheetPasteCommand, SheetPasteFormatCommand, SheetPasteShortKeyCommand, SheetPasteValueCommand, } from './commands/commands/clipboard.command';
|
|
19
|
+
export type { ISheetPasteByShortKeyParams, ISheetPasteParams } from './commands/commands/clipboard.command';
|
|
19
20
|
export { DeleteRangeMoveLeftConfirmCommand } from './commands/commands/delete-range-move-left-confirm.command';
|
|
20
21
|
export { DeleteRangeMoveUpConfirmCommand } from './commands/commands/delete-range-move-up-confirm.command';
|
|
21
22
|
export { SetColumnHeaderHeightCommand, SetRowHeaderWidthCommand } from './commands/commands/headersize-changed.command';
|
|
@@ -26,16 +27,18 @@ export { InsertRangeMoveRightConfirmCommand } from './commands/commands/insert-r
|
|
|
26
27
|
export { AddRangeProtectionFromContextMenuCommand, AddRangeProtectionFromSheetBarCommand, AddRangeProtectionFromToolbarCommand, DeleteRangeProtectionFromContextMenuCommand, SetRangeProtectionFromContextMenuCommand, ViewSheetPermissionFromContextMenuCommand, ViewSheetPermissionFromSheetBarCommand, } from './commands/commands/range-protection.command';
|
|
27
28
|
export { RemoveColConfirmCommand, RemoveRowConfirmCommand } from './commands/commands/remove-row-col-confirm.command';
|
|
28
29
|
export { RemoveSheetConfirmCommand } from './commands/commands/remove-sheet-confirm.command';
|
|
29
|
-
export { ApplyFormatPainterCommand, SetInfiniteFormatPainterCommand, SetOnceFormatPainterCommand } from './commands/commands/set-format-painter.command';
|
|
30
|
-
export { SetColumnFrozenCommand, SetFirstColumnFrozenCommand, SetFirstRowFrozenCommand, SetRowFrozenCommand, SetSelectionFrozenCommand } from './commands/commands/set-frozen.command';
|
|
31
|
-
export {
|
|
32
|
-
export {
|
|
30
|
+
export { ApplyFormatPainterCommand, SetInfiniteFormatPainterCommand, SetOnceFormatPainterCommand, } from './commands/commands/set-format-painter.command';
|
|
31
|
+
export { SetColumnFrozenCommand, SetFirstColumnFrozenCommand, SetFirstRowFrozenCommand, SetRowFrozenCommand, SetSelectionFrozenCommand, } from './commands/commands/set-frozen.command';
|
|
32
|
+
export { ResetScrollCommand, ScrollCommand, ScrollToCellCommand, SetScrollRelativeCommand, } from './commands/commands/set-scroll.command';
|
|
33
|
+
export type { IScrollCommandParams, IScrollToCellCommandParams, ISetScrollRelativeCommandParams, } from './commands/commands/set-scroll.command';
|
|
34
|
+
export { ExpandSelectionCommand, JumpOver, MoveSelectionCommand, MoveSelectionEnterAndTabCommand, SelectAllCommand, } from './commands/commands/set-selection.command';
|
|
33
35
|
export { SetWorksheetColAutoWidthCommand } from './commands/commands/set-worksheet-auto-col-width.command';
|
|
34
|
-
export { ChangeZoomRatioCommand,
|
|
36
|
+
export { ChangeZoomRatioCommand, SetZoomRatioCommand } from './commands/commands/set-zoom-ratio.command';
|
|
37
|
+
export type { ISetZoomRatioCommandParams } from './commands/commands/set-zoom-ratio.command';
|
|
35
38
|
export { ShowMenuListCommand } from './commands/commands/unhide.command';
|
|
36
|
-
export { ChangeSheetProtectionFromSheetBarCommand, DeleteWorksheetProtectionFormSheetBarCommand } from './commands/commands/worksheet-protection.command';
|
|
39
|
+
export { ChangeSheetProtectionFromSheetBarCommand, DeleteWorksheetProtectionFormSheetBarCommand, } from './commands/commands/worksheet-protection.command';
|
|
37
40
|
export { SetActivateCellEditOperation } from './commands/operations/activate-cell-edit.operation';
|
|
38
|
-
export { SetCellEditVisibleArrowOperation, SetCellEditVisibleOperation, SetCellEditVisibleWithF2Operation } from './commands/operations/cell-edit.operation';
|
|
41
|
+
export { SetCellEditVisibleArrowOperation, SetCellEditVisibleOperation, SetCellEditVisibleWithF2Operation, } from './commands/operations/cell-edit.operation';
|
|
39
42
|
export { RenameSheetOperation } from './commands/operations/rename-sheet.operation';
|
|
40
43
|
export { ScrollToRangeOperation } from './commands/operations/scroll-to-range.operation';
|
|
41
44
|
export { SetScrollOperation } from './commands/operations/scroll.operation';
|
|
@@ -46,7 +49,6 @@ export { SheetPermissionOpenPanelOperation } from './commands/operations/sheet-p
|
|
|
46
49
|
export { SidebarDefinedNameOperation } from './commands/operations/sidebar-defined-name.operation';
|
|
47
50
|
export { EMBEDDING_FORMULA_EDITOR_COMPONENT_KEY, RANGE_SELECTOR_COMPONENT_KEY, SHEET_VIEW_KEY } from './common/keys';
|
|
48
51
|
export { getCellRealRange, getViewportByCell } from './common/utils';
|
|
49
|
-
export { useActiveWorkbook, useActiveWorksheet, useWorkbooks } from './components/hook';
|
|
50
52
|
export { type IUniverSheetsUIConfig } from './config/config';
|
|
51
53
|
export { UNIVER_SHEET_PERMISSION_USER_PART } from './consts/permission';
|
|
52
54
|
export { SHEET_UI_PLUGIN_NAME } from './consts/plugin-name';
|
|
@@ -59,55 +61,64 @@ export { SheetClipboardController } from './controllers/clipboard/clipboard.cont
|
|
|
59
61
|
export { DragRenderController } from './controllers/drag-render.controller';
|
|
60
62
|
export { EditingRenderController } from './controllers/editor/editing.render-controller';
|
|
61
63
|
export { FormulaEditorController } from './controllers/editor/formula-editor.controller';
|
|
62
|
-
export { EMBEDDING_FORMULA_EDITOR, isEmbeddingFormulaEditor } from './controllers/editor/utils/is-embedding-formula-editor';
|
|
64
|
+
export { EMBEDDING_FORMULA_EDITOR, isEmbeddingFormulaEditor, } from './controllers/editor/utils/is-embedding-formula-editor';
|
|
63
65
|
export { isRangeSelector, RANGE_SELECTOR_SYMBOLS } from './controllers/editor/utils/is-range-selector';
|
|
64
66
|
export { HoverRenderController } from './controllers/hover-render.controller';
|
|
65
67
|
export { SheetPermissionCheckUIController } from './controllers/permission/sheet-permission-check-ui.controller';
|
|
66
68
|
export { HeaderFreezeRenderController } from './controllers/render-controllers/freeze.render-controller';
|
|
67
69
|
export { HeaderMoveRenderController } from './controllers/render-controllers/header-move.render-controller';
|
|
68
70
|
export { HeaderResizeRenderController } from './controllers/render-controllers/header-resize.render-controller';
|
|
69
|
-
export { HEADER_UNHIDE_RANGE_VISIBLE_CHECK, HeaderUnhideRenderController } from './controllers/render-controllers/header-unhide.render-controller';
|
|
71
|
+
export { HEADER_UNHIDE_RANGE_VISIBLE_CHECK, HeaderUnhideRenderController, } from './controllers/render-controllers/header-unhide.render-controller';
|
|
70
72
|
export { SheetsScrollRenderController } from './controllers/render-controllers/scroll.render-controller';
|
|
71
|
-
export {
|
|
72
|
-
export {
|
|
73
|
-
export { whenFormulaEditorActivated, whenSheetEditorActivated, whenSheetEditorFocused } from './controllers/shortcuts/utils';
|
|
73
|
+
export { SheetRenderController } from './controllers/render-controllers/sheet.render-controller';
|
|
74
|
+
export type { ITelemetryData } from './controllers/render-controllers/sheet.render-controller';
|
|
75
|
+
export { whenFormulaEditorActivated, whenSheetEditorActivated, whenSheetEditorFocused, } from './controllers/shortcuts/utils';
|
|
74
76
|
export { StatusBarController } from './controllers/status-bar.controller';
|
|
75
|
-
export {
|
|
77
|
+
export { SheetUIController } from './controllers/ui.controller';
|
|
78
|
+
export { getCoordByCell, getCoordByOffset, getSheetObject, getTransformCoord, } from './controllers/utils/component-tools';
|
|
76
79
|
export { virtualizeDiscreteRanges } from './controllers/utils/range-tools';
|
|
77
80
|
export { matchedSelectionByRowColIndex as checkInHeaderRanges } from './controllers/utils/selections-tools';
|
|
78
81
|
export { useHighlightRange } from './hooks/use-highlight-range';
|
|
79
|
-
export { COPY_SPECIAL_MENU_ID, menuClipboardDisabledObservable, PASTE_SPECIAL_MENU_ID, SheetMenuPosition } from './menu/menu';
|
|
80
|
-
export { deriveStateFromActiveSheet$, getCurrentExclusiveRangeInterest$, getCurrentRangeDisable$, getObservableWithExclusiveRange
|
|
82
|
+
export { COPY_SPECIAL_MENU_ID, menuClipboardDisabledObservable, PASTE_SPECIAL_MENU_ID, SheetMenuPosition, } from './menu/menu';
|
|
83
|
+
export { deriveStateFromActiveSheet$, getCurrentExclusiveRangeInterest$, getCurrentRangeDisable$, getObservableWithExclusiveRange$, } from './menu/menu-util';
|
|
81
84
|
export { menuSchema as SheetsUIMenuSchema } from './menu/schema';
|
|
82
85
|
export { UniverSheetsMobileUIPlugin } from './mobile-plugin';
|
|
83
86
|
export { UniverSheetsUIPlugin } from './plugin';
|
|
84
|
-
export {
|
|
85
|
-
export {
|
|
86
|
-
export {
|
|
87
|
+
export { SheetCanvasPopManagerService } from './services/canvas-pop-manager.service';
|
|
88
|
+
export type { ICanvasPopup } from './services/canvas-pop-manager.service';
|
|
89
|
+
export { CellAlertManagerService, CellAlertType } from './services/cell-alert-manager.service';
|
|
90
|
+
export type { ICellAlert } from './services/cell-alert-manager.service';
|
|
91
|
+
export { ISheetCellDropdownManagerService, SheetCellDropdownManagerService, } from './services/cell-dropdown-manager.service';
|
|
92
|
+
export type { IDropdownParam } from './services/cell-dropdown-manager.service';
|
|
87
93
|
export { CellPopupManagerService } from './services/cell-popup-manager.service';
|
|
88
|
-
export { getMatrixPlainText, ISheetClipboardService, PREDEFINED_HOOK_NAME, PREDEFINED_HOOK_NAME_COPY, PREDEFINED_HOOK_NAME_PASTE, SheetClipboardService } from './services/clipboard/clipboard.service';
|
|
94
|
+
export { getMatrixPlainText, ISheetClipboardService, PREDEFINED_HOOK_NAME, PREDEFINED_HOOK_NAME_COPY, PREDEFINED_HOOK_NAME_PASTE, SheetClipboardService, } from './services/clipboard/clipboard.service';
|
|
89
95
|
export { COPY_TYPE } from './services/clipboard/type';
|
|
90
|
-
export type { ICellDataWithSpanInfo, ICopyHookKeyType, ICopyHookValueType, ICopyPastePayload, IPasteHookKeyType, IPasteHookValueType, ISheetClipboardHook, ISheetDiscreteRangeLocation } from './services/clipboard/type';
|
|
96
|
+
export type { ICellDataWithSpanInfo, ICopyHookKeyType, ICopyHookValueType, ICopyPastePayload, IPasteHookKeyType, IPasteHookValueType, ISheetClipboardHook, ISheetDiscreteRangeLocation, } from './services/clipboard/type';
|
|
91
97
|
export { getRepeatRange, mergeSetRangeValues } from './services/clipboard/utils';
|
|
92
|
-
export { DragManagerService
|
|
93
|
-
export {
|
|
98
|
+
export { DragManagerService } from './services/drag-manager.service';
|
|
99
|
+
export type { IDragCellPosition } from './services/drag-manager.service';
|
|
100
|
+
export { EditorBridgeService, IEditorBridgeService } from './services/editor-bridge.service';
|
|
101
|
+
export type { IEditorBridgeServiceVisibleParam } from './services/editor-bridge.service';
|
|
94
102
|
export type { IEditorBridgeServiceParam } from './services/editor-bridge.service';
|
|
95
103
|
export { CellEditorManagerService, ICellEditorManagerService } from './services/editor/cell-editor-manager.service';
|
|
96
104
|
export { SheetCellEditorResizeService } from './services/editor/cell-editor-resize.service';
|
|
97
105
|
export { IFormulaEditorManagerService } from './services/editor/formula-editor-manager.service';
|
|
98
106
|
export { FormatPainterStatus, IFormatPainterService } from './services/format-painter/format-painter.service';
|
|
99
|
-
export type { IFormatPainterBeforeApplyHookParams, IFormatPainterHook } from './services/format-painter/format-painter.service';
|
|
100
|
-
export { HeaderUnhideRangeAxis, HeaderUnhideRangeService
|
|
107
|
+
export type { IFormatPainterBeforeApplyHookParams, IFormatPainterHook, } from './services/format-painter/format-painter.service';
|
|
108
|
+
export { HeaderUnhideRangeAxis, HeaderUnhideRangeService } from './services/header-unhide-range.service';
|
|
109
|
+
export type { HeaderUnhideRangeVisibleHandler, IHeaderUnhideRangeVisibleCheck, } from './services/header-unhide-range.service';
|
|
101
110
|
export { HoverManagerService } from './services/hover-manager.service';
|
|
102
|
-
export type { ICellPosWithEvent, IHoverCellPosition, IHoverRichTextInfo, IHoverRichTextPosition } from './services/hover-manager.service';
|
|
111
|
+
export type { ICellPosWithEvent, IHoverCellPosition, IHoverRichTextInfo, IHoverRichTextPosition, } from './services/hover-manager.service';
|
|
103
112
|
export { IMarkSelectionService, MarkSelectionService } from './services/mark-selection/mark-selection.service';
|
|
104
|
-
export {
|
|
113
|
+
export { SheetPermissionRenderManagerService } from './services/permission/sheet-permission-render-manager.service';
|
|
114
|
+
export type { ProtectedRangeShadowStrategy } from './services/permission/sheet-permission-render-manager.service';
|
|
105
115
|
export { SheetPermissionUserManagerService } from './services/permission/sheet-permission-user-list.service';
|
|
106
116
|
export { SheetPrintInterceptorService } from './services/print-interceptor.service';
|
|
107
|
-
export { IRepeatLastActionService,
|
|
117
|
+
export { IRepeatLastActionService, RepeatLastActionPermission } from './services/repeat-last-action.service';
|
|
118
|
+
export type { RepeatableCommandHandler } from './services/repeat-last-action.service';
|
|
108
119
|
export { SheetScrollManagerService } from './services/scroll-manager.service';
|
|
109
120
|
export type { IScrollState, IViewportScrollState } from './services/scroll-manager.service';
|
|
110
|
-
export { BaseSelectionRenderService, genSelectionByRange, selectionDataForSelectAll as getAllSelection, getTopLeftSelectionOfCurrSheet, ISheetSelectionRenderService } from './services/selection/base-selection-render.service';
|
|
121
|
+
export { BaseSelectionRenderService, genSelectionByRange, selectionDataForSelectAll as getAllSelection, getTopLeftSelectionOfCurrSheet, ISheetSelectionRenderService, } from './services/selection/base-selection-render.service';
|
|
111
122
|
export { genNormalSelectionStyle } from './services/selection/const';
|
|
112
123
|
export { SELECTION_SHAPE_DEPTH } from './services/selection/const';
|
|
113
124
|
export { SelectionControl, SelectionControl as SelectionShape } from './services/selection/selection-control';
|
|
@@ -116,15 +127,11 @@ export { SelectionShapeExtension } from './services/selection/selection-shape-ex
|
|
|
116
127
|
export { SheetSkeletonManagerService } from './services/sheet-skeleton-manager.service';
|
|
117
128
|
export { SheetsRenderService } from './services/sheets-render.service';
|
|
118
129
|
export { IStatusBarService, StatusBarService } from './services/status-bar.service';
|
|
119
|
-
export { calculateDocSkeletonRects, getCustomRangePosition, getEditingCustomRangePosition } from './services/utils/doc-skeleton-util';
|
|
130
|
+
export { calculateDocSkeletonRects, getCustomRangePosition, getEditingCustomRangePosition, } from './services/utils/doc-skeleton-util';
|
|
120
131
|
export { useKeyEventConfig } from './views/editor-container';
|
|
121
|
-
export {
|
|
122
|
-
export { MobileSheetBar } from './views/mobile/sheet-bar/MobileSheetBar';
|
|
132
|
+
export { useActiveWorkbook, useActiveWorksheet, useWorkbooks } from './views/hook';
|
|
123
133
|
export type { IRangeProtectionRenderCellData } from './views/permission/extensions/range-protection.render';
|
|
124
134
|
export { type IPermissionDetailUserPartProps } from './views/permission/panel-detail/PermissionDetailUserPart';
|
|
125
135
|
export { type IBaseSheetBarProps } from './views/sheet-bar/sheet-bar-tabs/SheetBarItem';
|
|
126
|
-
export { SheetBar } from './views/sheet-bar/SheetBar';
|
|
127
|
-
export { RenderSheetContent, RenderSheetFooter, RenderSheetHeader } from './views/sheet-container/SheetContainer';
|
|
128
136
|
export { type IStatisticItem } from './views/status-bar/CopyableStatisticItem';
|
|
129
137
|
export { functionDisplayNames } from './views/status-bar/CopyableStatisticItem';
|
|
130
|
-
export { SheetCopyDownCommand, SheetCopyRightCommand } from '@univerjs/sheets';
|
|
@@ -160,6 +160,7 @@ declare const locale: {
|
|
|
160
160
|
pasteFormat: string;
|
|
161
161
|
pasteColWidth: string;
|
|
162
162
|
pasteBesidesBorder: string;
|
|
163
|
+
pasteFormula: string;
|
|
163
164
|
insert: string;
|
|
164
165
|
insertRow: string;
|
|
165
166
|
insertRowBefore: string;
|
|
@@ -252,6 +253,8 @@ declare const locale: {
|
|
|
252
253
|
tipRowHeightLimit: string;
|
|
253
254
|
tipColumnWidthLimit: string;
|
|
254
255
|
problem: string;
|
|
256
|
+
error: string;
|
|
257
|
+
forceStringInfo: string;
|
|
255
258
|
};
|
|
256
259
|
clipboard: {
|
|
257
260
|
paste: {
|
|
@@ -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
|
+
import type { LocaleLeafKeys } from '@univerjs/core';
|
|
17
|
+
import type enUS from './en-US';
|
|
18
|
+
export type LocaleKey = LocaleLeafKeys<typeof enUS>;
|
|
@@ -16,4 +16,5 @@
|
|
|
16
16
|
import type { IAccessor } from '@univerjs/core';
|
|
17
17
|
import type { IBorderInfo } from '@univerjs/sheets';
|
|
18
18
|
import type { IMenuSelectorItem } from '@univerjs/ui';
|
|
19
|
-
|
|
19
|
+
import type { LocaleKey } from '../locale/types';
|
|
20
|
+
export declare function CellBorderSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, IBorderInfo, IBorderInfo>;
|
|
@@ -15,9 +15,10 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { IAccessor } from '@univerjs/core';
|
|
17
17
|
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
|
|
18
|
+
import type { LocaleKey } from '../locale/types';
|
|
18
19
|
export declare const CLEAR_SELECTION_MENU_ID = "sheet.menu.clear-selection";
|
|
19
|
-
export declare function ClearSelectionMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<
|
|
20
|
-
export declare function ClearSelectionContentMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
21
|
-
export declare function ClearSelectionFormatMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
22
|
-
export declare function ClearSelectionAllToolbarMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
23
|
-
export declare function ClearSelectionAllMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
20
|
+
export declare function ClearSelectionMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey>;
|
|
21
|
+
export declare function ClearSelectionContentMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
22
|
+
export declare function ClearSelectionFormatMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
23
|
+
export declare function ClearSelectionAllToolbarMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
24
|
+
export declare function ClearSelectionAllMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
@@ -15,9 +15,10 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { IAccessor } from '@univerjs/core';
|
|
17
17
|
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
|
|
18
|
+
import type { LocaleKey } from '../locale/types';
|
|
18
19
|
export declare const DELETE_RANGE_MENU_ID = "sheet.menu.delete";
|
|
19
|
-
export declare function DeleteRangeMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<
|
|
20
|
-
export declare function RemoveColMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
21
|
-
export declare function RemoveRowMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
22
|
-
export declare function DeleteRangeMoveLeftMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
23
|
-
export declare function DeleteRangeMoveUpMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
20
|
+
export declare function DeleteRangeMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey>;
|
|
21
|
+
export declare function RemoveColMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
22
|
+
export declare function RemoveRowMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
23
|
+
export declare function DeleteRangeMoveLeftMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
24
|
+
export declare function DeleteRangeMoveUpMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
@@ -15,10 +15,11 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { IAccessor } from '@univerjs/core';
|
|
17
17
|
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
|
|
18
|
+
import type { LocaleKey } from '../locale/types';
|
|
18
19
|
import { MenuItemType } from '@univerjs/ui';
|
|
19
20
|
import { Observable } from 'rxjs';
|
|
20
|
-
export declare function FontSizeSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<number>;
|
|
21
|
-
export declare function FontSizeIncreaseMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
21
|
+
export declare function FontSizeSelectorMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey, number>;
|
|
22
|
+
export declare function FontSizeIncreaseMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
22
23
|
export declare function FontSizeDecreaseMenuItemFactory(accessor: IAccessor): {
|
|
23
24
|
id: string;
|
|
24
25
|
type: MenuItemType;
|
|
@@ -15,15 +15,16 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { IAccessor } from '@univerjs/core';
|
|
17
17
|
import type { IMenuButtonItem, IMenuSelectorItem } from '@univerjs/ui';
|
|
18
|
+
import type { LocaleKey } from '../locale/types';
|
|
18
19
|
export declare const SHEET_FROZEN_MENU_ID = "sheet.menu.sheet-frozen";
|
|
19
|
-
export declare function SheetFrozenMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<
|
|
20
|
+
export declare function SheetFrozenMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey>;
|
|
20
21
|
export declare const SHEET_FROZEN_COLUMN_HEADER_MENU_ID = "sheet.column-header-menu.sheet-frozen";
|
|
21
|
-
export declare function SheetFrozenColumnHeaderMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<
|
|
22
|
+
export declare function SheetFrozenColumnHeaderMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey>;
|
|
22
23
|
export declare const SHEET_FROZEN_ROW_HEADER_MENU_ID = "sheet.row-header-menu.sheet-frozen";
|
|
23
|
-
export declare function SheetFrozenRowHeaderMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<
|
|
24
|
-
export declare function FrozenMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
25
|
-
export declare function FrozenRowMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
26
|
-
export declare function FrozenColMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
27
|
-
export declare function FrozenFirstRowMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
28
|
-
export declare function FrozenFirstColMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
29
|
-
export declare function CancelFrozenMenuItemFactory(accessor: IAccessor): IMenuButtonItem
|
|
24
|
+
export declare function SheetFrozenRowHeaderMenuItemFactory(accessor: IAccessor): IMenuSelectorItem<LocaleKey>;
|
|
25
|
+
export declare function FrozenMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
26
|
+
export declare function FrozenRowMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
27
|
+
export declare function FrozenColMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
28
|
+
export declare function FrozenFirstRowMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
29
|
+
export declare function FrozenFirstColMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
30
|
+
export declare function CancelFrozenMenuItemFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|
|
@@ -15,4 +15,5 @@
|
|
|
15
15
|
*/
|
|
16
16
|
import type { IAccessor } from '@univerjs/core';
|
|
17
17
|
import type { IMenuButtonItem } from '@univerjs/ui';
|
|
18
|
-
|
|
18
|
+
import type { LocaleKey } from '../locale/types';
|
|
19
|
+
export declare function ToggleGridlinesMenuFactory(accessor: IAccessor): IMenuButtonItem<LocaleKey>;
|