@univerjs/ui 0.2.7 → 0.2.8
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 +2 -2
- package/lib/es/index.js +119 -10
- package/lib/types/commands/operations/editor/set-editor-resize.operation.d.ts +0 -1
- package/lib/types/commands/operations/toggle-shortcut-panel.operation.d.ts +0 -1
- package/lib/types/common/component-manager.d.ts +0 -1
- package/lib/types/common/lifecycle.d.ts +0 -1
- package/lib/types/common/menu-hidden-observable.d.ts +0 -1
- package/lib/types/common/menu-merge-configs.d.ts +0 -1
- package/lib/types/components/custom-label/CustomLabel.d.ts +0 -1
- package/lib/types/components/editor/TextEditor.d.ts +0 -1
- package/lib/types/components/font-family/FontFamily.d.ts +0 -1
- package/lib/types/components/font-family/FontFamilyItem.d.ts +0 -1
- package/lib/types/components/font-family/interface.d.ts +0 -1
- package/lib/types/components/font-size/FontSize.d.ts +0 -1
- package/lib/types/components/font-size/interface.d.ts +0 -1
- package/lib/types/components/hooks/layout.d.ts +0 -1
- package/lib/types/components/hooks/locale.d.ts +0 -1
- package/lib/types/components/hooks/observable.d.ts +0 -1
- package/lib/types/components/hooks/virtual-list.d.ts +35 -0
- package/lib/types/components/menu/common/hook.d.ts +0 -1
- package/lib/types/components/menu/desktop/Menu.d.ts +0 -1
- package/lib/types/components/menu/mobile/MobileMenu.d.ts +0 -1
- package/lib/types/components/menu/mobile/MobileMenu.stories.d.ts +0 -1
- package/lib/types/components/notification/Notification.d.ts +0 -1
- package/lib/types/components/notification/Notification.stories.d.ts +0 -1
- package/lib/types/components/progress-bar/ProgressBar.d.ts +0 -1
- package/lib/types/components/range-selector/RangeSelector.d.ts +0 -1
- package/lib/types/controllers/error/error.controller.d.ts +0 -1
- package/lib/types/controllers/menus/menus.d.ts +0 -1
- package/lib/types/controllers/shared-shortcut.controller.d.ts +0 -1
- package/lib/types/controllers/shortcut-display/menu.d.ts +0 -1
- package/lib/types/controllers/shortcut-display/shortcut-panel.controller.d.ts +0 -1
- package/lib/types/controllers/ui/ui-desktop.controller.d.ts +0 -1
- package/lib/types/controllers/ui/ui-mobile.controller.d.ts +0 -1
- package/lib/types/controllers/ui/ui.controller.d.ts +0 -1
- package/lib/types/index.d.ts +1 -0
- package/lib/types/locale/en-US.d.ts +0 -1
- package/lib/types/locale/ru-RU.d.ts +0 -1
- package/lib/types/locale/vi-VN.d.ts +0 -1
- package/lib/types/locale/zh-TW.d.ts +0 -1
- package/lib/types/mobile-ui-plugin.d.ts +0 -1
- package/lib/types/services/before-close/before-close.service.d.ts +0 -1
- package/lib/types/services/clipboard/clipboard-interface.service.d.ts +0 -1
- package/lib/types/services/clipboard/clipboard.command.d.ts +0 -1
- package/lib/types/services/confirm/confirm.service.d.ts +0 -1
- package/lib/types/services/confirm/desktop-confirm.service.d.ts +0 -1
- package/lib/types/services/contextmenu/contextmenu.service.d.ts +0 -1
- package/lib/types/services/dialog/desktop-dialog.service.d.ts +0 -1
- package/lib/types/services/dialog/dialog.service.d.ts +0 -1
- package/lib/types/services/dom/canvas-dom-layer.service.d.ts +0 -1
- package/lib/types/services/editor/editor.service.d.ts +0 -1
- package/lib/types/services/global-zone/desktop-global-zone.service.d.ts +0 -1
- package/lib/types/services/global-zone/global-zone.service.d.ts +0 -1
- package/lib/types/services/layout/layout.service.d.ts +0 -1
- package/lib/types/services/local-storage/local-storage.service.d.ts +0 -1
- package/lib/types/services/menu/menu.d.ts +0 -1
- package/lib/types/services/menu/menu.service.d.ts +1 -1
- package/lib/types/services/message/__testing__/mock-message.service.d.ts +0 -1
- package/lib/types/services/message/desktop-message.service.d.ts +0 -1
- package/lib/types/services/message/message.service.d.ts +0 -1
- package/lib/types/services/notification/desktop-notification.service.d.ts +0 -1
- package/lib/types/services/notification/notification.service.d.ts +0 -1
- package/lib/types/services/parts/parts.service.d.ts +0 -1
- package/lib/types/services/popup/canvas-popup.service.d.ts +2 -1
- package/lib/types/services/progress/progress.service.d.ts +0 -1
- package/lib/types/services/range-selector/range-selector.service.d.ts +0 -1
- package/lib/types/services/shortcut/shortcut-panel.service.d.ts +0 -1
- package/lib/types/services/shortcut/shortcut.service.d.ts +0 -1
- package/lib/types/services/sidebar/desktop-sidebar.service.d.ts +0 -1
- package/lib/types/services/sidebar/sidebar.service.d.ts +0 -1
- package/lib/types/services/zen-zone/desktop-zen-zone.service.d.ts +0 -1
- package/lib/types/services/zen-zone/zen-zone.service.d.ts +0 -1
- package/lib/types/ui-plugin.d.ts +0 -1
- package/lib/types/utils/cell.d.ts +0 -1
- package/lib/types/views/MobileApp.d.ts +0 -1
- package/lib/types/views/components/ComponentContainer.d.ts +0 -1
- package/lib/types/views/components/confirm-part/ConfirmPart.d.ts +0 -1
- package/lib/types/views/components/confirm-part/interface.d.ts +0 -1
- package/lib/types/views/components/context-menu/ContextMenu.d.ts +0 -1
- package/lib/types/views/components/context-menu/MobileContextMenu.d.ts +0 -1
- package/lib/types/views/components/dialog-part/DialogPart.d.ts +0 -1
- package/lib/types/views/components/dialog-part/interface.d.ts +0 -1
- package/lib/types/views/components/doc-bars/Button/ToolbarButton.d.ts +0 -1
- package/lib/types/views/components/doc-bars/Toolbar.d.ts +0 -1
- package/lib/types/views/components/doc-bars/ToolbarItem.d.ts +0 -1
- package/lib/types/views/components/doc-bars/hook.d.ts +0 -1
- package/lib/types/views/components/dom/FloatDom.d.ts +0 -1
- package/lib/types/views/components/global-zone/GlobalZone.d.ts +0 -1
- package/lib/types/views/components/popup/CanvasPopup.d.ts +0 -1
- package/lib/types/views/components/shortcut-panel/ShortcutPanel.d.ts +0 -1
- package/lib/types/views/components/sidebar/Sidebar.d.ts +0 -1
- package/lib/types/views/components/sidebar/interface.d.ts +0 -1
- package/lib/types/views/components/zen-zone/ZenZone.d.ts +0 -1
- package/lib/types/views/parts.d.ts +0 -1
- package/lib/types/views/workbench/Workbench.d.ts +0 -1
- package/lib/umd/index.js +2 -2
- package/package.json +14 -14
|
@@ -3,7 +3,6 @@ import { ForwardRefExoticComponent } from 'react';
|
|
|
3
3
|
import { Subject } from 'rxjs';
|
|
4
4
|
import { ComponentManager } from '../../common/component-manager';
|
|
5
5
|
import { IGlobalZoneService } from './global-zone.service';
|
|
6
|
-
|
|
7
6
|
export declare class DesktopGlobalZoneService implements IGlobalZoneService {
|
|
8
7
|
private readonly _componentManager;
|
|
9
8
|
readonly visible$: Subject<boolean>;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { ContextService, IDisposable, Nullable, Disposable, IUniverInstanceService, UniverInstanceType } from '@univerjs/core';
|
|
2
2
|
import { IEditorService } from '../editor/editor.service';
|
|
3
|
-
|
|
4
3
|
type FocusHandlerFn = (unitId: string) => void;
|
|
5
4
|
export declare const FOCUSING_UNIVER = "FOCUSING_UNIVER";
|
|
6
5
|
export interface ILayoutService {
|
|
@@ -2,7 +2,6 @@ import { Disposable, IDisposable } from '@univerjs/core';
|
|
|
2
2
|
import { Observable } from 'rxjs';
|
|
3
3
|
import { IShortcutService } from '../shortcut/shortcut.service';
|
|
4
4
|
import { IDisplayMenuItem, IMenuItem, MenuConfig, MenuPosition } from './menu';
|
|
5
|
-
|
|
6
5
|
export declare const IMenuService: import('@univerjs/core').IdentifierDecorator<IMenuService>;
|
|
7
6
|
export interface IMenuService {
|
|
8
7
|
menuChanged$: Observable<void>;
|
|
@@ -29,4 +28,5 @@ export declare class MenuService extends Disposable implements IMenuService {
|
|
|
29
28
|
getMenuConfig(id: string): MenuConfig | null;
|
|
30
29
|
private _getDisplayMenuItems;
|
|
31
30
|
private _appendMenuToPosition;
|
|
31
|
+
private _updateMenuItems;
|
|
32
32
|
}
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { IMessageOptions, IMessageProps, Message } from '@univerjs/design';
|
|
2
2
|
import { IDisposable } from '@univerjs/core';
|
|
3
3
|
import { IMessageService } from './message.service';
|
|
4
|
-
|
|
5
4
|
export declare class DesktopMessageService implements IMessageService, IDisposable {
|
|
6
5
|
protected _portalContainer: HTMLElement | undefined;
|
|
7
6
|
protected _message?: Message;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { IMessageOptions } from '@univerjs/design';
|
|
2
2
|
import { IDisposable } from '@univerjs/core';
|
|
3
|
-
|
|
4
3
|
export declare const IMessageService: import('@univerjs/core').IdentifierDecorator<IMessageService>;
|
|
5
4
|
export interface IMessageService {
|
|
6
5
|
show(options: IMessageOptions): IDisposable;
|
|
@@ -2,7 +2,6 @@ import { Disposable, IDisposable, Injector } from '@univerjs/core';
|
|
|
2
2
|
import { INotificationOptions } from '../../components/notification/Notification';
|
|
3
3
|
import { IUIPartsService } from '../parts/parts.service';
|
|
4
4
|
import { INotificationService } from './notification.service';
|
|
5
|
-
|
|
6
5
|
export declare class DesktopNotificationService extends Disposable implements INotificationService {
|
|
7
6
|
private readonly _injector;
|
|
8
7
|
private readonly _uiPartsService;
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { IDisposable } from '@univerjs/core';
|
|
2
2
|
import { INotificationOptions } from '../../components/notification/Notification';
|
|
3
|
-
|
|
4
3
|
export declare const INotificationService: import('@univerjs/core').IdentifierDecorator<INotificationService>;
|
|
5
4
|
export interface INotificationService {
|
|
6
5
|
show(params: INotificationOptions): IDisposable;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { IDisposable, Disposable } from '@univerjs/core';
|
|
2
2
|
import { Observable } from 'rxjs';
|
|
3
3
|
import { ComponentType } from '../../common/component-manager';
|
|
4
|
-
|
|
5
4
|
type ComponentRenderer = () => ComponentType;
|
|
6
5
|
type ComponentPartKey = BuiltInUIPart | string;
|
|
7
6
|
export declare enum BuiltInUIPart {
|
|
@@ -2,7 +2,6 @@ import { Disposable } from '@univerjs/core';
|
|
|
2
2
|
import { IRectPopupProps } from '@univerjs/design';
|
|
3
3
|
import { IBoundRectNoAngle } from '@univerjs/engine-render';
|
|
4
4
|
import { Observable } from 'rxjs';
|
|
5
|
-
|
|
6
5
|
export interface IPopup extends Pick<IRectPopupProps, 'closeOnSelfTarget' | 'direction' | 'excludeOutside' | 'onClickOutside'> {
|
|
7
6
|
anchorRect: IBoundRectNoAngle;
|
|
8
7
|
anchorRect$: Observable<IBoundRectNoAngle>;
|
|
@@ -12,6 +11,8 @@ export interface IPopup extends Pick<IRectPopupProps, 'closeOnSelfTarget' | 'dir
|
|
|
12
11
|
unitId: string;
|
|
13
12
|
subUnitId: string;
|
|
14
13
|
offset?: [number, number];
|
|
14
|
+
canvasElement: HTMLCanvasElement;
|
|
15
|
+
hideOnInvisible?: boolean;
|
|
15
16
|
}
|
|
16
17
|
export interface ICanvasPopupService {
|
|
17
18
|
addPopup(item: IPopup): string;
|
|
@@ -3,7 +3,6 @@ import { Observable } from 'rxjs';
|
|
|
3
3
|
import { ILayoutService } from '../layout/layout.service';
|
|
4
4
|
import { IPlatformService } from '../platform/platform.service';
|
|
5
5
|
import { KeyCode } from './keycode';
|
|
6
|
-
|
|
7
6
|
export interface IShortcutItem<P extends object = object> {
|
|
8
7
|
/** This should reuse the corresponding command's id. */
|
|
9
8
|
id: string;
|
|
@@ -2,7 +2,6 @@ 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';
|
|
5
|
-
|
|
6
5
|
export declare class DesktopSidebarService implements ISidebarService {
|
|
7
6
|
private _sidebarOptions;
|
|
8
7
|
readonly sidebarOptions$: Subject<ISidebarMethodOptions>;
|
|
@@ -1,7 +1,6 @@
|
|
|
1
1
|
import { IDisposable } from '@univerjs/core';
|
|
2
2
|
import { Subject } from 'rxjs';
|
|
3
3
|
import { ISidebarMethodOptions } from '../../views/components/sidebar/interface';
|
|
4
|
-
|
|
5
4
|
export interface ISidebarService {
|
|
6
5
|
readonly sidebarOptions$: Subject<ISidebarMethodOptions>;
|
|
7
6
|
readonly scrollEvent$: Subject<Event>;
|
|
@@ -3,7 +3,6 @@ import { ForwardRefExoticComponent } from 'react';
|
|
|
3
3
|
import { Subject } from 'rxjs';
|
|
4
4
|
import { ComponentManager } from '../../common/component-manager';
|
|
5
5
|
import { IZenZoneService } from './zen-zone.service';
|
|
6
|
-
|
|
7
6
|
export declare class DesktopZenZoneService implements IZenZoneService {
|
|
8
7
|
private readonly _componentManager;
|
|
9
8
|
readonly visible$: Subject<boolean>;
|
package/lib/types/ui-plugin.d.ts
CHANGED
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { IContextService, Injector, Plugin } from '@univerjs/core';
|
|
2
2
|
import { IUniverUIConfig } from './controllers/ui/ui.controller';
|
|
3
|
-
|
|
4
3
|
export declare const UNIVER_UI_PLUGIN_NAME = "UNIVER_UI_PLUGIN";
|
|
5
4
|
export declare const DISABLE_AUTO_FOCUS_KEY = "DISABLE_AUTO_FOCUS";
|
|
6
5
|
/**
|
|
@@ -1,6 +1,5 @@
|
|
|
1
1
|
import { default as React } from 'react';
|
|
2
2
|
import { IWorkbenchOptions } from '../../controllers/ui/ui.controller';
|
|
3
|
-
|
|
4
3
|
export interface IUniverWorkbenchProps extends IWorkbenchOptions {
|
|
5
4
|
mountContainer: HTMLElement;
|
|
6
5
|
onRendered?: (containerElement: HTMLElement) => void;
|