@univerjs/ui 0.2.2 → 0.2.4-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/README.md +11 -4
- package/lib/cjs/index.js +14 -14
- package/lib/es/index.js +3781 -3733
- package/lib/index.css +1 -1
- package/lib/locale/vi-VN.json +61 -0
- package/lib/locale/zh-TW.json +61 -0
- package/lib/types/common/component-manager.d.ts +1 -1
- package/lib/types/common/lifecycle.d.ts +1 -1
- package/lib/types/common/menu-hidden-observable.d.ts +1 -2
- package/lib/types/const.d.ts +19 -0
- package/lib/types/controllers/menus/menus.d.ts +1 -1
- package/lib/types/controllers/shared-shortcut.controller.d.ts +1 -2
- package/lib/types/controllers/shortcut-display/menu.d.ts +1 -1
- package/lib/types/controllers/shortcut-display/shortcut-panel.controller.d.ts +1 -2
- package/lib/types/controllers/ui/ui-desktop.controller.d.ts +1 -2
- package/lib/types/controllers/ui/ui-mobile.controller.d.ts +1 -2
- package/lib/types/controllers/ui/ui.controller.d.ts +1 -1
- package/lib/types/index.d.ts +12 -6
- package/lib/types/locale/vi-VN.d.ts +4 -0
- package/lib/types/locale/zh-TW.d.ts +4 -0
- package/lib/types/mobile-ui-plugin.d.ts +1 -2
- package/lib/types/services/before-close/before-close.service.d.ts +2 -2
- package/lib/types/services/clipboard/clipboard-interface.service.d.ts +1 -1
- package/lib/types/services/confirm/confirm.service.d.ts +2 -2
- package/lib/types/services/confirm/desktop-confirm.service.d.ts +1 -2
- package/lib/types/services/contextmenu/contextmenu.service.d.ts +2 -3
- package/lib/types/services/dialog/desktop-dialog.service.d.ts +1 -2
- package/lib/types/services/dialog/dialog.service.d.ts +2 -2
- package/lib/types/services/editor/editor.service.d.ts +2 -3
- package/lib/types/services/global-zone/desktop-global-zone.service.d.ts +1 -1
- package/lib/types/services/global-zone/global-zone.service.d.ts +2 -2
- package/lib/types/services/layout/layout.service.d.ts +2 -3
- package/lib/types/services/menu/menu.d.ts +1 -1
- package/lib/types/services/menu/menu.service.d.ts +2 -3
- package/lib/types/services/message/__testing__/mock-message.service.d.ts +2 -1
- package/lib/types/services/message/desktop-message.service.d.ts +2 -1
- package/lib/types/services/message/message.service.d.ts +3 -2
- package/lib/types/services/notification/desktop-notification.service.d.ts +1 -2
- package/lib/types/services/notification/notification.service.d.ts +2 -2
- package/lib/types/services/parts/parts.service.d.ts +4 -4
- package/lib/types/services/platform/platform.service.d.ts +1 -1
- package/lib/types/services/popup/canvas-popup.service.d.ts +1 -1
- package/lib/types/services/progress/progress.service.d.ts +2 -3
- package/lib/types/services/range-selector/range-selector.service.d.ts +2 -3
- package/lib/types/services/shortcut/keycode.d.ts +2 -0
- package/lib/types/services/shortcut/shortcut.service.d.ts +2 -3
- package/lib/types/services/sidebar/desktop-sidebar.service.d.ts +2 -1
- package/lib/types/services/sidebar/sidebar.service.d.ts +3 -2
- package/lib/types/services/zen-zone/desktop-zen-zone.service.d.ts +1 -1
- package/lib/types/services/zen-zone/zen-zone.service.d.ts +2 -2
- package/lib/types/ui-plugin.d.ts +2 -3
- package/lib/types/utils/util.d.ts +1 -0
- package/lib/types/views/components/ComponentContainer.d.ts +1 -1
- package/lib/types/views/workbench/Workbench.d.ts +8 -0
- package/lib/umd/index.js +14 -14
- package/package.json +14 -16
- package/lib/types/views/DesktopApp.d.ts +0 -8
|
@@ -21,7 +21,7 @@ export interface IPlatformService {
|
|
|
21
21
|
readonly isWindows: boolean;
|
|
22
22
|
readonly isLinux: boolean;
|
|
23
23
|
}
|
|
24
|
-
export declare const IPlatformService: import('@
|
|
24
|
+
export declare const IPlatformService: import('@univerjs/core').IdentifierDecorator<IPlatformService>;
|
|
25
25
|
export declare class PlatformService implements IPlatformService {
|
|
26
26
|
get isMac(): boolean;
|
|
27
27
|
get isWindows(): boolean;
|
|
@@ -20,7 +20,7 @@ export interface ICanvasPopupService {
|
|
|
20
20
|
popups$: Observable<[string, IPopup][]>;
|
|
21
21
|
get popups(): [string, IPopup][];
|
|
22
22
|
}
|
|
23
|
-
export declare const ICanvasPopupService: import('@
|
|
23
|
+
export declare const ICanvasPopupService: import('@univerjs/core').IdentifierDecorator<ICanvasPopupService>;
|
|
24
24
|
export declare class CanvasPopupService extends Disposable implements ICanvasPopupService {
|
|
25
25
|
private readonly _popupMap;
|
|
26
26
|
private readonly _popups$;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { Disposable } from '@univerjs/core';
|
|
2
|
-
import { IDisposable } from '@wendellhu/redi';
|
|
1
|
+
import { Disposable, IDisposable } from '@univerjs/core';
|
|
3
2
|
import { Observable } from 'rxjs';
|
|
4
3
|
|
|
5
4
|
export interface IProgressCount {
|
|
@@ -51,4 +50,4 @@ export declare class ProgressService extends Disposable implements IProgressServ
|
|
|
51
50
|
getTaskCount(): number;
|
|
52
51
|
private _clear;
|
|
53
52
|
}
|
|
54
|
-
export declare const IProgressService: import('@
|
|
53
|
+
export declare const IProgressService: import('@univerjs/core').IdentifierDecorator<IProgressService>;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { IUnitRange, Nullable, Disposable } from '@univerjs/core';
|
|
2
|
-
import { IDisposable } from '@wendellhu/redi';
|
|
1
|
+
import { IDisposable, IUnitRange, Nullable, Disposable } from '@univerjs/core';
|
|
3
2
|
import { Observable } from 'rxjs';
|
|
4
3
|
|
|
5
4
|
export interface IRangeSelectorRange extends IUnitRange {
|
|
@@ -24,4 +23,4 @@ export declare class RangeSelectorService extends Disposable implements IRangeSe
|
|
|
24
23
|
selectionChange(range: IRangeSelectorRange[]): void;
|
|
25
24
|
openSelector(): void;
|
|
26
25
|
}
|
|
27
|
-
export declare const IRangeSelectorService: import('@
|
|
26
|
+
export declare const IRangeSelectorService: import('@univerjs/core').IdentifierDecorator<IRangeSelectorService>;
|
|
@@ -1,5 +1,4 @@
|
|
|
1
|
-
import { Disposable, ICommandService, IContextService } from '@univerjs/core';
|
|
2
|
-
import { IDisposable } from '@wendellhu/redi';
|
|
1
|
+
import { Disposable, ICommandService, IContextService, IDisposable } from '@univerjs/core';
|
|
3
2
|
import { Observable } from 'rxjs';
|
|
4
3
|
import { ILayoutService } from '../layout/layout.service';
|
|
5
4
|
import { IPlatformService } from '../platform/platform.service';
|
|
@@ -35,7 +34,7 @@ export interface IShortcutService {
|
|
|
35
34
|
getAllShortcuts(): IShortcutItem[];
|
|
36
35
|
setDisable(disable: boolean): void;
|
|
37
36
|
}
|
|
38
|
-
export declare const IShortcutService: import('@
|
|
37
|
+
export declare const IShortcutService: import('@univerjs/core').IdentifierDecorator<IShortcutService>;
|
|
39
38
|
export declare class ShortcutService extends Disposable implements IShortcutService {
|
|
40
39
|
private readonly _commandService;
|
|
41
40
|
private readonly _platformService;
|
|
@@ -1,4 +1,4 @@
|
|
|
1
|
-
import { IDisposable } from '@
|
|
1
|
+
import { IDisposable } from '@univerjs/core';
|
|
2
2
|
import { Subject } from 'rxjs';
|
|
3
3
|
import { ISidebarMethodOptions } from '../../views/components/sidebar/interface';
|
|
4
4
|
import { ISidebarService } from './sidebar.service';
|
|
@@ -6,6 +6,7 @@ import { ISidebarService } from './sidebar.service';
|
|
|
6
6
|
export declare class DesktopSidebarService implements ISidebarService {
|
|
7
7
|
private _sidebarOptions;
|
|
8
8
|
readonly sidebarOptions$: Subject<ISidebarMethodOptions>;
|
|
9
|
+
readonly scrollEvent$: Subject<Event>;
|
|
9
10
|
open(params: ISidebarMethodOptions): IDisposable;
|
|
10
11
|
close(): void;
|
|
11
12
|
}
|
|
@@ -1,10 +1,11 @@
|
|
|
1
|
-
import { IDisposable } from '@
|
|
1
|
+
import { IDisposable } from '@univerjs/core';
|
|
2
2
|
import { Subject } from 'rxjs';
|
|
3
3
|
import { ISidebarMethodOptions } from '../../views/components/sidebar/interface';
|
|
4
4
|
|
|
5
|
-
export declare const ISidebarService: import('@
|
|
5
|
+
export declare const ISidebarService: import('@univerjs/core').IdentifierDecorator<ISidebarService>;
|
|
6
6
|
export interface ISidebarService {
|
|
7
7
|
readonly sidebarOptions$: Subject<ISidebarMethodOptions>;
|
|
8
|
+
readonly scrollEvent$: Subject<Event>;
|
|
8
9
|
open(params: ISidebarMethodOptions): IDisposable;
|
|
9
10
|
close(): void;
|
|
10
11
|
}
|
|
@@ -1,7 +1,7 @@
|
|
|
1
|
-
import { IDisposable } from '@
|
|
1
|
+
import { IDisposable } from '@univerjs/core';
|
|
2
2
|
import { Subject } from 'rxjs';
|
|
3
3
|
|
|
4
|
-
export declare const IZenZoneService: import('@
|
|
4
|
+
export declare const IZenZoneService: import('@univerjs/core').IdentifierDecorator<IZenZoneService>;
|
|
5
5
|
export interface IZenZoneService {
|
|
6
6
|
readonly visible$: Subject<boolean>;
|
|
7
7
|
readonly componentKey$: Subject<string>;
|
package/lib/types/ui-plugin.d.ts
CHANGED
|
@@ -1,8 +1,7 @@
|
|
|
1
|
-
import { IContextService, Plugin } from '@univerjs/core';
|
|
2
|
-
import { Injector } from '@wendellhu/redi';
|
|
1
|
+
import { IContextService, Injector, Plugin } from '@univerjs/core';
|
|
3
2
|
import { IUniverUIConfig } from './controllers/ui/ui.controller';
|
|
4
3
|
|
|
5
|
-
export declare const
|
|
4
|
+
export declare const UNIVER_UI_PLUGIN_NAME = "UNIVER_UI_PLUGIN";
|
|
6
5
|
export declare const DISABLE_AUTO_FOCUS_KEY = "DISABLE_AUTO_FOCUS";
|
|
7
6
|
/**
|
|
8
7
|
* UI plugin provides basic interaction with users. Including workbench (menus, UI parts, notifications etc.), copy paste, shortcut.
|
|
@@ -0,0 +1,8 @@
|
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
import { IWorkbenchOptions } from '../../controllers/ui/ui.controller';
|
|
3
|
+
|
|
4
|
+
export interface IUniverWorkbenchProps extends IWorkbenchOptions {
|
|
5
|
+
mountContainer: HTMLElement;
|
|
6
|
+
onRendered?: (container: HTMLElement) => void;
|
|
7
|
+
}
|
|
8
|
+
export declare function DesktopWorkbench(props: IUniverWorkbenchProps): React.JSX.Element;
|