igniteui-angular-charts
Version:
Ignite UI Angular charting components for building rich data visualizations for modern web apps.
201 lines (200 loc) • 6.53 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 { HorizontalRangeCategorySeries } from "./HorizontalRangeCategorySeries";
import { Array_$type, typeCast, runOn, markType } from "igniteui-angular-core";
import { List$1 } from "igniteui-angular-core";
import { Polyline } from "igniteui-angular-core";
import { Polygon } from "igniteui-angular-core";
import { ScalerParams } from "./ScalerParams";
import { ChartSelection } from "./ChartSelection";
import { isNaN_ } from "igniteui-angular-core";
import { RangeCategorySeriesView } from "./RangeCategorySeriesView";
/**
* @hidden
*/
export let RangeAreaSeries = /*@__PURE__*/ (() => {
class RangeAreaSeries extends HorizontalRangeCategorySeries {
constructor() {
super();
this.ab = RangeAreaSeries.$;
}
bk() {
return new RangeAreaSeries();
}
ct() {
return new RangeAreaSeriesView(this);
}
rg(a) {
super.rg(a);
this.acm = a;
}
get_ey() {
return true;
}
get_ex() {
return true;
}
acn(a, b, c, d) {
if (isNaN_(b.x) || isNaN_(b.y)) {
return false;
}
if (isNaN_(c.x) || isNaN_(c.y)) {
return false;
}
if ((a.y <= b.y && a.y >= c.y)) {
return true;
}
return false;
}
g2(a, b) {
if (this.g1(a, b)) {
return true;
}
if (this.x1(a, b)) {
return true;
}
return false;
}
preferredCategoryMode(a) {
return 0;
}
ph(a, b) {
super.ph(a, b);
let c = b;
c.dl();
}
aa7(a, b) {
super.aa7(a, b);
let c = a.k.count;
let d = new List$1(Array_$type, 2, c);
for (let e = 0; e < c; e++) {
let f = a.k._inner[e];
let g = new Array(4);
g[0] = f[0];
g[1] = f[1];
let h = a.k._inner[a.k.count - 1 - e];
g[2] = h[0];
g[3] = h[2];
d.add(g);
}
let i = typeCast(RangeAreaSeriesView.$, b);
let j = this.getEffectiveViewport1(i);
this.zm.a2(this, this.z6(), runOn(this, this.y6), this.aaf(b), this.aag(b));
let k = false;
let l = this.zm.b;
if (l != null) {
k = true;
}
if (k) {
let m = new ScalerParams(0, b.ca, b.b9, this.xAxis.dn, j);
this.aa3(d, -1, this.lowColumn.count, this.xAxis, m, b.t, -1);
}
let n = i.dv;
let o = i.dw;
let p = i.dq;
this.zm.ad(n, true, false, true, true);
this.zm.ad(o, true, false, true, true);
this.zm.ad(p, false, true, false, false);
if (b.dd(a)) {
i.dm(a.k.count, d, false);
b.dg(a);
}
i.dq._opacity = this.zm.j * this.ig;
}
qh(a, b, c) {
this.aaz(a, b, c, this.zd, 1);
}
ak(a, b) {
let c = new List$1(ChartSelection.$, 0);
this.qh(a, c, b);
return c.toArray();
}
get useHighMarkerFidelity() {
return this.aaa;
}
}
RangeAreaSeries.$t = markType(RangeAreaSeries, 'RangeAreaSeries', HorizontalRangeCategorySeries.$);
return RangeAreaSeries;
})();
/**
* @hidden
*/
export let RangeAreaSeriesView = /*@__PURE__*/ (() => {
class RangeAreaSeriesView extends RangeCategorySeriesView {
constructor(a) {
super(a);
this.dk = null;
this.dt = new Polyline();
this.dp = new Polygon();
this.du = new Polyline();
this.ds = new Polyline();
this.dr = new Polyline();
this.dn = new Polygon();
this.dk = a;
}
a4() {
super.a4();
if (!this.t) {
this.dk.xu = 1;
}
}
get dv() {
return this.dt;
}
get dq() {
return this.dp;
}
get dw() {
return this.du;
}
dl() {
this.dp.an.clear();
this.dt.an.clear();
this.du.an.clear();
}
dm(a, b, c) {
this.dj(this.dt, this.dp, this.du, a, b, c);
this.a2();
}
bq() {
super.bq();
this.dr.an = this.dt.an;
this.ds.an = this.du.an;
this.dn.an = this.dp.an;
let a = this.b3();
this.dr._stroke = a;
this.dr.ad = this.f.il + 3;
this.ds._stroke = a;
this.ds.ad = this.f.il + 3;
this.dn._fill = a;
this.dn._opacity = 1;
}
bj(a, b) {
super.bj(a, b);
if (a.d) {
if (b) {
a.u(this.dn);
a.v(this.dr);
a.v(this.ds);
}
else {
a.u(this.dp);
a.v(this.dt);
a.v(this.du);
}
}
}
ax(a) {
super.ax(a);
this.f.bc.exportPolylineData(a, this.dt, "lowerShape", ["Lower"]);
this.f.bc.exportPolylineData(a, this.du, "upperShape", ["Upper", "Main"]);
this.f.bc.exportPolygonData(a, this.dp, "fillShape", ["Fill"]);
}
}
RangeAreaSeriesView.$t = markType(RangeAreaSeriesView, 'RangeAreaSeriesView', RangeCategorySeriesView.$);
return RangeAreaSeriesView;
})();