@leapfrog/interactive-canvas 2.0.18 → 2.0.20-beta-1
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/dist/ErrorOptions.interface.d.ts +3 -0
- package/dist/abstract-interactive-canvas.d.ts +26 -4
- package/dist/headless-interactive-canvas.d.ts +2 -2
- package/dist/interactive-canvas.d.ts +1 -1
- package/dist/interactive-canvas.es.js +1829 -1984
- package/dist/interactive-canvas.interface.d.ts +22 -2
- package/dist/interactive-canvas.js +1846 -1980
- package/dist/mutator/mutable-text.interface.d.ts +6 -0
- package/dist/object/abstract-canvas-object.d.ts +2 -2
- package/dist/object/impl/background-image.d.ts +3 -3
- package/dist/object/impl/border.d.ts +3 -3
- package/dist/object/impl/cutoff.d.ts +1 -1
- package/dist/object/impl/extended-fabric-object.interface.d.ts +2 -2
- package/dist/object/impl/extended-fabric-textbox.interface.d.ts +3 -2
- package/dist/object/impl/horizontal-rule.d.ts +1 -1
- package/dist/object/impl/image.d.ts +3 -3
- package/dist/object/impl/rectangle.d.ts +3 -3
- package/dist/object/impl/rich-text.d.ts +2 -2
- package/dist/object/impl/text.d.ts +12 -2
- package/dist/object/impl/vertical-rule.d.ts +1 -1
- package/dist/types/selection-data.interface.d.ts +9 -0
- package/dist/types/text-alignment.interface.d.ts +1 -1
- package/dist/undo-stack.d.ts +1 -1
- package/package.json +14 -11
|
@@ -18,9 +18,9 @@ import { ISelectionData } from "./types/selection-data.interface";
|
|
|
18
18
|
import { ICanvasState } from "./types/canvas-state.interface";
|
|
19
19
|
import { AbstractCanvasObject } from "./object/abstract-canvas-object";
|
|
20
20
|
import { ObjectType } from "./types/object-type.enum";
|
|
21
|
-
import { fabric } from "fabric";
|
|
22
21
|
import { IRichText } from "./object/impl/rich-text";
|
|
23
22
|
import { IBackgroundImage } from "./object/impl/background-image";
|
|
23
|
+
import { FabricObject } from "fabric";
|
|
24
24
|
/**
|
|
25
25
|
* New leapfrog canvas implementation c. 2019.
|
|
26
26
|
*/
|
|
@@ -183,6 +183,26 @@ export interface IInteractiveCanvas {
|
|
|
183
183
|
* @param imageUrl Url for image content.
|
|
184
184
|
*/
|
|
185
185
|
addBackgroundImageObject(imageUrl: string): Promise<IBackgroundImage>;
|
|
186
|
+
/**
|
|
187
|
+
* Bring object to front.
|
|
188
|
+
* @param object The object to move front.
|
|
189
|
+
*/
|
|
190
|
+
bringObjectToFront(object: FabricObject): void;
|
|
191
|
+
/**
|
|
192
|
+
* Bring object forward one place.
|
|
193
|
+
* @param object The object to move forward.
|
|
194
|
+
*/
|
|
195
|
+
bringObjectForward(object: FabricObject): void;
|
|
196
|
+
/**
|
|
197
|
+
* Send object backward one place.
|
|
198
|
+
* @param object The object to move backward.
|
|
199
|
+
*/
|
|
200
|
+
sendObjectBackwards(object: FabricObject): void;
|
|
201
|
+
/**
|
|
202
|
+
* Send object to the back.
|
|
203
|
+
* @param object The object to move back.
|
|
204
|
+
*/
|
|
205
|
+
sendObjectToBack(object: FabricObject): void;
|
|
186
206
|
/**
|
|
187
207
|
* Set the data used to prefill text into the canvas.
|
|
188
208
|
* @param data Prefill data.
|
|
@@ -277,7 +297,7 @@ export interface IInteractiveCanvas {
|
|
|
277
297
|
* Remove an underlying fabric object.
|
|
278
298
|
* @param obj The object.
|
|
279
299
|
*/
|
|
280
|
-
removeFabricObject(obj:
|
|
300
|
+
removeFabricObject(obj: FabricObject): void;
|
|
281
301
|
/**
|
|
282
302
|
* Create a PNG stream of the canvas. Only works on headless canvas.
|
|
283
303
|
*/
|