@aurigma/design-atoms
Version:
Design Atoms is a part of Customer's Canvas SDK which allows for manipulating individual design elements through your code.
29 lines • 874 B
JavaScript
var Section = /** @class */ (function () {
function Section(length, center) {
this._length = length;
this._center = center;
}
Object.defineProperty(Section.prototype, "length", {
get: function () {
return this._length;
},
enumerable: true,
configurable: true
});
Object.defineProperty(Section.prototype, "center", {
get: function () {
return this._center;
},
enumerable: true,
configurable: true
});
Section.fromAxisX = function (rectangle) {
return new Section(rectangle.width, rectangle.centerX);
};
Section.fromAxisY = function (rectangle) {
return new Section(rectangle.height, rectangle.centerY);
};
return Section;
}());
export { Section };
//# sourceMappingURL=Section.js.map