UNPKG

igniteui-react-charts

Version:

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

1,429 lines 61.8 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 { Series } from "./Series"; import { ISupportsFillScale_$type } from "./ISupportsFillScale"; import { DependencyProperty } from "igniteui-react-core"; import { BrushScale } from "./BrushScale"; import { HighlightingInfo } from "igniteui-react-core"; import { ShapeItemSearchMode_$type } from "./ShapeItemSearchMode"; import { IEnumerable$1_$type, String_$type, enumGetBox, Number_$type, Point_$type, typeCast, runOn, delegateCombine, fromEnum, Array_$type, markType, markDep } from "igniteui-react-core"; import { NumericXAxis } from "./NumericXAxis"; import { NumericYAxis } from "./NumericYAxis"; import { List$1 } from "igniteui-react-core"; import { Rect } from "igniteui-react-core"; import { StyleShapeEventArgs } from "./StyleShapeEventArgs"; import { FrameworkElement } from "igniteui-react-core"; import { IFastItemsSource_$type } from "igniteui-react-core"; import { DataContext } from "igniteui-react-core"; import { Tuple$2 } from "igniteui-react-core"; import { ShapeHitRegion } from "./ShapeHitRegion"; import { RectUtil } from "igniteui-react-core"; import { Tuple$3 } from "igniteui-react-core"; import { GeometryUtil } from "igniteui-react-core"; import { AssigningShapeStyleEventArgs } from "./AssigningShapeStyleEventArgs"; import { AssigningShapeMarkerStyleEventArgs } from "./AssigningShapeMarkerStyleEventArgs"; import { SeriesLayerPropertyOverlay } from "./SeriesLayerPropertyOverlay"; import { CustomPaletteBrushScale } from "./CustomPaletteBrushScale"; import { ValueBrushScale } from "./ValueBrushScale"; import { PointCollectionUtil } from "igniteui-react-core"; import { FlattenedShape } from "./FlattenedShape"; import { SeriesView } from "./SeriesView"; import { Clipper } from "igniteui-react-core"; import { ScalerParams } from "./ScalerParams"; import { Dictionary$2 } from "igniteui-react-core"; import { ActualRange } from "./ActualRange"; import { SeriesRenderManager } from "./SeriesRenderManager"; import { PolySimplification } from "igniteui-react-core"; import { DefaultFlattener } from "./DefaultFlattener"; import { ChartSelection } from "./ChartSelection"; import { AxisRange } from "./AxisRange"; import { Style } from "igniteui-react-core"; import { PropertyMetadata } from "igniteui-react-core"; import { boxArray$1 } from "igniteui-react-core"; import { InvalidOperationException } from "igniteui-react-core"; import { isNaN_, truncate } from "igniteui-react-core"; import { FastItemObjectColumn } from "igniteui-react-core"; import { Path } from "igniteui-react-core"; import { Pool$1 } from "igniteui-react-core"; import { PointCollection } from "igniteui-react-core"; import { PathGeometry } from "igniteui-react-core"; import { PolyLineSegment } from "igniteui-react-core"; import { PathFigure } from "igniteui-react-core"; import { PolygonUtil } from "igniteui-react-core"; /** * @hidden */ export let ShapeSeriesBase = /*@__PURE__*/ (() => { class ShapeSeriesBase extends Series { constructor() { super(); this.xv = null; this.x0 = false; this.xz = false; this.xt = null; this.xu = null; this.xj = 1; this.w4 = null; this.w5 = null; this.assigningShapeStyle = null; this.assigningShapeMarkerStyle = null; this.xn = null; this.xw = null; this.xf = null; this.xh = null; this.ym = 0; this.yi = null; this.w1 = null; this.w3 = null; this.w2 = null; this.w0 = null; this.z6 = null; this.xd = null; this.xp = null; this.w8 = null; this.yp = 0; this.styleShape = null; this.xn = new ShapeSeriesRenderManager(); FastItemObjectColumn.m(); this.yp = this.yo; this.z6 = Rect.empty; } o2() { super.o2(); this.xg = null; this.xi = null; } ai() { return [this.xg, this.xi]; } kq(a, b) { let c = this.nd(b); if (c == ShapeSeriesBase.$$p[9]) { return this.kr(a, b, this.y9); } return null; } md(a) { let b = this.nd(a); if (b == ShapeSeriesBase.$$p[9]) { return this.y9; } return super.md(a); } get xx() { return this.xv; } set xx(a) { if (this.xv != a) { let b = this.xx; this.xv = a; this.raisePropertyChanged("FillColumn", b, this.xx); } } get_fe() { return true; } get_ee() { return true; } xr(a, b, c) { if (this.dp == null) { return null; } let d = this.v9(b); let e = this.xo.c6(d, false); let f = -1; if (e == null) { if (a != null) { f = this.dp.indexOf(a); } else { return null; } } else if (e.dataContext != null) { f = e.dataContext.c; } if (f == -1) { return null; } let g = new HighlightingInfo(); g.i = this; g.g = f; g.f = f; g.c = false; if (c != null && c.g == g.g && c.f == g.f) { return c; } return g; } xs(a, b, c) { if (this.dp == null) { return null; } let d = this.xo.b8(this.v9(b)); let e = -1; if (d == null) { if (a != null) { e = this.dp.indexOf(a); } else { return null; } } else { e = d.ak; } if (e == -1) { return null; } let f = new HighlightingInfo(); f.i = this; f.g = e; f.f = e; f.c = false; f.d = true; if (c != null && c.g == f.g && c.f == f.f) { return c; } return f; } get xk() { return this.xj; } set xk(a) { let b = this.xj; this.xj = a; if (b != this.xj) { this.raisePropertyChanged("ActualItemSearchMode", enumGetBox(ShapeItemSearchMode_$type, b), enumGetBox(ShapeItemSearchMode_$type, this.xj)); } } xl() { if (this.xm != 0) { return this.xm; } return 1; } ir(a) { switch (this.xk) { case 1: return this.zf(a).c; case 2: return this.yn(a); case 3: return this.yn(a); } return -1; } zf(a) { let b = this.v9(a); let c = { $type: Point_$type, x: NaN, y: NaN }; let d = this.xo.ci; if (d == null) { return new Tuple$2(Number_$type, Point_$type, -1, c); } let e = this.xo.b9(b, false, !this.x2); if (e != null) { c = RectUtil.l(e.d); return new Tuple$2(Number_$type, Point_$type, e.b, c); } let f = b.x; let g = b.y; if (this.dp == null || this.xg == null || this.xi == null || this.yi == null) { return new Tuple$2(Number_$type, Point_$type, -1, c); } if (this.dp.count > this.ys) { return new Tuple$2(Number_$type, Point_$type, -1, c); } let h = 1.7976931348623157E+308; let i = -1; for (let j = 0; j < d.count; j++) { let k = d._inner[j].d; let l = RectUtil.g(k, b); if (l < h) { h = l; i = d._inner[j].b; c = RectUtil.l(d._inner[j].d); } } return new Tuple$2(Number_$type, Point_$type, i, c); } ze(a) { let b = this.v9(a); let c = b.x; let d = b.y; let e = { $type: Point_$type, x: NaN, y: NaN }; if (this.dp == null || this.xg == null || this.xi == null || this.yi == null) { return new Tuple$3(Number_$type, Point_$type, Point_$type, -1, e, e); } if (this.dp.count > this.ys) { return new Tuple$3(Number_$type, Point_$type, Point_$type, -1, e, e); } let f = 1.7976931348623157E+308; let g = this.xo.ci; if (g == null) { return new Tuple$3(Number_$type, Point_$type, Point_$type, -1, e, e); } let h = this.xo.b9(b, false, !this.x2); if (h != null) { let i = RectUtil.l(h.d); let j = this.zd(b, h.a, this.x2); return new Tuple$3(Number_$type, Point_$type, Point_$type, h.b, j.d, i); } for (let k = 0; k < g.count; k++) { let l = g._inner[k].d; let m = RectUtil.g(l, b); let n = (l.width * l.width) + (l.height * l.height) + m; if (n <= f) { f = n; } } let o = 1.7976931348623157E+308; let p = -1; for (let q = 0; q < g.count; q++) { let r = g._inner[q].d; let s = RectUtil.g(r, b); if (s < f) { let t = this.zd(b, g._inner[q].a, this.x2); if (t.c < o) { o = t.c; e = t.d; p = q; } } } if (p >= 0) { return new Tuple$3(Number_$type, Point_$type, Point_$type, g._inner[p].b, e, RectUtil.l(g._inner[p].d)); } return new Tuple$3(Number_$type, Point_$type, Point_$type, -1, e, e); } get_x2() { return true; } get x2() { return this.get_x2(); } zd(a, b, c) { let d = { $type: Point_$type, x: NaN, y: NaN }; let e = 1.7976931348623157E+308; let f = { $type: Point_$type, x: NaN, y: NaN }; let g = false; let h = -1; for (let i = 0; i < b.count; i++) { let j = b._inner[i]; if (i >= 1) { let k = GeometryUtil.h(a, d, j); if (k < e) { e = k; g = true; h = i; } } d = j; } if (c) { let l = b._inner[0]; let m = GeometryUtil.h(a, d, l); if (m < e) { e = m; let n = GeometryUtil.m(a, d, l); f = { $type: Point_$type, x: d.x + (l.x - d.x) * n, y: d.y + (l.y - d.y) * n }; return new Tuple$2(Number_$type, Point_$type, e, f); } } if (g) { let o = b._inner[h - 1]; let p = b._inner[h]; let q = GeometryUtil.m(a, o, p); f = { $type: Point_$type, x: o.x + (p.x - o.x) * q, y: o.y + (p.y - o.y) * q }; } return new Tuple$2(Number_$type, Point_$type, e, f); } yn(a) { return this.ze(a).c; } we(a, b, c) { if (this.xg == null || this.xi == null || this.yi == null) { return { $type: Point_$type, x: NaN, y: NaN }; } switch (this.xk) { case 1: let d = this.zf(a); return d.d; case 2: let e = this.ze(a); return e.e; case 3: let f = this.ze(a); return f.d; } return { $type: Point_$type, x: NaN, y: NaN }; } kn(a) { let b = this.j3(a); if (this.dp != null && b >= 0 && b < this.dp.count) { return this.dp.item(b); } return null; } xq(a, b, c) { let d = new HighlightingInfo(); d.i = this; d.g = 0; d.f = this.dp.count - 1; d.c = true; if (c != null && c.g == d.g && c.f == d.f) { return c; } return d; } dh(a, b, c) { if (this.ee && this.fz(this.by) && !c) { let d = this.xr(a, b, this.xt); this.xt = d; return d; } else { let e = this.xq(a, b, this.xt); this.xt = e; return e; } } di(a, b, c) { if (this.fz(this.by) && !c) { let d = this.xs(a, b, this.xu); this.xu = d; return d; } else { let e = this.xq(a, b, this.xu); e.d = true; this.xu = e; return e; } } yg() { return (this.assigningShapeStyle != null && this.x0) || this.d3 || (this.by != 1) || (this.cq != 1) || (this.cp != 1) || (this.xx != null && this.xc != null); } yf() { return (this.assigningShapeMarkerStyle != null && this.xz) || this.d3 || (this.by != 1) || (this.cq != 1) || (this.cp != 1); } get y0() { return this.c(ShapeSeriesBase.zw); } set y0(a) { this.h(ShapeSeriesBase.zw, a); } gb() { return this.highlightedItemsSource != null || this.y0 != null; } ht() { let a = super.ht(); { let b = ((() => { let $ret = new SeriesLayerPropertyOverlay(); $ret.ad = "ShapeMemberPath"; $ret.p = true; $ret.y = "HighlightedShapeMemberPath"; $ret.q = true; return $ret; })()); b.valueResolving = delegateCombine(b.valueResolving, runOn(this, this.zi)); a.add(b); } { let c = ((() => { let $ret = new SeriesLayerPropertyOverlay(); $ret.r = true; $ret.ad = "Brush"; $ret.p = true; $ret.y = "ActualBrush"; $ret.q = true; return $ret; })()); c.valueResolving = delegateCombine(c.valueResolving, runOn(this, this.r2)); a.add(c); } { let d = ((() => { let $ret = new SeriesLayerPropertyOverlay(); $ret.r = true; $ret.ad = "Outline"; $ret.p = true; $ret.y = "ActualOutline"; $ret.q = true; return $ret; })()); d.valueResolving = delegateCombine(d.valueResolving, runOn(this, this.r2)); a.add(d); } return a; } zi(a, b) { if (this.y0 != null) { b.value = this.y0; return; } b.value = this.y9; } get xy() { return this.xw; } set xy(a) { let b = this.xy != a; if (b) { let c = this.xy; this.xw = a; this.raisePropertyChanged("ShapeColumn", c, this.xy); } } x7(array_) { let a = (Array.isArray(array_)); return a; } static yb(a) { if (a == null) { return true; } let val_ = a; return (val_ == undefined); } convertToListList(a) { if (a == null) { return null; } let b = new List$1(List$1.$.specialize(Point_$type), 0); let c; let curr_; let d; let e; let f = false; let g = false; for (let h = 0; h < a.length; h++) { c = a[h]; if (c == null) { continue; } let i = new List$1(Point_$type, 0); for (let j = 0; j < c.length; j++) { curr_ = c[j]; if (f) { d = (curr_.X); e = (curr_.Y); } else { d = (curr_.x); e = (curr_.y); } if (!g) { if ((isNaN_(d) || ShapeSeriesBase.yb(d)) && (isNaN_(e) || ShapeSeriesBase.yb(e))) { d = (curr_.X); e = (curr_.Y); if (!isNaN_(d) && !ShapeSeriesBase.yb(d) && !isNaN_(e) && !ShapeSeriesBase.yb(e)) { g = true; f = true; } } else { g = true; } } i.add({ $type: Point_$type, x: d, y: e }); } b.add(i); } return b; } dn(a) { if (this.dp != null && this.x7(this.itemsSource) && a != null && a.split('!').length != 2) { if (this.coercionMethods == null) { this.coercionMethods = {}; } let methods_ = this.coercionMethods; methods_.convertToListList = this.convertToListList; a += "!convertToListList"; } return super.dn(a); } ra(a, b, c, d) { super.ra(a, b, c, d); let e = false; let f = false; switch (b) { case ShapeSeriesBase.$$p[5]: this.xk = this.xl(); break; case "FastItemsSource": let g = typeCast(IFastItemsSource_$type, c); if (g != null) { if (this.xx != null) { g.deregisterColumn(this.xx); } if (this.xy != null) { g.deregisterColumn(this.xy); } this.xy = null; } let h = typeCast(IFastItemsSource_$type, d); if (h != null) { if (this.y9 != null) { this.xy = this.dn(this.y9); } if (this.yw != null) { this.xx = this.dl(this.yw); } } e = this.xg != null && !this.xg.c1(); f = this.xi != null && !this.xi.c1(); if (e || f) { this.rs(this.gg && c != null); } break; case ShapeSeriesBase.$$p[9]: if (this.dp != null) { this.dp.deregisterColumn(this.xy); this.xy = this.dn(this.y9); } break; case "ShapeColumn": this.zq(); e = this.xg != null && !this.xg.c1(); f = this.xi != null && !this.xi.c1(); if (e || f) { this.rs(this.gg && this.d8); } this.ql(); break; case ShapeSeriesBase.$$p[10]: case ShapeSeriesBase.$$p[11]: this.xf = this.xg; this.xh = this.xi; let i = c; let j = d; this.zr(i); this.zj(j); if ((j != null && !j.c1()) || (j == null && i != null)) { this.rs(false); } this.ql(); break; case "ActualResolution": this.ym = this.id; this.ql(); break; case "ActualBrush": this.rs(false); break; case ShapeSeriesBase.$$p[8]: this.yp = this.yo; this.rs(false); this.ql(); break; case ShapeSeriesBase.$$p[2]: case "ActualThickness": this.rs(false); this.ql(); break; case ShapeSeriesBase.$$p[4]: this.x0 = this.ye(); this.rs(false); break; case ShapeSeriesBase.$$p[3]: this.xz = this.yd(); this.rs(false); break; case ShapeSeriesBase.$$p[1]: if (c != null) { c.o.remove(this); c.x(); this.xd = null; this.xp = null; } if (d != null) { d.o.add(this); d.x(); this.xd = typeCast(CustomPaletteBrushScale.$, d); this.xp = typeCast(ValueBrushScale.$, d); } this.rs(false); this.ql(); break; case "FillColumn": this.rs(this.gg && this.d8); this.ql(); break; case ShapeSeriesBase.$$p[0]: if (this.xc != null) { this.xc.x(); } if (this.dp != null) { this.dp.deregisterColumn(this.xx); this.xx = this.dl(this.yw); } break; } } ye() { return this.ya; } yd() { return this.x9; } x4(a) { if (typeCast(NumericYAxis.$, a) !== null) { return true; } return false; } x3(a) { if (typeCast(NumericXAxis.$, a) !== null) { return true; } return false; } zq() { this.yi = null; if (this.xy == null) { return; } this.yi = new List$1(Rect.$, 2, this.xy.count); for (let a = 0; a < this.xy.count; a++) { this.yi.add(PointCollectionUtil.j(this.xy.item(a))); } } z7(a) { if (typeCast(IEnumerable$1_$type.specialize(IEnumerable$1_$type.specialize(Point_$type)), a) !== null) { return PointCollectionUtil.h(a); } else if (typeCast(IEnumerable$1_$type.specialize(Point_$type), a) !== null) { return PointCollectionUtil.g(a); } return Rect.empty; } yk(a, b, c, d, e, f, g) { return this.yl(a, b, c, d, e, f, g); if (typeCast(List$1.$.specialize(List$1.$.specialize(Point_$type)), c) !== null) { return this.yl(a, b, c, d, e, f, g); } else if (typeCast(IEnumerable$1_$type.specialize(IEnumerable$1_$type.specialize(Point_$type)), c) !== null) { let h = c; let i = new List$1(FlattenedShape.$, 0); let j = null; for (let k of fromEnum(h)) { j = this.xe(a, b, PointCollectionUtil.b(k), d, e, f, g); if (j == null) { continue; } i.add(j); } return i; } else if (typeCast(IEnumerable$1_$type.specialize(Point_$type), c) !== null) { let l = c; let m = this.xe(a, b, PointCollectionUtil.b(l), d, e, f, g); let n = new List$1(FlattenedShape.$, 0); if (m != null) { n.add(m); } return n; } else { throw new InvalidOperationException(1, "Unrecognized data in ShapeColumn"); } } get_x8() { return true; } get x8() { return this.get_x8(); } yh() { return false; } rt(a) { this.zp(this.cw); } rr(a, b, c, d, e) { super.rr(a, b, c, d, e); let f = this.ba.a$j.item(d); let g = f; f.a6(c); if (this.d6(f)) { return; } this.zp(f); } updateFillScaleGlobals() { let a = new ActualRange(); a.b = NaN; a.a = NaN; if (this.xx != null) { a.b = this.xx.minimum; a.a = this.xx.maximum; } if (this.xc != null) { this.xc.z(a.b, a.a); } } zp(a) { if (this.d6(a)) { return; } if (this.xc != null) { this.w8 = this.w9(); } let b; let c; let d = a; let e = a.getViewInfo(c, b); c = e.p0; b = e.p1; if (c.width < 1 || c.height < 1 || this.xy == null) { return; } let f = this.xg; let g = this.xi; let h = this.getEffectiveViewport1(a); let i = new ScalerParams(1, b, c, f.ch); i.c = h; let j = new ScalerParams(1, b, c, g.ch); j.c = h; if (!this.gr) { d.cy(); let k = new Rect(0, 0, 0, 0, 0); let l; let m; let n; let o; let p = this.xy.count; if (this.w3 == null || this.w3.length != p) { this.w3 = new Array(p); this.w1 = new Array(p); this.w2 = new Array(p); this.w0 = new Array(p); } let q = this.w3; let r = this.w1; let s = this.w2; let t = this.w0; let u; for (let v = 0; v < p; v++) { u = this.yi._inner[v]; q[v] = u.top; r[v] = u.left; s[v] = u.right; t[v] = u.bottom; } this.xf.hq(boxArray$1(r), 0, r.length, i); this.xf.hq(boxArray$1(s), 0, s.length, i); this.xh.hq(boxArray$1(q), 0, q.length, j); this.xh.hq(boxArray$1(t), 0, t.length, j); d.cz(r, q, s, t); let w = this.xy; let x = this.dp; this.zs(d); let y = c.left; let z = c.right; let aa = c.top; let ab = c.bottom; let ac = null; if (this.z6.isEmpty) { ac = null; } else { ac = new Clipper(1, this.z6.left, this.z6.bottom, this.z6.right, this.z6.top, this.x8); } let ad = this.yh(); if (ad) { d.cg.clear(); } let ae = false; let af = true; let ag = 0; if (this.dc != null) { if (this.dc.f3()) { let ah = this.dc.m5(b, i); ae = ah.c; ag = ah.d; } } let ai; for (let aj = 0; aj < p; aj++) { n = r[aj]; l = q[aj]; m = t[aj]; o = s[aj]; k.x = Math.min(n, o); k.y = Math.min(l, m); k.width = Math.max(n, o) - k.x; k.height = Math.max(l, m) - k.y; if (k.intersectsWith(c)) { if (k.x < y || k.y < aa || k.x > z || k.y > ab) { ai = ac; } else { ai = null; } let ak = this.yk(a, ai, w.item(aj), i, j, 0, ag); if (ad) { ShapeSeriesBase.zo(d, aj, ak); } d.cm(aj, x.item(aj), k, ak); } else if (ae) { k.x = k.x + ag; if (k.intersectsWith(c)) { if (k.x < y || k.y < aa || k.x > z || k.y > ab) { ai = ac; } else { ai = null; } let al = this.yk(a, ai, w.item(aj), i, j, ag, ag); if (ad) { ShapeSeriesBase.zo(d, aj, al); } d.cm(aj, x.item(aj), k, al); } } } d.cx(); } let am = this.yg(); this.xn.az(this, this.yg(), runOn(this, this.w6)); let an = false; let ao = this.xn.b; if (ao != null) { an = true; } let ap = a.r; let aq = this.fy; let ar = d.ce; d.ct((as) => { let at = as.dataContext != null ? as.dataContext.item : null; let au = as.dataContext != null ? as.dataContext.c : -1; d.cq(as, at, am); if (an) { this.zl(as, aq, au, this.xy.count, ap, ar); } else { if (ar) { { this.xn.a1(as, this.ib, ar); } } } { this.xn.ad(as, false, false, false, false); } }); } w9() { let a = new ActualRange(); a.b = NaN; a.a = NaN; if (this.xx != null) { a.b = this.xx.minimum; a.a = this.xx.maximum; } let b = typeCast(ValueBrushScale.$, this.xc); if (b != null) { b.s(); if (this.x5 && this.xc.o.count > 1) { a.b = b.q; a.a = b.p; } } return a; } zl(a, b, c, d, e, f) { let g = this.by != 1; let h = this.cq != 1; let i = this.cp != 1; this.xn.a0(this.xn.b, c, d, false); { this.xn.a1(a, this.ib, f); } let j = this.xn.ax; let k = null; let l = null; let m = null; let n = this.dp; if (this.xx != null && this.xc != null) { if (j.z >= 0 && j.z < this.xx.count) { let o = this.xx.item(j.z); let p = this.w8; let q = p.b; let r = p.a; let s = j.aa; if (this.xd != null) { s = this.xd.getBrush1(j.z, this.xx.count); } else if (this.xp != null && this.xx != null) { let t = this.xx.item(j.z); s = this.xp.getBrushByRange(t, q, r); } else if (this.xc != null) { s = this.xc.getBrush(j.z); } j.aa = s; } } if (g && this.dc != null) { k = this.dc.dk.getHighlightingInfo(this, n, j.z, j.y, false); j.c = k; } if (h && this.dc != null) { l = this.dc.dl.getHighlightingInfo(this, n, j.z, j.y, false); if (l == null && this.bo != null) { l = this.dc.dl.getHighlightingInfo(this.bo, this.bo.dp, j.z, j.y, false); } if (l == null && this.bl != null) { l = this.dc.dl.getHighlightingInfo(this.bl, this.bl.dp, j.z, j.y, true); } j.d = l; } if (i && this.dc != null) { m = this.dc.dj.getHighlightingInfo(this, n, j.z, j.y, false); j.b = m; } j.h = e; this.zn(j); this.xn.z(this, k, l, m, e, g, h, i, false); } zk(a, b, c) { let d = this.by != 1; let e = this.cq != 1; let f = this.cp != 1; this.xn.a0(this.xn.d, a, b, true); this.xn.aa(this.ib); let g = this.xn.aw; let h = null; let i = null; let j = null; let k = this.dp; let l = null; let m = null; let n = null; if (d && this.dc != null) { h = this.dc.dk.getHighlightingInfo(this, k, g.z, g.y, true); if (this.dc.dk.isCrossContextHighlight(this)) { l = this.dc.dk.getHighlightingInfo(this, k, g.z, g.y, true); } g.c = h; } if (e && this.dc != null) { i = this.dc.dl.getHighlightingInfo(this, k, g.z, g.y, true); if (i == null && this.bo != null) { i = this.dc.dl.getHighlightingInfo(this.bo, this.bo.dp, g.z, g.y, true); } if (this.dc.dl.isCrossContextHighlight(this)) { m = this.dc.dl.getHighlightingInfo(this, k, g.z, g.y, true); } g.d = i; } if (f && this.dc != null) { j = this.dc.dj.getHighlightingInfo(this, k, g.z, g.y, true); if (this.dc.dj.isCrossContextHighlight(this)) { n = this.dc.dj.getHighlightingInfo(this, k, g.z, g.y, true); } g.b = i; } g.h = c; this.zm(g); this.xn.y(this, h, i, j, c, d, e, f, g.v, this.dc.dk.totalHighWaterMark, g.x, this.dc.dl.totalHighWaterMark, g.t, this.dc.dj.totalHighWaterMark); } zn(a) { if (this.assigningShapeStyle != null && this.x0) { this.assigningShapeStyle(this, a); } } zm(a) { if (this.assigningShapeMarkerStyle != null && this.xz) { this.assigningShapeMarkerStyle(this, a); } } w6(a, b) { return this.w7(a, b); } w7(a, b) { if (b < a || a < 0 || a > this.xy.count || b < 0 || b > this.xy.count) { return null; } let c = new Array((b - a) + 1); for (let d = a; d <= b; d++) { let e = d; c[d - a] = this.dp.item(d); } return c; } static zo(a, b, c) { let d = 0; let e = null; for (let f = 0; f < c.count; f++) { let g = c._inner[f]; let h = g.b.width * g.b.height; if (h > d) { d = h; e = g; } } a.cg.addItem(b, e); } qb() { super.qb(); if (this.xg != null) { this.xg.ia(); } if (this.xi != null) { this.xi.ia(); } } st(a, b) { this.rs(false); } ss(a, b) { this.rs(false); } pb(a, b, c, d) { super.pb(a, b, c, d); switch (a) { case 3: if (d == this.y9) { this.yi._inner[b] = this.z7(this.xy.item(b)); } break; case 1: for (let e = b; e < b + c; e++) { this.yi.insert(e, this.z7(this.xy.item(e))); } break; case 0: this.yi.v(b, c); break; case 2: for (let f = b; f < b + c; f++) { this.yi._inner[f] = this.z7(this.xy.item(f)); } break; case 4: this.zq(); break; } this.rs(false); } he(a, b, c) { let d = true; if (!super.he(a, b, c) || (this.yc && this.xy == null) || b.isEmpty || a.isEmpty || this.xg == null || this.xi == null || this.xg.bi == null || this.xi.bi == null || this.xg.l4 == this.xg.l3 || this.xi.l4 == this.xi.l3 || this.xy == null || this.xy.count == 0 || this.yi == null || this.yi.count == 0 || this.yi.count != this.xy.count) { d = false; } return d; } get_yc() { return true; } get yc() { return this.get_yc(); } q1(a) { super.q1(a); this.xo = typeCast(ShapeSeriesViewBase.$, a); } yl(a, b, c, d, e, f, g) { let h = new List$1(FlattenedShape.$, 0); let i; let j = c.count; for (let k = 0; k < j; k++) { i = c._inner[k]; let l = this.xe(a, b, i, d, e, f, g); if (l == null) { continue; } h.add(l); } return h; } xe(a, b, c, d, e, f, g) { let h = this.zg(c, d, e); let i = h.c; let j = h.d; let k = i.length; let l = 1.7976931348623157E+308; let m = 1.7976931348623157E+308; let n = -1.7976931348623157E+308; let o = -1.7976931348623157E+308; let p; let q; if (f != 0) { for (let r = 0; r < k; r++) { i[r] = i[r] + f; } } for (let s = 0; s < k; s++) { p = i[s]; q = j[s]; l = p < l ? p : l; m = q < m ? q : m; n = p > n ? p : n; o = q > o ? q : o; } let t = !(l > this.z6.right || n < this.z6.left || m > this.z6.bottom || o < this.z6.top); if (!t && f == 0 && g != 0) { if (g != 0) { for (let u = 0; u < k; u++) { i[u] = i[u] + g; } } for (let v = 0; v < k; v++) { p = i[v]; q = j[v]; l = p < l ? p : l; m = q < m ? q : m; n = p > n ? p : n; o = q > o ? q : o; } t = !(l > this.z6.right || n < this.z6.left || m > this.z6.bottom || o < this.z6.top); } if (!t) { return null; } let w = b != null && (l < this.z6.left || m < this.z6.top || n > this.z6.right || o > this.z6.bottom); let x = new Rect(0, l, m, n - l, o - m); if (!a.cf(x)) { return null; } l = l < this.z6.left ? this.z6.left : l; n = n > this.z6.right ? this.z6.right : n; m = m < this.z6.top ? this.z6.top : m; o = o > this.z6.bottom ? this.z6.bottom : o; let y = PolySimplification.b(h, this.id); let z = new DefaultFlattener().c(h.c, h.d, y, this.ym); let aa = z.count; if (w) { let ab = new List$1(Point_$type, 0); b.i = ab; for (let ac = 0; ac < aa; ac++) { b.j(z._inner[ac]); } b.i = null; z = ab; } if (z == null || z.count == 0) { return null; } let ad = new FlattenedShape(); ad.a = z; ad.b = new Rect(0, l, m, n - l, o - m); ad.c = x; return ad; } zg(a, b, c) { let d = this.xf; let e = this.xh; let f = a.count; let g = new Array(f); let h = new Array(f); for (let i = 0; i < f; i++) { g[i] = a._inner[i].x; h[i] = a._inner[i].y; } d.hq(boxArray$1(g), 0, g.length, b); e.hq(boxArray$1(h), 0, h.length, c); return new Tuple$2(Array_$type, Array_$type, g, h); } zs(a) { a.c4(); } o5(a, b) { super.o5(a, b); let c = b; c.cr(); } zj(a) { if (a != null) { a.ct(this); } } zr(a) { if (a != null) { a.b0(this); } } zh(a, b, c) { let d = this.cw; let e = d.b1; let f = this.dc.wk(this.dc.wa(a)); if (e.width < 1 || e.height < 1 || this.xy == null) { return; } let g = this.getEffectiveViewport1(d); let h = new ScalerParams(0, f, e, this.xg.ch, g); let i = new ScalerParams(0, f, e, this.xi.ch, g); d.cy(); let j = this.xy.count; let k = new Array(j); let l = new Array(j); let m = new Array(j); let n = new Array(j); let o; for (let p = 0; p < j; p++) { o = this.yi._inner[p]; k[p] = o.top; l[p] = o.left; m[p] = o.right; n[p] = o.bottom; } this.xg.hq(boxArray$1(l), 0, l.length, h); this.xg.hq(boxArray$1(m), 0, m.length, h); this.xi.hq(boxArray$1(k), 0, k.length, i); this.xi.hq(boxArray$1(n), 0, n.length, i); d.cz(l, k, m, n); d.c4(); let q = null; if (!this.z6.isEmpty) { q = new Clipper(1, this.z6.left, this.z6.bottom, this.z6.right, this.z6.top, this.x8); } let r = false; let s = 0; if (this.dc != null) { if (this.dc.f3()) { let t = this.dc.m5(f, h); r = t.c; s = t.d; } } let u, v, w, x; let y = new Rect(0, 0, 0, 0, 0); for (let z = 0; z < j; z++) { w = l[z]; u = k[z]; v = n[z]; x = m[z]; y.x = Math.min(w, x); y.y = Math.min(u, v); y.width = Math.max(w, x) - y.x; y.height = Math.max(u, v) - y.y; if (r) { y.x = y.x + s; } if (!y.intersectsWith(e)) { continue; } let aa = this.yk(d, q, this.xy.item(z), h, i, s, s); if (aa.count <= 0) { continue; } this.x1(b, c, z); } } x1(a, b, c) { if (b == 7 || b == 6) { a.add(((() => { let $ret = new ChartSelection(); $ret.series = this; return $ret; })())); return false; } else if (b == 1 || b == 2) { a.add(((() => { let $ret = new ChartSelection(); $ret.item = this.dp.item(c); return $ret; })())); return true; } else { a.add(((() => { let $ret = new ChartSelection(); $ret.item = this.dp.item(c); $ret.series = this; return $ret; })())); return true; } } a2(a, b) { let c = this.xo.c6(a, b); let d = null; if (c != null) { d = c.dataContext; } if (d != null) { return d; } return super.a2(a, b); } yt(a) { return this.dp.item(a); } get_g7() { return true; } set_g7(a) { super.set_g7(a); } ay(a) { if (typeCast(NumericXAxis.$, a) !== null && this.yi != null) { let b = 1.7976931348623157E+308; let c = -1.7976931348623157E+308; for (let d of fromEnum(this.yi)) { b = Math.min(b, d.left); c = Math.max(c, d.right); } return new AxisRange(b, c); } if (typeCast(NumericYAxis.$, a) !== null && this.yi != null) { let e = 1.7976931348623157E+308; let f = -1.7976931348623157E+308; for (let g of fromEnum(this.yi)) { e = Math.min(e, g.top); f = Math.max(f, g.bottom); } return new AxisRange(e, f); } return null; } get_fx() { return true; } get_fl() { return true; } get x6() { return this.styleShape != null; } z8(a, b, c) { if (this.styleShape != null) { if (this.xo.dd != null && c == this.xo.dd) { c = new Style(); let d = this.xo.dd; c.fill = d.fill; c.opacity = d.opacity; c.stroke = d.stroke; c.strokeThickness = d.strokeThickness; } else { if (c != null) { let e = new Style(); e.fill = c.fill; e.opacity = c.opacity; e.stroke = c.stroke; e.strokeThickness = c.strokeThickness; c = e; } else { c = new Style(); } } let f = new StyleShapeEventArgs(a, b, c); this.styleShape(this, f); return f.d(); } return c; } } ShapeSeriesBase.$t = /*@__PURE__*/ markType(ShapeSeriesBase, 'ShapeSeriesBase', Series.$, [ISupportsFillScale_$type]); ShapeSeriesBase.zw = /*@__PURE__*/ DependencyProperty.i("HighlightedValueMemberPath", String_$type, ShapeSeriesBase.$, /*@__PURE__*/ new PropertyMetadata(2, null, (a, b) => a.raisePropertyChanged("HighlightedValueMemberPath", b.oldValue, b.newValue))); ShapeSeriesBase.$$p = /*@__PURE__*/ markDep(DependencyProperty, PropertyMetadata, ShapeSeriesBase, 'raisePropertyChanged', ['FillMemberPath:yw:zt', [2], 'FillScale:xc:zu', [BrushScale.$], 'FillScaleUseGlobalValues:x5:zv', [0, false], 'IsCustomShapeMarkerStyleAllowed:x9:zx', [0, false], 'IsCustomShapeStyleAllowed:ya:zy', [0, false], 'ItemSea