/*
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 { RadialBucketCalculator } from "./RadialBucketCalculator";
import { markType, Point_$type, enumGetBox, typeCast, runOn, markDep } from "igniteui-angular-core";
import { isNaN_, intDivide, isInfinity } from "igniteui-angular-core";
import { RadialBase } from "./RadialBase";
import { CategoryLineRasterizer } from "./CategoryLineRasterizer";
import { DependencyProperty } from "igniteui-angular-core";
import { TrendLineType_$type } from "igniteui-angular-core";
import { Brush } from "igniteui-angular-core";
import { PenLineCap_$type } from "igniteui-angular-core";
import { DoubleCollection } from "igniteui-angular-core";
import { RadialFrame } from "./RadialFrame";
import { ScalerParams } from "./ScalerParams";
import { Rect } from "igniteui-angular-core";
import { DataLegendSeriesValueInfo } from "igniteui-angular-core";
import { DataLegendSeriesContext } from "igniteui-angular-core";
import { List$1 } from "igniteui-angular-core";
import { AxisRange } from "./AxisRange";
import { NumericAxisBase } from "./NumericAxisBase";
import { IFastItemsSource_$type } from "igniteui-angular-core";
import { RadialBaseView } from "./RadialBaseView";
import { CollisionAvoider } from "./CollisionAvoider";
import { Clipper } from "igniteui-angular-core";
import { TrendResolutionParams } from "./TrendResolutionParams";
import { RadialTrendLineManager } from "./RadialTrendLineManager";
import { CategoryMarkerManager } from "./CategoryMarkerManager";
import { PropertyMetadata } from "igniteui-angular-core";
import { stringIsNullOrEmpty } from "igniteui-angular-core";
/**
 * @hidden
 */
var AnchoredRadialBucketCalculator = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(AnchoredRadialBucketCalculator, _super);
    function AnchoredRadialBucketCalculator(a) {
        var _this = _super.call(this, a) || this;
        _this.f = null;
        _this.f = a;
        return _this;
    }
    AnchoredRadialBucketCalculator.prototype.getBucket = function (a) {
        var b = this.f.cw.s3;
        var c = Math.min(a * this.b, b.count - 1);
        var d = Math.min(c + this.b - 1, b.count - 1);
        var e = NaN;
        var f = NaN;
        for (var g = c; g <= d; ++g) {
            var h = b.item(g);
            if (!isNaN_(e)) {
                if (!isNaN_(h)) {
                    e = Math.min(e, h);
                    f = Math.max(f, h);
                }
            }
            else {
                e = h;
                f = h;
            }
        }
        if (!isNaN_(e)) {
            return [0.5 * (c + d), e, f];
        }
        return [0.5 * (c + d), NaN, NaN];
    };
    AnchoredRadialBucketCalculator.$t = markType(AnchoredRadialBucketCalculator, 'AnchoredRadialBucketCalculator', RadialBucketCalculator.$);
    return AnchoredRadialBucketCalculator;
}(RadialBucketCalculator));
export { AnchoredRadialBucketCalculator };
/**
 * @hidden
 */
