/*
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 * as tslib_1 from "tslib";
import { HorizontalAnchoredCategorySeries } from "./HorizontalAnchoredCategorySeries";
import { IUnknownValuePlotting_$type } from "igniteui-react-core";
import { CategoryLineRasterizer } from "./CategoryLineRasterizer";
import { UnknownValuePlotting_$type } from "igniteui-react-core";
import { DependencyProperty } from "igniteui-react-core";
import { typeCast, runOn, enumGetBox, markType, markDep } from "igniteui-react-core";
import { Path } from "igniteui-react-core";
import { ScalerParams } from "./ScalerParams";
import { PropertyMetadata } from "igniteui-react-core";
import { AnchoredCategorySeriesView } from "./AnchoredCategorySeriesView";
import { ISortingAxis_$type } from "./ISortingAxis";
import { Color } from "igniteui-react-core";
/**
 * @hidden
 */
var AreaSeries = /** @class */ /*@__PURE__*/ (function (_super) {
    tslib_1.__extends(AreaSeries, _super);
    function AreaSeries() {
        var _this = _super.call(this) || this;
        _this.qv = null;
        _this.qv = new CategoryLineRasterizer();
        _this.ab = AreaSeries.$;
        _this.qe = 0;
        return _this;
    }
    AreaSeries.prototype.bf = function () {
        return new AreaSeriesView(this);
    };
    AreaSeries.prototype.nt = function () {
        return 1;
    };
    AreaSeries.prototype.i2 = function (a) {
        _super.prototype.i2.call(this, a);
        this.qu = a;
    };
    AreaSeries.prototype.get_ck = function () {
        return true;
    };
    AreaSeries.prototype.preferredCategoryMode = function (a) {
        return this.qe;
    };
    AreaSeries.prototype.dh = function (a, b) {
        var c = this.lv(this.ly(a), true, false);
        if (this.ql(a, c, b)) {
            return true;
        }
        if (this.dg(a, b)) {
            return true;
        }
        if (this.me(a, b)) {
            return true;
        }
        return false;
    };
    AreaSeries.prototype.h3 = function (a, b) {
        _super.prototype.h3.call(this, a, b);
        var c = b;
        c.c7();
    };
    AreaSeries.prototype.o1 = function (a, b) {
        var _this = this;
        _super.prototype.o1.call(this, a, b);
        var c = b.cn.d;
        var d = typeCast(AreaSeriesView.$, b);
        var e = a.f;
        var f = this.getEffectiveViewport1(d);
        this.nr.x(this, this.oc(), this.qb, runOn(this, this.nd), this.ok(b), this.ol(b));
        var g = false;
        var h = this.nr.c;
        if (h != null) {
            g = true;
        }
        if (g) {
            var i = new ScalerParams(0, b.bs, b.br, this.qb.ca, f);
            this.ox(e, -1, this.valueColumn.count, this.qb, i, b.n);
        }
        var j = d.di;
        var k = d.dj;
        var l = d.dk;
        var m = d.dl;
        this.nr.ae(j, true, false, true, true);
        this.nr.ae(k, true, false, true, true);
        this.nr.ae(l, false, true, false, false);
        this.nr.ae(m, false, true, false, false);
        if (b.cr(a)) {
            d.c9(e.count, e, true, c, this.eu, function (n, o, p, q, r) { return _this.pv(n, a.f.count, b); }, this.unknownValuePlotting, e.count == 1 ? null : this.pa(e, e.count - 1, b.br, b.bs, true));
            b.cu(a);
        }
        var n = this.fetchYAxis();
        l._opacity = this.nr.i * this.d6;
        m._opacity = 0.5 * this.nr.i * this.d6;
    };
    AreaSeries.prototype.i7 = function (a, b, c, d) {
        _super.prototype.i7.call(this, a, b, c, d);
        switch (b) {
            case AreaSeries.$$p[0]:
                this.no.m = this.unknownValuePlotting == 0;
                this.jl(false);
                this.it();
                break;
        }
    };
    Object.defineProperty(AreaSeries.prototype, "useHighMarkerFidelity", {
        get: function () {
            return this.of;
        },
        enumerable: true,
        configurable: true
    });
    AreaSeries.$t = markType(AreaSeries, 'AreaSeries', HorizontalAnchoredCategorySeries.$, [IUnknownValuePlotting_$type]);
    AreaSeries.$$p = markDep(DependencyProperty, PropertyMetadata, AreaSeries, 'raisePropertyChanged', ['UnknownValuePlotting::qx', [UnknownValuePlotting_$type, enumGetBox(UnknownValuePlotting_$type, 1)]]);
    return AreaSeries;
}(HorizontalAnchoredCategorySeries));
export { AreaSeries };
/**
 * @hidden
 */
