@hufe921/canvas-editor 0.9.87 → 0.9.88
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/CHANGELOG.md +22 -0
- package/dist/canvas-editor.es.js +96 -56
- package/dist/canvas-editor.es.js.map +1 -1
- package/dist/canvas-editor.umd.js +39 -39
- package/dist/canvas-editor.umd.js.map +1 -1
- package/dist/src/editor/core/command/CommandAdapt.d.ts +2 -2
- package/dist/src/editor/core/draw/Draw.d.ts +3 -2
- package/dist/src/editor/interface/Background.d.ts +1 -0
- package/dist/src/editor/interface/Editor.d.ts +3 -0
- package/dist/src/editor/interface/Title.d.ts +1 -0
- package/package.json +1 -1
|
@@ -9,7 +9,7 @@ import { ICatalog } from '../../interface/Catalog';
|
|
|
9
9
|
import { DeepRequired } from '../../interface/Common';
|
|
10
10
|
import { IGetControlValueOption, IGetControlValueResult, ISetControlExtensionOption, ISetControlHighlightOption, ISetControlProperties, ISetControlValueOption } from '../../interface/Control';
|
|
11
11
|
import { IAppendElementListOption, IDrawImagePayload, IForceUpdateOption, IGetImageOption, IGetValueOption, IPainterOption } from '../../interface/Draw';
|
|
12
|
-
import { IEditorData, IEditorHTML, IEditorOption, IEditorResult, IEditorText, IUpdateOption } from '../../interface/Editor';
|
|
12
|
+
import { IEditorData, IEditorHTML, IEditorOption, IEditorResult, IEditorText, ISetValueOption, IUpdateOption } from '../../interface/Editor';
|
|
13
13
|
import { IElement, IUpdateElementByIdOption } from '../../interface/Element';
|
|
14
14
|
import { IPasteOption, IPositionContextByEvent } from '../../interface/Event';
|
|
15
15
|
import { IMargin } from '../../interface/Margin';
|
|
@@ -123,7 +123,7 @@ export declare class CommandAdapt {
|
|
|
123
123
|
insertElementList(payload: IElement[]): void;
|
|
124
124
|
appendElementList(elementList: IElement[], options?: IAppendElementListOption): void;
|
|
125
125
|
updateElementById(payload: IUpdateElementByIdOption): void;
|
|
126
|
-
setValue(payload: Partial<IEditorData
|
|
126
|
+
setValue(payload: Partial<IEditorData>, options?: ISetValueOption): void;
|
|
127
127
|
removeControl(): void;
|
|
128
128
|
setLocale(payload: string): void;
|
|
129
129
|
getLocale(): string;
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import { IAppendElementListOption, IComputeRowListPayload, IDrawOption, IDrawRowPayload, IGetImageOption, IGetValueOption, IPainterOption } from '../../interface/Draw';
|
|
2
|
-
import { IEditorData, IEditorOption, IEditorResult } from '../../interface/Editor';
|
|
2
|
+
import { IEditorData, IEditorOption, IEditorResult, ISetValueOption } from '../../interface/Editor';
|
|
3
3
|
import { IElement, IElementStyle } from '../../interface/Element';
|
|
4
4
|
import { IRow } from '../../interface/Row';
|
|
5
5
|
import { Cursor } from '../cursor/Cursor';
|
|
@@ -104,6 +104,7 @@ export declare class Draw {
|
|
|
104
104
|
getMode(): EditorMode;
|
|
105
105
|
setMode(payload: EditorMode): void;
|
|
106
106
|
isReadonly(): boolean;
|
|
107
|
+
isDisabled(): boolean;
|
|
107
108
|
getOriginalWidth(): number;
|
|
108
109
|
getOriginalHeight(): number;
|
|
109
110
|
getWidth(): number;
|
|
@@ -193,7 +194,7 @@ export declare class Draw {
|
|
|
193
194
|
setPaperDirection(payload: PaperDirection): void;
|
|
194
195
|
setPaperMargin(payload: IMargin): void;
|
|
195
196
|
getValue(options?: IGetValueOption): IEditorResult;
|
|
196
|
-
setValue(payload: Partial<IEditorData
|
|
197
|
+
setValue(payload: Partial<IEditorData>, options?: ISetValueOption): void;
|
|
197
198
|
setEditorData(payload: Partial<IEditorData>): void;
|
|
198
199
|
private _wrapContainer;
|
|
199
200
|
private _formatContainer;
|
|
@@ -94,3 +94,6 @@ export interface IEditorHTML {
|
|
|
94
94
|
}
|
|
95
95
|
export type IEditorText = IEditorHTML;
|
|
96
96
|
export type IUpdateOption = Omit<IEditorOption, 'mode' | 'width' | 'height' | 'scale' | 'pageGap' | 'pageMode' | 'paperDirection' | 'historyMaxRecordCount' | 'scrollContainerSelector'>;
|
|
97
|
+
export interface ISetValueOption {
|
|
98
|
+
isSetCursor?: boolean;
|
|
99
|
+
}
|