@syncfusion/ej2-image-editor 23.1.38 → 23.1.39

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.
@@ -4292,7 +4292,11 @@ var Draw = /** @__PURE__ @class */ (function () {
4292
4292
  /* eslint-disable-next-line @typescript-eslint/no-explicit-any */
4293
4293
  filesData = fileData = args.filesData[0].rawFile;
4294
4294
  }
4295
- var fileExtension = fileData.name && fileData.name.split('.')[1].toLowerCase();
4295
+ var fileExtension = void 0;
4296
+ if (fileData.name) {
4297
+ var fileExtensionArray = fileData.name.split('.');
4298
+ fileExtension = fileExtensionArray[fileExtensionArray.length - 1].toLowerCase();
4299
+ }
4296
4300
  if (fileExtension && ['jpg', 'jpeg', 'png', 'svg'].indexOf(fileExtension) === -1) {
4297
4301
  this.errorLoading();
4298
4302
  return;
@@ -6266,7 +6270,7 @@ var FreehandDrawing = /** @__PURE__ @class */ (function () {
6266
6270
  EventHandler.add(canvas, 'mousemove touchmove', this.freehandMoveHandler, this);
6267
6271
  var shapeSettings = { id: 'pen_' + (this.currFHDIdx + 1), type: ShapeType.FreehandDraw,
6268
6272
  startX: this.freehandDownPoint.x, startY: this.freehandDownPoint.y,
6269
- strokeColor: this.parent.activeObj.strokeSettings.strokeColor, strokeWidth: this.parent.activeObj.strokeSettings.strokeWidth,
6273
+ strokeColor: this.parent.activeObj.strokeSettings.strokeColor, strokeWidth: this.penStrokeWidth,
6270
6274
  points: null };
6271
6275
  var shapeChangingArgs = { action: 'draw-start', previousShapeSettings: shapeSettings,
6272
6276
  currentShapeSettings: shapeSettings };
@@ -6323,7 +6327,7 @@ var FreehandDrawing = /** @__PURE__ @class */ (function () {
6323
6327
  currentText: null, previousFilter: null, isCircleCrop: null } });
6324
6328
  var shapeSettings = { id: 'pen_' + (this.currFHDIdx + 1), type: ShapeType.FreehandDraw,
6325
6329
  startX: this.freehandDownPoint.x, startY: this.freehandDownPoint.y,
6326
- strokeColor: this.parent.activeObj.strokeSettings.strokeColor, strokeWidth: this.parent.activeObj.strokeSettings.strokeWidth,
6330
+ strokeColor: this.parent.activeObj.strokeSettings.strokeColor, strokeWidth: this.penStrokeWidth,
6327
6331
  points: this.parent.pointColl[this.currFHDIdx].points };
6328
6332
  var shapeChangingArgs = { action: 'draw-end', previousShapeSettings: shapeSettings,
6329
6333
  currentShapeSettings: shapeSettings };
@@ -6344,6 +6348,7 @@ var FreehandDrawing = /** @__PURE__ @class */ (function () {
6344
6348
  y = e.touches[0].clientY - rect.top;
6345
6349
  }
6346
6350
  if (this.isFreehandDrawing) {
6351
+ this.upperContext.fillStyle = this.parent.activeObj.strokeSettings.strokeColor;
6347
6352
  this.processPoint(x, y, false, this.upperContext);
6348
6353
  }
6349
6354
  };
@@ -7081,7 +7086,7 @@ var FreehandDrawing = /** @__PURE__ @class */ (function () {
7081
7086
  /* eslint-disable-next-line @typescript-eslint/no-explicit-any */
7082
7087
  parent.dotNetRef.invokeMethodAsync('ShapeEventAsync', 'OnShape', shapeChangingArgs).then(function (shapeChangingArgs) {
7083
7088
  parent.activeObj.strokeSettings.strokeColor = shapeChangingArgs.currentShapeSettings.strokeColor;
7084
- parent.activeObj.strokeSettings.strokeWidth = shapeChangingArgs.currentShapeSettings.strokeWidth;
7089
+ _this.penStrokeWidth = shapeChangingArgs.currentShapeSettings.strokeWidth;
7085
7090
  if (_this.fhdSelID) {
7086
7091
  parent.pointColl[_this.fhdSelIdx].strokeColor = shapeChangingArgs.currentShapeSettings.strokeColor;
7087
7092
  parent.pointColl[_this.fhdSelIdx].strokeWidth = shapeChangingArgs.currentShapeSettings.strokeWidth;
@@ -7097,7 +7102,7 @@ var FreehandDrawing = /** @__PURE__ @class */ (function () {
7097
7102
  else {
7098
7103
  parent.trigger('shapeChanging', shapeChangingArgs);
7099
7104
  parent.activeObj.strokeSettings.strokeColor = shapeChangingArgs.currentShapeSettings.strokeColor;
7100
- parent.activeObj.strokeSettings.strokeWidth = shapeChangingArgs.currentShapeSettings.strokeWidth;
7105
+ this.penStrokeWidth = shapeChangingArgs.currentShapeSettings.strokeWidth;
7101
7106
  if (this.fhdSelID) {
7102
7107
  parent.pointColl[this.fhdSelIdx].strokeColor = shapeChangingArgs.currentShapeSettings.strokeColor;
7103
7108
  parent.pointColl[this.fhdSelIdx].strokeWidth = shapeChangingArgs.currentShapeSettings.strokeWidth;
@@ -21196,6 +21201,33 @@ var ImageEditorCommand;
21196
21201
  ImageEditorCommand["RotateRight"] = "RotateRight";
21197
21202
  ImageEditorCommand["FlipHorizontal"] = "FlipHorizontal";
21198
21203
  ImageEditorCommand["FlipVertical"] = "FlipVertical";
21204
+ ImageEditorCommand["Undo"] = "Undo";
21205
+ ImageEditorCommand["Redo"] = "Redo";
21206
+ ImageEditorCommand["None"] = "None";
21207
+ ImageEditorCommand["Mat"] = "Mat";
21208
+ ImageEditorCommand["Bevel"] = "Bevel";
21209
+ ImageEditorCommand["Inset"] = "Inset";
21210
+ ImageEditorCommand["Hook"] = "Hook";
21211
+ ImageEditorCommand["Finetune"] = "Finetune";
21212
+ ImageEditorCommand["Filter"] = "Filter";
21213
+ ImageEditorCommand["Frame"] = "Frame";
21214
+ ImageEditorCommand["Resize"] = "Resize";
21215
+ ImageEditorCommand["HorizontalFlip"] = "HorizontalFlip";
21216
+ ImageEditorCommand["VerticalFlip"] = "VerticalFlip";
21217
+ ImageEditorCommand["Brightness"] = "Brightness";
21218
+ ImageEditorCommand["Contrast"] = "Contrast";
21219
+ ImageEditorCommand["Hue"] = "Hue";
21220
+ ImageEditorCommand["Saturation"] = "Saturation";
21221
+ ImageEditorCommand["Opacity"] = "Opacity";
21222
+ ImageEditorCommand["Blur"] = "Blur";
21223
+ ImageEditorCommand["Exposure"] = "Exposure";
21224
+ ImageEditorCommand["Default"] = "Default";
21225
+ ImageEditorCommand["Chrome"] = "Chrome";
21226
+ ImageEditorCommand["Cold"] = "Cold";
21227
+ ImageEditorCommand["Warm"] = "Warm";
21228
+ ImageEditorCommand["Grayscale"] = "Grayscale";
21229
+ ImageEditorCommand["Sepia"] = "Sepia";
21230
+ ImageEditorCommand["Invert"] = "Invert";
21199
21231
  })(ImageEditorCommand || (ImageEditorCommand = {}));
21200
21232
  /**
21201
21233
  * An enumeration of available image filter options.