import * as tslib_1 from "tslib";
import { Component, forwardRef, Input, ChangeDetectionStrategy } from '@angular/core';
import { TimeAxisDisplayType, TimeAxisDisplayType_$type } from "./TimeAxisDisplayType";
import { IgxTimeAxisBaseComponent } from "./igx-time-axis-base-component";
import { IgxCategoryAxisBaseComponent } from "./igx-category-axis-base-component";
import { IgxAxisComponent } from "./igx-axis-component";
import { CategoryDateTimeXAxis } from "./CategoryDateTimeXAxis";
import { ensureEnum } from "igniteui-angular-core";
/**
 * Represents a category-based horizontal X axis that uses a DateTime scale.
*
* `IgxCategoryDateTimeXAxisComponent` class represents a category-based horizontal X axis that uses a DateTime scale.
*
* ```html
* <igx-data-chart
*     [dataSource]="data">
*     <igx-time-x-axis
* 		dateTimeMemberPath="date"
* 		#xAxis>
*     </igx-time-x-axis>
* </igx-data-chart>
* ```
*
* ```ts
* let xAxis = new IgxTimeXAxisComponent();
* xAxis.dataTimeMemberPath="date";
* this.chart.axes.add(xAxis);
* ```
*/
export var IgxCategoryDateTimeXAxisComponent_PROVIDERS = [{ provide: IgxTimeAxisBaseComponent, useExisting: forwardRef(function () { return IgxCategoryDateTimeXAxisComponent; }) }, { provide: IgxCategoryAxisBaseComponent, useExisting: forwardRef(function () { return IgxCategoryDateTimeXAxisComponent; }) }, { provide: IgxAxisComponent, useExisting: forwardRef(function () { return IgxCategoryDateTimeXAxisComponent; }) }];
var IgxCategoryDateTimeXAxisComponent = /** @class */ (function (_super) {
    tslib_1.__extends(IgxCategoryDateTimeXAxisComponent, _super);
    function IgxCategoryDateTimeXAxisComponent() {
        return _super.call(this) || this;
    }
    IgxCategoryDateTimeXAxisComponent_1 = IgxCategoryDateTimeXAxisComponent;
    IgxCategoryDateTimeXAxisComponent.prototype.createImplementation = function () {
        return new CategoryDateTimeXAxis();
    };
    Object.defineProperty(IgxCategoryDateTimeXAxisComponent.prototype, "i", {
        /**
                                     * @hidden
                                     */
        get: function () {
            return this._implementation;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxCategoryDateTimeXAxisComponent.prototype, "isContinuous", {
        /**
         * Gets if the current axis is a continuous rather than a discrete scale
        */
        get: function () {
            return this.i.b4;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxCategoryDateTimeXAxisComponent.prototype, "displayType", {
        /**
         * Gets or sets the axis display type.
         * Continuous display type divides the axis into even intervals, where labels will not necessarily be aligned with data points.
         * Discrete display type will not use a constant interval, but will align each label with its data point.
        *
        * `displayType` property is used for axis display type.
        *
        * Continuous display type divides the axis into even intervals, where labels will not necessarily be aligned with data points. Discrete display type will not use a constant interval, but will align each label with its data point.
        *
        * ```html
        * <igx-data-chart
        *     [dataSource]="data">
        *     <igx-time-x-axis
        * 		dateTimeMemberPath="date"
        * 		displayType ="continuous"
        * 		#xAxis>
        *     </igx-time-x-axis>
        * </igx-data-chart>
        * ```
        */
        get: function () {
            return this.i.l4;
        },
        set: function (v) {
            this.i.l4 = ensureEnum(TimeAxisDisplayType_$type, v);
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxCategoryDateTimeXAxisComponent.prototype, "interval", {
        /**
         * Gets or sets the X axis time interval.
        *
        * `interval` property is used to get/sets the frequency of displayed labels.
        *
        * ```html
        * <igx-data-chart
        *     [dataSource]="data">
        *     <igx-time-x-axis
        * 		dateTimeMemberPath="date"
        * 		interval=2
        * 		#xAxis>
        *     </igx-time-x-axis>
        * </igx-data-chart>
        * ```
        */
        get: function () {
            return this.i.me;
        },
        set: function (v) {
            this.i.me = +v;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxCategoryDateTimeXAxisComponent.prototype, "actualInterval", {
        /**
         * Gets the effective value for the current Interval.
        */
        get: function () {
            return this.i.mb;
        },
        set: function (v) {
            this.i.mb = +v;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxCategoryDateTimeXAxisComponent.prototype, "minorInterval", {
        /**
         * Gets or sets the frequency of displayed minor lines.
         * The set value is a factor that determines how the minor lines will be displayed.
        */
        get: function () {
            return this.i.mf;
        },
        set: function (v) {
            this.i.mf = +v;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxCategoryDateTimeXAxisComponent.prototype, "actualMinorInterval", {
        /**
         * Gets the effective value for the current MinorInterval.
        */
        get: function () {
            return this.i.mc;
        },
        set: function (v) {
            this.i.mc = +v;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgxCategoryDateTimeXAxisComponent.prototype, "isCategoryDateTime", {
        /**
         * Gets if the current axis is of category date time axis type
        */
        get: function () {
            return this.i.b3;
        },
        enumerable: true,
        configurable: true
    });
    IgxCategoryDateTimeXAxisComponent.prototype.scrollIntoView = function (minimum, maximum) {
        this.i.ml(minimum, maximum);
    };
    var IgxCategoryDateTimeXAxisComponent_1;
    tslib_1.__decorate([
        Input(),
        tslib_1.__metadata("design:type", Number),
        tslib_1.__metadata("design:paramtypes", [Number])
    ], IgxCategoryDateTimeXAxisComponent.prototype, "displayType", null);
    tslib_1.__decorate([
        Input(),
        tslib_1.__metadata("design:type", Number),
        tslib_1.__metadata("design:paramtypes", [Number])
    ], IgxCategoryDateTimeXAxisComponent.prototype, "interval", null);
    tslib_1.__decorate([
        Input(),
        tslib_1.__metadata("design:type", Number),
        tslib_1.__metadata("design:paramtypes", [Number])
    ], IgxCategoryDateTimeXAxisComponent.prototype, "actualInterval", null);
    tslib_1.__decorate([
        Input(),
        tslib_1.__metadata("design:type", Number),
        tslib_1.__metadata("design:paramtypes", [Number])
    ], IgxCategoryDateTimeXAxisComponent.prototype, "minorInterval", null);
    tslib_1.__decorate([
        Input(),
        tslib_1.__metadata("design:type", Number),
        tslib_1.__metadata("design:paramtypes", [Number])
    ], IgxCategoryDateTimeXAxisComponent.prototype, "actualMinorInterval", null);
    IgxCategoryDateTimeXAxisComponent = IgxCategoryDateTimeXAxisComponent_1 = tslib_1.__decorate([
        Component({
            selector: 'igx-category-date-time-x-axis',
            template: "",
            providers: [{ provide: IgxTimeAxisBaseComponent, useExisting: forwardRef(function () { return IgxCategoryDateTimeXAxisComponent_1; }) }, { provide: IgxCategoryAxisBaseComponent, useExisting: forwardRef(function () { return IgxCategoryDateTimeXAxisComponent_1; }) }, { provide: IgxAxisComponent, useExisting: forwardRef(function () { return IgxCategoryDateTimeXAxisComponent_1; }) }],
            changeDetection: ChangeDetectionStrategy.OnPush
        }),
        tslib_1.__metadata("design:paramtypes", [])
    ], IgxCategoryDateTimeXAxisComponent);
    return IgxCategoryDateTimeXAxisComponent;
}(IgxTimeAxisBaseComponent));
export { IgxCategoryDateTimeXAxisComponent };
//# sourceMappingURL=igx-category-date-time-x-axis-component.js.map