/**
 * ldesign v0.2.14
 * (c) 2022/11/2 16:16 built by swimly
 * @license MIT
 */

import { h as helper } from '../../chunks/helper.js';
import Vue from 'vue';
import { renderContent } from '../../utils/render-node.js';
import { RadioProps } from './props.js';
import _Radio from './radio.js';
import '../../chunks/_commonjsHelpers.js';
import 'lodash';
import '../../utils/helper.js';
import 'lodash/camelCase';
import '../../utils/event.js';
import '../config-provider/config-receiver.js';
import 'lodash/mergeWith';
import '../config-provider/context.js';
import '../../chunks/zh_CN.js';
import '../config-provider/type.js';
import '../../utils/mixins.js';

var _RadioButton = Vue.extend({
  name: "LRadioButton",
  components: {
    Radio: _Radio
  },
  provide() {
    return {
      radioButton: this
    };
  },
  inject: {
    radioGroup: {
      default: void 0
    }
  },
  inheritAttrs: false,
  props: {
    ...RadioProps
  },
  render() {
    const h = arguments[0];
    const {
      $props,
      $listeners,
      radioGroup
    } = this;
    const radioProps = {
      props: {
        ...$props
      },
      on: $listeners
    };
    if (radioGroup) {
      radioProps.props.checked = $props.value === radioGroup.value;
      radioProps.props.disabled = $props.disabled === void 0 ? radioGroup.disabled : $props.disabled;
      radioProps.props.name = radioGroup.name;
    }
    return h(_Radio, helper([{}, radioProps]), [renderContent(this, "default", "label")]);
  }
});

export { _RadioButton as default };
//# sourceMappingURL=radio-button.js.map
