import * as tslib_1 from "tslib";
var IgxCustomPaletteColorScaleComponent_1;
import { Component, forwardRef, Input, ChangeDetectionStrategy } from '@angular/core';
import { ColorScaleInterpolationMode, ColorScaleInterpolationMode_$type } from "./ColorScaleInterpolationMode";
import { IgxColorScaleComponent } from "./igx-color-scale-component";
import { CustomPaletteColorScale } from "./CustomPaletteColorScale";
import { toColorCollection, fromColorCollection, ensureEnum } from "igniteui-angular-core/ES2015/componentUtil";
/**
 * ColorScale class for selecting a color from a given palette, or interpolating between adjacent colors in that palette.
*/
export const IgxCustomPaletteColorScaleComponent_PROVIDERS = [{ provide: IgxColorScaleComponent, useExisting: forwardRef(() => IgxCustomPaletteColorScaleComponent) }];
let IgxCustomPaletteColorScaleComponent = IgxCustomPaletteColorScaleComponent_1 = class IgxCustomPaletteColorScaleComponent extends IgxColorScaleComponent {
    constructor() {
        super();
    }
    createImplementation() {
        return new CustomPaletteColorScale();
    }
    get i() {
        return this._implementation;
    }
    /**
     * The lowest value to assign a color.  Any given value less than this value will be made Transparent.
    */
    get minimumValue() {
        return this.i.minimumValue;
    }
    set minimumValue(v) {
        this.i.minimumValue = +v;
    }
    /**
     * The highest value to assign a color.  Any given value greater than this value will be made Transparent.
    */
    get maximumValue() {
        return this.i.maximumValue;
    }
    set maximumValue(v) {
        this.i.maximumValue = +v;
    }
    /**
     * A list of colors to select from or interpolate between.
    */
    get palette() {
        return fromColorCollection(this.i.palette);
    }
    set palette(v) {
        this.i.palette = toColorCollection(v);
    }
    /**
     * The approach to use when getting a color from the palette.
    */
    get interpolationMode() {
        return this.i.interpolationMode;
    }
    set interpolationMode(v) {
        this.i.interpolationMode = ensureEnum(ColorScaleInterpolationMode_$type, v);
    }
    providePalette(colors) {
        this.i.providePalette(colors);
    }
};
tslib_1.__decorate([
    Input(),
    tslib_1.__metadata("design:type", Number),
    tslib_1.__metadata("design:paramtypes", [Number])
], IgxCustomPaletteColorScaleComponent.prototype, "minimumValue", null);
tslib_1.__decorate([
    Input(),
    tslib_1.__metadata("design:type", Number),
    tslib_1.__metadata("design:paramtypes", [Number])
], IgxCustomPaletteColorScaleComponent.prototype, "maximumValue", null);
tslib_1.__decorate([
    Input(),
    tslib_1.__metadata("design:type", Array),
    tslib_1.__metadata("design:paramtypes", [Array])
], IgxCustomPaletteColorScaleComponent.prototype, "palette", null);
tslib_1.__decorate([
    Input(),
    tslib_1.__metadata("design:type", Number),
    tslib_1.__metadata("design:paramtypes", [Number])
], IgxCustomPaletteColorScaleComponent.prototype, "interpolationMode", null);
IgxCustomPaletteColorScaleComponent = IgxCustomPaletteColorScaleComponent_1 = tslib_1.__decorate([
    Component({
        selector: 'igx-custom-palette-color-scale',
        template: ``,
        providers: [{ provide: IgxColorScaleComponent, useExisting: forwardRef(() => IgxCustomPaletteColorScaleComponent_1) }],
        changeDetection: ChangeDetectionStrategy.OnPush
    }),
    tslib_1.__metadata("design:paramtypes", [])
], IgxCustomPaletteColorScaleComponent);
export { IgxCustomPaletteColorScaleComponent };
//# sourceMappingURL=igx-custom-palette-color-scale-component.js.map