/*
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 { PolarLineSeriesBase } from "./PolarLineSeriesBase";
import { UnknownValuePlotting_$type } from "igniteui-react-core";
import { DependencyProperty } from "igniteui-react-core";
import { runOn, enumGetBox, markType, markDep, Point_$type } from "igniteui-react-core";
import { Path } from "igniteui-react-core";
import { List$1 } from "igniteui-react-core";
import { PropertyMetadata } from "igniteui-react-core";
import { PolarLineSeriesBaseView } from "./PolarLineSeriesBaseView";
import { Defaults } from "./Defaults";
import { Color } from "igniteui-react-core";
/**
 * @hidden
 */
export let PolarAreaSeries = /*@__PURE__*/ (() => {
    class PolarAreaSeries extends PolarLineSeriesBase {
        bj() {
            return new PolarAreaSeries();
        }
        get_eu() {
            return true;
        }
        cs() {
            return new PolarAreaSeriesView(this);
        }
        zw() {
            return false;
        }
        qz(a) {
            super.qz(a);
            this.acs = a;
        }
        constructor() {
            super();
            this.ab = PolarAreaSeries.$;
        }
        acq(a) {
            let b = a;
            b.da();
        }
        acr(a, b) {
            if (a.m.count > 0) {
                let c = a.m._inner[0];
                let d = a.m._inner[a.m.count - 1];
                let e = c.x == d.x && c.y == d.y;
                if (!e) {
                    a.m.add(a.m._inner[0]);
                }
            }
            let f = b;
            f.db(a.m, this.id);
            this.y3.az(this, this.zv(), runOn(this, this.yl));
            let g = false;
            let h = this.y3.b;
            if (h != null) {
                g = true;
            }
            if (g) {
                this.aba(-1, this.zh.count, b.q);
            }
            let i = f.dh;
            let j = f.dg;
            this.y3.ad(i, true, false, true, true);
            this.y3.ad(j, false, true, false, false);
            j._opacity = this.y3.j * this.h9;
        }
        get_acn() {
            return true;
        }
        aci() {
            return this.act;
        }
    }
    PolarAreaSeries.$t = /*@__PURE__*/ markType(PolarAreaSeries, 'PolarAreaSeries', PolarLineSeriesBase.$);
    PolarAreaSeries.$$p = /*@__PURE__*/ markDep(DependencyProperty, PropertyMetadata, PolarAreaSeries, 'raisePropertyChanged', ['UnknownValuePlotting:act:acv', [UnknownValuePlotting_$type, /*@__PURE__*/ enumGetBox(UnknownValuePlotting_$type, 1)]]);
    return PolarAreaSeries;
})();
/**
 * @hidden
 */
export let PolarAreaSeriesView = /*@__PURE__*/ (() => {
    class PolarAreaSeriesView extends PolarLineSeriesBaseView {
        constructor(a) {
            super(a);
            this.c9 = null;
            this.df = new Path();
            this.de = new Path();
            this.dd = new Path();
            this.dc = new Path();
            this.c9 = a;
        }
        au() {
            super.au();
            if (!this.q) {
                this.c9.w8 = Defaults.e;
            }
        }
        get dg() {
            return this.de;
        }
        get dh() {
            return this.df;
        }
        da() {
            this.de.an = null;
            this.df.an = null;
            this.dc.an = null;
            this.dd.an = null;
            this.as();
        }
        db(a, b) {
            let c = new List$1(Point_$type, 1, a);
            this.c9.acf.d(this.df, c, b);
            this.c9.acf.d(this.de, c, b);
            this.as();
        }
        bd() {
            super.bd();
        }
        be() {
            super.be();
            let a = this.br();
            this.dd.an = this.df.an;
            this.dc.an = this.de.an;
            this.dd._stroke = a;
            this.dd.ad = this.e.ie + 3;
            this.dc._fill = a;
            this.dc._opacity = 1;
        }
        a8(a, b) {
            super.a8(a, b);
            if (a.d) {
                if (b) {
                    a.t(this.dc);
                    a.t(this.dd);
                }
                else {
                    a.t(this.de);
                    a.t(this.df);
                }
            }
        }
        an(a) {
            super.an(a);
            this.e.bc.exportPathData(a, this.df, "polarShape", ["Main"]);
            this.e.bc.exportPathData(a, this.de, "fillShape", ["Fill"]);
        }
        af() {
            let a = new Color();
            a.colorString = "rgba(95,95,95,0.5)";
            this.e.vz = a;
            this.e.jm = 5;
            this.e.jn = 5;
            this.e.jo = 5;
        }
    }
    PolarAreaSeriesView.$t = /*@__PURE__*/ markType(PolarAreaSeriesView, 'PolarAreaSeriesView', PolarLineSeriesBaseView.$);
    return PolarAreaSeriesView;
})();
