@leapfrog/interactive-canvas 2.0.24-beta-2 → 2.0.24-beta-3
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.
|
@@ -3061,7 +3061,7 @@ class AbstractInteractiveCanvas {
|
|
|
3061
3061
|
src: imageUrl,
|
|
3062
3062
|
crossOrigin: "anonymous",
|
|
3063
3063
|
toObject: function () {
|
|
3064
|
-
return Object.assign(Object.assign({}, fabric.Object.prototype.toObject.call(this)), { src: this.src, crossOrigin: this.crossOrigin });
|
|
3064
|
+
return Object.assign(Object.assign({}, fabric.Object.prototype.toObject.call(this)), { src: this.src, crossOrigin: this.crossOrigin, id: id });
|
|
3065
3065
|
},
|
|
3066
3066
|
});
|
|
3067
3067
|
// Set image properties and add to the canvas
|
|
@@ -3079,7 +3079,7 @@ class AbstractInteractiveCanvas {
|
|
|
3079
3079
|
this.fabricCanvas.add(fabricImage);
|
|
3080
3080
|
const canvasObjectData = new CanvasObjectData(ObjectType.IMAGE, id);
|
|
3081
3081
|
canvasObjectData.imagePath = imageUrl;
|
|
3082
|
-
const object = new Image(this, fabricImage);
|
|
3082
|
+
const object = new Image(this, fabricImage, canvasObjectData);
|
|
3083
3083
|
this.trackNewObject(object);
|
|
3084
3084
|
this.syncObjectList();
|
|
3085
3085
|
return object;
|
|
@@ -3082,7 +3082,7 @@ class AbstractInteractiveCanvas {
|
|
|
3082
3082
|
src: imageUrl,
|
|
3083
3083
|
crossOrigin: "anonymous",
|
|
3084
3084
|
toObject: function () {
|
|
3085
|
-
return Object.assign(Object.assign({}, fabric__namespace.Object.prototype.toObject.call(this)), { src: this.src, crossOrigin: this.crossOrigin });
|
|
3085
|
+
return Object.assign(Object.assign({}, fabric__namespace.Object.prototype.toObject.call(this)), { src: this.src, crossOrigin: this.crossOrigin, id: id });
|
|
3086
3086
|
},
|
|
3087
3087
|
});
|
|
3088
3088
|
// Set image properties and add to the canvas
|
|
@@ -3100,7 +3100,7 @@ class AbstractInteractiveCanvas {
|
|
|
3100
3100
|
this.fabricCanvas.add(fabricImage);
|
|
3101
3101
|
const canvasObjectData = new CanvasObjectData(exports.ObjectType.IMAGE, id);
|
|
3102
3102
|
canvasObjectData.imagePath = imageUrl;
|
|
3103
|
-
const object = new Image(this, fabricImage);
|
|
3103
|
+
const object = new Image(this, fabricImage, canvasObjectData);
|
|
3104
3104
|
this.trackNewObject(object);
|
|
3105
3105
|
this.syncObjectList();
|
|
3106
3106
|
return object;
|