igniteui-angular-charts
Version:
Ignite UI Angular charting components for building rich data visualizations for modern web apps.
237 lines (236 loc) • 8.38 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 { __extends } from "tslib";
import { SplineSeriesBase } from "./SplineSeriesBase";
import { CategoryLineRasterizer } from "./CategoryLineRasterizer";
import { typeCast, runOn, markType } from "igniteui-angular-core";
import { Path } from "igniteui-angular-core";
import { ScalerParams } from "./ScalerParams";
import { SplineSeriesBaseView } from "./SplineSeriesBaseView";
import { Defaults } from "./Defaults";
import { ISortingAxis_$type } from "./ISortingAxis";
import { Color } from "igniteui-angular-core";
/**
* @hidden
*/
var SplineAreaSeries = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(SplineAreaSeries, _super);
function SplineAreaSeries() {
var _this = _super.call(this) || this;
_this.adg = null;
_this.adg = new CategoryLineRasterizer();
_this.ab = SplineAreaSeries.$;
return _this;
}
SplineAreaSeries.prototype.bj = function () {
return new SplineAreaSeries();
};
SplineAreaSeries.prototype.get_eu = function () {
return true;
};
SplineAreaSeries.prototype.get_f0 = function () {
return true;
};
SplineAreaSeries.prototype.cs = function () {
return new SplineAreaSeriesView(this);
};
SplineAreaSeries.prototype.y4 = function () {
return 1;
};
SplineAreaSeries.prototype.q1 = function (a) {
_super.prototype.q1.call(this, a);
this.adh = a;
};
SplineAreaSeries.prototype.preferredCategoryMode = function (a) {
return 0;
};
SplineAreaSeries.prototype.cy = function () {
if (this.cz == 0) {
return 2;
}
return _super.prototype.cy.call(this);
};
SplineAreaSeries.prototype.o5 = function (a, b) {
_super.prototype.o5.call(this, a, b);
var c = b;
c.di();
};
SplineAreaSeries.prototype.gw = function (a, b) {
var c = this.wc(this.wh(a), true, false);
if (this.acn(a, c, b)) {
return true;
}
if (this.gv(a, b)) {
return true;
}
if (this.xh(a, b)) {
return true;
}
return false;
};
SplineAreaSeries.prototype.aak = function (a, b) {
var _this = this;
_super.prototype.aak.call(this, a, b);
var c = this.y3.cw.d;
var d = typeCast(SplineAreaSeriesView.$, b);
var e = a.f;
var f = this.getEffectiveViewport1(b);
this.y2.a2(this, this.zm(), runOn(this, this.ym), this.zv(b), this.zw(b));
var g = false;
var h = this.y2.b;
if (h != null) {
g = true;
}
if (g) {
var i = new ScalerParams(0, b.by, b.bx, this.acd.ch, f);
this.aag(e, -1, this.valueColumn.count, this.acd, i, b.q, -1);
}
var j = d.du;
var k = d.dv;
var l = d.dw;
var m = d.dx;
this.y2.ad(j, true, false, true, true);
this.y2.ad(k, true, false, true, true);
this.y2.ad(l, false, true, false, false);
this.y2.ad(m, false, true, false, false);
l._opacity = this.y2.j * this.h9;
m._opacity = 0.5 * this.y2.j * this.h9;
if (b.c0(a)) {
d.dk(a.f.count, e, true, c, this.id, function (n, o, p, q, r) { return _this.abt(n, a.f.count, b); }, 1, a.f.count == 1 ? null : this.aau(e, e.count - 1, b.bx, b.by, true));
b.c3(a);
}
var n = this.fetchYAxis();
};
Object.defineProperty(SplineAreaSeries.prototype, "useHighMarkerFidelity", {
get: function () {
return this.zq;
},
enumerable: false,
configurable: true
});
SplineAreaSeries.$t = markType(SplineAreaSeries, 'SplineAreaSeries', SplineSeriesBase.$);
return SplineAreaSeries;
}(SplineSeriesBase));
export { SplineAreaSeries };
/**
* @hidden
*/
var SplineAreaSeriesView = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(SplineAreaSeriesView, _super);
function SplineAreaSeriesView(a) {
var _this = _super.call(this, a) || this;
_this.dh = null;
_this.dq = new Path();
_this.ds = new Path();
_this.dr = new Path();
_this.dt = new Path();
_this.dl = new Path();
_this.dn = new Path();
_this.dm = new Path();
_this.dp = new Path();
_this.dh = a;
return _this;
}
SplineAreaSeriesView.prototype.au = function () {
_super.prototype.au.call(this);
if (!this.q) {
this.dh.xa = Defaults.e;
}
};
Object.defineProperty(SplineAreaSeriesView.prototype, "du", {
get: function () {
return this.ds;
},
enumerable: false,
configurable: true
});
Object.defineProperty(SplineAreaSeriesView.prototype, "dv", {
get: function () {
return this.dt;
},
enumerable: false,
configurable: true
});
Object.defineProperty(SplineAreaSeriesView.prototype, "dw", {
get: function () {
return this.dq;
},
enumerable: false,
configurable: true
});
Object.defineProperty(SplineAreaSeriesView.prototype, "dx", {
get: function () {
return this.dr;
},
enumerable: false,
configurable: true
});
SplineAreaSeriesView.prototype.di = function () {
this.dq.an = null;
this.dr.an = null;
this.ds.an = null;
this.dt.an = null;
this.as();
};
SplineAreaSeriesView.prototype.dj = function (a, b, c, d, e, f, g) {
this.dk(a, b, c, d, e, f, g, null);
};
SplineAreaSeriesView.prototype.dk = function (a, b, c, d, e, f, g, h) {
this.dh.adg.a = typeCast(ISortingAxis_$type, this.cy.fetchXAxis()) !== null ? true : false;
this.dh.adg.j(this.dq, this.ds, this.dr, this.dt, a, b, c, d, e, f, g, h);
this.as();
};
SplineAreaSeriesView.prototype.be = function () {
_super.prototype.be.call(this);
this.dl.an = this.dq.an;
this.dn.an = this.ds.an;
this.dm.an = this.dr.an;
this.dp.an = this.dt.an;
var a = this.br();
this.dl._fill = a;
this.dl._opacity = 1;
this.dm._fill = a;
this.dm._opacity = 1;
this.dn._stroke = a;
this.dn.ad = this.e.ie + 3;
this.dp._stroke = a;
this.dp.ad = this.e.ie + 3;
};
SplineAreaSeriesView.prototype.a8 = function (a, b) {
_super.prototype.a8.call(this, a, b);
if (b) {
a.t(this.dl);
a.t(this.dm);
a.t(this.dn);
a.t(this.dp);
}
else {
a.t(this.dq);
a.t(this.dr);
a.t(this.ds);
a.t(this.dt);
}
};
SplineAreaSeriesView.prototype.an = function (a) {
_super.prototype.an.call(this, a);
this.e.bc.exportPathData(a, this.ds, "lowerShape", ["Lower"]);
this.e.bc.exportPathData(a, this.dt, "upperShape", ["Upper", "Main"]);
this.e.bc.exportPathData(a, this.dr, "translucentShape", ["Translucent"]);
this.e.bc.exportPathData(a, this.dq, "fillShape", ["Fill"]);
};
SplineAreaSeriesView.prototype.af = function () {
var a = new Color();
a.colorString = "rgba(95,95,95,0.5)";
this.e.v1 = a;
this.e.jm = 5;
this.e.jn = 1;
this.e.jo = -3;
};
SplineAreaSeriesView.$t = markType(SplineAreaSeriesView, 'SplineAreaSeriesView', SplineSeriesBaseView.$);
return SplineAreaSeriesView;
}(SplineSeriesBaseView));
export { SplineAreaSeriesView };