@univerjs/ui 0.22.1 → 0.23.0-insiders.20260522-e8f2a3b
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/index.js +224 -230
- package/lib/es/index.js +225 -223
- package/lib/index.js +225 -223
- package/lib/types/index.d.ts +1 -4
- package/lib/types/services/menu/menu-manager.service.d.ts +2 -0
- package/lib/types/services/ribbon/ribbon.service.d.ts +16 -0
- package/lib/umd/index.js +33 -33
- package/package.json +7 -7
- package/LICENSE +0 -176
- package/lib/types/services/global-zone/desktop-global-zone.service.d.ts +0 -31
- package/lib/types/services/global-zone/global-zone.service.d.ts +0 -26
- package/lib/types/views/components/global-zone/GlobalZone.d.ts +0 -16
- /package/lib/types/views/components/dom/{print.d.ts → Print.d.ts} +0 -0
package/lib/types/index.d.ts
CHANGED
|
@@ -53,8 +53,6 @@ export { CanvasFloatDomService, type IFloatDom, type IFloatDomLayout } from './s
|
|
|
53
53
|
export { type IFontConfig, IFontService } from './services/font.service';
|
|
54
54
|
export { DesktopGalleryService } from './services/gallery/desktop-gallery.service';
|
|
55
55
|
export { IGalleryService } from './services/gallery/gallery.service';
|
|
56
|
-
export { DesktopGlobalZoneService } from './services/global-zone/desktop-global-zone.service';
|
|
57
|
-
export { IGlobalZoneService } from './services/global-zone/global-zone.service';
|
|
58
56
|
export { DesktopLayoutService, ILayoutService } from './services/layout/layout.service';
|
|
59
57
|
export { DesktopLocalFileService } from './services/local-file/desktop-local-file.service';
|
|
60
58
|
export { ILocalFileService, type IOpenFileOptions } from './services/local-file/local-file.service';
|
|
@@ -92,8 +90,7 @@ export { MobileContextMenu } from './views/components/context-menu/MobileContext
|
|
|
92
90
|
export { type IDialogPartMethodOptions } from './views/components/dialog-part/interface';
|
|
93
91
|
export { FloatDomSingle } from './views/components/dom/FloatDom';
|
|
94
92
|
export { FloatDom } from './views/components/dom/FloatDom';
|
|
95
|
-
export { PrintFloatDomSingle } from './views/components/dom/
|
|
96
|
-
export { GlobalZone } from './views/components/global-zone/GlobalZone';
|
|
93
|
+
export { PrintFloatDomSingle } from './views/components/dom/Print';
|
|
97
94
|
export { CanvasPopup, SingleCanvasPopup } from './views/components/popup/CanvasPopup';
|
|
98
95
|
export { RectPopup, type RectPopupDirection } from './views/components/popup/RectPopup';
|
|
99
96
|
export { useToolbarItemStatus } from './views/components/ribbon/hook';
|
|
@@ -24,6 +24,7 @@ export interface IMenuSchema {
|
|
|
24
24
|
key: string;
|
|
25
25
|
order: number;
|
|
26
26
|
title?: string;
|
|
27
|
+
contextual?: boolean;
|
|
27
28
|
item?: IMenuItem;
|
|
28
29
|
children?: IMenuSchema[];
|
|
29
30
|
quickLayout?: ContextMenuQuickLayout;
|
|
@@ -40,6 +41,7 @@ export type MenuSchemaType = {
|
|
|
40
41
|
order?: number;
|
|
41
42
|
menuItemFactory?: (accessor: IAccessor) => IMenuItem;
|
|
42
43
|
title?: string;
|
|
44
|
+
contextual?: boolean;
|
|
43
45
|
quickLayout?: ContextMenuQuickLayout;
|
|
44
46
|
} | {
|
|
45
47
|
[key: string]: MenuSchemaType;
|
|
@@ -24,6 +24,11 @@ export interface IRibbonService {
|
|
|
24
24
|
collapsedIds$: Observable<string[]>;
|
|
25
25
|
fakeToolbarVisible$: Observable<boolean>;
|
|
26
26
|
setActivatedTab(tab: string): void;
|
|
27
|
+
showContextualTab(tab: string, options?: {
|
|
28
|
+
activate?: boolean;
|
|
29
|
+
}): void;
|
|
30
|
+
hideContextualTab(tab: string): void;
|
|
31
|
+
hideAllContextualTabs(): void;
|
|
27
32
|
setCollapsedIds(ids: string[]): void;
|
|
28
33
|
setFakeToolbarVisible(visible: boolean): void;
|
|
29
34
|
}
|
|
@@ -38,10 +43,21 @@ export declare class DesktopRibbonService extends Disposable implements IRibbonS
|
|
|
38
43
|
readonly collapsedIds$: Observable<string[]>;
|
|
39
44
|
private readonly _fakeToolbarVisible$;
|
|
40
45
|
readonly fakeToolbarVisible$: Observable<boolean>;
|
|
46
|
+
private readonly _visibleContextualTabs;
|
|
47
|
+
private readonly _contextualTabs;
|
|
48
|
+
private _lastNonContextualActivatedTab;
|
|
41
49
|
constructor(_menuManagerService: IMenuManagerService, _univerInstanceService: IUniverInstanceService);
|
|
42
50
|
setActivatedTab(tab: string): void;
|
|
51
|
+
showContextualTab(tab: string, options?: {
|
|
52
|
+
activate?: boolean;
|
|
53
|
+
}): void;
|
|
54
|
+
hideContextualTab(tab: string): void;
|
|
55
|
+
hideAllContextualTabs(): void;
|
|
43
56
|
setCollapsedIds(ids: string[]): void;
|
|
44
57
|
setFakeToolbarVisible(visible: boolean): void;
|
|
45
58
|
private _initRibbonSubscription;
|
|
46
59
|
private _updateRibbon;
|
|
60
|
+
private _filterContextualTabs;
|
|
61
|
+
private _setRibbon;
|
|
62
|
+
private _isContextualTab;
|
|
47
63
|
}
|