import * as tslib_1 from "tslib";
import { EditorType_$type } from "./EditorType";
import { IgcColumnComponent } from "./igc-column-component";
import { TextColumn } from "./TextColumn";
import { getAllPropertyNames, toSpinal, ensureEnum, enumToString } from "igniteui-webcomponents-core";
import { RegisterElementHelper } from "igniteui-webcomponents-core";
/**
 * Represents a Text grid column, used to allow the developer to display a formatted text in a cell.
*/
var IgcTextColumnComponent = /** @class */ /*@__PURE__*/ (function (_super) {
    tslib_1.__extends(IgcTextColumnComponent, _super);
    function IgcTextColumnComponent() {
        return _super.call(this) || this;
    }
    IgcTextColumnComponent.prototype.createImplementation = function () {
        return new TextColumn();
    };
    Object.defineProperty(IgcTextColumnComponent.prototype, "i", {
        /**
                                     * @hidden
                                     */
        get: function () {
            return this._implementation;
        },
        enumerable: true,
        configurable: true
    });
    IgcTextColumnComponent.prototype.connectedCallback = function () {
        if (_super.prototype["connectedCallback"]) {
            _super.prototype["connectedCallback"].call(this);
        }
        if (!this._attached) {
            this._attached = true;
            this._flushQueuedAttributes();
        }
    };
    Object.defineProperty(IgcTextColumnComponent, "observedAttributes", {
        get: function () {
            if (IgcTextColumnComponent._observedAttributesIgcTextColumnComponent == null) {
                var names = getAllPropertyNames(IgcTextColumnComponent);
                for (var i = 0; i < names.length; i++) {
                    names[i] = toSpinal(names[i]);
                }
                IgcTextColumnComponent._observedAttributesIgcTextColumnComponent = names;
            }
            return IgcTextColumnComponent._observedAttributesIgcTextColumnComponent;
        },
        enumerable: true,
        configurable: true
    });
    IgcTextColumnComponent.register = function () {
        if (!IgcTextColumnComponent._isElementRegistered) {
            IgcTextColumnComponent._isElementRegistered = true;
            RegisterElementHelper.registerElement(IgcTextColumnComponent.htmlTagName, IgcTextColumnComponent);
        }
    };
    Object.defineProperty(IgcTextColumnComponent.prototype, "editorType", {
        /**
         * Gets or sets the editor type used for editing cells in this column.
        */
        get: function () {
            return this.i.j3;
        },
        set: function (v) {
            this.i.j3 = ensureEnum(EditorType_$type, v);
            this._a("editorType", enumToString(EditorType_$type, this.i.j3));
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgcTextColumnComponent.prototype, "editorDataSource", {
        /**
         * Gets or sets the ComboBox data source.
        */
        get: function () {
            return this.i.j4;
        },
        set: function (v) {
            this.i.j4 = v;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgcTextColumnComponent.prototype, "editorTextField", {
        /**
         * Gets or sets the ComboBox text field.
        */
        get: function () {
            return this.i.j6;
        },
        set: function (v) {
            this.i.j6 = v;
        },
        enumerable: true,
        configurable: true
    });
    Object.defineProperty(IgcTextColumnComponent.prototype, "editorValueField", {
        /**
         * Gets or sets the ComboBox value field.
        */
        get: function () {
            return this.i.j2;
        },
        set: function (v) {
            this.i.j2 = v;
        },
        enumerable: true,
        configurable: true
    });
    IgcTextColumnComponent._observedAttributesIgcTextColumnComponent = null;
    IgcTextColumnComponent.htmlTagName = "igc-text-column";
    IgcTextColumnComponent._isElementRegistered = false;
    return IgcTextColumnComponent;
}(IgcColumnComponent));
export { IgcTextColumnComponent };
//# sourceMappingURL=igc-text-column-component.js.map
