"use strict";
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
const style = require("../../../utils/dom/style.js");
const index = require("../../../hooks/use-locale/index.js");
const index$1 = require("../../../hooks/use-namespace/index.js");
const empty = require("./empty.js");
const imgEmpty = require("./img-empty.js");
const vue = require("vue");
const _hoisted_1 = ["src"];
const _hoisted_2 = { key: 1 };
var empty_vue_vue_type_script_setup_true_lang_default = /* @__PURE__ */ vue.defineComponent({
  name: "ElEmpty",
  __name: "empty",
  props: empty.emptyProps,
  setup(__props) {
    const props = __props;
    const { t } = index.useLocale();
    const ns = index$1.useNamespace("empty");
    const emptyDescription = vue.computed(() => props.description || t("el.table.emptyText"));
    const imageStyle = vue.computed(() => ({ width: style.addUnit(props.imageSize) }));
    return (_ctx, _cache) => {
      return vue.openBlock(), vue.createElementBlock("div", { class: vue.normalizeClass(vue.unref(ns).b()) }, [
        vue.createElementVNode("div", {
          class: vue.normalizeClass(vue.unref(ns).e("image")),
          style: vue.normalizeStyle(imageStyle.value)
        }, [__props.image ? (vue.openBlock(), vue.createElementBlock("img", {
          key: 0,
          src: __props.image,
          ondragstart: "return false"
        }, null, 8, _hoisted_1)) : vue.renderSlot(_ctx.$slots, "image", { key: 1 }, () => [vue.createVNode(imgEmpty.default)])], 6),
        vue.createElementVNode("div", { class: vue.normalizeClass(vue.unref(ns).e("description")) }, [_ctx.$slots.description ? vue.renderSlot(_ctx.$slots, "description", { key: 0 }) : (vue.openBlock(), vue.createElementBlock("p", _hoisted_2, vue.toDisplayString(emptyDescription.value), 1))], 2),
        _ctx.$slots.default ? (vue.openBlock(), vue.createElementBlock("div", {
          key: 0,
          class: vue.normalizeClass(vue.unref(ns).e("bottom"))
        }, [vue.renderSlot(_ctx.$slots, "default")], 2)) : vue.createCommentVNode("v-if", true)
      ], 2);
    };
  }
});
exports.default = empty_vue_vue_type_script_setup_true_lang_default;
