igniteui-react-charts
Version:
Ignite UI React charting components for building rich data visualizations using TypeScript APIs.
166 lines (165 loc) • 5.36 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 { SplineSeriesBase } from "./SplineSeriesBase";
import { CategoryLineRasterizer } from "./CategoryLineRasterizer";
import { typeCast, runOn, markType } from "igniteui-react-core";
import { Path } from "igniteui-react-core";
import { ScalerParams } from "./ScalerParams";
import { SplineSeriesBaseView } from "./SplineSeriesBaseView";
import { Defaults } from "./Defaults";
import { ISortingAxis_$type } from "./ISortingAxis";
/**
* @hidden
*/
export let SplineSeries = /*@__PURE__*/ (() => {
class SplineSeries extends SplineSeriesBase {
bk() {
return new SplineSeries();
}
get_f0() {
return true;
}
ct() {
return new SplineSeriesView(this);
}
zq() {
return true;
}
q1(a) {
super.q1(a);
this.adi = a;
}
constructor() {
super();
this.adh = null;
this.adh = new CategoryLineRasterizer();
this.ab = SplineSeries.$;
}
preferredCategoryMode(a) {
return 0;
}
o5(a, b) {
super.o5(a, b);
let c = b;
c.dm();
}
aam(a, b) {
super.aam(a, b);
let c = b;
let d = c.c0.d;
let e = typeCast(SplineSeriesView.$, b);
let f = a.h;
let g = this.getEffectiveViewport1(b);
this.y4.a2(this, this.zo(), runOn(this, this.yo), this.zx(b), this.zy(b));
let h = false;
let i = this.y4.b;
if (i != null) {
h = true;
}
if (h) {
let j = new ScalerParams(0, b.b2, b.b1, this.ace.ch, g);
this.aai(f, -1, this.valueColumn.count, this.ace, j, b.r, -1);
}
let k = e.dt;
let l = e.du;
let m = e.ds;
this.y4.ad(k, true, false, true, false);
this.y4.ad(l, true, false, true, false);
this.y4.ad(m, false, true, false, false);
m._opacity = 0.75 * this.y4.j;
if (b.c4(a)) {
e.dn(f.count, f, true, 1, this.aau(f, f.count - 1, b.b1, b.b2), d, this.id);
b.c7(a);
}
}
get useHighMarkerFidelity() {
return this.zs;
}
}
SplineSeries.$t = /*@__PURE__*/ markType(SplineSeries, 'SplineSeries', SplineSeriesBase.$);
return SplineSeries;
})();
/**
* @hidden
*/
export let SplineSeriesView = /*@__PURE__*/ (() => {
class SplineSeriesView extends SplineSeriesBaseView {
constructor(a) {
super(a);
this.dl = null;
this.dw = new Path();
this.dv = new Path();
this.dx = new Path();
this.dr = new Path();
this.dq = new Path();
this.dp = new Path();
this.dl = a;
}
ax() {
super.ax();
if (!this.r) {
this.dl.xc = Defaults.e;
}
}
get dt() {
return this.dw;
}
get du() {
return this.dx;
}
get ds() {
return this.dv;
}
dm() {
this.dv.an = null;
this.dw.an = null;
this.dx.an = null;
this.av();
}
dn(a, b, c, d, e, f, g) {
this.dl.adh.a = typeCast(ISortingAxis_$type, this.c2.fetchXAxis()) !== null ? true : false;
this.dl.adh.m(this.dw, this.dv, this.dx, a, b, c, d, e, f, g);
this.av();
}
bi() {
super.bi();
this.dq.an = this.dw.an;
this.dr.an = this.dx.an;
this.dp.an = this.dv.an;
let a = this.bv();
this.dq._stroke = a;
this.dq.ad = this.f.ie + 3;
this.dr._stroke = a;
this.dr.ad = this.f.ie + 3;
this.dp._fill = a;
this.dp._opacity = 1;
}
bc(a, b) {
super.bc(a, b);
if (a.d) {
if (b) {
a.t(this.dp);
a.t(this.dq);
a.t(this.dr);
}
else {
a.t(this.dv);
a.t(this.dw);
a.t(this.dx);
}
}
}
aq(a) {
super.aq(a);
this.f.bc.exportPathData(a, this.dw, "lowerShape", ["Lower", "Main"]);
this.f.bc.exportPathData(a, this.dx, "upperShape", ["Upper"]);
this.f.bc.exportPathData(a, this.dv, "translucentShape", ["Translucent"]);
}
}
SplineSeriesView.$t = /*@__PURE__*/ markType(SplineSeriesView, 'SplineSeriesView', SplineSeriesBaseView.$);
return SplineSeriesView;
})();