import { defineComponent, useSlots, ref, resolveComponent, createBlock, openBlock, mergeProps, toHandlers, unref, createSlots, withCtx, renderSlot } from 'vue';
import '../../../../utils/index.mjs';
import { inputEmits } from 'element-plus';
import { inputEmits as inputEmits$1, inputProps } from './input.mjs';
import { getGmEvent } from '../../../../utils/src/elementPlus/event.mjs';
import { getGmExports } from '../../../../utils/src/elementPlus/exports.mjs';

var _sfc_main = /* @__PURE__ */ defineComponent({
  ...{
    name: "GmInput"
  },
  __name: "Input",
  props: inputProps,
  emits: inputEmits$1,
  setup(__props, { expose: __expose, emit: __emit }) {
    const slots = useSlots();
    const props = __props;
    const emit = __emit;
    const elEvents = getGmEvent(inputEmits, emit);
    const elRef = ref();
    const exposeNames = ["blur", "clear", "focus", "input", "ref", "resizeTextarea", "select", "textarea", "textareaStyle"];
    const { exposeFns } = getGmExports(elRef, exposeNames);
    __expose({
      ...exposeFns
    });
    return (_ctx, _cache) => {
      const _component_el_input = resolveComponent("el-input");
      return openBlock(), createBlock(
        _component_el_input,
        mergeProps({
          ref_key: "elRef",
          ref: elRef
        }, props, toHandlers(unref(elEvents))),
        createSlots({
          _: 2
          /* DYNAMIC */
        }, [
          unref(slots).prefix ? {
            name: "prefix",
            fn: withCtx(() => [
              renderSlot(_ctx.$slots, "prefix")
            ]),
            key: "0"
          } : void 0,
          unref(slots).suffix ? {
            name: "suffix",
            fn: withCtx(() => [
              renderSlot(_ctx.$slots, "suffix")
            ]),
            key: "1"
          } : void 0,
          unref(slots).prepend ? {
            name: "prepend",
            fn: withCtx(() => [
              renderSlot(_ctx.$slots, "prepend")
            ]),
            key: "2"
          } : void 0,
          unref(slots).append ? {
            name: "append",
            fn: withCtx(() => [
              renderSlot(_ctx.$slots, "append")
            ]),
            key: "3"
          } : void 0
        ]),
        1040
        /* FULL_PROPS, DYNAMIC_SLOTS */
      );
    };
  }
});

export { _sfc_main as default };
//# sourceMappingURL=Input.vue2.mjs.map
