UNPKG

igniteui-react-charts

Version:

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

225 lines (224 loc) 8.44 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 { __extends } from "tslib"; 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 */ var RadialAreaSeries = /** @class */ /*@__PURE__*/ (function (_super) { __extends(RadialAreaSeries, _super); function RadialAreaSeries() { var _this = _super.call(this) || this; _this.ab = RadialAreaSeries.$; return _this; } RadialAreaSeries.prototype.bk = function () { return new RadialAreaSeries(); }; RadialAreaSeries.prototype.get_ex = function () { return true; }; RadialAreaSeries.prototype.ct = function () { return new RadialAreaSeriesView(this); }; RadialAreaSeries.prototype.ri = function (a) { _super.prototype.ri.call(this, a); this.aeg = a; }; RadialAreaSeries.prototype.g3 = function (a, b) { var c = this.wx(this.w3(a), true, false); if (this.aaj(a, c, b)) { return true; } if (this.g2(a, b)) { return true; } if (this.x3(a, b)) { return true; } return false; }; RadialAreaSeries.prototype.preferredCategoryMode = function (a) { return 0; }; RadialAreaSeries.prototype.pj = function (a, b) { _super.prototype.pj.call(this, a, b); this.aeg.dj(); }; RadialAreaSeries.prototype.abz = function (a, b) { _super.prototype.abz.call(this, a, b); var c = b.ca; var d = b.b9; var e = b.getEffectiveViewport(); var f = b; if (b.r() && !c.isEmpty && !d.isEmpty && this.zl != null && this.zr != null) { var g = a.k; var h = g.count; var i = new List$1(Array_$type, 2, h); var j = 0; for (var k = 0; k < h; k++) { var l = new Array(4); i.add(l); l[0] = this.zs.d(a.k._inner[k][0], a.k._inner[k][1], c, d, e); l[1] = this.zs.e(a.k._inner[k][0], a.k._inner[k][1], c, d, e); l[2] = this.zs.d(a.k._inner[k][0], a.k._inner[k][2], c, d, e); var m = a.k._inner[k][2]; l[3] = this.zs.e(a.k._inner[k][0], m, c, d, e); if (m > j) { j = m; } } var n = ViewportUtils.e(0.5, c, d, e); var o = ViewportUtils.i(0.5, c, d, e); this.aef = { $type: Point_$type, x: n, y: o }; var p = this.getEffectiveViewport1(f); this.z0.a2(this, this.aah(), runOn(this, this.y9), this.aar(b), this.aas(b)); var q = false; var r = this.z0.b; if (r != null) { q = true; } if (q) { var s = new ScalerParams(0, b.ca, b.b9, this.zl.dn, p); this.adw(g, -1, this.acz.count, this.zl, s, b.t); } var t = f.ds; var u = f.dt; var v = f.dq; var w = f.dr; this.z0.ad(t, true, false, true, true); this.z0.ad(u, true, false, true, true); this.z0.ad(v, false, true, false, false); this.z0.ad(w, false, true, false, false); f.dk(a.k.count, i, false, this.aeg.da.b, this.il, runOn(this, this.adx), this.aeh); v._opacity = this.z0.j * this.ih; w._opacity = 0.5 * this.z0.j * this.ih; } }; RadialAreaSeries.prototype.ak = function (a, b) { var c = new List$1(ChartSelection.$, 0); this.qj(a, c, b); return c.toArray(); }; RadialAreaSeries.prototype.qj = function (a, b, c) { this.adt(a, b, c, this.zm); }; RadialAreaSeries.prototype.rr = function (a, b, c, d) { _super.prototype.rr.call(this, a, b, c, d); switch (b) { case RadialAreaSeries.$$p[0]: this.r9(false); this.q1(); break; } }; RadialAreaSeries.prototype.get_ac5 = function () { return true; }; RadialAreaSeries.$t = markType(RadialAreaSeries, 'RadialAreaSeries', AnchoredRadialSeries.$); RadialAreaSeries.$$p = markDep(DependencyProperty, PropertyMetadata, RadialAreaSeries, 'raisePropertyChanged', ['UnknownValuePlotting:aeh:aej', [UnknownValuePlotting_$type, enumGetBox(UnknownValuePlotting_$type, 1)]]); return RadialAreaSeries; }(AnchoredRadialSeries)); export { RadialAreaSeries }; /** * @hidden */ var RadialAreaSeriesView = /** @class */ /*@__PURE__*/ (function (_super) { __extends(RadialAreaSeriesView, _super); function RadialAreaSeriesView(a) { var _this = _super.call(this, a) || this; _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; return _this; } RadialAreaSeriesView.prototype.a4 = function () { _super.prototype.a4.call(this); if (!this.t) { this.di.xw = Defaults.e; } }; RadialAreaSeriesView.prototype.dj = function () { 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(); }; RadialAreaSeriesView.prototype.dk = function (a, b, c, d, e, f, g) { this.de.acu.i(this.dq, this.ds, this.dr, this.dt, a, b, c, d, e, f, g); this.a2(); }; RadialAreaSeriesView.prototype.bp = function () { _super.prototype.bp.call(this); }; RadialAreaSeriesView.prototype.bq = function () { _super.prototype.bq.call(this); var 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.im + 3; this.dp._stroke = a; this.dp.ad = this.f.im + 3; this.dl._fill = a; this.dl._opacity = 1; this.dm._fill = a; this.dm._opacity = 1; }; RadialAreaSeriesView.prototype.bj = function (a, b) { _super.prototype.bj.call(this, 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); } } }; RadialAreaSeriesView.prototype.ax = function (a) { _super.prototype.ax.call(this, 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 = markType(RadialAreaSeriesView, 'RadialAreaSeriesView', AnchoredRadialSeriesView.$); return RadialAreaSeriesView; }(AnchoredRadialSeriesView)); export { RadialAreaSeriesView };