var AnchoredRadialSeries = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(AnchoredRadialSeries, _super);
    function AnchoredRadialSeries() {
        var _this = _super.call(this) || this;
        _this.sy = null;
        _this.s2 = null;
        _this.t5 = { $type: Point_$type, x: 0, y: 0 };
        _this.s0 = null;
        _this.sz = null;
        _this.s0 = new RadialFrame(3);
        _this.sy = new CategoryLineRasterizer();
        return _this;
    }
    AnchoredRadialSeries.prototype.bx = function () {
        return new AnchoredRadialSeriesView(this);
    };
    AnchoredRadialSeries.prototype.ku = function () {
        _super.prototype.ku.call(this);
        this.rk = null;
        this.rr = null;
    };
    AnchoredRadialSeries.prototype.hw = function (a, b) {
        var c = this.jq(b);
        if (c == AnchoredRadialSeries.$$p[2]) {
            return this.hx(a, b, this.tj);
        }
        return _super.prototype.hw.call(this, a, b);
    };
    AnchoredRadialSeries.prototype.ly = function (a) {
        _super.prototype.ly.call(this, a);
        this.sx = a;
    };
    AnchoredRadialSeries.prototype.hj = function (a, b) {
        return this.hk(a, b, this.rk, null, this.s3);
    };
    AnchoredRadialSeries.prototype.hh = function (a, b) {
        return this.hi(a, b, this.rk, null, this.s3);
    };
    AnchoredRadialSeries.prototype.f3 = function (a, b, c, d, e) {
        if (this.s3 == null) {
            return Number.POSITIVE_INFINITY;
        }
        return this.f4(a, b, this.rk, d, e, this.s3.count, null);
    };
    AnchoredRadialSeries.prototype.gj = function (a, b, c) {
        var d = this.getEffectiveViewport1(this.b0);
        var e = this.s8(this.rk, this.b0.bv, this.b0.bu, d);
        var f = new ScalerParams(0, this.b0.bv, this.b0.bu, this.rk.cg, d);
        f.c = this.cd.su;
        return this.gl(this.s3, a, this.rk, f, e, null, b, c);
    };
    AnchoredRadialSeries.prototype.pl = function (a, b, c) {
        if (this.rr == null || this.rk == null || this.b0 == null || this.b0.bv.isEmpty || this.b0.bu.isEmpty) {
            return { $type: Point_$type, x: NaN, y: NaN };
        }
        var d = this.getEffectiveViewport1(this.b0);
        var e = new ScalerParams(0, this.b0.bv, this.b0.bu, this.rr.cg, d);
        e.c = this.getEffectiveViewport1(this.b0);
        var f = this.gj(a, b, c);
        f = this.rr.ei(f, e);
        var g = this.rs.c(a);
        if (!b && this.rk != null) {
            var h = this.hj(a, c);
            var i = this.hh(a, c);
            var j = this.s8(this.rk, this.b0.bv, this.b0.bu, d);
            var k = new ScalerParams(0, this.b0.bv, this.b0.bu, this.rk.cg, d);
            k.c = this.cd.su;
            var l = this.f3(a, h, this.rk, k, j);
            var m = this.f3(a, i, this.rk, k, j);
            if (m <= l) {
                g = this.rk.ei(i, k) + j;
            }
            else {
                g = this.rk.ei(h, k) + j;
            }
        }
        var n = this.rs.d(g, f, this.b0.bv, this.b0.bu);
        var o = this.rs.e(g, f, this.b0.bv, this.b0.bu);
        return { $type: Point_$type, x: n, y: o };
    };
    Object.defineProperty(AnchoredRadialSeries.prototype, "s3", {
        get: function () {
            return this.s2;
        },
        set: function (a) {
            if (this.s2 != a) {
                var b = this.s2;
                this.s2 = a;
                this.raisePropertyChanged("ValueColumn", b, this.s2);
            }
        },
        enumerable: false,
        configurable: true
    });
    AnchoredRadialSeries.prototype.getDataLegendSeriesContextAt = function (a, b) {
        var c = new DataLegendSeriesValueInfo();
        c.a = 0;
        c.l = this.gj({ $type: Point_$type, x: a, y: b }, false, false);
        c.p = this.tj != null ? this.tj : "Value";
        c.q = this.tf != null ? this.tf : "V:";
        c.r = this.th != null ? this.th : "";
        var d = new DataLegendSeriesContext();
        d.f = ((function () {
            var $ret = new List$1(DataLegendSeriesValueInfo.$, 0);
            $ret.add(c);
            return $ret;
        })());
        d.b = this.av();
        return d;
    };
    Object.defineProperty(AnchoredRadialSeries.prototype, "t1", {
        get: function () {
            return this.c(AnchoredRadialSeries.tq);
        },
        set: function (a) {
            this.h(AnchoredRadialSeries.tq, a);
        },
        enumerable: false,
        configurable: true
    });
    AnchoredRadialSeries.prototype.ap = function (a) {
        if (a != null && a == this.rk && this.s3 != null && this.s3.count > 0) {
            return new AxisRange(0, this.s3.count - 1);
        }
        if (a != null && a == this.rr && this.s3 != null && this.s3.count > 0) {
            return new AxisRange(this.s3.minimum, this.s3.maximum);
        }
        return null;
    };
    AnchoredRadialSeries.prototype.l3 = function (a, b, c, d) {
        _super.prototype.l3.call(this, a, b, c, d);
        if (this.sx.cx.g$b(a, b, c, d)) {
            this.mh(false);
            this.lo();
        }
        var e = typeCast(NumericAxisBase.$, this.rr);
        switch (b) {
            case "FastItemsSource":
                if (typeCast(IFastItemsSource_$type, c) !== null) {
                    c.deregisterColumn(this.s3);
                    this.s3 = null;
                }
                if (typeCast(IFastItemsSource_$type, d) !== null) {
                    this.s3 = this.ch(this.tj);
                    this.sx.cs.e(this.ft);
                }
                if (e != null && !e.c0()) {
                    this.sx.cs.e(this.ft);
                    this.mh(false);
                }
                break;
            case AnchoredRadialSeries.$$p[2]:
                if (this.ck != null) {
                    this.ck.deregisterColumn(this.s3);
                    this.s3 = this.ch(this.tj);
                }
                break;
            case "ValueColumn":
                if (e != null && !e.c0()) {
                    this.sx.cs.e(this.ft);
                    this.mh(false);
                }
                break;
            case "TrendLineBrush":
                this.mv();
                break;
            case "TrendLineType":
                this.lo();
                break;
        }
    };
    AnchoredRadialSeries.prototype.k0 = function (a, b, c, d) {
        switch (a) {
            case 4:
            case 1:
            case 0:
                this.sx.cs.e(this.ft);
                break;
        }
        this.sx.cx.g$e(a, b, c, d);
        switch (a) {
            case 4:
                if (this.rr != null && !this.rr.c0()) {
                    this.mh(true);
                }
                break;
            case 1:
                if (this.rr != null && !this.rr.c0()) {
                    this.mh(true);
                }
                break;
            case 0:
                if (this.rr != null && !this.rr.c0()) {
                    this.mh(true);
                }
                break;
            case 2:
                if (this.tj != null && this.sx.cs.b > 0 && this.rr != null && !this.rr.c0()) {
                    this.mh(true);
                }
                break;
            case 3:
                if (d == this.tj) {
                    if (this.rr != null && !this.rr.c0()) {
                        this.mh(true);
                    }
                }
                break;
        }
    };
    AnchoredRadialSeries.prototype.e9 = function (a, b, c) {
        var d = _super.prototype.e9.call(this, a, b, c);
        var e = c;
        if (this.ck == null || this.ck.count == 0 || this.rk == null || this.s3 == null || this.rk.le == 0 || this.rr == null || isInfinity(this.rr.lv) || isInfinity(this.rr.lu) || e.cs.b < 1) {
            d = false;
        }
        return d;
    };
    AnchoredRadialSeries.prototype.getOffsetValue = function () {
        return this.s8(this.rk, this.b0.bv, this.b0.bu, this.getEffectiveViewport1(this.b0));
    };
    AnchoredRadialSeries.prototype.getCategoryWidth = function () {
        return this.rk.getCategorySize(this.b0.bv, this.b0.bu, this.getEffectiveViewport1(this.b0));
    };
    AnchoredRadialSeries.prototype.get_s6 = function () {
        return false;
    };
    Object.defineProperty(AnchoredRadialSeries.prototype, "s6", {
        get: function () {
            return this.get_s6();
        },
        enumerable: false,
        configurable: true
    });
    AnchoredRadialSeries.prototype.get_c6 = function () {
        return true;
    };
    AnchoredRadialSeries.prototype.get_ej = function () {
        return this.rr != null && this.rr.cg;
    };
    AnchoredRadialSeries.prototype.s8 = function (a, b, c, d) {
        var e = 0;
        var f = this.preferredCategoryMode(a);
        if (f == 0 && a.categoryMode != 0) {
            f = 1;
        }
        switch (f) {
            case 0:
                e = 0;
                break;
            case 1:
                e = 0.5 * a.getCategorySize(b, c, d);
                break;
            case 2:
                e = a.getGroupCenter(this.se(), b, c, d);
                break;
        }
        if (a.cg) {
            e = -e;
        }
        return e;
    };
    AnchoredRadialSeries.prototype.sm = function (a, b) {
        var _this = this;
        var c = b.bv;
        var d = b.bu;
        var e = this.getEffectiveViewport1(b);
        var f = this.rk;
        var g = this.rr;
        var h = g.lv;
        var i = g.lu;
        a.f.clear();
        a.m.clear();
        a.p.clear();
        var j = this.qe();
        var k = 0;
        var l = b;
        var m = new CollisionAvoider();
        var n = 0;
        var o = b.cs.d;
        n = this.s8(f, c, d, e);
        l.cx.i = this.rr.nm;
        l.cx.h = this.rr.nl;
        l.cx.j = function (p, q) { return _this.s9(p, q, c, d); };
        l.cx.k = function (p, q) { return _this.ta(p, q, c, d); };
        var p = ((function () {
            var $ret = new Clipper(0, d, false);
            $ret.i = a.p;
            return $ret;
        })());
        var q = ((function () {
            var $ret = new TrendResolutionParams();
            $ret.c = b.cs.b;
            $ret.d = b.cs.c;
            $ret.e = o;
            $ret.a = n;
            $ret.b = _this.ft;
            $ret.f = d;
            $ret.g = c;
            return $ret;
        })());
        l.cx.l(a.p, this.s1, this.s3, this.tc, function (r) { return _this.rk.getScaledAngle(r); }, function (r) { return _this.rr.ns(r); }, q, p);
        var r = true;
        if (this.s7(b)) {
            o--;
        }
        for (var s = b.cs.c; s <= o; ++s) {
            var t = s;
            if (t * b.cs.b >= this.rk.le) {
                t -= intDivide((this.rk.le), b.cs.b);
            }
            var u = b.cs.getBucket(t);
            if (!isNaN_(u[0])) {
                u[0] = f.getScaledAngle(u[0]) + n;
                if (u[1] < h || u[1] > i) {
                    continue;
                }
                u[1] = g.ns(u[1]);
                if (b.cs.b > 1) {
                    if (u[2] < h || u[2] > i) {
                        continue;
                    }
                    u[2] = g.ns(u[2]);
                }
                else {
                    u[2] = u[1];
                }
                if ((isNaN_(u[1]) || isNaN_(u[2])) && r && this.s6 && this.s5()) {
                    o++;
                }
                else {
                    r = false;
                }
                a.f.add(u);
                if (j) {
                    var v = Math.min(t * b.cs.b, this.ck.count - 1);
                    var w = this.rs.d(u[0], u[1], c, d);
                    var x = this.rs.e(u[0], u[1], c, d);
                    var y = new Rect(0, w - 5, x - 5, 11, 11);
                    if (!isNaN_(w) && !isNaN_(x) && !isInfinity(w) && !isInfinity(x) && m.tryAdd(y)) {
                        a.m.add({ $type: Point_$type, x: w, y: x });
                        var z = b.ct.item(k);
                        z.al = t;
                        z.ak = v;
                        z.content.item = this.ck.item(v);
                        ++k;
                    }
                }
            }
            else {
                if (r && this.s6 && this.s5()) {
                    o++;
                }
            }
        }
        b.ct.count = k;
        return;
    };
    AnchoredRadialSeries.prototype.s9 = function (a, b, c, d) {
        return this.rs.d(a, b, c, d);
    };
    AnchoredRadialSeries.prototype.ta = function (a, b, c, d) {
        return this.rs.e(a, b, c, d);
    };
    AnchoredRadialSeries.prototype.s7 = function (a) {
        var b = a;
        return !this.s6 && b.cs.c == 0 && b.cs.d == this.rk.le;
    };
    AnchoredRadialSeries.prototype.sw = function (a, b, c) {
        var d = null;
        var e = c.bv;
        var f = c.bu;
        if (b > -1 && !e.isEmpty && !f.isEmpty) {
            var g = a._inner[0][0] < f.left - 2000 ? f.left - 10 : NaN;
            var h = f.bottom + 10;
            var i = a._inner[b][0] > f.right + 2000 ? f.right + 10 : NaN;
            var j = f.top - 10;
            d = new Clipper(1, g, h, i, j, false);
        }
        return d;
    };
    AnchoredRadialSeries.prototype.tp = function (a, b, c, d, e) {
        if (a.count > 0 && d.count > 0) {
            if (!e || this.s4()) {
                a.add(this.t5);
                a.add(a._inner[0]);
                d.add(this.t5);
                d.add(d._inner[0]);
            }
        }
    };
    AnchoredRadialSeries.prototype.s5 = function () {
        return !this.s4();
    };
    AnchoredRadialSeries.prototype.s4 = function () {
        var a = this.b0.bv;
        return !a.containsPoint({ $type: Point_$type, x: 0.5, y: 0.5 });
    };
    AnchoredRadialSeries.prototype.kx = function (a, b) {
        _super.prototype.kx.call(this, a, b);
        var c = b;
        if (a) {
            c.ct.clear();
        }
        c.cx.g$d();
    };
    AnchoredRadialSeries.prototype.sp = function (a, b) {
        var c = b.bv;
        var d = b.bu;
        var e = this.getEffectiveViewport1(b);
        var f = this.pq(b);
        var g = b;
        g.cx.g$g(a.p);
        CategoryMarkerManager.e(this, a.m, g.ct, this.qg);
        this.tm(b, a);
        g.cm();
        this.tl(d, c, e, f, g);
    };
    AnchoredRadialSeries.prototype.sv = function (a, b, c) {
        if (b < a || a < 0 || a > this.s3.count || b < 0 || b > this.s3.count || c == null) {
            return null;
        }
        var d = new Array((b - a) + 1);
        var e = c.cm;
        var f = null;
        if (e) {
            f = c.i$b;
        }
        for (var g = a; g <= b; g++) {
            var h = g;
            if (e) {
                h = f._inner[h];
            }
            d[g - a] = this.ck.item(g);
        }
        return d;
    };
    AnchoredRadialSeries.prototype.tn = function (a, b, c, d, e, f) {
        var g = this.bk != 1;
        this.ry.a1(this.ry.d, d.cm, a, b, c, d, e, f, true);
        this.ry.aa(this.fr);
        var h = this.ry.av;
        var i = null;
        var j = this.ck;
        var k = null;
        if (g && this.cd != null) {
            i = this.cd.a3.getHighlightingInfo(this, j, h.o, h.n, true);
            if (this.cd.a3.isCrossSeriesHighlight(this)) {
                k = this.cd.a3.getHighlightingInfo(this, j, h.o, h.n, true);
            }
            h.b = i;
        }
        h.f = f;
        this.sn(h);
        this.ry.y(this, i, f, g, h.m, this.cd.a3.totalHighlightingProgress);
    };
    AnchoredRadialSeries.prototype.to = function (a, b, c, d, e, f) {
        var g = this.bk != 1;
        this.ry.a1(this.ry.b, d.cm, a, b, c, d, e, f, false);
        this.ry.ab(this.fr);
        var h = this.ry.aw;
        var i = null;
        var j = this.ck;
        if (g && this.cd != null) {
            i = this.cd.a3.getHighlightingInfo(this, j, h.o, h.n, false);
            h.b = i;
        }
        h.f = f;
        this.so(h);
        this.ry.z(this, i, f, g, b < 0);
    };
    AnchoredRadialSeries.prototype.tm = function (a, b) {
        a.b3 = true;
        this.ry.az(this, this.r9(), runOn(this, this.rh), this.sc(a), this.sd(a));
        var c = this.ry.d;
        var d = c != null;
        var e = this.rk;
        if (e == null) {
            return;
        }
        var f = this.getEffectiveViewport1(a);
        var g = new ScalerParams(0, a.bv, a.bu, e.cg, f);
        var h = this.ck == null ? 0 : this.ck.count;
        var i = a;
        var j = b.f;
        var k = i.cs.c;
        var l = i.cs.d;
        var m = i.cs.b;
        var n = k * m;
        for (var o = 0; o < a.ct.count; o++) {
            var p = a.ct.item(o);
            var q = p.content;
            if (d) {
                var r = p.al;
                this.tn(j, r, h, e, g, a.q);
            }
            this.ry.ac(p, q);
        }
    };
    AnchoredRadialSeries.prototype.tl = function (a, b, c, d, e) {
        e.cy(a, b, c, d);
    };
    AnchoredRadialSeries.prototype.mv = function () {
        _super.prototype.mv.call(this);
        if (this.index < 0) {
            return;
        }
        this.sx.cz();
    };
    AnchoredRadialSeries.prototype.hz = function (a, b) {
        if (a == this.sx.cx.g$j) {
            return null;
        }
        return _super.prototype.hz.call(this, a, b);
    };
    AnchoredRadialSeries.prototype.en = function (a) {
        var b = this.b0.bv;
        b = b.copy();
        var c = this.b0.bu;
        var d = !b.isEmpty && !c.isEmpty && this.ck != null ? this.ck.indexOf(a) : -1;
        if (this.rk == null || this.s3 == null || this.rr == null) {
            return false;
        }
        if (d < 0 || d > this.s3.count - 1) {
            return false;
        }
        var e = this.rk.getScaledAngle(d);
        var f = this.rr.ns(this.s3.item(d));
        if (isNaN_(f)) {
            f = (this.rr.nl + this.rr.nm) / 2;
        }
        var g = 0.5 + (Math.cos(e) * f);
        var h = 0.5 + (Math.sin(e) * f);
        if (!isNaN_(g)) {
            if (g < b.left + 0.1 * b.width) {
                g = g + 0.4 * b.width;
                b.x = g - 0.5 * b.width;
            }
            if (g > b.right - 0.1 * b.width) {
                g = g - 0.4 * b.width;
                b.x = g - 0.5 * b.width;
            }
        }
        if (!isNaN_(h)) {
            if (h < b.top + 0.1 * b.height) {
                h = h + 0.4 * b.height;
                b.y = h - 0.5 * b.height;
            }
            if (h > b.bottom - 0.1 * b.height) {
                h = h - 0.4 * b.height;
                b.y = h - 0.5 * b.height;
            }
        }
        if (this.b8 != null) {
            this.b8.au(this.cd, b, true);
        }
        return d >= 0;
    };
    AnchoredRadialSeries.prototype.mj = function (a, b) {
        _super.prototype.mj.call(this, a, b);
        if (!this.ez) {
            this.b0.a2(b);
            return;
        }
        this.b0.a2(b);
        var c = typeCast(AnchoredRadialSeriesView.$, this.bz);
        c.cs.e(this.ft);
        if (this.cx(this.bz)) {
            return;
        }
        if (!this.et) {
            this.s0 = new RadialFrame(3);
            this.sm(this.s0, c);
        }
        this.et = false;
        this.sp(this.s0, c);
        this.ez = false;
    };
    AnchoredRadialSeries.prototype.mg = function (a, b, c, d, e) {
        _super.prototype.mg.call(this, a, b, c, d, e);
        var f = this.a6.a$h.item(d);
        var g = f;
        g.cs.e(this.ft);
        f.a1(c);
        if (this.cx(g)) {
            return;
        }
        if (this.sz == null) {
            this.sz = new RadialFrame(3);
        }
        this.sz.u();
        this.sm(this.sz, g);
        this.sp(this.sz, g);
    };
    AnchoredRadialSeries.prototype.k7 = function (a) {
        _super.prototype.k7.call(this, a);
        this.a8.exportTrendlineData(this, a, this.sx.cx.g$j);
    };
    AnchoredRadialSeries.$t = markType(AnchoredRadialSeries, 'AnchoredRadialSeries', RadialBase.$);
    AnchoredRadialSeries.tq = DependencyProperty.i("ActualTrendLineBrush", Brush.$, AnchoredRadialSeries.$, new PropertyMetadata(2, null, function (a, b) { return a.raisePropertyChanged("ActualTrendLineBrush", b.oldValue, b.newValue); }));
    AnchoredRadialSeries.$$p = markDep(DependencyProperty, PropertyMetadata, AnchoredRadialSeries, 'raisePropertyChanged', ['ValueMemberAsLegendLabel:tf:ty', [2, null], 'ValueMemberAsLegendUnit:th:tz', [2, null], 'ValueMemberPath:tj:t0', [2, null], 'TrendLineType:s1:tw', [TrendLineType_$type, enumGetBox(TrendLineType_$type, 0)], 'TrendLineThickness:tb:tv', [1, 1.5], 'TrendLinePeriod:tc:tu', [1, 7], 'TrendLineZIndex:td:tx', [1, 1], 'TrendLineBrush:t2:tr', [Brush.$, null], 'TrendLineDashArray:t3:ts', [DoubleCollection.$], 'TrendLineDashCap:t4:tt', [PenLineCap_$type, enumGetBox(PenLineCap_$type, 0)]]);
    return AnchoredRadialSeries;
}(RadialBase));
export { AnchoredRadialSeries };
/**
 * @hidden
 */