var AreaSeriesView = /** @class */ /*@__PURE__*/ (function (_super) {
    tslib_1.__extends(AreaSeriesView, _super);
    function AreaSeriesView(a) {
        var _this = _super.call(this, a) || this;
        _this.c6 = null;
        _this.de = new Path();
        _this.dg = new Path();
        _this.df = new Path();
        _this.dh = new Path();
        _this.da = new Path();
        _this.dc = new Path();
        _this.db = new Path();
        _this.dd = new Path();
        _this.c6 = a;
        return _this;
    }
    AreaSeriesView.prototype.ap = function () {
        _super.prototype.ap.call(this);
        if (!this.n) {
            this.e.bj = 1;
        }
    };
    Object.defineProperty(AreaSeriesView.prototype, "di", {
        get: function () {
            return this.dg;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(AreaSeriesView.prototype, "dj", {
        get: function () {
            return this.dh;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(AreaSeriesView.prototype, "dk", {
        get: function () {
            return this.de;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(AreaSeriesView.prototype, "dl", {
        get: function () {
            return this.df;
        },
        enumerable: true,
        configurable: true
    });
    AreaSeriesView.prototype.c7 = function () {
        this.de.ak = null;
        this.df.ak = null;
        this.dg.ak = null;
        this.dh.ak = null;
        this.an();
    };
    AreaSeriesView.prototype.c8 = function (a, b, c, d, e, f, g) {
        this.c9(a, b, c, d, e, f, g, null);
    };
    AreaSeriesView.prototype.c9 = function (a, b, c, d, e, f, g, h) {
        this.c6.qv.a = typeCast(ISortingAxis_$type, this.cp.fetchXAxis()) !== null ? true : false;
        this.c6.qv.j(this.de, this.dg, this.df, this.dh, a, b, c, d, e, f, g, h);
        this.an();
    };
    AreaSeriesView.prototype.a9 = function () {
        _super.prototype.a9.call(this);
        this.da.ak = this.de.ak;
        this.dc.ak = this.dg.ak;
        this.db.ak = this.df.ak;
        this.dd.ak = this.dh.ak;
        var a = this.bl();
        this.da._fill = a;
        this.da._opacity = 1;
        this.db._fill = a;
        this.db._opacity = 1;
        this.dc._stroke = a;
        this.dc.ac = this.e.ey + 3;
        this.dd._stroke = a;
        this.dd.ac = this.e.ey + 3;
    };
    AreaSeriesView.prototype.a3 = function (a, b) {
        _super.prototype.a3.call(this, a, b);
        if (b) {
            a.s(this.da);
            a.s(this.db);
            a.s(this.dc);
            a.s(this.dd);
        }
        else {
            a.s(this.de);
            a.s(this.df);
            a.s(this.dg);
            a.s(this.dh);
        }
    };
    AreaSeriesView.prototype.ai = function (a) {
        _super.prototype.ai.call(this, a);
        this.e.a2.exportPathData(a, this.dg, "lowerShape", ["Lower"]);
        this.e.a2.exportPathData(a, this.dh, "upperShape", ["Upper", "Main"]);
        this.e.a2.exportPathData(a, this.df, "translucentShape", ["Translucent"]);
        this.e.a2.exportPathData(a, this.de, "fillShape", ["Fill"]);
    };
    AreaSeriesView.prototype.ac = function () {
        var a = new Color();
        a.colorString = "rgba(95,95,95,0.5)";
        this.e.lk = a;
        this.e.ev = 5;
        this.e.ew = 1;
        this.e.ex = -3;
    };
    AreaSeriesView.$t = markType(AreaSeriesView, 'AreaSeriesView', AnchoredCategorySeriesView.$);
    return AreaSeriesView;
}(AnchoredCategorySeriesView));
export { AreaSeriesView };
//# sourceMappingURL=AreaSeries_combined.js.map
