@leapfrog/interactive-canvas 2.0.4 → 2.0.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.
|
@@ -3,7 +3,7 @@ export declare class InteractiveCanvas extends AbstractInteractiveCanvas {
|
|
|
3
3
|
protected devicePixelRatio: number;
|
|
4
4
|
readonly headless: boolean;
|
|
5
5
|
private readonly undoStack;
|
|
6
|
-
constructor(
|
|
6
|
+
constructor(canvas: HTMLCanvasElement | string, devicePixelRatio: number);
|
|
7
7
|
/**
|
|
8
8
|
* @override
|
|
9
9
|
* @inheritDoc
|
|
@@ -3918,11 +3918,12 @@ var UndoStack = /** @class */ (function () {
|
|
|
3918
3918
|
|
|
3919
3919
|
var InteractiveCanvas = /** @class */ (function (_super) {
|
|
3920
3920
|
__extends(InteractiveCanvas, _super);
|
|
3921
|
-
function InteractiveCanvas(
|
|
3922
|
-
var _this = _super.call(this, window['fabric'], new window['fabric'].Canvas(
|
|
3921
|
+
function InteractiveCanvas(canvas, devicePixelRatio) {
|
|
3922
|
+
var _this = _super.call(this, window['fabric'], new window['fabric'].Canvas(canvas), devicePixelRatio) || this;
|
|
3923
3923
|
_this.devicePixelRatio = devicePixelRatio;
|
|
3924
3924
|
_this.headless = false;
|
|
3925
3925
|
_this.undoStack = new UndoStack(_this);
|
|
3926
|
+
console.log('**************** ic', canvas);
|
|
3926
3927
|
//Initialize watchers
|
|
3927
3928
|
_this.fabricCanvas.on("selection:updated", function () { return _this.onFabricSelectionChanged(); });
|
|
3928
3929
|
_this.fabricCanvas.on("selection:created", function () { return _this.onFabricSelectionChanged(); });
|
|
@@ -3918,11 +3918,12 @@ var UndoStack = /** @class */ (function () {
|
|
|
3918
3918
|
|
|
3919
3919
|
var InteractiveCanvas = /** @class */ (function (_super) {
|
|
3920
3920
|
__extends(InteractiveCanvas, _super);
|
|
3921
|
-
function InteractiveCanvas(
|
|
3922
|
-
var _this = _super.call(this, window['fabric'], new window['fabric'].Canvas(
|
|
3921
|
+
function InteractiveCanvas(canvas, devicePixelRatio) {
|
|
3922
|
+
var _this = _super.call(this, window['fabric'], new window['fabric'].Canvas(canvas), devicePixelRatio) || this;
|
|
3923
3923
|
_this.devicePixelRatio = devicePixelRatio;
|
|
3924
3924
|
_this.headless = false;
|
|
3925
3925
|
_this.undoStack = new UndoStack(_this);
|
|
3926
|
+
console.log('**************** ic', canvas);
|
|
3926
3927
|
//Initialize watchers
|
|
3927
3928
|
_this.fabricCanvas.on("selection:updated", function () { return _this.onFabricSelectionChanged(); });
|
|
3928
3929
|
_this.fabricCanvas.on("selection:created", function () { return _this.onFabricSelectionChanged(); });
|