@univerjs/ui 0.1.3 → 0.1.5
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 +4 -0
- package/lib/cjs/index.js +14 -14
- package/lib/es/index.js +3481 -3408
- package/lib/index.css +1 -1
- package/lib/types/commands/operations/editor/set-editor-resize.operation.d.ts +2 -16
- package/lib/types/commands/operations/toggle-shortcut-panel.operation.d.ts +2 -16
- package/lib/types/common/component-manager.d.ts +4 -18
- package/lib/types/common/lifecycle.d.ts +2 -16
- package/lib/types/common/menu-hidden-observable.d.ts +3 -17
- package/lib/types/components/custom-label/CustomLabel.d.ts +3 -18
- package/lib/types/components/editor/TextEditor.d.ts +4 -18
- package/lib/types/components/font-family/FontFamily.d.ts +3 -17
- package/lib/types/components/font-family/FontFamilyItem.d.ts +3 -17
- package/lib/types/components/font-family/interface.d.ts +2 -16
- package/lib/types/components/font-size/FontSize.d.ts +3 -17
- package/lib/types/components/font-size/interface.d.ts +3 -17
- package/lib/types/components/hooks/__tests__/observable.spec.d.ts +16 -0
- package/lib/types/components/hooks/locale.d.ts +1 -15
- package/lib/types/components/hooks/observable.d.ts +8 -19
- package/lib/types/components/menu/Menu.d.ts +3 -17
- package/lib/types/components/notification/Notification.d.ts +3 -17
- package/lib/types/components/notification/Notification.stories.d.ts +3 -17
- package/lib/types/components/range-selector/RangeSelector.d.ts +3 -17
- package/lib/types/controllers/error/error.controller.d.ts +2 -16
- package/lib/types/controllers/menus/menus.d.ts +3 -17
- package/lib/types/controllers/shared-shortcut.controller.d.ts +4 -19
- package/lib/types/controllers/shortcut-display/menu.d.ts +3 -17
- package/lib/types/controllers/shortcut-display/shortcut-panel.controller.d.ts +5 -19
- package/lib/types/controllers/ui/ui-desktop.controller.d.ts +15 -50
- package/lib/types/controllers/ui/ui.controller.d.ts +1 -5
- package/lib/types/index.d.ts +1 -0
- package/lib/types/locale/en-US.d.ts +2 -16
- package/lib/types/locale/zh-CN.d.ts +1 -0
- package/lib/types/services/before-close/before-close.service.d.ts +3 -17
- package/lib/types/services/clipboard/clipboard-interface.service.d.ts +3 -17
- package/lib/types/services/clipboard/clipboard.command.d.ts +2 -16
- package/lib/types/services/confirm/confirm.service.d.ts +5 -19
- package/lib/types/services/confirm/desktop-confirm.service.d.ts +4 -18
- package/lib/types/services/contextmenu/contextmenu.service.d.ts +4 -18
- package/lib/types/services/dialog/desktop-dialog.service.d.ts +5 -19
- package/lib/types/services/dialog/dialog.service.d.ts +5 -19
- package/lib/types/services/editor/editor.service.d.ts +10 -22
- package/lib/types/services/global-zone/desktop-global-zone.service.d.ts +5 -19
- package/lib/types/services/global-zone/global-zone.service.d.ts +4 -18
- package/lib/types/services/layout/layout.service.d.ts +4 -19
- package/lib/types/services/local-storage/local-storage.service.d.ts +2 -16
- package/lib/types/services/menu/menu.d.ts +3 -17
- package/lib/types/services/menu/menu.service.d.ts +6 -20
- package/lib/types/services/message/desktop-message.service.d.ts +4 -19
- package/lib/types/services/message/message.service.d.ts +4 -18
- package/lib/types/services/notification/desktop-notification.service.d.ts +4 -18
- package/lib/types/services/notification/notification.service.d.ts +4 -18
- package/lib/types/services/platform/platform.service.d.ts +1 -1
- package/lib/types/services/popup/canvas-popup.service.d.ts +31 -0
- package/lib/types/services/range-selector/range-selector.service.d.ts +5 -20
- package/lib/types/services/shortcut/shortcut-panel.service.d.ts +2 -16
- package/lib/types/services/shortcut/shortcut.service.d.ts +6 -20
- package/lib/types/services/sidebar/desktop-sidebar.service.d.ts +4 -18
- package/lib/types/services/sidebar/sidebar.service.d.ts +5 -19
- package/lib/types/services/zen-zone/desktop-zen-zone.service.d.ts +5 -19
- package/lib/types/services/zen-zone/zen-zone.service.d.ts +4 -18
- package/lib/types/ui-plugin.d.ts +3 -17
- package/lib/types/utils/cell.d.ts +2 -16
- package/lib/types/views/App.d.ts +4 -18
- package/lib/types/views/components/ComponentContainer.d.ts +2 -17
- package/lib/types/views/components/confirm-part/ConfirmPart.d.ts +2 -16
- package/lib/types/views/components/confirm-part/interface.d.ts +3 -17
- package/lib/types/views/components/context-menu/ContextMenu.d.ts +2 -16
- package/lib/types/views/components/dialog-part/DialogPart.d.ts +2 -16
- package/lib/types/views/components/dialog-part/interface.d.ts +3 -17
- package/lib/types/views/components/doc-bars/Button/ToolbarButton.d.ts +2 -16
- package/lib/types/views/components/doc-bars/Toolbar.d.ts +2 -17
- package/lib/types/views/components/doc-bars/ToolbarItem.d.ts +3 -17
- package/lib/types/views/components/global-zone/GlobalZone.d.ts +2 -16
- package/lib/types/views/components/popup/CanvasPopup.d.ts +3 -0
- package/lib/types/views/components/popup/index.d.ts +16 -0
- package/lib/types/views/components/shortcut-panel/ShortcutPanel.d.ts +2 -16
- package/lib/types/views/components/sidebar/Sidebar.d.ts +2 -16
- package/lib/types/views/components/sidebar/interface.d.ts +2 -16
- package/lib/types/views/components/zen-zone/ZenZone.d.ts +2 -16
- package/lib/types/views/hooks/active.d.ts +2 -16
- package/lib/types/views/parts.d.ts +2 -16
- package/lib/umd/index.js +14 -14
- package/package.json +22 -17
|
@@ -1,22 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
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 { IMessageMethodOptions, IMessageProps } from '@univerjs/design';
|
|
17
|
-
import { Message } from '@univerjs/design';
|
|
18
|
-
import type { IDisposable } from '@wendellhu/redi';
|
|
19
|
-
import type { IMessageService } from './message.service';
|
|
1
|
+
import { IMessageService } from './message.service';
|
|
2
|
+
import { IDisposable } from '@wendellhu/redi';
|
|
3
|
+
import { IMessageMethodOptions, IMessageProps, Message } from '@univerjs/design';
|
|
4
|
+
|
|
20
5
|
export declare class DesktopMessageService implements IMessageService {
|
|
21
6
|
portalContainer: HTMLElement;
|
|
22
7
|
message?: Message;
|
|
@@ -1,21 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
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 { IMessageMethodOptions, IMessageProps } from '@univerjs/design';
|
|
17
|
-
import type { IDisposable } from '@wendellhu/redi';
|
|
18
|
-
export declare const IMessageService: import("@wendellhu/redi").IdentifierDecorator<IMessageService>;
|
|
1
|
+
import { IDisposable } from '@wendellhu/redi';
|
|
2
|
+
import { IMessageMethodOptions, IMessageProps } from '@univerjs/design';
|
|
3
|
+
|
|
4
|
+
export declare const IMessageService: import('@wendellhu/redi').IdentifierDecorator<IMessageService>;
|
|
19
5
|
export interface IMessageService {
|
|
20
6
|
show(options: IMessageMethodOptions & Omit<IMessageProps, 'key'>): IDisposable;
|
|
21
7
|
setContainer(container: HTMLElement): void;
|
|
@@ -1,21 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
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 { IDisposable } from '@wendellhu/redi';
|
|
17
|
-
import type { INotificationMethodOptions } from '../../components/notification/Notification';
|
|
18
|
-
import type { INotificationService } from './notification.service';
|
|
1
|
+
import { INotificationService } from './notification.service';
|
|
2
|
+
import { INotificationMethodOptions } from '../../components/notification/Notification';
|
|
3
|
+
import { IDisposable } from '@wendellhu/redi';
|
|
4
|
+
|
|
19
5
|
export declare class DesktopNotificationService implements INotificationService {
|
|
20
6
|
show(params: INotificationMethodOptions): IDisposable;
|
|
21
7
|
}
|
|
@@ -1,21 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
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 { IDisposable } from '@wendellhu/redi';
|
|
17
|
-
import type { INotificationMethodOptions } from '../../components/notification/Notification';
|
|
18
|
-
export declare const INotificationService: import("@wendellhu/redi").IdentifierDecorator<INotificationService>;
|
|
1
|
+
import { INotificationMethodOptions } from '../../components/notification/Notification';
|
|
2
|
+
import { IDisposable } from '@wendellhu/redi';
|
|
3
|
+
|
|
4
|
+
export declare const INotificationService: import('@wendellhu/redi').IdentifierDecorator<INotificationService>;
|
|
19
5
|
export interface INotificationService {
|
|
20
6
|
show(params: INotificationMethodOptions): IDisposable;
|
|
21
7
|
}
|
|
@@ -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('@wendellhu/redi').IdentifierDecorator<IPlatformService>;
|
|
25
25
|
export declare class DesktopPlatformService implements IPlatformService {
|
|
26
26
|
get isMac(): boolean;
|
|
27
27
|
get isWindows(): boolean;
|
|
@@ -0,0 +1,31 @@
|
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import { IBoundRectNoAngle } from '@univerjs/engine-render';
|
|
3
|
+
|
|
4
|
+
export interface IPopup {
|
|
5
|
+
anchorRect: IBoundRectNoAngle;
|
|
6
|
+
anchorRect$: Observable<IBoundRectNoAngle>;
|
|
7
|
+
componentKey: string;
|
|
8
|
+
onClickOutside?: (e: MouseEvent) => void;
|
|
9
|
+
unitId: string;
|
|
10
|
+
subUnitId: string;
|
|
11
|
+
direction?: 'vertical' | 'horizontal';
|
|
12
|
+
offset?: [number, number];
|
|
13
|
+
}
|
|
14
|
+
export interface ICanvasPopupService {
|
|
15
|
+
addPopup(item: IPopup): string;
|
|
16
|
+
removePopup(id: string): void;
|
|
17
|
+
removeAll(): void;
|
|
18
|
+
popups$: Observable<[string, IPopup][]>;
|
|
19
|
+
get popups(): [string, IPopup][];
|
|
20
|
+
}
|
|
21
|
+
export declare const ICanvasPopupService: import('@wendellhu/redi').IdentifierDecorator<ICanvasPopupService>;
|
|
22
|
+
export declare class CanvasPopupService implements ICanvasPopupService {
|
|
23
|
+
private _popupMap;
|
|
24
|
+
private _popups$;
|
|
25
|
+
popups$: Observable<[string, IPopup][]>;
|
|
26
|
+
get popups(): [string, IPopup][];
|
|
27
|
+
private _notice;
|
|
28
|
+
addPopup(item: IPopup): string;
|
|
29
|
+
removePopup(id: string): void;
|
|
30
|
+
removeAll(): void;
|
|
31
|
+
}
|
|
@@ -1,22 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
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 { IUnitRange, Nullable } from '@univerjs/core';
|
|
17
|
-
import { Disposable } from '@univerjs/core';
|
|
18
|
-
import type { IDisposable } from '@wendellhu/redi';
|
|
19
|
-
import type { Observable } from 'rxjs';
|
|
1
|
+
import { Observable } from 'rxjs';
|
|
2
|
+
import { IDisposable } from '@wendellhu/redi';
|
|
3
|
+
import { IUnitRange, Nullable, Disposable } from '@univerjs/core';
|
|
4
|
+
|
|
20
5
|
export interface IRangeSelectorRange extends IUnitRange {
|
|
21
6
|
sheetName: string;
|
|
22
7
|
}
|
|
@@ -39,4 +24,4 @@ export declare class RangeSelectorService extends Disposable implements IRangeSe
|
|
|
39
24
|
selectionChange(range: IRangeSelectorRange[]): void;
|
|
40
25
|
openSelector(): void;
|
|
41
26
|
}
|
|
42
|
-
export declare const IRangeSelectorService: import(
|
|
27
|
+
export declare const IRangeSelectorService: import('@wendellhu/redi').IdentifierDecorator<IRangeSelectorService>;
|
|
@@ -1,22 +1,8 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
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
1
|
import { Disposable } from '@univerjs/core';
|
|
2
|
+
|
|
17
3
|
export declare class ShortcutPanelService extends Disposable {
|
|
18
4
|
private _open$;
|
|
19
|
-
open$: import(
|
|
5
|
+
open$: import('rxjs').Observable<boolean>;
|
|
20
6
|
get isOpen(): boolean;
|
|
21
7
|
dispose(): void;
|
|
22
8
|
open(): void;
|
|
@@ -1,23 +1,9 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
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 { Disposable, ICommandService, IContextService } from '@univerjs/core';
|
|
17
|
-
import type { IDisposable } from '@wendellhu/redi';
|
|
18
|
-
import type { Observable } from 'rxjs';
|
|
19
|
-
import { ILayoutService } from '../layout/layout.service';
|
|
20
1
|
import { IPlatformService } from '../platform/platform.service';
|
|
2
|
+
import { ILayoutService } from '../layout/layout.service';
|
|
3
|
+
import { Observable } from 'rxjs';
|
|
4
|
+
import { IDisposable } from '@wendellhu/redi';
|
|
5
|
+
import { Disposable, ICommandService, IContextService } from '@univerjs/core';
|
|
6
|
+
|
|
21
7
|
export interface IShortcutItem<P extends object = object> {
|
|
22
8
|
/** This should reuse the corresponding command's id. */
|
|
23
9
|
id: string;
|
|
@@ -49,7 +35,7 @@ export interface IShortcutService {
|
|
|
49
35
|
getAllShortcuts(): IShortcutItem[];
|
|
50
36
|
setDisable(disable: boolean): void;
|
|
51
37
|
}
|
|
52
|
-
export declare const IShortcutService: import(
|
|
38
|
+
export declare const IShortcutService: import('@wendellhu/redi').IdentifierDecorator<IShortcutService>;
|
|
53
39
|
export declare class DesktopShortcutService extends Disposable implements IShortcutService {
|
|
54
40
|
private readonly _commandService;
|
|
55
41
|
private readonly _platformService;
|
|
@@ -1,22 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
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 { IDisposable } from '@wendellhu/redi';
|
|
1
|
+
import { ISidebarService } from './sidebar.service';
|
|
2
|
+
import { ISidebarMethodOptions } from '../../views/components/sidebar/interface';
|
|
17
3
|
import { Subject } from 'rxjs';
|
|
18
|
-
import
|
|
19
|
-
|
|
4
|
+
import { IDisposable } from '@wendellhu/redi';
|
|
5
|
+
|
|
20
6
|
export declare class DesktopSidebarService implements ISidebarService {
|
|
21
7
|
private _sidebarOptions;
|
|
22
8
|
readonly sidebarOptions$: Subject<ISidebarMethodOptions>;
|
|
@@ -1,22 +1,8 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
5
|
-
|
|
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 { IDisposable } from '@wendellhu/redi';
|
|
17
|
-
import type { Subject } from 'rxjs';
|
|
18
|
-
import type { ISidebarMethodOptions } from '../../views/components/sidebar/interface';
|
|
19
|
-
export declare const ISidebarService: import("@wendellhu/redi").IdentifierDecorator<ISidebarService>;
|
|
1
|
+
import { ISidebarMethodOptions } from '../../views/components/sidebar/interface';
|
|
2
|
+
import { Subject } from 'rxjs';
|
|
3
|
+
import { IDisposable } from '@wendellhu/redi';
|
|
4
|
+
|
|
5
|
+
export declare const ISidebarService: import('@wendellhu/redi').IdentifierDecorator<ISidebarService>;
|
|
20
6
|
export interface ISidebarService {
|
|
21
7
|
readonly sidebarOptions$: Subject<ISidebarMethodOptions>;
|
|
22
8
|
open(params: ISidebarMethodOptions): IDisposable;
|
|
@@ -1,23 +1,9 @@
|
|
|
1
|
-
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
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 IDisposable } from '@wendellhu/redi';
|
|
17
|
-
import type { ForwardRefExoticComponent } from 'react';
|
|
18
|
-
import { Subject } from 'rxjs';
|
|
1
|
+
import { IZenZoneService } from './zen-zone.service';
|
|
19
2
|
import { ComponentManager } from '../../common/component-manager';
|
|
20
|
-
import
|
|
3
|
+
import { Subject } from 'rxjs';
|
|
4
|
+
import { ForwardRefExoticComponent } from 'react';
|
|
5
|
+
import { IDisposable } from '@wendellhu/redi';
|
|
6
|
+
|
|
21
7
|
export declare class DesktopZenZoneService implements IZenZoneService {
|
|
22
8
|
private readonly _componentManager;
|
|
23
9
|
readonly visible$: Subject<boolean>;
|
|
@@ -1,21 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
3
|
-
|
|
4
|
-
|
|
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 { IDisposable } from '@wendellhu/redi';
|
|
17
|
-
import type { Subject } from 'rxjs';
|
|
18
|
-
export declare const IZenZoneService: import("@wendellhu/redi").IdentifierDecorator<IZenZoneService>;
|
|
1
|
+
import { Subject } from 'rxjs';
|
|
2
|
+
import { IDisposable } from '@wendellhu/redi';
|
|
3
|
+
|
|
4
|
+
export declare const IZenZoneService: import('@wendellhu/redi').IdentifierDecorator<IZenZoneService>;
|
|
19
5
|
export interface IZenZoneService {
|
|
20
6
|
readonly visible$: Subject<boolean>;
|
|
21
7
|
readonly componentKey$: Subject<string>;
|
package/lib/types/ui-plugin.d.ts
CHANGED
|
@@ -1,21 +1,7 @@
|
|
|
1
|
-
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
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 { LocaleService, Plugin, PluginType } from '@univerjs/core';
|
|
1
|
+
import { IWorkbenchOptions } from './controllers/ui/ui.controller';
|
|
17
2
|
import { Injector } from '@wendellhu/redi';
|
|
18
|
-
import
|
|
3
|
+
import { LocaleService, Plugin, PluginType } from '@univerjs/core';
|
|
4
|
+
|
|
19
5
|
export interface IUniverUIConfig extends IWorkbenchOptions {
|
|
20
6
|
}
|
|
21
7
|
/**
|
|
@@ -1,19 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
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 { IDocumentData, IRange, IStyleData } from '@univerjs/core';
|
|
1
|
+
import { IDocumentData, IRange, IStyleData } from '@univerjs/core';
|
|
2
|
+
|
|
17
3
|
/**
|
|
18
4
|
* The entire list of DOM spans is parsed into a rich-text JSON style sheet
|
|
19
5
|
* @param $dom
|
package/lib/types/views/App.d.ts
CHANGED
|
@@ -1,27 +1,13 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
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 { ComponentType } from 'react';
|
|
17
|
-
import React from 'react';
|
|
18
|
-
import type { IWorkbenchOptions } from '../controllers/ui/ui.controller';
|
|
1
|
+
import { IWorkbenchOptions } from '../controllers/ui/ui.controller';
|
|
2
|
+
import { ComponentType, default as React } from 'react';
|
|
3
|
+
|
|
19
4
|
export interface IUniverAppProps extends IWorkbenchOptions {
|
|
20
5
|
mountContainer: HTMLElement;
|
|
21
6
|
headerComponents?: Set<() => ComponentType>;
|
|
22
7
|
contentComponents?: Set<() => ComponentType>;
|
|
23
8
|
footerComponents?: Set<() => ComponentType>;
|
|
24
9
|
headerMenuComponents?: Set<() => ComponentType>;
|
|
10
|
+
leftSidebarComponents?: Set<() => ComponentType>;
|
|
25
11
|
onRendered?: (container: HTMLElement) => void;
|
|
26
12
|
}
|
|
27
13
|
export declare function App(props: IUniverAppProps): React.JSX.Element;
|
|
@@ -1,20 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
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 { ComponentType } from 'react';
|
|
17
|
-
import React from 'react';
|
|
1
|
+
import { ComponentType, default as React } from 'react';
|
|
2
|
+
|
|
18
3
|
export declare function ComponentContainer(props: {
|
|
19
4
|
components?: Set<() => ComponentType>;
|
|
20
5
|
}): React.ReactElement<{}, string | React.JSXElementConstructor<any>>[] | null;
|
|
@@ -1,17 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
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 React from 'react';
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
17
3
|
export declare function ConfirmPart(): React.JSX.Element[];
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
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 { IConfirmProps } from '@univerjs/design';
|
|
17
|
-
import type { ICustomLabelProps } from '../../../components/custom-label/CustomLabel';
|
|
1
|
+
import { ICustomLabelProps } from '../../../components/custom-label/CustomLabel';
|
|
2
|
+
import { IConfirmProps } from '@univerjs/design';
|
|
3
|
+
|
|
18
4
|
export type IConfirmPartMethodOptions = {
|
|
19
5
|
id: string;
|
|
20
6
|
children?: ICustomLabelProps;
|
|
@@ -1,19 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
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 React from 'react';
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
17
3
|
export interface IProps {
|
|
18
4
|
}
|
|
19
5
|
export declare function ContextMenu(): React.JSX.Element;
|
|
@@ -1,17 +1,3 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
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 React from 'react';
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
17
3
|
export declare function DialogPart(): React.JSX.Element;
|
|
@@ -1,20 +1,6 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
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 { IDialogProps } from '@univerjs/design';
|
|
17
|
-
import type { ICustomLabelProps } from '../../../components/custom-label/CustomLabel';
|
|
1
|
+
import { ICustomLabelProps } from '../../../components/custom-label/CustomLabel';
|
|
2
|
+
import { IDialogProps } from '@univerjs/design';
|
|
3
|
+
|
|
18
4
|
export type IDialogPartMethodOptions = {
|
|
19
5
|
id: string;
|
|
20
6
|
children?: ICustomLabelProps;
|
|
@@ -1,19 +1,5 @@
|
|
|
1
|
-
|
|
2
|
-
|
|
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 React from 'react';
|
|
1
|
+
import { default as React } from 'react';
|
|
2
|
+
|
|
17
3
|
export interface IBaseToolbarButtonProps {
|
|
18
4
|
children?: React.ReactNode;
|
|
19
5
|
/** Semantic DOM class */
|
|
@@ -1,21 +1,6 @@
|
|
|
1
|
-
/**
|
|
2
|
-
* Copyright 2023-present DreamNum Inc.
|
|
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 { ComponentType } from 'react';
|
|
17
|
-
import React from 'react';
|
|
18
1
|
import { MenuPosition } from '../../../services/menu/menu';
|
|
2
|
+
import { ComponentType, default as React } from 'react';
|
|
3
|
+
|
|
19
4
|
export declare const positions: MenuPosition[];
|
|
20
5
|
export interface IToolbarProps {
|
|
21
6
|
headerMenuComponents?: Set<() => ComponentType>;
|