import { __extends } from "tslib";
import { Component, forwardRef, Input, ChangeDetectionStrategy } from '@angular/core';
import { ConsolidatedItemsPosition_$type } from "./ConsolidatedItemsPosition";
import { IgxHorizontalAnchoredCategorySeriesComponent } from "./igx-horizontal-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 { ColumnSeries } from "./ColumnSeries";
import { ensureEnum, toPoint, fromRect } from "igniteui-angular-core";
import * as i0 from "@angular/core";
/**
 * Represents a IgxDataChartComponent column series.
 * Compare values across categories by using vertical rectangles.
 * Use it when the order of categories is not important or for displaying
 * item counts such as a histogram.
*
* ```html
*     <igx-data-chart [dataSource]="data" >
*       <igx-category-x-axis
*         label="label"
*         #xAxis>
*       </igx-category-x-axis>
*       <igx-numeric-y-axis #yAxis>
*       </igx-numeric-y-axis>
*       <igx-column-series
*         [xAxis]="xAxis"
*         [yAxis]="yAxis"
*         valueMemberPath="value" >
*       </igx-column-series>
*     </igx-data-chart>
* ```
*/
var IgxColumnSeriesComponent = /** @class */ /*@__PURE__*/ (function (_super) {
    __extends(IgxColumnSeriesComponent, _super);
    function IgxColumnSeriesComponent() {
        return _super.call(this) || this;
    }
    IgxColumnSeriesComponent.prototype.createImplementation = function () {
        return new ColumnSeries();
    };
    Object.defineProperty(IgxColumnSeriesComponent.prototype, "i", {
        /**
                                     * @hidden
                                     */
        get: function () {
            return this._implementation;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxColumnSeriesComponent.prototype, "isColumn", {
        /**
         * Gets whether the current series shows a column shape.
        */
        get: function () {
            return this.i.dk;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxColumnSeriesComponent.prototype, "isMarkerlessDisplayPreferred", {
        /**
         * Overridden by derived series classes to indicate when marker-less display is preferred or not.
        */
        get: function () {
            return this.i.d5;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxColumnSeriesComponent.prototype, "radiusX", {
        /**
         * Gets or sets the x-radius of the ellipse that is used to round the corners of the column.
        */
        get: function () {
            return this.i.vn;
        },
        set: function (v) {
            this.i.vn = +v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxColumnSeriesComponent.prototype, "radiusY", {
        /**
         * Gets or sets the y-radius of the ellipse that is used to round the corners of the column.
        */
        get: function () {
            return this.i.vo;
        },
        set: function (v) {
            this.i.vo = +v;
        },
        enumerable: false,
        configurable: true
    });
    Object.defineProperty(IgxColumnSeriesComponent.prototype, "consolidatedColumnVerticalPosition", {
        /**
         * The positioning logic to use for columns which have been consolidated into a single visual element.
        */
        get: function () {
            return this.i.vl;
        },
        set: function (v) {
            this.i.vl = ensureEnum(ConsolidatedItemsPosition_$type, 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
    */
    IgxColumnSeriesComponent.prototype.getSeriesValueBoundingBox = function (world) {
        var iv = this.i.p3(toPoint(world));
        return fromRect(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.
    
    */
    IgxColumnSeriesComponent.prototype.getItemSpan = function () {
        var iv = this.i.ge();
        return (iv);
    };
    IgxColumnSeriesComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: IgxColumnSeriesComponent, deps: [], target: i0.ɵɵFactoryTarget.Component });
    IgxColumnSeriesComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: IgxColumnSeriesComponent, selector: "igx-column-series", inputs: { radiusX: "radiusX", radiusY: "radiusY", consolidatedColumnVerticalPosition: "consolidatedColumnVerticalPosition" }, providers: [{ provide: IgxHorizontalAnchoredCategorySeriesComponent, useExisting: forwardRef(function () { return IgxColumnSeriesComponent; }) }, { provide: IgxAnchoredCategorySeriesComponent, useExisting: forwardRef(function () { return IgxColumnSeriesComponent; }) }, { provide: IgxCategorySeriesComponent, useExisting: forwardRef(function () { return IgxColumnSeriesComponent; }) }, { provide: IgxMarkerSeriesComponent, useExisting: forwardRef(function () { return IgxColumnSeriesComponent; }) }, { provide: IgxSeriesComponent, useExisting: forwardRef(function () { return IgxColumnSeriesComponent; }) }], usesInheritance: true, ngImport: i0, template: "", isInline: true, changeDetection: i0.ChangeDetectionStrategy.OnPush });
    return IgxColumnSeriesComponent;
}(IgxHorizontalAnchoredCategorySeriesComponent));
export { IgxColumnSeriesComponent };
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: IgxColumnSeriesComponent, decorators: [{
            type: Component,
            args: [{
                    selector: 'igx-column-series',
                    template: "",
                    providers: [{ provide: IgxHorizontalAnchoredCategorySeriesComponent, useExisting: forwardRef(function () { return IgxColumnSeriesComponent; }) }, { provide: IgxAnchoredCategorySeriesComponent, useExisting: forwardRef(function () { return IgxColumnSeriesComponent; }) }, { provide: IgxCategorySeriesComponent, useExisting: forwardRef(function () { return IgxColumnSeriesComponent; }) }, { provide: IgxMarkerSeriesComponent, useExisting: forwardRef(function () { return IgxColumnSeriesComponent; }) }, { provide: IgxSeriesComponent, useExisting: forwardRef(function () { return IgxColumnSeriesComponent; }) }],
                    changeDetection: ChangeDetectionStrategy.OnPush
                }]
        }], ctorParameters: function () { return []; }, propDecorators: { radiusX: [{
                type: Input
            }], radiusY: [{
                type: Input
            }], consolidatedColumnVerticalPosition: [{
                type: Input
            }] } });
