UNPKG

igniteui-react-charts

Version:

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

302 lines (301 loc) 12.2 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 { AnchoredCategorySeries } from "./AnchoredCategorySeries"; import { IHorizontalAnchoredCategorySeriesInteractionManager_$type } from "./IHorizontalAnchoredCategorySeriesInteractionManager"; import { DVContainer } from "igniteui-react-core"; import { runOn, Point_$type, typeCast, EnumUtil, enumGetBox, markType, markDep } from "igniteui-react-core"; import { CategoryAxisBase } from "./CategoryAxisBase"; import { DependencyProperty } from "igniteui-react-core"; import { NumericYAxis } from "./NumericYAxis"; import { CategoryMode_$type } from "./CategoryMode"; import { Axis } from "./Axis"; import { Rect } from "igniteui-react-core"; import { ScalerParams } from "./ScalerParams"; import { TrendLineType_$type } from "igniteui-react-core"; import { CategoryTrendLineManagerFactory } from "./CategoryTrendLineManagerFactory"; import { ISortingAxis_$type } from "./ISortingAxis"; import { CategoryXAxis } from "./CategoryXAxis"; import { PropertyMetadata } from "igniteui-react-core"; /** * @hidden */ var HorizontalAnchoredCategorySeries = /** @class */ /*@__PURE__*/ (function (_super) { __extends(HorizontalAnchoredCategorySeries, _super); function HorizontalAnchoredCategorySeries() { var _this = _super !== null && _super.apply(this, arguments) || this; _this.aco = null; _this.ack = null; _this.acq = null; _this.acm = 0; return _this; } Object.defineProperty(HorizontalAnchoredCategorySeries.prototype, "acp", { get: function () { var _this = this; if (this.aco == null) { this.aco = DVContainer.instance.createInstance(IHorizontalAnchoredCategorySeriesInteractionManager_$type, function () { return _this.ds.n; }); } return this.aco; }, enumerable: false, configurable: true }); HorizontalAnchoredCategorySeries.prototype.o4 = function () { _super.prototype.o4.call(this); this.xAxis = null; this.yAxis = null; }; HorizontalAnchoredCategorySeries.prototype.cl = function () { return 1; }; HorizontalAnchoredCategorySeries.prototype.cm = function () { if (this.yAxis != null && this.yAxis.ch) { return 4; } return 3; }; HorizontalAnchoredCategorySeries.prototype.b3 = function () { if (this.b4 == 0) { return 1; } else { return _super.prototype.b3.call(this); } }; HorizontalAnchoredCategorySeries.prototype.yx = function () { return this.ack; }; HorizontalAnchoredCategorySeries.prototype.ze = function () { return this.acq; }; HorizontalAnchoredCategorySeries.prototype.wu = function (a) { if (this.yz == null || this.yz.p.count == 0 || !this.hasMarkers || !this.xl()) { return Rect.empty; } return this.acp.d$d(this, this.yz.p, a, runOn(this, this.ac2)); }; HorizontalAnchoredCategorySeries.prototype.ac2 = function (a) { return this.aa2.ds(a); }; HorizontalAnchoredCategorySeries.prototype.acu = function (a, b, c) { return this.acp.d$c(this, this.ze(), a, b, c); }; HorizontalAnchoredCategorySeries.prototype.aj = function (a) { return this.acp.d$a(this, this.yz.h, this.z0(this.cw), this.z1(this.cw), a); }; HorizontalAnchoredCategorySeries.prototype.al = function (a) { return this.acp.d$b(this, this.yz.h, this.z0(this.cw), this.z1(this.cw), a); }; HorizontalAnchoredCategorySeries.prototype.gx = function (a, b) { if (this.gw(a, b)) { return true; } if (this.xm(a, b)) { return true; } return false; }; HorizontalAnchoredCategorySeries.prototype.getOffsetValue = function () { return this.y4.r(this.yx(), this.cw.ca, this.cw.b9, this.getEffectiveViewport1(this.cw)); }; HorizontalAnchoredCategorySeries.prototype.getCategoryWidth = function () { var a = this.getEffectiveViewport1(this.cw); return this.yx().getCategorySize(this.cw.ca, this.cw.b9, a); }; HorizontalAnchoredCategorySeries.prototype.i6 = function (a, b, c) { if (this.dc == null) { return NaN; } var d = this.getEffectiveViewport1(this.cw); var e = this.yx(); if (e == null) { return NaN; } var f = new ScalerParams(0, this.dc.wt, this.cw.b9, e.ch, d); var g = this.y4.r(e, this.dc.wt, this.cw.b9, d); return this.i8(this.valueColumn, a, e, f, g, runOn(this, this.zy), b, c); }; HorizontalAnchoredCategorySeries.prototype.kb = function (a, b) { return this.kc(a, b, this.yx(), runOn(this, this.zy), this.valueColumn); }; HorizontalAnchoredCategorySeries.prototype.j9 = function (a, b) { return this.ka(a, b, this.yx(), runOn(this, this.zy), this.valueColumn); }; HorizontalAnchoredCategorySeries.prototype.iq = function (a, b, c, d, e) { if (this.valueColumn == null) { return Number.POSITIVE_INFINITY; } return this.ir(a, b, this.yx(), d, e, this.valueColumn.count, runOn(this, this.zy)); }; HorizontalAnchoredCategorySeries.prototype.wh = function (a, b, c) { if (this.yx() == null || this.ze() == null) { return { $type: Point_$type, x: NaN, y: NaN }; } return this.wj(a, b, c, this.y4.r(this.yx(), this.cw.ca, this.cw.b9, this.getEffectiveViewport1(this.cw)), this.ze(), this.yx(), null, null, null); }; HorizontalAnchoredCategorySeries.prototype.fetchXAxis = function () { return this.ack; }; HorizontalAnchoredCategorySeries.prototype.fetchYAxis = function () { return this.acq; }; HorizontalAnchoredCategorySeries.prototype.aby = function (a) { this.xAxis = typeCast(CategoryAxisBase.$, a); }; HorizontalAnchoredCategorySeries.prototype.abz = function (a) { this.yAxis = typeCast(NumericYAxis.$, a); }; HorizontalAnchoredCategorySeries.prototype.zu = function () { return this.acq != null && this.acq.c1(); }; HorizontalAnchoredCategorySeries.prototype.acy = function (a) { this.ack = a; }; HorizontalAnchoredCategorySeries.prototype.acz = function (a) { this.acq = a; }; HorizontalAnchoredCategorySeries.prototype.yr = function (a, b) { return this.aaz(a, b, this.ack); }; HorizontalAnchoredCategorySeries.prototype.rc = function (a, b, c, d) { switch (b) { case HorizontalAnchoredCategorySeries.$$p[0]: this.acy(this.xAxis); if (this.aa2.dl) { this.aa2.dk = CategoryTrendLineManagerFactory.a(this.aa2.dk, this.ack, this.sz, this, this.ds); this.aa2.dk.g$b = this.trendLineType; this.aa2.dk.g$f = this.trendLinePeriod; } break; case "TrendLineType": var e = EnumUtil.getEnumValue(TrendLineType_$type, d); if (e != 0) { this.aa2.dk = CategoryTrendLineManagerFactory.a(this.aa2.dk, this.ack, this.sz, this, this.ds); this.aa2.dk.g$b = this.trendLineType; this.aa2.dk.g$f = this.trendLinePeriod; } break; } _super.prototype.rc.call(this, a, b, c, d); switch (b) { case HorizontalAnchoredCategorySeries.$$p[0]: if (c != d) { this.pe(typeCast(Axis.$, c)); this.rk(typeCast(Axis.$, d)); this.acy(this.xAxis); this.y8.c9.g(this.ie); this.ru(false); this.qn(); } break; case HorizontalAnchoredCategorySeries.$$p[1]: if (c != d) { this.pe(typeCast(Axis.$, c)); this.rk(typeCast(Axis.$, d)); this.acz(this.yAxis); if (this.dc != null) { this.dc.ok(); } this.y8.c9.g(this.ie); this.zu(); this.ru(false); this.qn(); } break; case "CategoryMode": if (this.xAxis != null) { this.xAxis.ma(true); } break; } }; HorizontalAnchoredCategorySeries.prototype.pd = function (a, b, c, d) { _super.prototype.pd.call(this, a, b, c, d); if (this.ack != null && typeCast(ISortingAxis_$type, this.ack) !== null) { this.ack.i$i(); } switch (a) { case 4: if (this.ack != null) { this.ack.c1(); } if (this.acq != null && !this.acq.c1()) { this.ru(true); } break; case 1: if (this.ack != null) { this.ack.c1(); } if (this.acq != null && !this.acq.c1()) { this.ru(true); } break; case 0: if (this.ack != null) { this.ack.c1(); } if (this.acq != null && !this.acq.c1()) { this.ru(true); } break; case 2: if (this.abk != null && this.aa2.c9.d > 0 && this.acq != null && !this.acq.c1()) { this.ru(true); } break; case 3: if (d == this.abk) { if (this.ack != null) { this.ack.c1(); } if (this.acq != null && !this.acq.c1()) { this.ru(true); } } break; } }; HorizontalAnchoredCategorySeries.prototype.acs = function (a) { if (typeCast(CategoryXAxis.$, a) !== null || a.ce) { return true; } return false; }; HorizontalAnchoredCategorySeries.prototype.act = function (a) { if (typeCast(NumericYAxis.$, a) !== null) { return true; } return false; }; Object.defineProperty(HorizontalAnchoredCategorySeries.prototype, "acn", { get: function () { return this.acm; }, set: function (a) { var b = this.acn; if (a != b) { this.acm = a; this.raisePropertyChanged("CategoryMode", enumGetBox(CategoryMode_$type, b), enumGetBox(CategoryMode_$type, this.acn)); } }, enumerable: false, configurable: true }); Object.defineProperty(HorizontalAnchoredCategorySeries.prototype, "useHighMarkerFidelity", { get: function () { return this.zv; }, enumerable: false, configurable: true }); HorizontalAnchoredCategorySeries.$t = markType(HorizontalAnchoredCategorySeries, 'HorizontalAnchoredCategorySeries', AnchoredCategorySeries.$); HorizontalAnchoredCategorySeries.$$p = markDep(DependencyProperty, PropertyMetadata, HorizontalAnchoredCategorySeries, 'raisePropertyChanged', ['XAxis::ac0', [CategoryAxisBase.$, null], 'YAxis::ac1', [NumericYAxis.$, null]]); return HorizontalAnchoredCategorySeries; }(AnchoredCategorySeries)); export { HorizontalAnchoredCategorySeries };