'use strict';

Object.defineProperty(exports, '__esModule', { value: true });

var normalizeComponent = require('./normalize-component-6fa50395.js');
var ThemeMixin = require('./ThemeMixin-a2f817cd.js');
require('./svg-atom-d2541b7d.js');
require('./icon-atom-65241b51.js');
require('./hover-atom-17a12a07.js');
require('./tooltip-atom-8f536df5.js');
var tooltipMolecule = require('./tooltip-molecule-479b5142.js');

var script = {
  name: 'VRadio',
  props: {
    value: {
      type: String,
      required: true
    },
    modelValue: {
      type: String,
      default: null
    },
    tooltipLabel: {
      type: String,
      default: null
    },
    isError: {
      type: Boolean,
      default: false
    }
  },
  computed: {
    vRadioCssClass: function vRadioCssClass() {
      return ThemeMixin._objectSpread2(ThemeMixin._objectSpread2({}, this.themeCssClass), {}, {
        'v-radio': true,
        'is-error': this.isError,
        'is-disabled': this.$attrs.disabled
      });
    }
  },
  methods: {
    onInputChange: function onInputChange() {
      this.$emit('change', this.value);
    }
  },
  mixins: [ThemeMixin.ThemeMixin],
  components: {
    TooltipMolecule: tooltipMolecule.TooltipMolecule
  },
  model: {
    prop: 'modelValue',
    event: 'change'
  }
};

/* script */
const __vue_script__ = script;

/* template */
var __vue_render__ = function () {var _vm=this;var _h=_vm.$createElement;var _c=_vm._self._c||_h;return _c('label',{class:_vm.vRadioCssClass},[_c('input',_vm._b({staticClass:"v-radio-input",attrs:{"type":"radio"},domProps:{"checked":_vm.value === _vm.modelValue},on:{"input":_vm.onInputChange}},'input',_vm.$attrs,false)),_vm._v(" "),_c('span',{staticClass:"v-radio-box"}),_vm._v(" "),(_vm.$slots.default)?_c('span',{staticClass:"v-radio-label"},[_vm._t("default")],2):_vm._e(),_vm._v(" "),(_vm.tooltipLabel)?_c('div',[_c('tooltip-molecule',{attrs:{"label":_vm.tooltipLabel}})],1):_vm._e()])};
var __vue_staticRenderFns__ = [];

  /* style */
  const __vue_inject_styles__ = undefined;
  /* scoped */
  const __vue_scope_id__ = undefined;
  /* module identifier */
  const __vue_module_identifier__ = undefined;
  /* functional template */
  const __vue_is_functional_template__ = false;
  /* style inject */
  
  /* style inject SSR */
  

  
  var VRadio = normalizeComponent.__vue_normalize__(
    { render: __vue_render__, staticRenderFns: __vue_staticRenderFns__ },
    __vue_inject_styles__,
    __vue_script__,
    __vue_scope_id__,
    __vue_is_functional_template__,
    __vue_module_identifier__,
    undefined,
    undefined
  );

exports.default = VRadio;
