import { Component, ViewContainerRef, ViewChild, Input, ChangeDetectionStrategy } from '@angular/core';
import { AngularRenderer, AngularWrapper } from "igniteui-angular-core";
import { TypeRegistrar } from "igniteui-angular-core";
import { CategoryChart } from './CategoryChart';
import { CategoryChartType_$type } from './CategoryChartType';
import { CategorySeriesMarkerCollisionAvoidance_$type } from './CategorySeriesMarkerCollisionAvoidance';
import { CategoryTransitionInMode_$type } from './CategoryTransitionInMode';
import { TransitionInSpeedType_$type } from './TransitionInSpeedType';
import { fromBrushCollection, toBrushCollection, ensureEnum, ensureBool, NamePatcher } from "igniteui-angular-core";
import { IgxXYChartComponent } from './igx-xy-chart-component';
import { DataChartStylingDefaults } from './DataChartStylingDefaults';
import { DataSeriesType } from "igniteui-angular-core";
import { IgxDataContext } from "igniteui-angular-core";
import { IgxCategoryXAxisComponent } from './igx-category-x-axis-component';
import { IgxNumericYAxisComponent } from './igx-numeric-y-axis-component';
import { AxisRangeBufferMode_$type } from './AxisRangeBufferMode';
import { AutoMarginsAndAngleUpdateMode_$type } from './AutoMarginsAndAngleUpdateMode';
import * as i0 from "@angular/core";
/**
 * Represents a chart with an ordinal X-axis and a numeric Y-axis.
*
* **Ignite UI for Angular Category Chart** - [Documentation](https://www.infragistics.com/products/ignite-ui-angular/angular/components/CategoryChart.html)
*
* The Ignite UI Category Chart is a lightweight, highly performant chart. It can be easily configured to display category data using an extremely simple and intuitive API. All you need to do is provide your data to the chart and it will take care of everything else.
*
* Example:
*
* ```html
* <igx-category-chart
*     [dataSource]="data"    >
* </igx-category-chart>
* ```
*/
export let IgxCategoryChartComponent = /*@__PURE__*/ (() => {
    class IgxCategoryChartComponent extends IgxXYChartComponent {
        constructor(renderer, _elRef, ngZone, injector, componentFactoryResolver) {
            super();
            this.renderer = renderer;
            this._elRef = _elRef;
            this.ngZone = ngZone;
            this.injector = injector;
            this.componentFactoryResolver = componentFactoryResolver;
            this._dataSource = null;
            this._defaultTooltips = null;
            if (this._styling) {
                NamePatcher.ensureStylablePatched(Object.getPrototypeOf(this));
            }
            this._zoneRunner = (act) => ngZone.run(act);
            this.container = renderer.createElement("div");
            renderer.appendChild(_elRef.element.nativeElement, this.container);
            renderer.setStyle(this.container, "display", "block");
            renderer.setStyle(this.container, "width", "100%");
            renderer.setStyle(this.container, "height", "100%");
            var root;
            root = this.container;
            if (this.container != null) {
                root = this.container;
            }
            var ren = new AngularRenderer(root, this.renderer, window.document, this.ngZone, true, DataChartStylingDefaults);
            this._wrapper = ren;
            var chart = this.i;
            this._chart = chart;
            if (chart.xAxis) {
                let x = new IgxCategoryXAxisComponent();
                x._provideRenderer(ren);
                x._implementation = chart.xAxis;
                chart.xAxis.externalObject = x;
            }
            if (chart.yAxis) {
                let y = new IgxNumericYAxisComponent();
                y._provideRenderer(ren);
                y._implementation = chart.yAxis;
                chart.yAxis.externalObject = y;
            }
            chart.provideContainer(ren);
            this.bindData();
            chart.notifyResized();
            ren.addSizeWatcher(() => {
                this._chart.notifyResized();
            });
        }
        set height(value) {
            this._height = value;
            this.renderer.setStyle(this._elRef.element.nativeElement, "height", value);
            this._chart.notifyResized();
        }
        get height() {
            return this._height;
        }
        set width(value) {
            this._width = value;
            this.renderer.setStyle(this._elRef.element.nativeElement, "width", value);
            this._chart.notifyResized();
        }
        get width() {
            return this._width;
        }
        ngOnDestroy() {
            this._chart.destroy();
            this._wrapper.destroy();
        }
        createImplementation() {
            return new CategoryChart();
        }
        get i() {
            return this._implementation;
        }
        createSeriesComponent(type) {
            if (TypeRegistrar.isRegistered(type)) {
                let s = TypeRegistrar.create(type);
                s.owner = this;
                s._provideRenderer(this.renderer);
                return s;
            }
            else {
                //we shouldn't get here, hopefully.
                throw Error("series type not loaded: " + type);
            }
        }
        createSeries(type) {
            switch (type) {
                case DataSeriesType.Area:
                    return this.createSeriesComponent('IgxAreaSeriesComponent');
                case DataSeriesType.Column:
                    return this.createSeriesComponent('IgxColumnSeriesComponent');
                case DataSeriesType.Line:
                    return this.createSeriesComponent('IgxLineSeriesComponent');
                case DataSeriesType.Point:
                    return this.createSeriesComponent('IgxPointSeriesComponent');
                case DataSeriesType.Spline:
                    return this.createSeriesComponent('IgxSplineSeriesComponent');
                case DataSeriesType.SplineArea:
                    return this.createSeriesComponent('IgxSplineAreaSeriesComponent');
                case DataSeriesType.StepArea:
                    return this.createSeriesComponent('IgxStepAreaSeriesComponent');
                case DataSeriesType.StepLine:
                    return this.createSeriesComponent('IgxStepLineSeriesComponent');
                case DataSeriesType.Waterfall:
                    return this.createSeriesComponent('IgxWaterfallSeriesComponent');
                case DataSeriesType.ItemToolTipLayer:
                    return this.createSeriesComponent('IgxItemToolTipLayerComponent');
                case DataSeriesType.CategoryToolTipLayer:
                    return this.createSeriesComponent('IgxCategoryToolTipLayerComponent');
                case DataSeriesType.CrosshairLayer:
                    return this.createSeriesComponent('IgxCrosshairLayerComponent');
                case DataSeriesType.FinalValueLayer:
                    return this.createSeriesComponent('IgxFinalValueLayerComponent');
                case DataSeriesType.CalloutLayer:
                    return this.createSeriesComponent('IgxCalloutLayerComponent');
                case DataSeriesType.CategoryHighlightLayer:
                    return this.createSeriesComponent('IgxCategoryHighlightLayerComponent');
                case DataSeriesType.CategoryItemHighlightLayer:
                    return this.createSeriesComponent('IgxCategoryItemHighlightLayerComponent');
                case DataSeriesType.DataToolTipLayer:
                    return this.createSeriesComponent('IgxDataToolTipLayerComponent');
                case DataSeriesType.ValueLayer:
                    return this.createSeriesComponent('IgxValueLayerComponent');
                default:
                    return this.createSeriesComponent('IgxColumnSeriesComponent');
            }
        }
        set dataSource(value) {
            this._dataSource = value;
            this.bindData();
        }
        get dataSource() {
            return this._dataSource;
        }
        bindData() {
            if (this._chart != null && this._chart !== undefined) {
                this._chart.itemsSource = this._dataSource;
            }
        }
        ngAfterContentInit() {
            if (TypeRegistrar.isRegistered("IgxDataChartDefaultTooltipsComponent")) {
                let c = TypeRegistrar.get("IgxDataChartDefaultTooltipsComponent");
                let cf = this.componentFactoryResolver.resolveComponentFactory(c);
                //let cr = cf.create(this.injector);
                let cr = this._dynamicContent.createComponent(cf);
                this._defaultTooltips = cr;
                cr.instance.onContentReady.subscribe(() => {
                    this._onDefaultTooltipsReady(cr);
                });
                this.container.appendChild(cr.location.nativeElement);
            }
        }
        ngAfterViewInit() {
            this.updateStyle();
        }
        updateStyle() {
            this._styling(this.container, this);
        }
        createTooltip() {
            if (!TypeRegistrar.isRegistered("IgxTooltipContainerComponent")) {
                return null;
            }
            let t = TypeRegistrar.get("IgxTooltipContainerComponent");
            let cf = this.componentFactoryResolver.resolveComponentFactory(t);
            //let cr = cf.create(this.injector);
            let cr = this._dynamicContent.createComponent(cf);
            let ele = cr.location.nativeElement;
            let self = this;
            ele.updateToolTip = function (c, isSubContent) {
                if (c.externalObject) {
                    c = c.externalObject;
                }
                else {
                    let ext = new IgxDataContext();
                    ext._implementation = c;
                    c = ext;
                }
                if (!isSubContent) {
                    if (ele.parentElement != self.container) {
                        if (ele.parentElement != null) {
                            ele.parentElement.removeChild(ele);
                        }
                        self.container.appendChild(ele);
                    }
                }
                else {
                    c.isSubContent = true;
                }
                cr.instance.context = c;
                ele.style.display = "block";
                return true;
            };
            ele.hideToolTip = function () {
                ele.style.display = "none";
            };
            ele.style.display = "none";
            return cr;
        }
        _ensureTooltipCreated(series) {
            series._ensureTooltipCreated(() => this.createTooltip(), (ele) => {
                let wrapper = new AngularWrapper(ele, this.renderer, this.ngZone);
                wrapper.updateToolTip = ele.updateToolTip;
                wrapper.hideToolTip = ele.hideToolTip;
                return wrapper;
            });
        }
        _createXAxis() {
            let x = new IgxCategoryXAxisComponent();
            x._provideRenderer(this.renderer);
            return x.i;
        }
        _createYAxis() {
            let y = new IgxNumericYAxisComponent();
            y.provideRenderer(this.renderer);
            return y.i;
        }
        _ensureDefaultTooltip(series) {
            if (this._defaultTooltips == null) {
                return;
            }
            this._defaultTooltips.instance["ensureDefaultTooltip"](series);
        }
        _onDefaultTooltipsReady(cr) {
            if (this.i.dataChart) {
                var currSeries = this.i.dataChart.series;
                for (var i = 0; i < currSeries.count; i++) {
                    if (currSeries.item(i).externalObject.showDefaultTooltip) {
                        this._ensureDefaultTooltip(currSeries.item(i).externalObject);
                    }
                }
            }
        }
        /**
     * Gets or sets the duration used for animating series plots when the chart is loading into view
    *
    * `TransitionInDuration` controls the length of time taken by the transition-in animation.  Try setting it to 2 seconds:
    *
    * ```html
    * <igx-category-chart
    *     [dataSource]="data"
    *     isTransitionInEnabled="true"
    *     transitionInDuration="2000">
    * </igx-category-chart>
    * ```
    */
        get transitionInDuration() {
            return this.i.ajk;
        }
        set transitionInDuration(v) {
            this.i.ajk = +v;
        }
        /**
         * Gets or sets the duration used for animating series plots when the series is leaving view
        */
        get transitionOutDuration() {
            return this.i.ajl;
        }
        set transitionOutDuration(v) {
            this.i.ajl = +v;
        }
        /**
         * Gets or sets the easing function used for animating series plots when the chart is loading into view
         * This can be set to one of the known values "linear" or "cubic," or it can be set to an easing function which takes a single numeric parameter and returns a number.
        */
        get transitionInEasingFunction() {
            return this.i.ahm;
        }
        set transitionInEasingFunction(v) {
            this.i.ahm = v;
        }
        /**
         * Gets or sets the easing function used for animating series plots when the chart is loading into view
         * This can be set to one of the known values "linear" or "cubic," or it can be set to an easing function which takes a single numeric parameter and returns a number.
        */
        get transitionOutEasingFunction() {
            return this.i.ahn;
        }
        set transitionOutEasingFunction(v) {
            this.i.ahn = v;
        }
        /**
         * Gets domain type of this chart
        */
        get domainType() {
            return this.i.cb;
        }
        /**
         * Gets or sets the type of chart series to generate from the data.
        *
        * The `ChartType` property determines the type of data series to display.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     chartType="stepArea">
        * </igx-category-chart>
        * ```
        */
        get chartType() {
            return this.i.ag5;
        }
        set chartType(v) {
            this.i.ag5 = ensureEnum(CategoryChartType_$type, v);
        }
        /**
         * Gets or sets the behavior for markers in each series which are placed too close together for the current view, resulting in a collision.
        *
        * `MarkerCollisionAvoidance` controls the technique the chart uses to avoid overlapping markers.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     markerCollisionAvoidance="none">
        * </igx-category-chart>
        * ```
        */
        get markerCollisionAvoidance() {
            return this.i.ag7;
        }
        set markerCollisionAvoidance(v) {
            this.i.ag7 = ensureEnum(CategorySeriesMarkerCollisionAvoidance_$type, v);
        }
        /**
         * Gets or sets whether to include the spline shape in the axis range requested of the axis for spline type series.
        */
        get isSplineShapePartOfRange() {
            return this.i.ah1;
        }
        set isSplineShapePartOfRange(v) {
            this.i.ah1 = ensureBool(v);
        }
        /**
         * Gets or sets whether animation of series plots is enabled when the chart is loading into view
        *
        * Set `IsTransitionInEnabled` to true if you want your chart series to animate into position when the chart is loading into view.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     isTransitionInEnabled="true">
        * </igx-category-chart>
        * ```
        */
        get isTransitionInEnabled() {
            return this.i.ah2;
        }
        set isTransitionInEnabled(v) {
            this.i.ah2 = ensureBool(v);
        }
        /**
         * Gets or sets the method that determines how to animate series plots when the chart is loading into view
        *
        * `TransitionInMode` controls the direction of the transition-in animation.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     isTransitionInEnabled="true"
        *     transitionInMode="accordionfromRight">
        * </igx-category-chart>
        * ```
        */
        get transitionInMode() {
            return this.i.ag9;
        }
        set transitionInMode(v) {
            this.i.ag9 = ensureEnum(CategoryTransitionInMode_$type, v);
        }
        /**
         * Gets or sets the arrival speed used for animating series plots when the chart is loading into view
        *
        * `TransitionInSpeedType` controls the speed of the transition-in animation.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     isTransitionInEnabled="true"
        *     transitionInSpeedType="indexScaled">
        * </igx-category-chart>
        * ```
        */
        get transitionInSpeedType() {
            return this.i.ahj;
        }
        set transitionInSpeedType(v) {
            this.i.ahj = ensureEnum(TransitionInSpeedType_$type, v);
        }
        /**
         * Gets or sets the frequency of displayed labels along the X-axis.
         * Gets or sets the set value is a factor that determines which labels will be hidden. For example, an interval of 2 will display every other label.
        *
        * `XAxisInterval` determines how often to show a label, tickmark, and/or gridline along the x-axis.  Set this property to _n_ to display a label every _nth_ item.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     xAxisInterval="3">
        * </igx-category-chart>
        * ```
        */
        get xAxisInterval() {
            return this.i.ai1;
        }
        set xAxisInterval(v) {
            this.i.ai1 = +v;
        }
        /**
         * Gets or sets the frequency of displayed minor lines along the X-axis.
         * Gets or sets the set value is a factor that determines how the minor lines will be displayed.
        *
        * `XAxisMinorInterval` determines how often to show a minor gridline along the x-axis.  This property is relevant only when the displayed series is a type with grouping, like column series.
        *
        * `XAxisMinorInterval` is expressed as a number between 0 and 1, representing the frequency of the interval.  To display minor gridlines representing 10ths of an item width, set `XAxisMinorInterval` to 0.1.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     xAxisMinorInterval="0.1"
        *     xAxisMinorStroke="green"
        *     xAxisMinorStrokeThickness="1">
        * </igx-category-chart>
        * ```
        */
        get xAxisMinorInterval() {
            return this.i.ai4;
        }
        set xAxisMinorInterval(v) {
            this.i.ai4 = +v;
        }
        /**
         * Gets or sets the amount of space between adjacent categories for the X-axis.
         * The gap is silently clamped to the range [0, 1] when used.
        *
        * Use the `XAxisGap` property to configure the spacing between items on the x-axis.  This property is relevant only when the displayed series is a type with item spacing, like column series.
        *
        * An `XAxisGap` of 0 allocates no space between items.  An `XAxisGap` of 1 allocates a space between items equal to the width of one item.
        *
        * To set the item spacing to 75% the width of one item, set the `XAxisGap` to 0.75, as in this code:
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     xAxisGap="0.75">
        * </igx-category-chart>
        * ```
        */
        get xAxisGap() {
            return this.i.ai0;
        }
        set xAxisGap(v) {
            this.i.ai0 = +v;
        }
        /**
         * Gets or sets the minimum amount of pixels to use for the gap between categories, if possible.
        */
        get xAxisMinimumGapSize() {
            return this.i.ai3;
        }
        set xAxisMinimumGapSize(v) {
            this.i.ai3 = +v;
        }
        /**
         * Gets or sets the maximum gap value to allow. This defaults to 1.0.
        */
        get xAxisMaximumGap() {
            return this.i.ai2;
        }
        set xAxisMaximumGap(v) {
            this.i.ai2 = +v;
        }
        /**
         * Gets or sets the amount of overlap between adjacent categories for the X-axis.
         * Gets or sets the overlap is silently clamped to the range [-1, 1] when used.
        *
        * Use the `XAxisOverlap` property to configure the spacing between items on the x-axis.  This property is relevant only when the displayed series is a type with item spacing, like column series.
        *
        * An `XAxisOverlap` of 0 places grouped items adjacent to each other.  An `XAxisOverlap` of 1 places grouped items in the same axis space, completely overlapping.  An `XAxisOverlap` of -1 places a space between grouped items equal to the width of one item.
        *
        * To place grouped items with 75% overlap, set the `XAxisOverlap` to 0.75, as in this code:
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     xAxisOverlap="0.75">
        * </igx-category-chart>
        * ```
        */
        get xAxisOverlap() {
            return this.i.ai5;
        }
        set xAxisOverlap(v) {
            this.i.ai5 = +v;
        }
        /**
         * Gets or sets the distance between each label and grid line along the Y-axis.
        *
        * `YAxisInterval` determines how often to show a label, tickmark, and/or gridline along the y-axis.  Set this property to a number less than the numeric range of the y-axis.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     yAxisInterval="10">
        * </igx-category-chart>
        * ```
        */
        get yAxisInterval() {
            return this.i.ajd;
        }
        set yAxisInterval(v) {
            this.i.ajd = +v;
        }
        /**
         * Gets or sets a whether the series viewer should auto expand margins to accommodate the initial horizontal axis labels.
        */
        get autoMarginAndAngleUpdateMode() {
            return this.i.ag1;
        }
        set autoMarginAndAngleUpdateMode(v) {
            this.i.ag1 = ensureEnum(AutoMarginsAndAngleUpdateMode_$type, v);
        }
        /**
         * Gets or sets a whether the series viewer should auto expand margins to accommodate the initial horizontal axis labels.
        */
        get shouldAutoExpandMarginForInitialLabels() {
            return this.i.ah3;
        }
        set shouldAutoExpandMarginForInitialLabels(v) {
            this.i.ah3 = ensureBool(v);
        }
        /**
         * Gets or sets a whether the series viewer should consider auto rotating labels to fit them in the initial view. This implies that ShouldAutoExpandMarginForInitialLabels is true.
        */
        get shouldConsiderAutoRotationForInitialLabels() {
            return this.i.ah4;
        }
        set shouldConsiderAutoRotationForInitialLabels(v) {
            this.i.ah4 = ensureBool(v);
        }
        /**
         * Gets or sets the extra amount the series viewer should auto expand margins to accommodate the initial horizontal axis labels.
        */
        get autoExpandMarginExtraPadding() {
            return this.i.ais;
        }
        set autoExpandMarginExtraPadding(v) {
            this.i.ais = +v;
        }
        /**
         * Gets or sets the maximum amount the series viewer should auto expand margins to accommodate the initial horizontal axis labels.
        */
        get autoExpandMarginMaximumValue() {
            return this.i.ait;
        }
        set autoExpandMarginMaximumValue(v) {
            this.i.ait = +v;
        }
        /**
         * Gets or sets whether the axis should favor emitting a label at the end of the scale.
        */
        get yAxisFavorLabellingScaleEnd() {
            return this.i.ah8;
        }
        set yAxisFavorLabellingScaleEnd(v) {
            this.i.ah8 = ensureBool(v);
        }
        /**
         * Gets or sets whether the x axis enhanced interval management should prefer to show all the labels if possible without collisions for supported types of category axes. This is for use with EnhancedIntervalMinimumCharacters = -1 and axes that have an integral interval.
        */
        get xAxisEnhancedIntervalPreferMoreCategoryLabels() {
            return this.i.ah5;
        }
        set xAxisEnhancedIntervalPreferMoreCategoryLabels(v) {
            this.i.ah5 = ensureBool(v);
        }
        /**
         * Gets or sets whether the y axis enhanced interval management should prefer to show all the labels if possible without collisions for supported types of category axes. This is for use with EnhancedIntervalMinimumCharacters = -1 and axes that have an integral interval.
        */
        get yAxisEnhancedIntervalPreferMoreCategoryLabels() {
            return this.i.ah7;
        }
        set yAxisEnhancedIntervalPreferMoreCategoryLabels(v) {
            this.i.ah7 = ensureBool(v);
        }
        /**
         * Gets or sets how the numeric axis will adjust its range buffer to less closely fix the data from the series.
        */
        get yAxisAutoRangeBufferMode() {
            return this.i.ag3;
        }
        set yAxisAutoRangeBufferMode(v) {
            this.i.ag3 = ensureEnum(AxisRangeBufferMode_$type, v);
        }
        /**
         * Gets or sets whether the Y-axis should use a logarithmic scale instead of a linear one.
         * Since log(-1) is imaginary and log(0) is undefined, it is recommended to enable this property only when the Y-axis minimum is greater than zero.
        *
        * Set `YAxisIsLogarithmic` to true if you want the y-axis to be a logarithmic scale.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     yAxisIsLogarithmic="true">
        * </igx-category-chart>
        * ```
        */
        get yAxisIsLogarithmic() {
            return this.i.ah9;
        }
        set yAxisIsLogarithmic(v) {
            this.i.ah9 = ensureBool(v);
        }
        /**
         * Gets or sets the base value to use in the log function when mapping the position of data items along the Y-axis.
         * This property is effective only when YAxisIsLogarithmic is true.
        *
        * When `YAxisIsLogarithmic` is true, `YAxisLogarithmBase` sets the logarithm base of the y-axis scale.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     yAxisIsLogarithmic="true"
        *     yAxisLogarithmBase="2">
        * </igx-category-chart>
        * ```
        */
        get yAxisLogarithmBase() {
            return this.i.ajm;
        }
        set yAxisLogarithmBase(v) {
            this.i.ajm = +v;
        }
        /**
         * Gets or sets the data value corresponding to the minimum value of the Y-axis.
        *
        * `YAxisMaximumValue` determines the minimum of the y-axis.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     yAxisMinimumValue="42">
        * </igx-category-chart>
        * ```
        */
        get yAxisMinimumValue() {
            return this.i.ajf;
        }
        set yAxisMinimumValue(v) {
            this.i.ajf = +v;
        }
        /**
         * Gets or sets the data value corresponding to the maximum value of the Y-axis.
        *
        * `YAxisMaximumValue` determines the maximum of the y-axis.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     yAxisMaximumValue="42">
        * </igx-category-chart>
        * ```
        */
        get yAxisMaximumValue() {
            return this.i.aje;
        }
        set yAxisMaximumValue(v) {
            this.i.aje = +v;
        }
        /**
         * Gets or sets the frequency of displayed minor lines along the Y-axis.
        *
        * `YAxisMinorInterval` determines how often to show a minor gridline along the y-axis.  Set this property to a number less than the y-axis interval.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     yAxisMinorInterval="2"
        *     yAxisMinorStroke="green"
        *     yAxisMinorStrokeThickness="1">
        * </igx-category-chart>
        * ```
        */
        get yAxisMinorInterval() {
            return this.i.ajg;
        }
        set yAxisMinorInterval(v) {
            this.i.ajg = +v;
        }
        /**
         * Gets the current minimum value for the X-axis.
        */
        get xAxisActualMinimum() {
            return this.i.aiz;
        }
        /**
         * Gets the current maximum value for the X-axis.
        */
        get xAxisActualMaximum() {
            return this.i.aiy;
        }
        /**
         * Gets the current minimum value for the Y-axis.
        */
        get yAxisActualMinimum() {
            return this.i.ajc;
        }
        /**
         * Gets the current maximum value for the Y-axis.
        */
        get yAxisActualMaximum() {
            return this.i.ajb;
        }
        /**
         * Gets or sets the palette used for coloring negative items of Waterfall chart type.
        *
        * `NegativeBrushes` controls the brushes used by the chart for negative data, when the `ChartType` is one that supports negative brushes.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     chartType="waterfall"
        *     negativeBrushes="#ff0000, #cc0000, #aa0000">
        * </igx-category-chart>
        * ```
        */
        get negativeBrushes() {
            return fromBrushCollection(this.i.agy);
        }
        set negativeBrushes(v) {
            this.i.agy = toBrushCollection(v);
        }
        /**
         * Brushes to use for drawing negative elements, when using a chart type with contextual coloring, such as Waterfall.
        *
        * `NegativeOutlines` controls the outlines used by the chart for negative data, when the `ChartType` is one that supports negative brushes.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     chartType="waterfall"
        *     negativeOutlines="#0000ff, #0000cc, #0000aa">
        * </igx-category-chart>
        * ```
        */
        get negativeOutlines() {
            return fromBrushCollection(this.i.agz);
        }
        set negativeOutlines(v) {
            this.i.agz = toBrushCollection(v);
        }
        /**
         * Gets or sets whether the large numbers on the Y-axis labels are abbreviated.
        *
        * To abbreviate on the y-axis using formats like "1K" or "1M," set `YAxisAbbreviateLargeNumbers` to true.
        *
        * ```html
        * <igx-category-chart
        *     [dataSource]="data"
        *     yAxisAbbreviateLargeNumbers="true">
        * </igx-category-chart>
        * ```
        */
        get yAxisAbbreviateLargeNumbers() {
            return this.i.ah6;
        }
        set yAxisAbbreviateLargeNumbers(v) {
            this.i.ah6 = ensureBool(v);
        }
        /**
         * Gets or sets number of visible categories at maximum zooming level
         * This property is overridden by chart's WindowRectMinWidth property
        */
        get xAxisZoomMaximumCategoryRange() {
            return this.i.ai6;
        }
        set xAxisZoomMaximumCategoryRange(v) {
            this.i.ai6 = +v;
        }
        /**
         * Gets or sets maximum pixel span of series item that will be visible at maximum zooming level
         * This property ensures that series item does not get stretch above specified value.
         * This property is overridden by chart's WindowRectMinWidth property
        */
        get xAxisZoomMaximumItemSpan() {
            return this.i.ai7;
        }
        set xAxisZoomMaximumItemSpan(v) {
            this.i.ai7 = +v;
        }
        /**
         * Gets or sets number of categories that the chart will zoom in and fill plot area
         * This property is overridden by chart's WindowRect or WindowScaleHorizontal properties
        */
        get xAxisZoomToCategoryRange() {
            return this.i.ai8;
        }
        set xAxisZoomToCategoryRange(v) {
            this.i.ai8 = +v;
        }
        /**
         * Gets or sets starting category that chart will move its zoom window. Acceptable value is between 0 and number of data items
         * This property is overridden by chart's WindowRect or WindowScaleHorizontal properties
        */
        get xAxisZoomToCategoryStart() {
            return this.i.ai9;
        }
        set xAxisZoomToCategoryStart(v) {
            this.i.ai9 = +v;
        }
        /**
         * Gets or sets pixel span of series item that will be used to zoom chart such that the item has desired span
         * Chart will automatically zoom in until series item has specified pixel span.
         * This property is overridden by chart's WindowRect or WindowScaleHorizontal properties
        */
        get xAxisZoomToItemSpan() {
            return this.i.aja;
        }
        set xAxisZoomToItemSpan(v) {
            this.i.aja = +v;
        }
        /**
         * Gets or sets whether the category should be highlighted when hovered
        */
        get isCategoryHighlightingEnabled() {
            return this.i.ahz;
        }
        set isCategoryHighlightingEnabled(v) {
            this.i.ahz = ensureBool(v);
        }
        /**
         * Gets or sets whether the item should be highlighted when hovered
        */
        get isItemHighlightingEnabled() {
            return this.i.ah0;
        }
        set isItemHighlightingEnabled(v) {
            this.i.ah0 = ensureBool(v);
        }
        /**
     * Export serialized visual data.
    
    */
        exportSerializedVisualData() {
            let iv = this.i.ajr();
            return (iv);
        }
        recalculateMarginAutoExpansion() {
            this.i.akx();
        }
        getCurrentXAxisActualMinimum() {
            let iv = this.i.aiv();
            return (iv);
        }
        getCurrentYAxisActualMinimum() {
            let iv = this.i.aix();
            return (iv);
        }
        getCurrentXAxisActualMaximum() {
            let iv = this.i.aiu();
            return (iv);
        }
        getCurrentYAxisActualMaximum() {
            let iv = this.i.aiw();
            return (iv);
        }
    }
    IgxCategoryChartComponent.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: IgxCategoryChartComponent, deps: [{ token: i0.Renderer2 }, { token: i0.ViewContainerRef }, { token: i0.NgZone }, { token: i0.Injector }, { token: i0.ComponentFactoryResolver }], target: i0.ɵɵFactoryTarget.Component });
    IgxCategoryChartComponent.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "12.0.0", version: "12.2.17", type: IgxCategoryChartComponent, selector: "igx-category-chart", inputs: { height: "height", width: "width", dataSource: "dataSource", transitionInDuration: "transitionInDuration", transitionOutDuration: "transitionOutDuration", transitionInEasingFunction: "transitionInEasingFunction", transitionOutEasingFunction: "transitionOutEasingFunction", chartType: "chartType", markerCollisionAvoidance: "markerCollisionAvoidance", isSplineShapePartOfRange: "isSplineShapePartOfRange", isTransitionInEnabled: "isTransitionInEnabled", transitionInMode: "transitionInMode", transitionInSpeedType: "transitionInSpeedType", xAxisInterval: "xAxisInterval", xAxisMinorInterval: "xAxisMinorInterval", xAxisGap: "xAxisGap", xAxisMinimumGapSize: "xAxisMinimumGapSize", xAxisMaximumGap: "xAxisMaximumGap", xAxisOverlap: "xAxisOverlap", yAxisInterval: "yAxisInterval", autoMarginAndAngleUpdateMode: "autoMarginAndAngleUpdateMode", shouldAutoExpandMarginForInitialLabels: "shouldAutoExpandMarginForInitialLabels", shouldConsiderAutoRotationForInitialLabels: "shouldConsiderAutoRotationForInitialLabels", autoExpandMarginExtraPadding: "autoExpandMarginExtraPadding", autoExpandMarginMaximumValue: "autoExpandMarginMaximumValue", yAxisFavorLabellingScaleEnd: "yAxisFavorLabellingScaleEnd", xAxisEnhancedIntervalPreferMoreCategoryLabels: "xAxisEnhancedIntervalPreferMoreCategoryLabels", yAxisEnhancedIntervalPreferMoreCategoryLabels: "yAxisEnhancedIntervalPreferMoreCategoryLabels", yAxisAutoRangeBufferMode: "yAxisAutoRangeBufferMode", yAxisIsLogarithmic: "yAxisIsLogarithmic", yAxisLogarithmBase: "yAxisLogarithmBase", yAxisMinimumValue: "yAxisMinimumValue", yAxisMaximumValue: "yAxisMaximumValue", yAxisMinorInterval: "yAxisMinorInterval", negativeBrushes: "negativeBrushes", negativeOutlines: "negativeOutlines", yAxisAbbreviateLargeNumbers: "yAxisAbbreviateLargeNumbers", xAxisZoomMaximumCategoryRange: "xAxisZoomMaximumCategoryRange", xAxisZoomMaximumItemSpan: "xAxisZoomMaximumItemSpan", xAxisZoomToCategoryRange: "xAxisZoomToCategoryRange", xAxisZoomToCategoryStart: "xAxisZoomToCategoryStart", xAxisZoomToItemSpan: "xAxisZoomToItemSpan", isCategoryHighlightingEnabled: "isCategoryHighlightingEnabled", isItemHighlightingEnabled: "isItemHighlightingEnabled" }, host: { classAttribute: "ig-category-chart igx-category-chart" }, providers: [], viewQueries: [{ propertyName: "_dynamicContent", first: true, predicate: ["dynamicContent"], descendants: true, read: ViewContainerRef, static: true }], usesInheritance: true, ngImport: i0, template: `<ng-container #dynamicContent></ng-container>`, isInline: true, styles: ["\n\t\t:host {\n\t\t\tdisplay: block;\n\t\t}\n\t"], changeDetection: i0.ChangeDetectionStrategy.OnPush });
    return IgxCategoryChartComponent;
})();
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "12.2.17", ngImport: i0, type: IgxCategoryChartComponent, decorators: [{
            type: Component,
            args: [{
                    selector: 'igx-category-chart',
                    template: `<ng-container #dynamicContent></ng-container>`,
                    changeDetection: ChangeDetectionStrategy.OnPush,
                    providers: [],
                    host: { 'class': 'ig-category-chart igx-category-chart' },
                    styles: [`
		:host {
			display: block;
		}
	`]
                }]
        }], ctorParameters: function () { return [{ type: i0.Renderer2 }, { type: i0.ViewContainerRef }, { type: i0.NgZone }, { type: i0.Injector }, { type: i0.ComponentFactoryResolver }]; }, propDecorators: { _dynamicContent: [{
                type: ViewChild,
                args: ["dynamicContent", { read: ViewContainerRef, static: true }]
            }], height: [{
                type: Input
            }], width: [{
                type: Input
            }], dataSource: [{
                type: Input
            }], transitionInDuration: [{
                type: Input
            }], transitionOutDuration: [{
                type: Input
            }], transitionInEasingFunction: [{
                type: Input
            }], transitionOutEasingFunction: [{
                type: Input
            }], chartType: [{
                type: Input
            }], markerCollisionAvoidance: [{
                type: Input
            }], isSplineShapePartOfRange: [{
                type: Input
            }], isTransitionInEnabled: [{
                type: Input
            }], transitionInMode: [{
                type: Input
            }], transitionInSpeedType: [{
                type: Input
            }], xAxisInterval: [{
                type: Input
            }], xAxisMinorInterval: [{
                type: Input
            }], xAxisGap: [{
                type: Input
            }], xAxisMinimumGapSize: [{
                type: Input
            }], xAxisMaximumGap: [{
                type: Input
            }], xAxisOverlap: [{
                type: Input
            }], yAxisInterval: [{
                type: Input
            }], autoMarginAndAngleUpdateMode: [{
                type: Input
            }], shouldAutoExpandMarginForInitialLabels: [{
                type: Input
            }], shouldConsiderAutoRotationForInitialLabels: [{
                type: Input
            }], autoExpandMarginExtraPadding: [{
                type: Input
            }], autoExpandMarginMaximumValue: [{
                type: Input
            }], yAxisFavorLabellingScaleEnd: [{
                type: Input
            }], xAxisEnhancedIntervalPreferMoreCategoryLabels: [{
                type: Input
            }], yAxisEnhancedIntervalPreferMoreCategoryLabels: [{
                type: Input
            }], yAxisAutoRangeBufferMode: [{
                type: Input
            }], yAxisIsLogarithmic: [{
                type: Input
            }], yAxisLogarithmBase: [{
                type: Input
            }], yAxisMinimumValue: [{
                type: Input
            }], yAxisMaximumValue: [{
                type: Input
            }], yAxisMinorInterval: [{
                type: Input
            }], negativeBrushes: [{
                type: Input
            }], negativeOutlines: [{
                type: Input
            }], yAxisAbbreviateLargeNumbers: [{
                type: Input
            }], xAxisZoomMaximumCategoryRange: [{
                type: Input
            }], xAxisZoomMaximumItemSpan: [{
                type: Input
            }], xAxisZoomToCategoryRange: [{
                type: Input
            }], xAxisZoomToCategoryStart: [{
                type: Input
            }], xAxisZoomToItemSpan: [{
                type: Input
            }], isCategoryHighlightingEnabled: [{
                type: Input
            }], isItemHighlightingEnabled: [{
                type: Input
            }] } });
