// #region Imports
var __decorate = (this && this.__decorate) || function (decorators, target, key, desc) {
    var c = arguments.length, r = c < 3 ? target : desc === null ? desc = Object.getOwnPropertyDescriptor(target, key) : desc, d;
    if (typeof Reflect === "object" && typeof Reflect.decorate === "function") r = Reflect.decorate(decorators, target, key, desc);
    else for (var i = decorators.length - 1; i >= 0; i--) if (d = decorators[i]) r = (c < 3 ? d(r) : c > 3 ? d(target, key, r) : d(target, key)) || r;
    return c > 3 && r && Object.defineProperty(target, key, r), r;
};
var __metadata = (this && this.__metadata) || function (k, v) {
    if (typeof Reflect === "object" && typeof Reflect.metadata === "function") return Reflect.metadata(k, v);
};
import { Appearanceable } from '../../../Behaviors/Appearanceable';
import { Disableable } from '../../../Behaviors/Disableable';
import { Variantable } from '../../../Behaviors/Variantable';
import { Attribute } from '../../../Decorators/AttributeDecorator';
import { Component } from '../../../Decorators/ComponentDecorator';
import { CheckType } from '../../../Types/CheckType';
import { CustomElement } from '../../Abstracts/CustomElement';
import { checkmarkElementTemplate } from './CheckmarkElementTemplate';
import { checkmarkElementJoyStyle } from './Themes/CheckmarkElement.Joy';
import { checkmarkElementMemphisStyle } from './Themes/CheckmarkElement.Memphis';
import { checkmarkElementCosmopolitanStyle } from './Themes/CheckmarkElement.Cosmopolitan';
import { Themeable } from '../../../Behaviors/Themeable';
// #endregion
/**
 * Checkmark - A small marking symbol often used to indicate selected items.
 *
 * @element mosaik-checkmark
 *
 * @public
 */
let CheckmarkElement = class CheckmarkElement extends Themeable(Disableable(Variantable(Appearanceable(CustomElement)))) {
    // #region Fields
    _checked;
    _type;
    _isThreeState;
    // #endregion
    // #region Ctor
    /**
     * @public
     */
    constructor() {
        super();
        this._checked = false;
        this._type = null;
        this._isThreeState = false;
    }
    // #endregion
    // #region Properties
    /**
     * Returns the `is` property.
     *
     * @public
     * @static
     * @readonly
    */
    static get is() {
        return 'mosaik-checkmark';
    }
    /**
     * Gets or sets the `checked` property.
     *
     * @public
     * @attr
     */
    get checked() {
        return this._checked;
    }
    set checked(value) {
        if (this._checked !== value) {
            this._checked = value;
            this.requestUpdate('checked');
        }
    }
    /**
     * Gets or sets the `type` property.
     *
     * @public
     * @attr
     */
    get type() {
        return this._type;
    }
    set type(value) {
        if (this._type !== value) {
            this._type = value;
            this.requestUpdate('type');
        }
    }
    /**
     * Gets or sets the `isThreeState` property.
     *
     * @public
     * @attr
     */
    get isThreeState() { return this._isThreeState; }
    set isThreeState(value) {
        if (this._isThreeState !== value) {
            this._isThreeState = value;
            this.requestUpdate('isThreeState');
        }
    }
};
__decorate([
    Attribute({
        type: Boolean,
        useDefault: true,
        converter: {
            toAttribute: (value) => String(value)
            // fromAttribute: (value: string | null): boolean | null => value === 'true'
        }
    }),
    __metadata("design:type", Object),
    __metadata("design:paramtypes", [Object])
], CheckmarkElement.prototype, "checked", null);
__decorate([
    Attribute({ type: CheckType }),
    __metadata("design:type", Object),
    __metadata("design:paramtypes", [Object])
], CheckmarkElement.prototype, "type", null);
__decorate([
    Attribute({
        type: Boolean,
        useDefault: true
    }),
    __metadata("design:type", Boolean),
    __metadata("design:paramtypes", [Boolean])
], CheckmarkElement.prototype, "isThreeState", null);
CheckmarkElement = __decorate([
    Component({
        selector: 'mosaik-checkmark',
        template: checkmarkElementTemplate,
        themes: {
            joy: checkmarkElementJoyStyle,
            memphis: checkmarkElementMemphisStyle,
            cosmopolitan: checkmarkElementCosmopolitanStyle
        },
        imports: []
    }),
    __metadata("design:paramtypes", [])
], CheckmarkElement);
export { CheckmarkElement };
//# sourceMappingURL=CheckmarkElement.js.map