import { __extends } from "tslib";
import { Component, forwardRef, Input, ChangeDetectionStrategy } from '@angular/core';
import { IgxVerticalAnchoredCategorySeriesComponent } from "./igx-vertical-anchored-category-series-component";
import { IgxAnchoredCategorySeriesComponent } from "./igx-anchored-category-series-component";
import { IgxCategorySeriesComponent } from "./igx-category-series-component";
import { IgxMarkerSeriesComponent } from "./igx-marker-series-component";
import { IgxSeriesComponent } from "./igx-series-component";
import { BarSeries } from "./BarSeries";
import { toPoint, fromRect } from "igniteui-angular-core";
import * as i0 from "@angular/core";
/**
 * Represents a IgxDataChartComponent bar series.
*/
var IgxBarSeriesComponent = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(IgxBarSeriesComponent, _super);
    function IgxBarSeriesComponent() {
        return _super.call(this) || this;
    }
    IgxBarSeriesComponent.prototype.createImplementation = function () {
        return new BarSeries();
    };
    Object.defineProperty(IgxBarSeriesComponent.prototype, "i", {
        /**
                                     * @hidden
                                     */
        get: function () {
            return this._implementation;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBarSeriesComponent.prototype, "isBar", {
        /**
         * Gets whether the current series shows a bar shape.
        */
        get: function () {
            return this.i.ex;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBarSeriesComponent.prototype, "isMarkerlessDisplayPreferred", {
        /**
         * Overridden by derived series classes to indicate when marker-less display is preferred or not.
        */
        get: function () {
            return this.i.fl;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBarSeriesComponent.prototype, "radiusX", {
        /**
         * Gets or sets the x-radius of the ellipse that is used to round the corners of the bar.
        */
        get: function () {
            return this.i.acn;
        },
        set: function (v) {
            this.i.acn = +v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxBarSeriesComponent.prototype, "radiusY", {
        /**
         * Gets or sets the y-radius of the ellipse that is used to round the corners of the bar.
        */
        get: function () {
            return this.i.aco;
        },
        set: function (v) {
            this.i.aco = +v;
        },
        enumerable: false,
        configurable: true
    });
    /**
     * If possible, will return the best available value bounding box within the series that has the best value match for the world position provided.
    
    * @param world  * The world coordinate for which to get a value bounding box for
    */
    IgxBarSeriesComponent.prototype.getSeriesValueBoundingBox = function (world) {
        var iv = this.i.wl(toPoint(world));
        return fromRect(iv);
    };
    /**
     * Scrolls the series to display the item for the specified data item.
     * The series is scrolled by the minimum amount required to place the specified data item within
     * the central 80% of the visible axis.
    
    * @param item  * The data item (item) to scroll to.
    */
    IgxBarSeriesComponent.prototype.scrollIntoView = function (item) {
        var iv = this.i.gd(item);
        return (iv);
    };
    /**
     * For a category plotted series, returns the current width of the items within the categories. This only returns a value if the items have some form of width (e.g. columns, bars, etc.) otherwise 0 is returned.
    
    */
    IgxBarSeriesComponent.prototype.getItemSpan = function () {
        var iv = this.i.iw();
        return (iv);
    };
    IgxBarSeriesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: IgxBarSeriesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
    IgxBarSeriesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: IgxBarSeriesComponent, selector: "igx-bar-series", inputs: { radiusX: "radiusX", radiusY: "radiusY" }, providers: [{ provide: IgxVerticalAnchoredCategorySeriesComponent, useExisting: forwardRef(function () { return IgxBarSeriesComponent; }) }, { provide: IgxAnchoredCategorySeriesComponent, useExisting: forwardRef(function () { return IgxBarSeriesComponent; }) }, { provide: IgxCategorySeriesComponent, useExisting: forwardRef(function () { return IgxBarSeriesComponent; }) }, { provide: IgxMarkerSeriesComponent, useExisting: forwardRef(function () { return IgxBarSeriesComponent; }) }, { provide: IgxSeriesComponent, useExisting: forwardRef(function () { return IgxBarSeriesComponent; }) }], usesInheritance: true, ngImport: i0, template: "", isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
    return IgxBarSeriesComponent;
}(IgxVerticalAnchoredCategorySeriesComponent));
export { IgxBarSeriesComponent };
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: IgxBarSeriesComponent, decorators: [{
            type: Component,
            args: [{
                    selector: 'igx-bar-series',
                    template: "",
                    providers: [{ provide: IgxVerticalAnchoredCategorySeriesComponent, useExisting: forwardRef(function () { return IgxBarSeriesComponent; }) }, { provide: IgxAnchoredCategorySeriesComponent, useExisting: forwardRef(function () { return IgxBarSeriesComponent; }) }, { provide: IgxCategorySeriesComponent, useExisting: forwardRef(function () { return IgxBarSeriesComponent; }) }, { provide: IgxMarkerSeriesComponent, useExisting: forwardRef(function () { return IgxBarSeriesComponent; }) }, { provide: IgxSeriesComponent, useExisting: forwardRef(function () { return IgxBarSeriesComponent; }) }],
                    changeDetection: ChangeDetectionStrategy.OnPush
                }]
        }], ctorParameters: function () { return []; }, propDecorators: { radiusX: [{
                type: Input
            }], radiusY: [{
                type: Input
            }] } });
