import { __extends } from "tslib";
import { Component, forwardRef, Input, ChangeDetectionStrategy } from '@angular/core';
import { IgxSizeScaleComponent } from "./igx-size-scale-component";
import { IgxBrushScaleComponent } from "./igx-brush-scale-component";
import { IgxScatterBaseComponent } from "./igx-scatter-base-component";
import { IgxMarkerSeriesComponent } from "./igx-marker-series-component";
import { IgxSeriesComponent } from "./igx-series-component";
import { BubbleSeries } from "./BubbleSeries";
import { ensureBool } from "igniteui-angular-core";
import * as i0 from "@angular/core";
/**
 * Represents a IgxDataChartComponent bubble series.
*/
var IgxBubbleSeriesComponent = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(IgxBubbleSeriesComponent, _super);
    function IgxBubbleSeriesComponent() {
        return _super.call(this) || this;
    }
    IgxBubbleSeriesComponent.prototype.createImplementation = function () {
        return new BubbleSeries();
    };
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "i", {
        /**
                                     * @hidden
                                     */
        get: function () {
            return this._implementation;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "hasOnlyMarkers", {
        /**
         * Gets whether the series has only marker as visuals
        */
        get: function () {
            return this.i.ek;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "isColoredItemwise", {
        get: function () {
            return this.i.isColoredItemwise;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "radiusMemberPath", {
        /**
         * Gets or sets the radius mapping property for the current series object.
        */
        get: function () {
            return this.i.ad3;
        },
        set: function (v) {
            this.i.ad3 = v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "radiusScale", {
        /**
         * Gets or sets the radius size scale for the bubbles.
        */
        get: function () {
            var r = this.i.ac2;
            if (r == null) {
                return null;
            }
            if (!r.externalObject) {
                var e = IgxSizeScaleComponent._createFromInternal(r);
                if (e) {
                    e._implementation = r;
                }
                r.externalObject = e;
            }
            return r.externalObject;
        },
        set: function (v) {
            if (v != null && this._stylingContainer && v._styling)
                v._styling(this._stylingContainer, this, this);
            v == null ? this.i.ac2 = null : this.i.ac2 = v.i;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "labelMemberPath", {
        /**
         * Gets or sets the Label mapping property for the current series object.
        */
        get: function () {
            return this.i.adt;
        },
        set: function (v) {
            this.i.adt = v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "fillMemberPath", {
        /**
         * Gets or sets the fill mapping property for the current series object.
        */
        get: function () {
            return this.i.ado;
        },
        set: function (v) {
            this.i.ado = v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "fillScale", {
        /**
         * Gets or sets the brush scale for the fill brush of markers.
        */
        get: function () {
            var r = this.i.acz;
            if (r == null) {
                return null;
            }
            if (!r.externalObject) {
                var e = IgxBrushScaleComponent._createFromInternal(r);
                if (e) {
                    e._implementation = r;
                }
                r.externalObject = e;
            }
            return r.externalObject;
        },
        set: function (v) {
            if (v != null && this._stylingContainer && v._styling)
                v._styling(this._stylingContainer, this, this);
            v == null ? this.i.acz = null : this.i.acz = v.i;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "fillScaleUseGlobalValues", {
        /**
         * Gets or sets whether or not the FillScale uses global min/max values of FillMemberPath from multiple series.
         * This setting applies only if multiple series are using the same FillScale.
        */
        get: function () {
            return this.i.adb;
        },
        set: function (v) {
            this.i.adb = ensureBool(v);
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "markerOutlineUsesFillScale", {
        /**
         * Gets or sets whether or not the marker outline should use FillScale like the marker fill does.
         * This setting applies only if the current series has a FillScale set and it overrides MarkerOutline setting.
        */
        get: function () {
            return this.i.adc;
        },
        set: function (v) {
            this.i.adc = ensureBool(v);
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "markerOutlineBrightness", {
        /**
         * Gets or sets brightness of the marker outline. Using negative value will change marker outline to darker color and positive value will change marker outline to brighter color
         * Note you can use any values between minimum value of -1 (darkest outline) and maximum value of 1 (brightest outline)
        */
        get: function () {
            return this.i.adi;
        },
        set: function (v) {
            this.i.adi = +v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "markerBrushBrightness", {
        /**
         * Gets or sets brightness of the marker fill. Using negative value will change marker fill to darker color and positive value will change marker fill to brighter color
         * Note you can use any values between minimum value of -1 (darkest fill) and maximum value of 1 (brightest fill)
        */
        get: function () {
            return this.i.adh;
        },
        set: function (v) {
            this.i.adh = +v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "radiusScaleUseGlobalValues", {
        /**
         * Gets or sets the whether or not the RadiusScale uses global values of RadiusMemberPath from multiple series.
         * This setting applies only if multiple series are using the same RadiusScale.
        */
        get: function () {
            return this.i.add;
        },
        set: function (v) {
            this.i.add = ensureBool(v);
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "radiusMemberAsLegendLabel", {
        /**
         * Gets or sets the label displayed before series' radius value in the Data Legend.
        */
        get: function () {
            return this.i.adz;
        },
        set: function (v) {
            this.i.adz = v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "fillMemberAsLegendLabel", {
        /**
         * Gets or sets the label displayed before series' fill value in the Data Legend.
        */
        get: function () {
            return this.i.adk;
        },
        set: function (v) {
            this.i.adk = v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "radiusMemberAsLegendUnit", {
        /**
         * Gets or sets the unit displayed after series' radius value in the Data Legend.
        */
        get: function () {
            return this.i.ad1;
        },
        set: function (v) {
            this.i.ad1 = v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBubbleSeriesComponent.prototype, "fillMemberAsLegendUnit", {
        /**
         * Gets or sets the unit displayed after series' fill value in the Data Legend.
        */
        get: function () {
            return this.i.adm;
        },
        set: function (v) {
            this.i.adm = v;
        },
        enumerable: false,
        configurable: true
    });
    IgxBubbleSeriesComponent.prototype.findByName = function (name) {
        var baseResult = _super.prototype.findByName.call(this, name);
        if (baseResult) {
            return baseResult;
        }
        if (this.radiusScale && this.radiusScale.name && this.radiusScale.name == name) {
            return this.radiusScale;
        }
        if (this.fillScale && this.fillScale.name && this.fillScale.name == name) {
            return this.fillScale;
        }
        return null;
    };
    IgxBubbleSeriesComponent.prototype._styling = function (container, component, parent) {
        _super.prototype._styling.call(this, container, component, parent);
        this._inStyling = true;
        if (this.radiusScale && this.radiusScale._styling) {
            this.radiusScale._styling(container, component, this);
        }
        if (this.fillScale && this.fillScale._styling) {
            this.fillScale._styling(container, component, this);
        }
        this._inStyling = false;
    };
    IgxBubbleSeriesComponent.prototype.getItemValue = function (item, memberPathName) {
        var iv = this.i.ku(item, memberPathName);
        return (iv);
    };
    /**
     * Gets the value of a requested member path from the series.
    
    * @param memberPathName  * The property name of a valid member path for the series
    */
    IgxBubbleSeriesComponent.prototype.getMemberPathValue = function (memberPathName) {
        var iv = this.i.mi(memberPathName);
        return (iv);
    };
    IgxBubbleSeriesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: IgxBubbleSeriesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
    IgxBubbleSeriesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: IgxBubbleSeriesComponent, selector: "igx-bubble-series", inputs: { radiusMemberPath: "radiusMemberPath", radiusScale: "radiusScale", labelMemberPath: "labelMemberPath", fillMemberPath: "fillMemberPath", fillScale: "fillScale", fillScaleUseGlobalValues: "fillScaleUseGlobalValues", markerOutlineUsesFillScale: "markerOutlineUsesFillScale", markerOutlineBrightness: "markerOutlineBrightness", markerBrushBrightness: "markerBrushBrightness", radiusScaleUseGlobalValues: "radiusScaleUseGlobalValues", radiusMemberAsLegendLabel: "radiusMemberAsLegendLabel", fillMemberAsLegendLabel: "fillMemberAsLegendLabel", radiusMemberAsLegendUnit: "radiusMemberAsLegendUnit", fillMemberAsLegendUnit: "fillMemberAsLegendUnit" }, providers: [{ provide: IgxScatterBaseComponent, useExisting: forwardRef(function () { return IgxBubbleSeriesComponent; }) }, { provide: IgxMarkerSeriesComponent, useExisting: forwardRef(function () { return IgxBubbleSeriesComponent; }) }, { provide: IgxSeriesComponent, useExisting: forwardRef(function () { return IgxBubbleSeriesComponent; }) }], usesInheritance: true, ngImport: i0, template: "", isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
    return IgxBubbleSeriesComponent;
}(IgxScatterBaseComponent));
export { IgxBubbleSeriesComponent };
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: IgxBubbleSeriesComponent, decorators: [{
            type: Component,
            args: [{
                    selector: 'igx-bubble-series',
                    template: "",
                    providers: [{ provide: IgxScatterBaseComponent, useExisting: forwardRef(function () { return IgxBubbleSeriesComponent; }) }, { provide: IgxMarkerSeriesComponent, useExisting: forwardRef(function () { return IgxBubbleSeriesComponent; }) }, { provide: IgxSeriesComponent, useExisting: forwardRef(function () { return IgxBubbleSeriesComponent; }) }],
                    changeDetection: ChangeDetectionStrategy.OnPush
                }]
        }], ctorParameters: function () { return []; }, propDecorators: { radiusMemberPath: [{
                type: Input
            }], radiusScale: [{
                type: Input
            }], labelMemberPath: [{
                type: Input
            }], fillMemberPath: [{
                type: Input
            }], fillScale: [{
                type: Input
            }], fillScaleUseGlobalValues: [{
                type: Input
            }], markerOutlineUsesFillScale: [{
                type: Input
            }], markerOutlineBrightness: [{
                type: Input
            }], markerBrushBrightness: [{
                type: Input
            }], radiusScaleUseGlobalValues: [{
                type: Input
            }], radiusMemberAsLegendLabel: [{
                type: Input
            }], fillMemberAsLegendLabel: [{
                type: Input
            }], radiusMemberAsLegendUnit: [{
                type: Input
            }], fillMemberAsLegendUnit: [{
                type: Input
            }] } });
