import { resolveComponent, resolveDirective, openBlock, createBlock, Teleport, createVNode, Transition, withCtx, withDirectives, createElementVNode, normalizeClass, normalizeStyle, withModifiers, renderSlot, toDisplayString, createElementBlock, resolveDynamicComponent, createCommentVNode, Fragment, createTextVNode, vShow } from 'vue';

const _hoisted_1 = ["aria-label"];
const _hoisted_2 = { class: "el-dialog__header" };
const _hoisted_3 = { class: "el-dialog__title" };
const _hoisted_4 = { class: "el-dialog__body" };
const _hoisted_5 = {
  key: 1,
  class: "el-dialog__footer"
};
function render(_ctx, _cache, $props, $setup, $data, $options) {
  const _component_el_icon = resolveComponent("el-icon");
  const _component_ElButton = resolveComponent("ElButton");
  const _component_el_overlay = resolveComponent("el-overlay");
  const _directive_trap_focus = resolveDirective("trap-focus");
  return openBlock(), createBlock(Teleport, {
    to: "body",
    disabled: !_ctx.appendToBody
  }, [
    createVNode(Transition, {
      name: "dialog-fade",
      onAfterEnter: _ctx.afterEnter,
      onAfterLeave: _ctx.afterLeave,
      onBeforeLeave: _ctx.beforeLeave
    }, {
      default: withCtx(() => [
        withDirectives(createVNode(_component_el_overlay, {
          "custom-mask-event": "",
          mask: _ctx.modal,
          "overlay-class": _ctx.modalClass,
          "z-index": _ctx.zIndex
        }, {
          default: withCtx(() => [
            createElementVNode("div", {
              class: "el-overlay-dialog",
              onClick: _cache[2] || (_cache[2] = (...args) => _ctx.overlayEvent.onClick && _ctx.overlayEvent.onClick(...args)),
              onMousedown: _cache[3] || (_cache[3] = (...args) => _ctx.overlayEvent.onMousedown && _ctx.overlayEvent.onMousedown(...args)),
              onMouseup: _cache[4] || (_cache[4] = (...args) => _ctx.overlayEvent.onMouseup && _ctx.overlayEvent.onMouseup(...args))
            }, [
              withDirectives(createElementVNode("div", {
                ref: "dialogRef",
                class: normalizeClass([
                  "el-dialog",
                  {
                    "is-fullscreen": _ctx.fullscreen,
                    "el-dialog--center": _ctx.center
                  },
                  _ctx.customClass
                ]),
                "aria-modal": "true",
                role: "dialog",
                "aria-label": _ctx.title || "dialog",
                style: normalizeStyle(_ctx.style),
                onClick: _cache[1] || (_cache[1] = withModifiers(() => {
                }, ["stop"]))
              }, [
                createElementVNode("div", _hoisted_2, [
                  renderSlot(_ctx.$slots, "title", {}, () => [
                    createElementVNode("span", _hoisted_3, toDisplayString(_ctx.title), 1)
                  ]),
                  _ctx.showClose ? (openBlock(), createElementBlock("button", {
                    key: 0,
                    "aria-label": "close",
                    class: "el-dialog__headerbtn",
                    type: "button",
                    onClick: _cache[0] || (_cache[0] = (...args) => _ctx.handleClose && _ctx.handleClose(...args))
                  }, [
                    createVNode(_component_el_icon, { class: "el-dialog__close" }, {
                      default: withCtx(() => [
                        (openBlock(), createBlock(resolveDynamicComponent(_ctx.closeIcon || "close")))
                      ]),
                      _: 1
                    })
                  ])) : createCommentVNode("v-if", true)
                ]),
                _ctx.rendered ? (openBlock(), createElementBlock(Fragment, { key: 0 }, [
                  renderSlot(_ctx.$slots, "body-prefix"),
                  createElementVNode("div", _hoisted_4, [
                    renderSlot(_ctx.$slots, "default")
                  ]),
                  renderSlot(_ctx.$slots, "body-suffix")
                ], 64)) : createCommentVNode("v-if", true),
                _ctx.isShowFooter ? (openBlock(), createElementBlock("div", _hoisted_5, [
                  renderSlot(_ctx.$slots, "footer", {}, () => [
                    _ctx.cancelText ? (openBlock(), createBlock(_component_ElButton, {
                      key: 0,
                      class: "el-dialog__footerBtn",
                      onClick: _ctx.handleClose
                    }, {
                      default: withCtx(() => [
                        createTextVNode(toDisplayString(_ctx.cancelText), 1)
                      ]),
                      _: 1
                    }, 8, ["onClick"])) : createCommentVNode("v-if", true),
                    createVNode(_component_ElButton, {
                      loading: _ctx.loading,
                      type: "primary",
                      class: "el-dialog__footerBtn",
                      onClick: _ctx.handleSubmit
                    }, {
                      default: withCtx(() => [
                        createTextVNode(toDisplayString(_ctx.submitText), 1)
                      ]),
                      _: 1
                    }, 8, ["loading", "onClick"])
                  ])
                ])) : createCommentVNode("v-if", true)
              ], 14, _hoisted_1), [
                [_directive_trap_focus]
              ])
            ], 32)
          ]),
          _: 3
        }, 8, ["mask", "overlay-class", "z-index"]), [
          [vShow, _ctx.visible]
        ])
      ]),
      _: 3
    }, 8, ["onAfterEnter", "onAfterLeave", "onBeforeLeave"])
  ], 8, ["disabled"]);
}

export { render };
//# sourceMappingURL=dialog.vue_vue_type_template_id_02672805_lang.mjs.map
