"use strict";
Object.defineProperties(exports, { __esModule: { value: true }, [Symbol.toStringTag]: { value: "Module" } });
require("../../../../../node_modules/element-plus/es/index.js");
;/* empty css                                                             */
const Vue = require("vue");
const H2Wrapper = require("./H2Wrapper.vue.js");
const SubTitle = require("./SubTitle.vue.js");
;/* empty css               */
const _pluginVue_exportHelper = require("../../../../../_virtual/_plugin-vue_export-helper.js");
const index = require("../../../../../node_modules/element-plus/es/components/icon/index.js");
const _hoisted_1 = { class: "contract-container" };
const _hoisted_2 = {
  key: 0,
  style: { "margin-bottom": "12px" }
};
const _hoisted_3 = { class: "contract-preview" };
const _hoisted_4 = { class: "preview-icon" };
const _hoisted_5 = { class: "preview-info" };
const _hoisted_6 = ["title"];
const _hoisted_7 = { class: "preview-mode" };
const _sfc_main = {
  __name: "Contract",
  props: {
    componentData: {
      type: Object,
      required: true
    }
  },
  setup(__props) {
    const props = __props;
    const titleMode = Vue.computed(() => {
      var _a;
      const mode = ((_a = props.componentData) == null ? void 0 : _a.titleMode) || "none";
      return mode;
    });
    const modeText = Vue.computed(() => {
      var _a;
      const modeMap = {
        view: "合同查看",
        make: "合同制作",
        sign: "合同签署"
      };
      return modeMap[(_a = props.componentData) == null ? void 0 : _a.mode] || "合同查看";
    });
    return (_ctx, _cache) => {
      const _component_Document = Vue.resolveComponent("Document");
      const _component_el_icon = index.ElIcon;
      return Vue.openBlock(), Vue.createElementBlock("div", _hoisted_1, [
        titleMode.value !== "none" ? (Vue.openBlock(), Vue.createElementBlock("div", _hoisted_2, [
          titleMode.value === "label" ? (Vue.openBlock(), Vue.createBlock(H2Wrapper.default, {
            key: 0,
            componentData: __props.componentData
          }, null, 8, ["componentData"])) : titleMode.value === "subLabel" ? (Vue.openBlock(), Vue.createBlock(SubTitle.default, {
            key: 1,
            componentData: __props.componentData
          }, null, 8, ["componentData"])) : Vue.createCommentVNode("", true)
        ])) : Vue.createCommentVNode("", true),
        Vue.createElementVNode("div", _hoisted_3, [
          Vue.createElementVNode("div", _hoisted_4, [
            Vue.createVNode(_component_el_icon, null, {
              default: Vue.withCtx(() => [
                Vue.createVNode(_component_Document)
              ]),
              _: 1
            })
          ]),
          Vue.createElementVNode("div", _hoisted_5, [
            Vue.createElementVNode("div", {
              class: "preview-name",
              title: __props.componentData.label
            }, Vue.toDisplayString(__props.componentData.label), 9, _hoisted_6),
            Vue.createElementVNode("div", _hoisted_7, Vue.toDisplayString(modeText.value), 1)
          ])
        ])
      ]);
    };
  }
};
const Contract = /* @__PURE__ */ _pluginVue_exportHelper.default(_sfc_main, [["__scopeId", "data-v-cbec96d0"]]);
exports.default = Contract;
