UNPKG

@aurigma/design-atoms

Version:

Design Atoms is a part of Customer's Canvas SDK which allows for manipulating individual design elements through your code.

39 lines 1.66 kB
var __extends = (this && this.__extends) || (function () { var extendStatics = function (d, b) { extendStatics = Object.setPrototypeOf || ({ __proto__: [] } instanceof Array && function (d, b) { d.__proto__ = b; }) || function (d, b) { for (var p in b) if (b.hasOwnProperty(p)) d[p] = b[p]; }; return extendStatics(d, b); }; return function (d, b) { extendStatics(d, b); function __() { this.constructor = d; } d.prototype = b === null ? Object.create(b) : (__.prototype = b.prototype, new __()); }; })(); import { TextImageData } from "./BaseTextItemHandler"; import { ShapeHandlerData } from "./ShapeHandlerData"; var BaseTextHandlerData = /** @class */ (function (_super) { __extends(BaseTextHandlerData, _super); function BaseTextHandlerData(handler) { var _this = _super.call(this, handler) || this; _this.__type = "BaseTextHandlerData"; return _this; } BaseTextHandlerData.prototype.applyState = function (textData, handler) { if (handler) { handler.beginUpdate(); //call endUpdate in base class if (textData.currentTextImage != null) { handler.currentTextImage = Object.assign(new TextImageData(), textData.currentTextImage); } else { handler.currentTextImage = null; } } _super.prototype.applyState.call(this, textData, handler); }; ; return BaseTextHandlerData; }(ShapeHandlerData)); export { BaseTextHandlerData }; //# sourceMappingURL=BaseTextHandlerData.js.map