import { __decorate, __extends } from "tslib";
import Component from 'vue-class-component';
import { Prop } from 'vue-property-decorator';
import { ModulVue } from '../../utils/vue/vue';
import { RADIO_STYLE_NAME } from '../component-names';
import WithRender from './radio-style.html?style=./radio-style.scss';
export var MRadioStylePosition;
(function (MRadioStylePosition) {
    MRadioStylePosition["Left"] = "left";
    MRadioStylePosition["Right"] = "right";
})(MRadioStylePosition || (MRadioStylePosition = {}));
var MRadioStyle = /** @class */ (function (_super) {
    __extends(MRadioStyle, _super);
    function MRadioStyle() {
        return _super !== null && _super.apply(this, arguments) || this;
    }
    Object.defineProperty(MRadioStyle.prototype, "isInputRight", {
        get: function () {
            return this.radioPosition === MRadioStylePosition.Right;
        },
        enumerable: false,
        configurable: true
    });
    MRadioStyle.prototype.onClick = function (event) {
        if (!this.disabled) {
            this.$emit('click', event);
        }
    };
    __decorate([
        Prop({
            default: MRadioStylePosition.Right,
            validator: function (value) {
                return value === MRadioStylePosition.Left ||
                    value === MRadioStylePosition.Right;
            }
        })
    ], MRadioStyle.prototype, "radioPosition", void 0);
    __decorate([
        Prop({ default: '1em' })
    ], MRadioStyle.prototype, "inputSize", void 0);
    __decorate([
        Prop()
    ], MRadioStyle.prototype, "focus", void 0);
    __decorate([
        Prop()
    ], MRadioStyle.prototype, "checked", void 0);
    __decorate([
        Prop()
    ], MRadioStyle.prototype, "disabled", void 0);
    __decorate([
        Prop()
    ], MRadioStyle.prototype, "fullWidth", void 0);
    MRadioStyle = __decorate([
        WithRender,
        Component
    ], MRadioStyle);
    return MRadioStyle;
}(ModulVue));
export { MRadioStyle };
var RadioStylePlugin = {
    install: function (v, options) {
        v.component(RADIO_STYLE_NAME, MRadioStyle);
    }
};
export default RadioStylePlugin;
//# sourceMappingURL=radio-style.js.map