UNPKG

igniteui-react-charts

Version:

Ignite UI React charting components for building rich data visualizations using TypeScript APIs.

222 lines (221 loc) 7.97 kB
/* 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 { AnchoredRadialSeries } from "./AnchoredRadialSeries"; import { UnknownValuePlotting_$type } from "igniteui-react-core"; import { DependencyProperty } from "igniteui-react-core"; import { Array_$type, Point_$type, runOn, enumGetBox, markType, markDep } from "igniteui-react-core"; import { List$1 } from "igniteui-react-core"; import { Path } from "igniteui-react-core"; import { ScalerParams } from "./ScalerParams"; import { ViewportUtils } from "./ViewportUtils"; import { ChartSelection } from "./ChartSelection"; import { PropertyMetadata } from "igniteui-react-core"; import { AnchoredRadialSeriesView } from "./AnchoredRadialSeriesView"; import { Defaults } from "./Defaults"; /** * @hidden */ export let RadialAreaSeries = /*@__PURE__*/ (() => { class RadialAreaSeries extends AnchoredRadialSeries { bk() { return new RadialAreaSeries(); } get_ex() { return true; } ct() { return new RadialAreaSeriesView(this); } rj(a) { super.rj(a); this.aek = a; } g4(a, b) { let c = this.wy(this.w4(a), true, false); if (this.aan(a, c, b)) { return true; } if (this.g3(a, b)) { return true; } if (this.x4(a, b)) { return true; } return false; } constructor() { super(); this.ab = RadialAreaSeries.$; } preferredCategoryMode(a) { return 0; } pk(a, b) { super.pk(a, b); this.aek.dj(); } ab3(a, b) { super.ab3(a, b); let c = b.ca; let d = b.b9; let e = b.getEffectiveViewport(); let f = b; if (b.r() && !c.isEmpty && !d.isEmpty && this.zp != null && this.zv != null) { let g = a.k; let h = g.count; let i = new List$1(Array_$type, 2, h); let j = 0; for (let k = 0; k < h; k++) { let l = new Array(4); i.add(l); l[0] = this.zw.d(a.k._inner[k][0], a.k._inner[k][1], c, d, e); l[1] = this.zw.e(a.k._inner[k][0], a.k._inner[k][1], c, d, e); l[2] = this.zw.d(a.k._inner[k][0], a.k._inner[k][2], c, d, e); let m = a.k._inner[k][2]; l[3] = this.zw.e(a.k._inner[k][0], m, c, d, e); if (m > j) { j = m; } } let n = ViewportUtils.e(0.5, c, d, e); let o = ViewportUtils.i(0.5, c, d, e); this.aej = { $type: Point_$type, x: n, y: o }; let p = this.getEffectiveViewport1(f); this.z4.a2(this, this.aal(), runOn(this, this.zd), this.aav(b), this.aaw(b)); let q = false; let r = this.z4.b; if (r != null) { q = true; } if (q) { let s = new ScalerParams(0, b.ca, b.b9, this.zp.dn, p); this.ad0(g, -1, this.ac3.count, this.zp, s, b.t); } let t = f.ds; let u = f.dt; let v = f.dq; let w = f.dr; this.z4.ad(t, true, false, true, true); this.z4.ad(u, true, false, true, true); this.z4.ad(v, false, true, false, false); this.z4.ad(w, false, true, false, false); f.dk(a.k.count, i, false, this.aek.da.b, this.im, runOn(this, this.ad1), this.ael); v._opacity = this.z4.j * this.ii; w._opacity = 0.5 * this.z4.j * this.ii; } } ak(a, b) { let c = new List$1(ChartSelection.$, 0); this.qk(a, c, b); return c.toArray(); } qk(a, b, c) { this.adx(a, b, c, this.zq); } rs(a, b, c, d) { super.rs(a, b, c, d); switch (b) { case RadialAreaSeries.$$p[0]: this.sa(false); this.q2(); break; } } get_ac9() { return true; } } RadialAreaSeries.$t = /*@__PURE__*/ markType(RadialAreaSeries, 'RadialAreaSeries', AnchoredRadialSeries.$); RadialAreaSeries.$$p = /*@__PURE__*/ markDep(DependencyProperty, PropertyMetadata, RadialAreaSeries, 'raisePropertyChanged', ['UnknownValuePlotting:ael:aen', [UnknownValuePlotting_$type, /*@__PURE__*/ enumGetBox(UnknownValuePlotting_$type, 1)]]); return RadialAreaSeries; })(); /** * @hidden */ export let RadialAreaSeriesView = /*@__PURE__*/ (() => { class RadialAreaSeriesView extends AnchoredRadialSeriesView { constructor(a) { super(a); this.di = 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.di = a; } a4() { super.a4(); if (!this.t) { this.di.xx = Defaults.e; } } dj() { this.dq.an = null; this.ds.an = null; this.dr.an = null; this.dt.an = null; this.dl.an = null; this.dn.an = null; this.dm.an = null; this.dp.an = null; this.a2(); } dk(a, b, c, d, e, f, g) { this.de.acy.i(this.dq, this.ds, this.dr, this.dt, a, b, c, d, e, f, g); this.a2(); } bp() { super.bp(); } bq() { super.bq(); let a = this.b3(); this.dn.an = this.ds.an; this.dp.an = this.dt.an; this.dl.an = this.dq.an; this.dm.an = this.dr.an; this.dn._stroke = a; this.dn.ad = this.f.io + 3; this.dp._stroke = a; this.dp.ad = this.f.io + 3; this.dl._fill = a; this.dl._opacity = 1; this.dm._fill = a; this.dm._opacity = 1; } bj(a, b) { super.bj(a, b); if (a.d) { 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); } } } ax(a) { super.ax(a); this.f.bc.exportPathData(a, this.ds, "lowerShape", ["Lower"]); this.f.bc.exportPathData(a, this.dt, "upperShape", ["Upper", "Main"]); this.f.bc.exportPathData(a, this.dr, "translucentShape", ["Translucent"]); this.f.bc.exportPathData(a, this.dq, "fillShape", ["Fill"]); } } RadialAreaSeriesView.$t = /*@__PURE__*/ markType(RadialAreaSeriesView, 'RadialAreaSeriesView', AnchoredRadialSeriesView.$); return RadialAreaSeriesView; })();