/*
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 { SplineSeriesBase } from "./SplineSeriesBase";
import { CategoryLineRasterizer } from "./CategoryLineRasterizer";
import { typeCast, runOn, markType } from "igniteui-react-core";
import { Path } from "igniteui-react-core";
import { ScalerParams } from "./ScalerParams";
import { SplineSeriesBaseView } from "./SplineSeriesBaseView";
import { ISortingAxis_$type } from "./ISortingAxis";
import { Color } from "igniteui-react-core";
/**
 * @hidden
 */
export let SplineAreaSeries = /*@__PURE__*/ (() => {
    class SplineAreaSeries extends SplineSeriesBase {
        constructor() {
            super();
            this.tg = null;
            this.tg = new CategoryLineRasterizer();
            this.ab = SplineAreaSeries.$;
        }
        bp() {
            return new SplineAreaSeriesView(this);
        }
        p4() {
            return 1;
        }
        kk(a) {
            super.kk(a);
            this.th = a;
        }
        preferredCategoryMode(a) {
            return 0;
        }
        bv() {
            if (this.bw == 0) {
                return 2;
            }
            return super.bv();
        }
        jl(a, b) {
            super.jl(a, b);
            let c = b;
            c.dc();
        }
        dy(a, b) {
            let c = this.nt(this.nw(a), true, false);
            if (this.sx(a, c, b)) {
                return true;
            }
            if (this.dx(a, b)) {
                return true;
            }
            if (this.ol(a, b)) {
                return true;
            }
            return false;
        }
        rc(a, b) {
            super.rc(a, b);
            let c = this.p3.cr.d;
            let d = typeCast(SplineAreaSeriesView.$, b);
            let e = a.f;
            let f = this.getEffectiveViewport1(b);
            this.p2.a0(this, this.qm(), runOn(this, this.po), this.qu(b), this.qv(b));
            let g = false;
            let h = this.p2.b;
            if (h != null) {
                g = true;
            }
            if (g) {
                let i = new ScalerParams(0, b.bv, b.bu, this.sn.ca, f);
                this.q8(e, -1, this.valueColumn.count, this.sn, i, b.q);
            }
            let j = d.dn;
            let k = d.dp;
            let l = d.dq;
            let m = d.dr;
            this.p2.ad(j, true, false, true, true);
            this.p2.ad(k, true, false, true, true);
            this.p2.ad(l, false, true, false, false);
            this.p2.ad(m, false, true, false, false);
            l._opacity = this.p2.j * this.er;
            m._opacity = 0.5 * this.p2.j * this.er;
            if (b.cv(a)) {
                d.de(a.f.count, e, true, c, this.fq, (n, o, p, q, r) => this.r7(n, a.f.count, b), 1, a.f.count == 1 ? null : this.rl(e, e.count - 1, b.bu, b.bv, true));
                b.cy(a);
            }
            let n = this.fetchYAxis();
        }
        get useHighMarkerFidelity() {
            return this.qp;
        }
    }
    SplineAreaSeries.$t = /*@__PURE__*/ markType(SplineAreaSeries, 'SplineAreaSeries', SplineSeriesBase.$);
    return SplineAreaSeries;
})();
/**
 * @hidden
 */
export let SplineAreaSeriesView = /*@__PURE__*/ (() => {
    class SplineAreaSeriesView extends SplineSeriesBaseView {
        constructor(a) {
            super(a);
            this.db = null;
            this.dj = new Path();
            this.dl = new Path();
            this.dk = new Path();
            this.dm = new Path();
            this.df = new Path();
            this.dh = new Path();
            this.dg = new Path();
            this.di = new Path();
            this.db = a;
        }
        as() {
            super.as();
            if (!this.q) {
                this.e.bx = 1;
            }
        }
        get dn() {
            return this.dl;
        }
        get dp() {
            return this.dm;
        }
        get dq() {
            return this.dj;
        }
        get dr() {
            return this.dk;
        }
        dc() {
            this.dj.ak = null;
            this.dk.ak = null;
            this.dl.ak = null;
            this.dm.ak = null;
            this.aq();
        }
        dd(a, b, c, d, e, f, g) {
            this.de(a, b, c, d, e, f, g, null);
        }
        de(a, b, c, d, e, f, g, h) {
            this.db.tg.a = typeCast(ISortingAxis_$type, this.ct.fetchXAxis()) !== null ? true : false;
            this.db.tg.j(this.dj, this.dl, this.dk, this.dm, a, b, c, d, e, f, g, h);
            this.aq();
        }
        bc() {
            super.bc();
            this.df.ak = this.dj.ak;
            this.dh.ak = this.dl.ak;
            this.dg.ak = this.dk.ak;
            this.di.ak = this.dm.ak;
            let a = this.bo();
            this.df._fill = a;
            this.df._opacity = 1;
            this.dg._fill = a;
            this.dg._opacity = 1;
            this.dh._stroke = a;
            this.dh.ac = this.e.eu + 3;
            this.di._stroke = a;
            this.di.ac = this.e.eu + 3;
        }
        a6(a, b) {
            super.a6(a, b);
            if (b) {
                a.s(this.df);
                a.s(this.dg);
                a.s(this.dh);
                a.s(this.di);
            }
            else {
                a.s(this.dj);
                a.s(this.dk);
                a.s(this.dl);
                a.s(this.dm);
            }
        }
        al(a) {
            super.al(a);
            this.e.a5.exportPathData(a, this.dl, "lowerShape", ["Lower"]);
            this.e.a5.exportPathData(a, this.dm, "upperShape", ["Upper", "Main"]);
            this.e.a5.exportPathData(a, this.dk, "translucentShape", ["Translucent"]);
            this.e.a5.exportPathData(a, this.dj, "fillShape", ["Fill"]);
        }
        af() {
            let a = new Color();
            a.colorString = "rgba(95,95,95,0.5)";
            this.e.ni = a;
            this.e.fs = 5;
            this.e.ft = 1;
            this.e.fu = -3;
        }
    }
    SplineAreaSeriesView.$t = /*@__PURE__*/ markType(SplineAreaSeriesView, 'SplineAreaSeriesView', SplineSeriesBaseView.$);
    return SplineAreaSeriesView;
})();
//# sourceMappingURL=SplineAreaSeries_combined.js.map
