/*
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 { AnchoredRadialSeries } from "./AnchoredRadialSeries";
import { UnknownValuePlotting_$type } from "igniteui-react-core";
import { DependencyProperty } from "igniteui-react-core";
import { Array_$type, runOn, enumGetBox, markType, markDep } from "igniteui-react-core";
import { List$1 } from "igniteui-react-core";
import { Path } from "igniteui-react-core";
import { ScalerParams } from "./ScalerParams";
import { PropertyMetadata } from "igniteui-react-core";
import { AnchoredRadialSeriesView } from "./AnchoredRadialSeriesView";
import { Defaults } from "./Defaults";
import { Color } from "igniteui-react-core";
/**
 * @hidden
 */
export let RadialLineSeries = /*@__PURE__*/ (() => {
    class RadialLineSeries extends AnchoredRadialSeries {
        get_ex() {
            return true;
        }
        cg() {
            return new RadialLineSeriesView(this);
        }
        o0(a) {
            super.o0(a);
            this.x9 = a;
        }
        constructor() {
            super();
            this.ab = RadialLineSeries.$;
        }
        ac() {
            super.ac();
        }
        preferredCategoryMode(a) {
            return 0;
        }
        v9() {
            return true;
        }
        nj(a, b) {
            super.nj(a, b);
            let c = b;
            c.c4();
        }
        wo(a, b) {
            super.wo(a, b);
            let c = b.by;
            let d = b.bx;
            let e = a.f;
            let f = e.count;
            let g = new List$1(Array_$type, 2, f);
            let h = 0;
            for (let i = 0; i < f; i++) {
                let j = new Array(4);
                g.add(j);
                j[0] = this.vq.d(a.f._inner[i][0], a.f._inner[i][1], c, d);
                j[1] = this.vq.e(a.f._inner[i][0], a.f._inner[i][1], c, d);
                j[2] = this.vq.d(a.f._inner[i][0], a.f._inner[i][2], c, d);
                let k = a.f._inner[i][2];
                j[3] = this.vq.e(a.f._inner[i][0], k, c, d);
                if (k > h) {
                    h = k;
                }
            }
            let l = this.getEffectiveViewport1(b);
            this.vw.a2(this, this.v8(), runOn(this, this.vf), this.wb(b), this.wc(b));
            let m = false;
            let n = this.vw.b;
            if (n != null) {
                m = true;
            }
            if (m) {
                let o = new ScalerParams(0, b.by, b.bx, this.vi.ch, l);
                this.xq(e, -1, this.w2.count, this.vi, o, b.q);
            }
            let p = b;
            let q = p.dd;
            let r = p.de;
            let s = p.dc;
            this.vw.ad(q, true, false, true, false);
            this.vw.ad(r, true, false, true, false);
            this.vw.ad(s, false, true, false, false);
            s._opacity = 0.75 * this.vw.j;
            p.c5(f, g, false, this.ya, this.wv(g, f - 1, b), p.cv.b, this.hj);
        }
        o8(a, b, c, d) {
            super.o8(a, b, c, d);
            switch (b) {
                case RadialLineSeries.$$p[0]:
                    this.pp(false);
                    this.ol();
                    break;
            }
        }
        get_w5() {
            return true;
        }
    }
    RadialLineSeries.$t = /*@__PURE__*/ markType(RadialLineSeries, 'RadialLineSeries', AnchoredRadialSeries.$);
    RadialLineSeries.$$p = /*@__PURE__*/ markDep(DependencyProperty, PropertyMetadata, RadialLineSeries, 'raisePropertyChanged', ['UnknownValuePlotting:ya:yc', [UnknownValuePlotting_$type, /*@__PURE__*/ enumGetBox(UnknownValuePlotting_$type, 1)]]);
    return RadialLineSeries;
})();
/**
 * @hidden
 */
export let RadialLineSeriesView = /*@__PURE__*/ (() => {
    class RadialLineSeriesView extends AnchoredRadialSeriesView {
        constructor(a) {
            super(a);
            this.c3 = null;
            this.da = new Path();
            this.c9 = new Path();
            this.db = new Path();
            this.c7 = new Path();
            this.c6 = new Path();
            this.c8 = new Path();
            this.c3 = a;
        }
        au() {
            super.au();
            if (!this.q) {
                this.b4.ua = Defaults.e;
            }
        }
        get dd() {
            return this.da;
        }
        get de() {
            return this.db;
        }
        get dc() {
            return this.c9;
        }
        c4() {
            this.da.an = null;
            this.c9.an = null;
            this.db.an = null;
            this.c7.an = null;
            this.c6.an = null;
            this.c8.an = null;
            this.as();
        }
        c5(a, b, c, d, e, f, g) {
            this.cz.wx.m(this.da, this.c9, this.db, a, b, c, d, e, f, g);
            this.as();
        }
        bd() {
            super.bd();
        }
        be() {
            super.be();
            let a = this.br();
            this.c6.an = this.c9.an;
            this.c7.an = this.da.an;
            this.c8.an = this.db.an;
            this.c7._stroke = a;
            this.c7.ad = this.e.hk + 3;
            this.c8._stroke = a;
            this.c8.ad = this.e.hk + 3;
            this.c6._fill = a;
            this.c6._opacity = 1;
        }
        a8(a, b) {
            super.a8(a, b);
            if (a.d) {
                if (b) {
                    a.t(this.c6);
                    a.t(this.c7);
                    a.t(this.c8);
                }
                else {
                    a.t(this.c9);
                    a.t(this.da);
                    a.t(this.db);
                }
            }
        }
        an(a) {
            super.an(a);
            this.e.a9.exportPathData(a, this.da, "lowerShape", ["Lower", "Main"]);
            this.e.a9.exportPathData(a, this.db, "upperShape", ["Upper"]);
            this.e.a9.exportPathData(a, this.c9, "translucentShape", ["Translucent"]);
        }
        af() {
            let a = new Color();
            a.colorString = "rgba(95,95,95,0.5)";
            this.e.s6 = a;
            this.e.ir = 3;
            this.e.is = 1;
            this.e.it = 4;
            this.e.gj = false;
        }
    }
    RadialLineSeriesView.$t = /*@__PURE__*/ markType(RadialLineSeriesView, 'RadialLineSeriesView', AnchoredRadialSeriesView.$);
    return RadialLineSeriesView;
})();
