canvas-editor-engine 2.1.25 → 2.1.27

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.
Files changed (2) hide show
  1. package/dist/index.mjs +9 -11
  2. package/package.json +1 -1
package/dist/index.mjs CHANGED
@@ -194,6 +194,7 @@ var CanvasComponent = function(_super) {
194
194
  CanvasComponent.prototype.getComponent = function() {
195
195
  var canvasTemplate = this.getTemplate(this.template);
196
196
  var canvasStyle = this.getStyle(this.css);
197
+ canvasTemplate.style.display = "flex";
197
198
  this.canvas = canvasTemplate.getElementsByTagName("canvas")[0];
198
199
  this.canvas.width = this.appConfig.CANVAS_SIZE.width;
199
200
  this.canvas.height = this.appConfig.CANVAS_SIZE.height;
@@ -1941,22 +1942,19 @@ var DrawService = function() {
1941
1942
  if (!this.imageProcessor) {
1942
1943
  throw new Error("No valid ImageProcessor instance found");
1943
1944
  }
1944
- this.imageProcessor.vague(filterArgs, filterOptions).then(this.updateImageStateAfterVague).finally((function() {
1945
+ this.imageProcessor.vague(filterArgs, filterOptions).then((function(data) {
1946
+ return _this.updateImageStateAfterVague(data);
1947
+ })).finally((function() {
1945
1948
  return _this.eventService.dispatch("loading-end");
1946
1949
  }));
1947
1950
  };
1948
1951
  DrawService.prototype.updateImageStateAfterVague = function(data) {
1949
- var _this = this;
1950
1952
  var imageData = data.imageData, position = data.position, size = data.size, quality = data.quality;
1951
- console.log("this", this);
1952
- var reduce = function(quality) {
1953
- _this.appStoreRepository.store.imageState.reduce({
1954
- tempImageData: imageData,
1955
- position,
1956
- size
1957
- }, "[Filter Vague] quality: ".concat(quality));
1958
- };
1959
- reduce(quality);
1953
+ this.appStoreRepository.store.imageState.reduce({
1954
+ tempImageData: imageData,
1955
+ position,
1956
+ size
1957
+ }, "[Filter Vague] quality: ".concat(quality));
1960
1958
  };
1961
1959
  DrawService.prototype.getFilterArgs = function(useStore, options) {
1962
1960
  var _a, _b;
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "canvas-editor-engine",
3
- "version": "2.1.25",
3
+ "version": "2.1.27",
4
4
  "description": "CanvasEditorEngine library, use: [typescript] [canvas]",
5
5
  "main": "dist/index.mjs",
6
6
  "types": "dist/index.d.ts",