igniteui-react-charts
Version:
Ignite UI React charting components for building rich data visualizations using TypeScript APIs.
898 lines (897 loc) • 32.3 kB
JavaScript
/*
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 { FinancialSeries } from "./FinancialSeries";
import { ITrendLineSeries_$type } from "./ITrendLineSeries";
import { IndicatorDisplayType_$type } from "./IndicatorDisplayType";
import { DependencyProperty } from "igniteui-react-core";
import { TrendLineType_$type } from "igniteui-react-core";
import { Brush } from "igniteui-react-core";
import { PenLineCap_$type } from "igniteui-react-core";
import { DoubleCollection } from "igniteui-react-core";
import { List$1 } from "igniteui-react-core";
import { AxisRange } from "./AxisRange";
import { CategoryFrame } from "./CategoryFrame";
import { Number_$type, typeCast, enumGetBox, EnumUtil, runOn, markType, markDep } from "igniteui-react-core";
import { Rect } from "igniteui-react-core";
import { ScalerParams } from "./ScalerParams";
import { ISortingAxis_$type } from "./ISortingAxis";
import { CategoryTrendLineManagerFactory } from "./CategoryTrendLineManagerFactory";
import { FinancialSeriesView } from "./FinancialSeriesView";
import { FinancialBucketCalculator } from "./FinancialBucketCalculator";
import { TrendResolutionParams } from "./TrendResolutionParams";
import { CategorySeries } from "./CategorySeries";
import { NotImplementedException } from "igniteui-react-core";
import { Path } from "igniteui-react-core";
import { PropertyMetadata } from "igniteui-react-core";
import { isNaN_ } from "igniteui-react-core";
import { PathGeometry } from "igniteui-react-core";
import { GeometryGroup } from "igniteui-react-core";
import { Pool$1 } from "igniteui-react-core";
import { LineGeometry } from "igniteui-react-core";
import { Defaults } from "./Defaults";
import { Extensions } from "igniteui-react-core";
import { IndicatorRenderer } from "./IndicatorRenderer";
/**
* @hidden
*/
var FinancialIndicator = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(FinancialIndicator, _super);
function FinancialIndicator() {
var _this = _super.call(this) || this;
_this._indicatorColumn = null;
_this.aa2 = null;
_this.xc = new CategoryFrame(3);
_this.xe = new CategoryFrame(3);
_this.xa = new CategoryFrame(3);
_this.indicatorColumn = new List$1(Number_$type, 0);
_this.aa2 = new AxisRange(-100, 100);
return _this;
}
FinancialIndicator.prototype.get_e8 = function () {
return true;
};
FinancialIndicator.prototype.ct = function () {
return new FinancialIndicatorView(this);
};
FinancialIndicator.prototype.q1 = function (a) {
_super.prototype.q1.call(this, a);
this.aa3 = a;
};
FinancialIndicator.prototype.abg = function (a) {
if (this.xr != null && !this.xr.c1()) {
this.rs(true);
}
};
FinancialIndicator.prototype.aa8 = function (a, b, c) {
if (isNaN_(b.x) || isNaN_(b.y)) {
return false;
}
var d = this.xr;
var e = 0;
if (d != null) {
e = d.e6(d.me);
}
if ((a.y >= e && a.y <= b.y) || (a.y <= e && a.y >= b.y)) {
return true;
}
return false;
};
FinancialIndicator.prototype.b3 = function () {
if (this.b4 == 0) {
return 1;
}
else {
return _super.prototype.b3.call(this);
}
};
FinancialIndicator.prototype.wp = function (a) {
if (this.w8 == null || this.xr == null) {
return Rect.empty;
}
var b = this.v9(a);
var c = this.cw.b2;
var d = this.cw.b1;
var e = this.getEffectiveViewport1(this.cw);
var f = new ScalerParams(0, c, d, this.xr.ch, e);
f.b = this.iy();
var g = this.an(this.w8, this.xa.h, this.y5(this.cw), this.y7(this.cw), a, true);
if (g == null) {
return Rect.empty;
}
var h = g[0];
var i = g[1];
var j = Math.abs(b.x - h[0]);
var k = Math.abs(b.x - i[0]);
var l = this.xr.el(this.xr.me, f);
var m = 1;
if (j < k) {
var n = h[0] - 0.5 * m;
var o = h[1];
var p = l;
return new Rect(0, n, Math.min(o, p), m, Math.max(o, p) - Math.min(o, p));
}
else {
var q = i[0] - 0.5 * m;
var r = i[1];
var s = l;
return new Rect(0, q, Math.min(r, s), m, Math.max(r, s) - Math.min(r, s));
}
};
FinancialIndicator.prototype.gw = function (a, b) {
var c = this.we(this.wj(a), true, false);
if (this.aa5 == 1) {
if (this.aa8(a, c, b)) {
return true;
}
}
if (this.aa5 == 1 || this.aa5 == 0) {
if (this.gv(a, b)) {
return true;
}
}
if (this.aa5 == 2) {
if (this.gz(a, b)) {
return true;
}
}
return false;
};
FinancialIndicator.prototype.pb = function (a, b, c, d) {
_super.prototype.pb.call(this, a, b, c, d);
if (this.w8 != null && typeCast(ISortingAxis_$type, this.w8) !== null) {
this.w8.i$i();
}
if (this.aa3.ce) {
this.aa3.cc.g$i(a, b, c, d);
}
if (d != null && this.yk.containsKey(d)) {
var e = this.yk.tryGetValue(d, d);
d = e.p1;
}
if (this.w8 != null && typeCast(ISortingAxis_$type, this.w8) !== null) {
a = 4;
b = 0;
c = this.dp.count;
}
switch (a) {
case 3:
if (this.aa7(b, c, d)) {
this.abi(b, c, d);
this.abg(true);
}
break;
case 2:
if (this.aa7(b, this.dp.count - b, d)) {
this.abi(b, this.dp.count - b, d);
this.abg(true);
}
break;
case 1:
if (this.aa7(b, this.dp.count - b, d)) {
var f = new Array(c);
for (var g = 0; g < c; g++) {
f[g] = 0;
}
this.indicatorColumn.s(b, f);
this.abi(b, this.dp.count - b, d);
this.abg(true);
}
break;
case 0:
if (this.aa7(b, this.dp.count - b, d)) {
this.indicatorColumn.v(b, c);
this.abi(b, this.dp.count - b, d);
this.abg(true);
}
break;
case 4:
if (this.aa7(b, this.dp.count - b, d)) {
this.indicatorColumn = new List$1(Number_$type, 2, this.dp.count);
var h = new Array(c);
for (var i = 0; i < c; i++) {
h[i] = 0;
}
this.indicatorColumn.s(0, h);
this.abi(b, this.dp.count - b, d);
this.abg(true);
}
break;
}
};
FinancialIndicator.prototype.get_aa4 = function () {
return 0;
};
Object.defineProperty(FinancialIndicator.prototype, "aa4", {
get: function () {
return this.get_aa4();
},
enumerable: false,
configurable: true
});
Object.defineProperty(FinancialIndicator.prototype, "abt", {
get: function () {
return this.c(FinancialIndicator.abj);
},
set: function (a) {
this.h(FinancialIndicator.abj, a);
},
enumerable: false,
configurable: true
});
FinancialIndicator.prototype.abd = function () {
return -1;
};
Object.defineProperty(FinancialIndicator.prototype, "indicatorColumn", {
get: function () {
return this._indicatorColumn;
},
set: function (a) {
this._indicatorColumn = a;
},
enumerable: false,
configurable: true
});
FinancialIndicator.prototype.ra = function (a, b, c, d) {
switch (b) {
case "XAxis":
this.aa3.ck();
break;
case "TrendLineType":
var e = EnumUtil.getEnumValue(TrendLineType_$type, d);
if (e != 0) {
this.aa3.cc = CategoryTrendLineManagerFactory.a(this.aa3.cc, this.w8, this.sx, this, this.ds);
}
break;
}
_super.prototype.ra.call(this, a, b, c, d);
if (this.aa3.ce && this.aa3.cc.g$e(a, b, c, d)) {
this.rs(false);
var f = typeCast(FinancialIndicatorView.$, this.cv);
if (f != null && f.ce) {
f.cc.g$e(a, b, c, d);
}
this.ql();
}
switch (b) {
case "FastItemsSource":
if (this.dp != null) {
this.indicatorColumn = new List$1(Number_$type, 2, this.dp.count);
var g = new Array(this.dp.count);
for (var h = 0; h < this.dp.count; h++) {
g[h] = 0;
}
this.indicatorColumn.s(0, g);
this.abi(0, this.dp.count, null);
if (this.xr != null && !this.xr.c1()) {
this.xp.b4.e(this.id);
this.rs(this.gg && c != null);
}
}
break;
case "TrendLineBrush":
this.rg(b);
break;
case FinancialIndicator.$$p[0]:
this.o5(true, this.cw);
this.sk();
this.rs(false);
this.ql();
break;
case "OpenColumn":
case "HighColumn":
case "LowColumn":
case "CloseColumn":
case "VolumeColumn":
if (this.dp != null) {
if (this.indicatorColumn.count != this.dp.count) {
this.indicatorColumn = new List$1(Number_$type, 2, this.dp.count);
var i = new Array(this.dp.count);
for (var j = 0; j < this.dp.count; j++) {
i[j] = 0;
}
this.indicatorColumn.s(0, i);
}
if (this.aa7(0, this.dp.count - 1, b)) {
this.abh();
}
}
break;
case "XAxis":
if (this.w8 != null && (typeCast(ISortingAxis_$type, this.w8) !== null || typeCast(ISortingAxis_$type, c) !== null)) {
this.abh();
}
break;
case "YAxis":
case FinancialIndicator.$$p[1]:
this.abh();
this.ql();
break;
case "TrendLineType":
this.ql();
break;
}
};
FinancialIndicator.prototype.i5 = function (a, b, c) {
if (this.indicatorColumn == null) {
return _super.prototype.i5.call(this, a, b, c);
}
var d = this.getEffectiveViewport1(this.cw);
var e = this.yz(this.cw.b2, this.cw.b1, d);
var f = new ScalerParams(0, this.cw.b2, this.cw.b1, this.w8.ch, d);
f.c = this.dc.wn;
return this.i7(this.indicatorColumn, a, this.w8, f, e, runOn(this, this.yy), b, c);
};
FinancialIndicator.prototype.ka = function (a, b) {
if (this.indicatorColumn == null) {
return _super.prototype.ka.call(this, a, b);
}
return this.kb(a, b, this.w8, runOn(this, this.yy), this.indicatorColumn);
};
FinancialIndicator.prototype.j8 = function (a, b) {
if (this.indicatorColumn == null) {
return _super.prototype.j8.call(this, a, b);
}
return this.j9(a, b, this.w8, runOn(this, this.yy), this.indicatorColumn);
};
FinancialIndicator.prototype.get_hd = function () {
return true;
};
FinancialIndicator.prototype.aa7 = function (a, b, c) {
if (c == null) {
return true;
}
if (this.aa9(a, b).contains(c)) {
return true;
}
return false;
};
FinancialIndicator.prototype.abi = function (a, b, c) {
this.aa6(a, b);
};
FinancialIndicator.prototype.ay = function (a) {
if (this.dp == null) {
return null;
}
if (a != null && a == this.xr) {
return this.aa2;
}
return null;
};
FinancialIndicator.prototype.gd = function (a) {
var b = this.dp != null ? this.dp.indexOf(a) : -1;
var c = this.cw.b2;
c = c.copy();
var d = this.cw.b1;
var e = new Rect(0, 0, 0, 1, 1);
var f = this.wn(this.cw);
if (b >= 0 && Rect.l_op_Inequality(c, null) && Rect.l_op_Inequality(d, null)) {
if (this.w8 != null) {
var g = new ScalerParams(0, e, e, this.w8.ch, f);
var h = this.w8.el(b, g);
if (h < c.left + 0.1 * c.width) {
h = h + 0.4 * c.width;
}
if (h > c.right - 0.1 * c.width) {
h = h - 0.4 * c.width;
}
c.x = h - 0.5 * c.width;
}
if (this.xr != null && this.indicatorColumn != null && b < this.indicatorColumn.count) {
var i = new ScalerParams(0, e, e, this.xr.ch, f);
i.b = this.iy();
var j = this.xr.el(this.indicatorColumn._inner[b], i);
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;
};
FinancialIndicator.prototype.he = function (a, b, c) {
var d = _super.prototype.he.call(this, a, b, c);
if (this.indicatorColumn == null || this.indicatorColumn.count == 0) {
d = false;
}
return d;
};
FinancialIndicator.prototype.aae = function (a, b) {
var _this = this;
_super.prototype.aae.call(this, a, b);
var c = b.b2;
var d = b.b1;
var e = this.getEffectiveViewport1(b);
var f = this.w8;
var g = this.xr;
var h = new ScalerParams(0, c, d, f.ch, e);
var i = new ScalerParams(0, c, d, g.ch, e);
i.b = this.iy();
var j = this.w8.ag();
var k = j[0];
var l = j[1];
a.h.clear();
a.p.clear();
a.s.clear();
var m = 0;
var n = typeCast(ISortingAxis_$type, this.w8);
if (n != null && n.i$b.count != this.dp.count) {
return;
}
m = this.yz(c, d, e);
var o = this.abd();
if (o == -1) {
o = this.trendLinePeriod;
}
var p = typeCast(FinancialIndicatorView.$, b);
if (p.ce) {
p.cc.prepareLineCore(a.s, this.trendLineType, this.indicatorColumn, o, function (q) { return _this.w8.el(q, h); }, function (q) { return _this.xr.el(q, i); }, ((function () {
var $ret = new TrendResolutionParams();
$ret.e = b.b4.b;
$ret.f = b.b4.c;
$ret.g = b.b4.d;
$ret.a = m;
$ret.d = _this.id;
$ret.i = d;
$ret.j = c;
$ret.h = e;
$ret.b = l;
$ret.c = k;
return $ret;
})()));
}
var q = this.w8.eo(2, h) - this.w8.eo(1, h);
for (var r = b.b4.c; r <= b.b4.d; ++r) {
var s = void 0;
if (n == null) {
s = b.b4.getBucket(r);
}
else {
var t = n.i$b._inner[r];
var u = n.i$d(t);
var v = this.indicatorColumn._inner[r];
var w = v;
var x = u;
while (r < b.b4.d) {
t = n.i$b._inner[r + 1];
x = n.i$d(t);
if (x - u > q) {
break;
}
r++;
var y = this.indicatorColumn._inner[r];
v = Math.min(v, y);
w = Math.max(w, y);
}
var z = NaN;
if (!isNaN_(u)) {
z = this.w8.el(u, h);
}
s = [z, v, w];
}
if (!isNaN_(s[0])) {
if (this.w8 != null && typeCast(ISortingAxis_$type, this.w8) !== null) {
s[0] = s[0] + m;
}
else {
s[0] = f.el(s[0], h) + m;
}
s[1] = g.el(s[1], i);
if (b.b4.b > 1 || n != null) {
s[2] = g.el(s[2], i);
}
else {
s[2] = s[1];
}
a.h.add(s);
}
}
return;
};
FinancialIndicator.prototype.o5 = function (a, b) {
_super.prototype.o5.call(this, a, b);
var c = b;
c.cf(a);
if (c.ce) {
c.cc.g$h();
}
};
FinancialIndicator.prototype.xi = function () {
switch (this.aa5) {
case 1: return 1;
case 2: return 1;
case 0: return 12;
}
return 1;
};
FinancialIndicator.prototype.aag = function (a, b) {
_super.prototype.aag.call(this, a, b);
var c = typeCast(FinancialIndicatorView.$, b);
var d = function (e) { return a.h._inner[e][0]; };
var e = function (f) { return a.h._inner[f][1]; };
if (c.ce) {
c.cc.g$h();
c.cc.g$k(a.s);
}
var f = b.b1;
var g = this.getEffectiveViewport1(b);
var h = 0;
var i = this.vb;
var j = this.aay;
if (b.b7(a)) {
c.cf(false);
if (a.h.count > 0) {
switch (this.aa5) {
case 0:
var k = CategorySeries.yp(a.h, a.h.count - 1, f, b.b2, false);
c.cj(a.h.count, d, e, true, k);
break;
case 1:
if (this.xr != null) {
h = this.y3(b);
}
else {
h = 0.5 * (f.top + f.bottom);
}
var l = CategorySeries.yp(a.h, a.h.count - 1, f, b.b2, false);
c.ch(a.h.count, d, e, true, h, l);
break;
case 2:
h = this.y3(b);
c.ci(a.h.count, d, e, true, h);
break;
default: throw new NotImplementedException(0);
}
}
b.b9(a);
}
var m = a.h;
var n = this.dp.count;
this.xh.a2(this, this.yg(), runOn(this, this.w0), this.y5(b), this.y7(b));
var o = false;
var p = this.xh.b;
if (p != null) {
o = true;
}
this.xh.ak = i;
this.xh.ag = i;
if (o) {
var q = new ScalerParams(0, b.b2, b.b1, this.w8.ch, g);
this.xh.f = false;
this.aad(m, -1, n, this.w8, q, b.r, -1);
}
this.xh.ad(c.c1, true, false, true, false);
this.xh.ad(c.c3, true, false, true, false);
this.xh.ad(c.c2, false, true, false, false);
c.c2._opacity = 0.8 * this.xh.j * this.h9;
this.xh.ad(c.c0, true, false, false, false);
this.xh.ak = j;
this.xh.ag = j;
if (o) {
var r = new ScalerParams(0, b.b2, b.b1, this.w8.ch, g);
this.xh.f = true;
this.aad(m, -1, n, this.w8, r, b.r, -1);
}
this.xh.ad(c.cx, true, false, true, false);
this.xh.ad(c.cz, true, false, true, false);
this.xh.ad(c.cy, false, true, false, false);
c.cy._opacity = 0.8 * this.xh.j * this.h9;
this.xh.ad(c.cw, true, false, false, false);
c.cl();
};
FinancialIndicator.prototype.sj = function () {
_super.prototype.sj.call(this);
if (this.index < 0) {
return;
}
if (this.aa3.ce) {
this.aa3.cm();
}
};
FinancialIndicator.prototype.abh = function () {
if (this.aa3.ce) {
this.aa3.cc.g$m();
}
this.aa6(0, this.indicatorColumn.count);
if (this.xr != null && !this.xr.c1()) {
this.rs(this.gg && this.d8);
}
};
FinancialIndicator.prototype.pz = function (a) {
_super.prototype.pz.call(this, a);
this.bc.exportTrendlineData(this, a, this.aa3.cc.g$n);
};
FinancialIndicator.prototype.bf = function (a) {
if (this.aa5 == 1 || this.aa5 == 2) {
return 3;
}
else if (this.aa5 == 0) {
return 2;
}
return a;
};
FinancialIndicator.$t = markType(FinancialIndicator, 'FinancialIndicator', FinancialSeries.$, [ITrendLineSeries_$type]);
FinancialIndicator.abj = DependencyProperty.i("ActualTrendLineBrush", Brush.$, FinancialIndicator.$, new PropertyMetadata(2, null, function (a, b) { return a.raisePropertyChanged("ActualTrendLineBrush", b.oldValue, b.newValue); }));
FinancialIndicator.$$p = markDep(DependencyProperty, PropertyMetadata, FinancialIndicator, 'raisePropertyChanged', ['DisplayType:aa5:abk', [IndicatorDisplayType_$type, enumGetBox(IndicatorDisplayType_$type, 0)], 'IgnoreFirst:abb:abl', [1, 0], 'TrendLineType::abr', [TrendLineType_$type, enumGetBox(TrendLineType_$type, 0)], 'TrendLineThickness::abq', [1, 1.5], 'TrendLinePeriod::abp', [1, 7], 'TrendLineBrush::abm', [Brush.$, null], 'TrendLineZIndex:abc:abs', [1, 1001], 'TrendLineDashArray:abu:abn', [DoubleCollection.$], 'TrendLineDashCap:abv:abo', [PenLineCap_$type, enumGetBox(PenLineCap_$type, 0)]]);
return FinancialIndicator;
}(FinancialSeries));
export { FinancialIndicator };
/**
* @hidden
*/
var FinancialIndicatorBucketCalculator = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(FinancialIndicatorBucketCalculator, _super);
function FinancialIndicatorBucketCalculator(a) {
var _this = _super.call(this, a) || this;
_this.f = null;
_this.f = a;
return _this;
}
FinancialIndicatorBucketCalculator.prototype.getBucket = function (a) {
var b = a * this.b;
var c = Math.min(b + this.b - 1, this.f.ca.indicatorColumn.count - 1);
var d = NaN;
var e = NaN;
for (var f = b; f <= c; ++f) {
var g = this.f.ca.indicatorColumn._inner[f];
if (!isNaN_(d)) {
if (!isNaN_(g)) {
d = Math.min(d, g);
e = Math.max(e, g);
}
}
else {
d = g;
e = g;
}
}
if (!isNaN_(d)) {
return [0.5 * (b + c), d, e];
}
return [NaN, NaN, NaN];
};
FinancialIndicatorBucketCalculator.$t = markType(FinancialIndicatorBucketCalculator, 'FinancialIndicatorBucketCalculator', FinancialBucketCalculator.$);
return FinancialIndicatorBucketCalculator;
}(FinancialBucketCalculator));
export { FinancialIndicatorBucketCalculator };
/**
* @hidden
*/
var FinancialIndicatorView = /** @class */ /*@__PURE__*/ (function (_super) {
__extends(FinancialIndicatorView, _super);
function FinancialIndicatorView(a) {
var _this = _super.call(this, a) || this;
_this.ca = null;
_this.cd = null;
_this.c1 = ((function () {
var $ret = new Path();
$ret.an = new PathGeometry();
return $ret;
})());
_this.cx = ((function () {
var $ret = new Path();
$ret.an = new PathGeometry();
return $ret;
})());
_this.c2 = ((function () {
var $ret = new Path();
$ret.an = new PathGeometry();
return $ret;
})());
_this.cy = ((function () {
var $ret = new Path();
$ret.an = new PathGeometry();
return $ret;
})());
_this.c3 = ((function () {
var $ret = new Path();
$ret.an = new PathGeometry();
return $ret;
})());
_this.cz = ((function () {
var $ret = new Path();
$ret.an = new PathGeometry();
return $ret;
})());
_this.c0 = ((function () {
var $ret = new Path();
$ret.an = new GeometryGroup();
return $ret;
})());
_this.cw = ((function () {
var $ret = new Path();
$ret.an = new GeometryGroup();
return $ret;
})());
_this.cb = null;
_this.ct = new Path();
_this.cv = new Path();
_this.cu = new Path();
_this.cs = new Path();
_this.cp = new Path();
_this.cr = new Path();
_this.cq = new Path();
_this.co = new Path();
_this.ca = a;
_this.cd = ((function () {
var $ret = new Pool$1(LineGeometry.$);
$ret.create = runOn(_this, _this.cn);
$ret.destroy = runOn(_this, _this.cg);
return $ret;
})());
return _this;
}
FinancialIndicatorView.prototype.b5 = function () {
return new FinancialIndicatorBucketCalculator(this);
};
FinancialIndicatorView.prototype.ax = function () {
_super.prototype.ax.call(this);
if (!this.r) {
this.ca.aay = Defaults.ah;
this.ca.aa5 = this.ca.aa4;
}
};
FinancialIndicatorView.prototype.cn = function () {
return new LineGeometry();
};
FinancialIndicatorView.prototype.cg = function (a) {
};
Object.defineProperty(FinancialIndicatorView.prototype, "cc", {
get: function () {
if (this.cb == null) {
this.cb = CategoryTrendLineManagerFactory.a(this.cb, this.f.a0(), this.f.sx, this.f, this.f.ds);
}
return this.cb;
},
set: function (a) {
this.cb = a;
},
enumerable: false,
configurable: true
});
Object.defineProperty(FinancialIndicatorView.prototype, "ce", {
get: function () {
return this.cb != null;
},
enumerable: false,
configurable: true
});
FinancialIndicatorView.prototype.cf = function (a) {
Extensions.e(this.c1.an);
Extensions.e(this.c2.an);
Extensions.e(this.c3.an);
Extensions.e(this.cx.an);
Extensions.e(this.cy.an);
Extensions.e(this.cz.an);
Extensions.d(this.c0.an);
Extensions.d(this.cw.an);
if (a) {
this.cd.count = 0;
}
this.av();
};
FinancialIndicatorView.prototype.cl = function () {
};
FinancialIndicatorView.prototype.cj = function (a, b, c, d, e) {
IndicatorRenderer.g(a, b, c, d, this.b2, this.b1, this.c1, this.cx, this.b4.b, this.f.id, e);
this.av();
};
FinancialIndicatorView.prototype.ch = function (a, b, c, d, e, f) {
IndicatorRenderer.e(a, b, c, d, this.b2, this.b1, this.c1, this.c2, this.cx, this.cy, e, this.b4.b, this.f.id, f);
this.av();
};
FinancialIndicatorView.prototype.ci = function (a, b, c, d, e) {
IndicatorRenderer.f(a, b, c, d, this.b1, e, this.cd, this.c0, this.cw);
this.av();
};
FinancialIndicatorView.prototype.cm = function () {
this.ca.abt = null;
if (this.ca.trendLineBrush != null) {
this.ca.abt = this.ca.trendLineBrush;
}
else {
this.ca.abt = this.ca.vb;
}
};
FinancialIndicatorView.prototype.bi = function () {
_super.prototype.bi.call(this);
var a = this.bv();
this.ct.an = this.c1.an;
this.cv.an = this.c3.an;
this.cu.an = this.c2.an;
this.cs.an = this.c0.an;
this.cp.an = this.cx.an;
this.cr.an = this.cz.an;
this.cq.an = this.cy.an;
this.co.an = this.cw.an;
this.ct._stroke = a;
this.cv._stroke = a;
this.ct.ad = this.f.ie + 3;
this.cv.ad = this.f.ie + 3;
this.cu._fill = a;
this.cu._opacity = 1;
this.cs._stroke = a;
this.cs.ad = this.f.ie + 3;
this.cp._stroke = a;
this.cr._stroke = a;
this.cp.ad = this.f.ie + 3;
this.cr.ad = this.f.ie + 3;
this.cq._fill = a;
this.cq._opacity = 1;
this.co._stroke = a;
this.co.ad = this.f.ie + 3;
};
FinancialIndicatorView.prototype.bc = function (a, b) {
_super.prototype.bc.call(this, a, b);
if (a.d) {
if (b) {
if (this.ca.aa5 == 2) {
a.t(this.cs);
a.t(this.co);
}
else {
a.t(this.cu);
a.t(this.ct);
a.t(this.cv);
a.t(this.cq);
a.t(this.cp);
a.t(this.cr);
}
}
else {
if (this.ca.aa5 == 2) {
a.t(this.c0);
a.t(this.cw);
}
else {
a.t(this.c2);
a.t(this.c1);
a.t(this.c3);
a.t(this.cy);
a.t(this.cx);
a.t(this.cz);
}
}
}
};
FinancialIndicatorView.prototype.bb = function (a, b) {
if (a.d) {
if (this.ca.trendLineType != 0 && !b) {
var c = this.cc.g$n;
c.ad = this.ca.trendLineThickness;
c._stroke = this.ca.abt;
c.aj = this.ca.abv;
c.ai = this.ca.abu;
a.v(c);
}
}
_super.prototype.bb.call(this, a, b);
};
FinancialIndicatorView.prototype.aq = function (a) {
_super.prototype.aq.call(this, a);
this.f.bc.exportPathData(a, this.c0, "positiveColumnsShape", ["Positive", "Main"]);
this.f.bc.exportPathData(a, this.cw, "negativeColumnsShape", ["Negative"]);
this.f.bc.exportPathData(a, this.c1, "positive0", ["Positive", "Main"]);
this.f.bc.exportPathData(a, this.c3, "positive1", ["Positive"]);
this.f.bc.exportPathData(a, this.c2, "positive01", ["PositiveFill"]);
this.f.bc.exportPathData(a, this.cx, "negative0", ["Negative", "Main"]);
this.f.bc.exportPathData(a, this.cz, "negative1", ["Negative"]);
this.f.bc.exportPathData(a, this.cy, "negative01", ["NegativeFill"]);
};
FinancialIndicatorView.prototype.ck = function () {
if (this.ce) {
this.cb = CategoryTrendLineManagerFactory.a(this.cb, this.f.a0(), this.f.sx, this.f, this.f.ds);
}
};
FinancialIndicatorView.$t = markType(FinancialIndicatorView, 'FinancialIndicatorView', FinancialSeriesView.$);
return FinancialIndicatorView;
}(FinancialSeriesView));
export { FinancialIndicatorView };