@univerjs/docs-drawing-ui 0.2.12 → 0.2.13
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 +1 -1
- package/lib/es/index.js +457 -492
- package/lib/index.css +1 -1
- package/lib/types/commands/commands/insert-image.command.d.ts +5 -0
- package/lib/types/controllers/doc-drawing-transformer-update.controller.d.ts +2 -3
- package/lib/types/controllers/doc-drawing.controller.d.ts +2 -3
- package/lib/types/controllers/render-controllers/doc-drawing-transform-update.controller.d.ts +2 -2
- package/lib/types/controllers/render-controllers/doc-drawing-update.render-controller.d.ts +11 -14
- package/lib/types/index.d.ts +1 -2
- package/lib/types/plugin.d.ts +1 -1
- package/lib/types/views/doc-image-panel/DocDrawingPosition.d.ts +1 -1
- package/lib/types/views/menu/image.menu.d.ts +1 -1
- package/lib/umd/index.js +1 -1
- package/package.json +24 -25
- package/lib/types/commands/operations/insert-image.operation.d.ts +0 -8
- package/lib/types/views/upload-component/UploadFile.d.ts +0 -2
- package/lib/types/views/upload-component/component-name.d.ts +0 -16
package/lib/index.css
CHANGED
|
@@ -1 +1 @@
|
|
|
1
|
-
.univer-
|
|
1
|
+
.univer-image-common-panel{text-align:center;padding:var(--padding-sm);font-size:var(--font-size-sm)}.univer-image-common-panel-grid{position:relative;width:100%}.univer-image-common-panel-border{border-top:1px solid rgb(var(--border-color));margin-top:20px}.univer-image-common-panel-title{color:rgb(var(--text-color-secondary));text-align:left}.univer-image-common-panel-subtitle{color:rgb(var(--text-color-primary));text-align:left}.univer-image-common-panel-row{position:relative;display:flex;justify-content:flex-start;align-items:flex-start;height:100%;margin-top:10px}.univer-image-common-panel-row-vertical{justify-content:center;align-items:center;height:36px}.univer-image-common-panel-column{width:100%}.univer-image-common-panel-column-center{display:flex;justify-content:center;align-items:center}.univer-image-common-panel-inline{display:flex;align-items:center;gap:var(--margin-xxs)}.univer-image-common-panel-span2{width:50%}.univer-image-common-panel-span3{width:33.33333333%}.univer-image-common-panel-input{width:90%}.univer-sheet-image-menu{position:absolute;height:100%;width:100%;text-align:center}.univer-sheet-image-menu-input{display:none}
|
|
@@ -1,17 +1,16 @@
|
|
|
1
1
|
import { Disposable, ICommandService, IUniverInstanceService } from '@univerjs/core';
|
|
2
2
|
import { IDrawingManagerService } from '@univerjs/drawing';
|
|
3
|
-
import { IRenderManagerService
|
|
3
|
+
import { IRenderManagerService } from '@univerjs/engine-render';
|
|
4
4
|
export declare class DocDrawingTransformerController extends Disposable {
|
|
5
5
|
private readonly _commandService;
|
|
6
6
|
private readonly _univerInstanceService;
|
|
7
7
|
private readonly _drawingManagerService;
|
|
8
8
|
private readonly _renderManagerService;
|
|
9
|
-
private readonly _textSelectionRenderManager;
|
|
10
9
|
private _liquid;
|
|
11
10
|
private _listenerOnImageMap;
|
|
12
11
|
private _transformerCache;
|
|
13
12
|
private _anchorShape;
|
|
14
|
-
constructor(_commandService: ICommandService, _univerInstanceService: IUniverInstanceService, _drawingManagerService: IDrawingManagerService, _renderManagerService: IRenderManagerService
|
|
13
|
+
constructor(_commandService: ICommandService, _univerInstanceService: IUniverInstanceService, _drawingManagerService: IDrawingManagerService, _renderManagerService: IRenderManagerService);
|
|
15
14
|
private _init;
|
|
16
15
|
private _listenDrawingFocus;
|
|
17
16
|
private _listenTransformerChange;
|
|
@@ -1,12 +1,11 @@
|
|
|
1
|
-
import { Disposable, ICommandService
|
|
1
|
+
import { Disposable, ICommandService } from '@univerjs/core';
|
|
2
2
|
import { ComponentManager, IMenuManagerService, IShortcutService } from '@univerjs/ui';
|
|
3
3
|
export declare class DocDrawingUIController extends Disposable {
|
|
4
|
-
private readonly _injector;
|
|
5
4
|
private readonly _componentManager;
|
|
6
5
|
private readonly _menuManagerService;
|
|
7
6
|
private readonly _commandService;
|
|
8
7
|
private readonly _shortcutService;
|
|
9
|
-
constructor(
|
|
8
|
+
constructor(_componentManager: ComponentManager, _menuManagerService: IMenuManagerService, _commandService: ICommandService, _shortcutService: IShortcutService);
|
|
10
9
|
private _initCustomComponents;
|
|
11
10
|
private _initMenus;
|
|
12
11
|
private _initCommands;
|
package/lib/types/controllers/render-controllers/doc-drawing-transform-update.controller.d.ts
CHANGED
|
@@ -1,8 +1,8 @@
|
|
|
1
|
-
import {
|
|
1
|
+
import { Disposable, ICommandService, IUniverInstanceService, LifecycleService, DocumentDataModel } from '@univerjs/core';
|
|
2
2
|
import { DocSkeletonManagerService } from '@univerjs/docs';
|
|
3
3
|
import { IDrawingManagerService } from '@univerjs/drawing';
|
|
4
|
-
import { IRenderContext, IRenderModule } from '@univerjs/engine-render';
|
|
5
4
|
import { IEditorService } from '@univerjs/ui';
|
|
5
|
+
import { IRenderContext, IRenderModule } from '@univerjs/engine-render';
|
|
6
6
|
import { DocRefreshDrawingsService } from '../../services/doc-refresh-drawings.service';
|
|
7
7
|
export declare class DocDrawingTransformUpdateController extends Disposable implements IRenderModule {
|
|
8
8
|
private readonly _context;
|
|
@@ -1,14 +1,15 @@
|
|
|
1
|
-
import {
|
|
2
|
-
import {
|
|
3
|
-
import { IMessageService } from '@univerjs/ui';
|
|
1
|
+
import { Disposable, ICommandService, IContextService, LocaleService, DocumentDataModel } from '@univerjs/core';
|
|
2
|
+
import { DocSelectionManagerService } from '@univerjs/docs';
|
|
4
3
|
import { IDocDrawingService } from '@univerjs/docs-drawing';
|
|
5
|
-
import {
|
|
6
|
-
import {
|
|
4
|
+
import { DocSelectionRenderService } from '@univerjs/docs-ui';
|
|
5
|
+
import { IDrawingManagerService, IImageIoService } from '@univerjs/drawing';
|
|
6
|
+
import { IRenderManagerService, IRenderContext, IRenderModule } from '@univerjs/engine-render';
|
|
7
|
+
import { ILocalFileService, IMessageService } from '@univerjs/ui';
|
|
7
8
|
import { DocRefreshDrawingsService } from '../../services/doc-refresh-drawings.service';
|
|
8
9
|
export declare class DocDrawingUpdateRenderController extends Disposable implements IRenderModule {
|
|
9
10
|
private readonly _context;
|
|
10
11
|
private readonly _commandService;
|
|
11
|
-
private readonly
|
|
12
|
+
private readonly _docSelectionManagerService;
|
|
12
13
|
private readonly _renderManagerSrv;
|
|
13
14
|
private readonly _imageIoService;
|
|
14
15
|
private readonly _docDrawingService;
|
|
@@ -16,19 +17,15 @@ export declare class DocDrawingUpdateRenderController extends Disposable impleme
|
|
|
16
17
|
private readonly _contextService;
|
|
17
18
|
private readonly _messageService;
|
|
18
19
|
private readonly _localeService;
|
|
19
|
-
private readonly
|
|
20
|
-
private readonly _textSelectionRenderManager;
|
|
20
|
+
private readonly _docSelectionRenderService;
|
|
21
21
|
private readonly _docRefreshDrawingsService;
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
*/
|
|
26
|
-
private _initCommandListeners;
|
|
22
|
+
private readonly _fileOpenerService;
|
|
23
|
+
constructor(_context: IRenderContext<DocumentDataModel>, _commandService: ICommandService, _docSelectionManagerService: DocSelectionManagerService, _renderManagerSrv: IRenderManagerService, _imageIoService: IImageIoService, _docDrawingService: IDocDrawingService, _drawingManagerService: IDrawingManagerService, _contextService: IContextService, _messageService: IMessageService, _localeService: LocaleService, _docSelectionRenderService: DocSelectionRenderService, _docRefreshDrawingsService: DocRefreshDrawingsService, _fileOpenerService: ILocalFileService);
|
|
24
|
+
insertDocImage(): Promise<boolean>;
|
|
27
25
|
private _insertFloatImages;
|
|
28
26
|
private _isInsertInHeaderFooter;
|
|
29
27
|
private _getImagePosition;
|
|
30
28
|
private _updateOrderListener;
|
|
31
|
-
private _updateDrawingListener;
|
|
32
29
|
private _groupDrawingListener;
|
|
33
30
|
private _getCurrentSceneAndTransformer;
|
|
34
31
|
private _focusDrawingListener;
|
package/lib/types/index.d.ts
CHANGED
|
@@ -23,7 +23,6 @@ export { SetDocDrawingArrangeCommand } from './commands/commands/set-drawing-arr
|
|
|
23
23
|
export { UngroupDocDrawingCommand } from './commands/commands/ungroup-doc-drawing.command';
|
|
24
24
|
export { ClearDocDrawingTransformerOperation } from './commands/operations/clear-drawing-transformer.operation';
|
|
25
25
|
export { EditDocDrawingOperation } from './commands/operations/edit-doc-drawing.operation';
|
|
26
|
-
export {
|
|
26
|
+
export { InsertDocImageCommand } from './commands/commands/insert-image.command';
|
|
27
27
|
export { SidebarDocDrawingOperation } from './commands/operations/open-drawing-panel.operation';
|
|
28
28
|
export { IMAGE_MENU_ID } from './views/menu/image.menu';
|
|
29
|
-
export { COMPONENT_DOC_UPLOAD_FILE_MENU } from './views/upload-component/component-name';
|
package/lib/types/plugin.d.ts
CHANGED
|
@@ -8,7 +8,7 @@ export declare class UniverDocsDrawingUIPlugin extends Plugin {
|
|
|
8
8
|
private readonly _configService;
|
|
9
9
|
static type: UniverInstanceType;
|
|
10
10
|
static pluginName: string;
|
|
11
|
-
constructor(_config: Partial<IUniverDocsDrawingUIConfig
|
|
11
|
+
constructor(_config: Partial<IUniverDocsDrawingUIConfig> | undefined, _injector: Injector, _renderManagerSrv: IRenderManagerService, _configService: IConfigService);
|
|
12
12
|
onStarting(): void;
|
|
13
13
|
onReady(): void;
|
|
14
14
|
}
|
|
@@ -2,6 +2,6 @@ import { IMenuItem } from '@univerjs/ui';
|
|
|
2
2
|
import { IAccessor } from '@univerjs/core';
|
|
3
3
|
export declare const ImageUploadIcon = "addition-and-subtraction-single";
|
|
4
4
|
export declare const IMAGE_MENU_ID = "doc.menu.image";
|
|
5
|
-
export declare const IMAGE_MENU_UPLOAD_FLOAT_ID
|
|
5
|
+
export declare const IMAGE_MENU_UPLOAD_FLOAT_ID: string;
|
|
6
6
|
export declare function ImageMenuFactory(accessor: IAccessor): IMenuItem;
|
|
7
7
|
export declare function UploadFloatImageMenuFactory(_accessor: IAccessor): IMenuItem;
|