igniteui-react-charts
Version:
Ignite UI React charting components for building rich data visualizations using TypeScript APIs.
126 lines (125 loc) • 4.13 kB
JavaScript
/*
THIS INFRAGISTICS ULTIMATE SOFTWARE LICENSE AGREEMENT ("AGREEMENT") LOCATED HERE:
https://www.infragistics.com/legal/license/igultimate-la
https://www.infragistics.com/legal/license/igultimate-eula
GOVERNS THE LICENSING, INSTALLATION AND USE OF INFRAGISTICS SOFTWARE. BY DOWNLOADING AND/OR INSTALLING AND USING INFRAGISTICS SOFTWARE: you are indicating that you have read and understand this Agreement, and agree to be legally bound by it on behalf of the yourself and your company.
*/
import { Base, fromEnum, markType } from "igniteui-react-core";
import { FunnelSliceVisualDataList } from "./FunnelSliceVisualDataList";
import { StringBuilder } from "igniteui-react-core";
/**
* @hidden
*/
export let FunnelChartVisualData = /*@__PURE__*/ (() => {
class FunnelChartVisualData extends Base {
constructor() {
super();
this._slices = null;
this._name = null;
this._viewport = null;
this._isInverted = false;
this._backgroundColor = null;
this._foregroundColor = null;
this._opacity = 0;
this._borderBrush = null;
this._selectedItems = null;
this._dipScalingRatio = 0;
this.dipScalingRatio = 1;
this.slices = new FunnelSliceVisualDataList();
}
get slices() {
return this._slices;
}
set slices(a) {
this._slices = a;
}
get name() {
return this._name;
}
set name(a) {
this._name = a;
}
get viewport() {
return this._viewport;
}
set viewport(a) {
this._viewport = a;
}
get isInverted() {
return this._isInverted;
}
set isInverted(a) {
this._isInverted = a;
}
get backgroundColor() {
return this._backgroundColor;
}
set backgroundColor(a) {
this._backgroundColor = a;
}
get foregroundColor() {
return this._foregroundColor;
}
set foregroundColor(a) {
this._foregroundColor = a;
}
get opacity() {
return this._opacity;
}
set opacity(a) {
this._opacity = a;
}
get borderBrush() {
return this._borderBrush;
}
set borderBrush(a) {
this._borderBrush = a;
}
get selectedItems() {
return this._selectedItems;
}
set selectedItems(a) {
this._selectedItems = a;
}
get dipScalingRatio() {
return this._dipScalingRatio;
}
set dipScalingRatio(a) {
this._dipScalingRatio = a;
}
scaleByViewport() {
for (let a of fromEnum(this.slices)) {
a.scaleByViewport(this.viewport);
}
}
serialize() {
let a = new StringBuilder(0);
a.u("{");
if (this.name != null) {
a.u("name: \"" + this.name + "\", ");
}
else {
a.u("name: \"\", ");
}
if (this.slices != null && this.slices.count > 0) {
a.u("slices: [");
for (let b = 0; b < this.slices.count; b++) {
let c = this.slices._inner[b].serialize();
a.l(c);
if (b < this.slices.count - 1) {
a.u(", ");
}
}
a.u("],");
}
a.u("viewport: {");
a.l("left: " + this.viewport.left + ", top: " + this.viewport.top + ", width: " + this.viewport.width + ", height: " + this.viewport.height);
a.u("},");
a.l("dipScalingRatio: " + this.dipScalingRatio.toString());
a.u("}");
return a.toString();
}
}
FunnelChartVisualData.$t = /*@__PURE__*/ markType(FunnelChartVisualData, 'FunnelChartVisualData');
return FunnelChartVisualData;
})();