@aurigma/design-atoms-model
Version:
Design Atoms is a part of Customer's Canvas SDK which allows for manipulating individual design elements through your code.
66 lines • 2.6 kB
JavaScript
import { arrayEquals } from "../../Utils/Utils";
var ThemeBinding = /** @class */ (function () {
function ThemeBinding() {
this.styles = [];
this.clipartColors = [];
}
ThemeBinding.fromRaw = function (object) {
var result = new ThemeBinding();
result.text = object.text;
result.stroke = object.stroke;
result.shadow = object.shadow;
result.img = object.img;
result.border = object.border;
result.fill = object.fill;
result.textFill = object.textFill;
result.line = object.line;
result.altline = object.altline;
result.horizontal = object.horizontal;
result.vertical = object.vertical;
result.barcode = object.barcode;
result.styles = object.styles != null ? object.styles.slice(0) : null;
result.clipartColors = object.clipartColors != null ? object.clipartColors.slice(0) : null;
return result;
};
ThemeBinding.prototype.clone = function () {
var clone = new ThemeBinding();
clone.text = this.text;
clone.stroke = this.stroke;
clone.shadow = this.shadow;
clone.img = this.img;
clone.border = this.border;
clone.fill = this.fill;
clone.textFill = this.textFill;
clone.line = this.line;
clone.altline = this.altline;
clone.horizontal = this.horizontal;
clone.vertical = this.vertical;
clone.barcode = this.barcode;
clone.styles = this.styles != null
? this.styles.slice(0)
: null;
clone.clipartColors = this.clipartColors != null
? this.clipartColors.slice(0)
: null;
return clone;
};
ThemeBinding.prototype.equals = function (other) {
return this.text === other.text &&
this.stroke === other.stroke &&
this.shadow === other.shadow &&
this.img === other.img &&
this.border === other.border &&
this.fill === other.fill &&
this.textFill === other.textFill &&
this.line === other.line &&
this.altline === other.altline &&
this.horizontal === other.horizontal &&
this.vertical === other.vertical &&
this.barcode === other.barcode &&
arrayEquals(this.styles, other.styles) &&
arrayEquals(this.clipartColors, other.clipartColors);
};
return ThemeBinding;
}());
export { ThemeBinding };
//# sourceMappingURL=ThemeBinding.js.map