UNPKG

igniteui-react-charts

Version:

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

134 lines (133 loc) 5 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 { FinancialSeries } from "./FinancialSeries"; import { DependencyProperty } from "igniteui-react-core"; import { ISortingAxis_$type } from "./ISortingAxis"; import { typeCast, markType, markDep } from "igniteui-react-core"; import { Rect } from "igniteui-react-core"; import { ScalerParams } from "./ScalerParams"; import { AxisRange } from "./AxisRange"; import { PropertyMetadata } from "igniteui-react-core"; import { isNaN_ } from "igniteui-react-core"; /** * @hidden */ export let FinancialOverlay = /*@__PURE__*/ (() => { class FinancialOverlay extends FinancialSeries { get_e9() { return true; } constructor() { super(); this.aa2 = false; this.aa2 = false; } pb(a, b, c, d) { super.pb(a, b, c, d); if (this.w8 != null && typeCast(ISortingAxis_$type, this.w8) !== null) { this.w8.i$i(); } this.xp.b4.e(this.id); this.aa3(); if (this.xr != null) { this.xr.c1(); } this.rs(true); } get_hd() { return true; } ra(a, b, c, d) { switch (b) { case "FastItemsSource": this.aa2 = false; break; case FinancialOverlay.$$p[0]: this.aa2 = false; this.rs(false); this.ql(); break; case "XAxis": this.aa2 = false; break; } super.ra(a, b, c, d); } b3() { if (this.b4 == 0) { return 1; } else { return super.b3(); } } gw(a, b) { if (this.gv(a, b)) { return true; } return false; } ac() { super.ac(); this.rs(false); } gd(a) { let b = this.dp != null ? this.dp.indexOf(a) : -1; let c = this.cw.b2; c = c.copy(); let d = this.cw.b1; let e = new Rect(0, 0, 0, 1, 1); let f = this.wn(this.cw); let g = new ScalerParams(0, e, e, this.w8.ch, f); let h = new ScalerParams(0, e, e, this.xr.ch, f); h.b = this.iy(); if (b >= 0 && Rect.l_op_Inequality(c, null) && Rect.l_op_Inequality(d, null)) { if (this.w8 != null) { let i = this.w8.el(b, g); if (i < c.left + 0.1 * c.width) { i = i + 0.4 * c.width; } if (i > c.right - 0.1 * c.width) { i = i - 0.4 * c.width; } c.x = i - 0.5 * c.width; } if (this.xr != null && this.x3 != null && this.x2 != null && b < this.x3.count && b < this.x2.count) { let j = this.xr.el(this.x3.item(b), h); let k = this.xr.el(this.x2.item(b), h); if (!isNaN_(j) && !isNaN_(k)) { let l = Math.abs(j - k); if (c.height < l) { c.height = l; c.y = Math.min(j, k); } else { if (j < c.top + 0.1 * c.height) { j = j + 0.4 * c.height; } if (j > c.bottom - 0.1 * c.height) { j = j - 0.4 * c.height; } c.y = j - 0.5 * c.height; } } } this.c4.au(this.dc, c, true); } return b >= 0; } ay(a) { if (a != null && a == this.xr && this.x3 != null && this.x2 != null) { return new AxisRange(this.x3.minimum, this.x2.maximum); } return null; } } FinancialOverlay.$t = /*@__PURE__*/ markType(FinancialOverlay, 'FinancialOverlay', FinancialSeries.$); FinancialOverlay.$$p = /*@__PURE__*/ markDep(DependencyProperty, PropertyMetadata, FinancialOverlay, 'raisePropertyChanged', ['IgnoreFirst:aa4:aa6', [1, 0]]); return FinancialOverlay; })();