var AnchoredRadialSeriesView = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(AnchoredRadialSeriesView, _super);
    function AnchoredRadialSeriesView(a) {
        var _this = _super.call(this, a) || this;
        _this.cw = null;
        _this.cx = null;
        _this.cs = new AnchoredRadialBucketCalculator(_this);
        _this.cw = a;
        _this.cx = new RadialTrendLineManager();
        return _this;
    }
    AnchoredRadialSeriesView.prototype.cy = function (a, b, c, d) {
    };
    AnchoredRadialSeriesView.prototype.cz = function () {
        this.cw.t1 = null;
        if (this.cw.t2 != null) {
            this.cw.t1 = this.cw.t2;
        }
        else {
            this.cw.t1 = this.cw.oy;
        }
    };
    AnchoredRadialSeriesView.prototype.a5 = function (a, b) {
        if (a.d) {
            if (!b) {
            }
            if (this.cw.s1 != 0 && !b) {
                var c = this.cx.g$j;
                c.ac = this.cw.tb;
                c._stroke = this.cw.t1;
                c.ai = this.cw.t3;
                c.ad = this.cw.t4;
                a.u(c);
            }
        }
        _super.prototype.a5.call(this, a, b);
    };
    AnchoredRadialSeriesView.prototype.getDefaultTooltipTemplate = function () {
        var a = "<div class='ui-chart-default-tooltip-content'>";
        if (this.cw.rk.fz != null) {
            a += "<span>${item." + this.cw.rk.fz + "}</span><br/>";
        }
        a += "<span";
        var b = this.e.a6.a$r(this.e);
        if (!stringIsNullOrEmpty(b)) {
            a += " style='color:" + b + "'";
        }
        a += ">" + this.cw.title + ": </span><span class='ui-priority-primary'>" + "${item." + this.cw.tj + "}</span></div>";
        return a;
    };
    AnchoredRadialSeriesView.$t = markType(AnchoredRadialSeriesView, 'AnchoredRadialSeriesView', RadialBaseView.$);
    return AnchoredRadialSeriesView;
}(RadialBaseView));
export { AnchoredRadialSeriesView };
