@inweb/markup 26.12.6 → 26.12.7

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@inweb/markup",
3
- "version": "26.12.6",
3
+ "version": "26.12.7",
4
4
  "description": "JavaScript 2D markups",
5
5
  "homepage": "https://cloud.opendesign.com/docs/index.html",
6
6
  "license": "SEE LICENSE IN LICENSE",
@@ -26,8 +26,8 @@
26
26
  "docs": "typedoc"
27
27
  },
28
28
  "dependencies": {
29
- "@inweb/eventemitter2": "~26.12.6",
30
- "@inweb/viewer-core": "~26.12.6"
29
+ "@inweb/eventemitter2": "~26.12.7",
30
+ "@inweb/viewer-core": "~26.12.7"
31
31
  },
32
32
  "devDependencies": {
33
33
  "konva": "^10.0.2"
@@ -313,7 +313,7 @@ export class KonvaMarkup implements IMarkup {
313
313
  }
314
314
 
315
315
  getViewpoint(viewpoint: IViewpoint): IViewpoint {
316
- if (!viewpoint) viewpoint = {};
316
+ if (!viewpoint) viewpoint = { custom_fields: {} };
317
317
 
318
318
  viewpoint.lines = this.getMarkupLines();
319
319
  viewpoint.texts = this.getMarkupTexts();
@@ -323,8 +323,8 @@ export class KonvaMarkup implements IMarkup {
323
323
  viewpoint.images = this.getMarkupImages();
324
324
  viewpoint.rectangles = this.getMarkupRectangles();
325
325
 
326
- viewpoint.custom_fields = { markup_color: this.getMarkupColor() };
327
326
  viewpoint.snapshot = { data: this.combineMarkupWithDrawing() };
327
+ viewpoint.custom_fields.markup_color = this.getMarkupColor();
328
328
 
329
329
  return viewpoint;
330
330
  }