UNPKG

igniteui-react-charts

Version:

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

263 lines (262 loc) 9.19 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 { HorizontalAnchoredCategorySeries } from "./HorizontalAnchoredCategorySeries"; import { IUnknownValuePlotting_$type } from "igniteui-react-core"; import { CategoryLineRasterizer } from "./CategoryLineRasterizer"; import { UnknownValuePlotting_$type } from "igniteui-react-core"; import { DependencyProperty } from "igniteui-react-core"; import { typeCast, 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 { ChartSelection } from "./ChartSelection"; import { PropertyMetadata } from "igniteui-react-core"; import { AnchoredCategorySeriesView } from "./AnchoredCategorySeriesView"; import { Defaults } from "./Defaults"; import { ISortingAxis_$type } from "./ISortingAxis"; import { Color } from "igniteui-react-core"; /** * @hidden */ var AreaSeries = /** @class */ /*@__PURE__*/ (function (_super) { __extends(AreaSeries, _super); function AreaSeries() { var _this = _super.call(this) || this; _this.acy = null; _this.acy = new CategoryLineRasterizer(); _this.ab = AreaSeries.$; _this.ach = 0; return _this; } AreaSeries.prototype.bk = function () { return new AreaSeries(); }; AreaSeries.prototype.ct = function () { return new AreaSeriesView(this); }; AreaSeries.prototype.y6 = function () { return 1; }; AreaSeries.prototype.cz = function () { if (this.c0 == 0) { return 2; } return _super.prototype.cz.call(this); }; AreaSeries.prototype.q1 = function (a) { _super.prototype.q1.call(this, a); this.acx = a; }; AreaSeries.prototype.get_ew = function () { return true; }; AreaSeries.prototype.get_ev = function () { return true; }; AreaSeries.prototype.preferredCategoryMode = function (a) { return this.ach; }; AreaSeries.prototype.gw = function (a, b) { var c = this.we(this.wj(a), true, false); if (this.aco(a, c, b)) { return true; } if (this.gv(a, b)) { return true; } if (this.xj(a, b)) { return true; } return false; }; AreaSeries.prototype.o5 = function (a, b) { _super.prototype.o5.call(this, a, b); var c = b; c.dk(); }; AreaSeries.prototype.aam = function (a, b) { var _this = this; _super.prototype.aam.call(this, a, b); var c = b.c0.d; var d = typeCast(AreaSeriesView.$, b); var e = a.h; var f = this.getEffectiveViewport1(d); this.y4.a2(this, this.zo(), runOn(this, this.yo), this.zx(b), this.zy(b)); var g = false; var h = this.y4.b; if (h != null) { g = true; } if (g) { var i = new ScalerParams(0, b.b2, b.b1, this.ace.ch, f); this.aai(e, -1, this.valueColumn.count, this.ace, i, b.r, -1); } var j = d.dw; var k = d.dx; var l = d.dy; var m = d.dz; this.y4.ad(j, true, false, true, true); this.y4.ad(k, true, false, true, true); this.y4.ad(l, false, true, false, false); this.y4.ad(m, false, true, false, false); if (b.c4(a)) { d.dm(e.count, e, true, c, this.id, function (n, o, p, q, r) { return _this.abu(n, a.h.count, b); }, this.unknownValuePlotting, e.count == 1 ? null : this.aav(e, e.count - 1, b.b1, b.b2, true)); b.c7(a); } var n = this.fetchYAxis(); l._opacity = this.y4.j * this.h9; m._opacity = 0.5 * this.y4.j * this.h9; }; AreaSeries.prototype.ra = function (a, b, c, d) { _super.prototype.ra.call(this, a, b, c, d); switch (b) { case AreaSeries.$$p[0]: this.y1.m = this.unknownValuePlotting == 0; this.rs(false); this.ql(); break; } }; AreaSeries.prototype.ak = function (a, b) { var c = new List$1(ChartSelection.$, 0); this.p4(a, c, b); return c.toArray(); }; AreaSeries.prototype.p4 = function (a, b, c) { this.aae(a, b, c, this.yv, 0); }; Object.defineProperty(AreaSeries.prototype, "useHighMarkerFidelity", { get: function () { return this.zs; }, enumerable: false, configurable: true }); AreaSeries.$t = markType(AreaSeries, 'AreaSeries', HorizontalAnchoredCategorySeries.$, [IUnknownValuePlotting_$type]); AreaSeries.$$p = markDep(DependencyProperty, PropertyMetadata, AreaSeries, 'raisePropertyChanged', ['UnknownValuePlotting::ac0', [UnknownValuePlotting_$type, enumGetBox(UnknownValuePlotting_$type, 1)]]); return AreaSeries; }(HorizontalAnchoredCategorySeries)); export { AreaSeries }; /** * @hidden */ var AreaSeriesView = /** @class */ /*@__PURE__*/ (function (_super) { __extends(AreaSeriesView, _super); function AreaSeriesView(a) { var _this = _super.call(this, a) || this; _this.dj = null; _this.ds = new Path(); _this.du = new Path(); _this.dt = new Path(); _this.dv = new Path(); _this.dn = new Path(); _this.dq = new Path(); _this.dp = new Path(); _this.dr = new Path(); _this.dj = a; return _this; } AreaSeriesView.prototype.ax = function () { _super.prototype.ax.call(this); if (!this.r) { this.dj.xc = Defaults.e; } }; Object.defineProperty(AreaSeriesView.prototype, "dw", { get: function () { return this.du; }, enumerable: false, configurable: true }); Object.defineProperty(AreaSeriesView.prototype, "dx", { get: function () { return this.dv; }, enumerable: false, configurable: true }); Object.defineProperty(AreaSeriesView.prototype, "dy", { get: function () { return this.ds; }, enumerable: false, configurable: true }); Object.defineProperty(AreaSeriesView.prototype, "dz", { get: function () { return this.dt; }, enumerable: false, configurable: true }); AreaSeriesView.prototype.dk = function () { this.ds.an = null; this.dt.an = null; this.du.an = null; this.dv.an = null; this.av(); }; AreaSeriesView.prototype.dl = function (a, b, c, d, e, f, g) { this.dm(a, b, c, d, e, f, g, null); }; AreaSeriesView.prototype.dm = function (a, b, c, d, e, f, g, h) { this.dj.acy.a = typeCast(ISortingAxis_$type, this.c2.fetchXAxis()) !== null ? true : false; this.dj.acy.j(this.ds, this.du, this.dt, this.dv, a, b, c, d, e, f, g, h); this.av(); }; AreaSeriesView.prototype.bi = function () { _super.prototype.bi.call(this); this.dn.an = this.ds.an; this.dq.an = this.du.an; this.dp.an = this.dt.an; this.dr.an = this.dv.an; var a = this.bv(); this.dn._fill = a; this.dn._opacity = 1; this.dp._fill = a; this.dp._opacity = 1; this.dq._stroke = a; this.dq.ad = this.f.ie + 3; this.dr._stroke = a; this.dr.ad = this.f.ie + 3; }; AreaSeriesView.prototype.bc = function (a, b) { _super.prototype.bc.call(this, a, b); if (b) { a.t(this.dn); a.t(this.dp); a.t(this.dq); a.t(this.dr); } else { a.t(this.ds); a.t(this.dt); a.t(this.du); a.t(this.dv); } }; AreaSeriesView.prototype.aq = function (a) { _super.prototype.aq.call(this, a); this.f.bc.exportPathData(a, this.du, "lowerShape", ["Lower"]); this.f.bc.exportPathData(a, this.dv, "upperShape", ["Upper", "Main"]); this.f.bc.exportPathData(a, this.dt, "translucentShape", ["Translucent"]); this.f.bc.exportPathData(a, this.ds, "fillShape", ["Fill"]); }; AreaSeriesView.prototype.ai = function () { var a = new Color(); a.colorString = "rgba(95,95,95,0.5)"; this.f.v3 = a; this.f.jm = 5; this.f.jn = 1; this.f.jo = -3; }; AreaSeriesView.$t = markType(AreaSeriesView, 'AreaSeriesView', AnchoredCategorySeriesView.$); return AreaSeriesView; }(AnchoredCategorySeriesView)); export { AreaSeriesView };