UNPKG

igniteui-react-charts

Version:

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

207 lines (206 loc) 7 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 { 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 */ export let LineSeries = /*@__PURE__*/ (() => { class LineSeries extends HorizontalAnchoredCategorySeries { bk() { return new LineSeries(); } get_fk() { return true; } ct() { return new LineSeriesView(this); } q1(a) { super.q1(a); this.acy = a; } zq() { return true; } get_ew() { return true; } constructor() { super(); this.acx = null; this.acx = new CategoryLineRasterizer(); this.ab = LineSeries.$; this.ach = 0; } preferredCategoryMode(a) { return this.ach; } o5(a, b) { super.o5(a, b); let c = b; c.dk(); } aam(a, b) { super.aam(a, b); let c = b.c0.d; let d = typeCast(LineSeriesView.$, b); let e = a.h; let f = this.getEffectiveViewport1(b); this.y4.a2(this, this.zo(), runOn(this, this.yo), this.zx(b), this.zy(b)); let g = false; let h = this.y4.b; if (h != null) { g = true; } if (g) { let 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); } let j = d.dr; let k = d.ds; let l = d.dq; this.y4.ad(j, true, false, true, false); this.y4.ad(k, true, false, true, false); this.y4.ad(l, false, true, false, false); l._opacity = 0.75 * this.y4.j; if (b.c4(a)) { d.dl(e.count, e, true, this.unknownValuePlotting, this.aau(e, e.count - 1, b.b1, b.b2), c, this.id); b.c7(a); } } ak(a, b) { let c = new List$1(ChartSelection.$, 0); this.p4(a, c, b); return c.toArray(); } p4(a, b, c) { this.aae(a, b, c, this.yv, 0); } ra(a, b, c, d) { super.ra(a, b, c, d); switch (b) { case LineSeries.$$p[0]: this.y1.m = this.unknownValuePlotting == 0; this.rs(false); this.ql(); break; } } get useHighMarkerFidelity() { return this.zs; } } LineSeries.$t = /*@__PURE__*/ markType(LineSeries, 'LineSeries', HorizontalAnchoredCategorySeries.$, [IUnknownValuePlotting_$type]); LineSeries.$$p = /*@__PURE__*/ markDep(DependencyProperty, PropertyMetadata, LineSeries, 'raisePropertyChanged', ['UnknownValuePlotting::ac0', [UnknownValuePlotting_$type, /*@__PURE__*/ enumGetBox(UnknownValuePlotting_$type, 1)]]); return LineSeries; })(); /** * @hidden */ export let LineSeriesView = /*@__PURE__*/ (() => { class LineSeriesView extends AnchoredCategorySeriesView { constructor(a) { super(a); this.dj = null; this.du = new Path(); this.dt = new Path(); this.dv = new Path(); this.dp = new Path(); this.dn = new Path(); this.dm = new Path(); this.dj = a; } ax() { super.ax(); if (!this.r) { this.dj.xc = Defaults.e; } } get dr() { return this.du; } get ds() { return this.dv; } get dq() { return this.dt; } dk() { this.dt.an = null; this.du.an = null; this.dv.an = null; this.av(); } dl(a, b, c, d, e, f, g) { this.dj.acx.a = typeCast(ISortingAxis_$type, this.c2.fetchXAxis()) !== null ? true : false; this.dj.acx.m(this.du, this.dt, this.dv, a, b, c, d, e, f, g); this.av(); } bh() { super.bh(); } bi() { super.bi(); this.dn.an = this.du.an; this.dp.an = this.dv.an; this.dm.an = this.dt.an; let a = this.bv(); this.dn._stroke = a; this.dn.ad = this.f.ie + 3; this.dp._stroke = a; this.dp.ad = this.f.ie + 3; this.dm._fill = a; this.dm._opacity = 1; } bc(a, b) { super.bc(a, b); if (a.d) { if (b) { a.t(this.dm); a.t(this.dn); a.t(this.dp); } else { a.t(this.dt); a.t(this.du); a.t(this.dv); } } } aq(a) { super.aq(a); this.f.bc.exportPathData(a, this.du, "lowerShape", ["Lower", "Main"]); this.f.bc.exportPathData(a, this.dv, "upperShape", ["Upper"]); this.f.bc.exportPathData(a, this.dt, "translucentShape", ["Translucent"]); } ai() { let a = new Color(); a.colorString = "rgba(95,95,95,0.5)"; this.f.v3 = a; this.f.jm = 3; this.f.jn = 1; this.f.jo = 4; this.f.hc = false; } } LineSeriesView.$t = /*@__PURE__*/ markType(LineSeriesView, 'LineSeriesView', AnchoredCategorySeriesView.$); return LineSeriesView; })();