import "../../../../../node_modules/element-plus/es/index.mjs";
/* empty css                                                             */
/* empty css                                                                     */
import { computed, createBlock, openBlock, withCtx, resolveDynamicComponent, unref } from "vue";
import { getCurrentItem } from "../../utils/common.mjs";
import widgets from "./widgets.vue.mjs";
import _sfc_main$2 from "./pageHeaderBtn.vue.mjs";
import _sfc_main$1 from "./pageFooterBtn.vue.mjs";
import _sfc_main$3 from "./subTitleH2.vue.mjs";
import _sfc_main$4 from "./subForm.vue.mjs";
import subTable from "./subTable.vue.mjs";
import _sfc_main$5 from "./blank.vue.mjs";
import _sfc_main$6 from "./approvalHistory.vue.mjs";
import document from "./document.vue.mjs";
import contract from "./contract.vue.mjs";
import { ElScrollbar } from "../../../../../node_modules/element-plus/es/components/scrollbar/index.mjs";
const _sfc_main = {
  __name: "index",
  setup(__props) {
    const currentItem = computed(() => {
      return getCurrentItem();
    });
    const editingProperty = computed(() => {
      var _a, _b, _c, _d, _e, _f, _g, _h, _i, _j;
      switch ((_a = currentItem.value) == null ? void 0 : _a.type) {
        case "widgets":
          if (((_b = currentItem.value) == null ? void 0 : _b.fieldType) == "subTitle" || ((_c = currentItem.value) == null ? void 0 : _c.fieldType) == "h2") {
            return _sfc_main$3;
          } else if (((_d = currentItem.value) == null ? void 0 : _d.fieldType) == "subForm") {
            return _sfc_main$4;
          } else if (((_e = currentItem.value) == null ? void 0 : _e.fieldType) == "subTable") {
            return subTable;
          } else if (((_f = currentItem.value) == null ? void 0 : _f.fieldType) == "blank") {
            return _sfc_main$5;
          } else if (((_g = currentItem.value) == null ? void 0 : _g.fieldType) == "approvalHistory") {
            return _sfc_main$6;
          } else if (((_h = currentItem.value) == null ? void 0 : _h.fieldType) == "document") {
            return document;
          } else if (((_i = currentItem.value) == null ? void 0 : _i.fieldType) == "contract") {
            return contract;
          } else if (((_j = currentItem.value) == null ? void 0 : _j.fieldType) == "divider") {
            return null;
          } else {
            return widgets;
          }
        case "pageHeaderBtn":
          return _sfc_main$2;
        case "pageFooterBtn":
          return _sfc_main$1;
      }
      return null;
    });
    return (_ctx, _cache) => {
      const _component_el_scrollbar = ElScrollbar;
      return openBlock(), createBlock(_component_el_scrollbar, null, {
        default: withCtx(() => [
          (openBlock(), createBlock(resolveDynamicComponent(unref(editingProperty))))
        ]),
        _: 1
      });
    };
  }
};
export {
  _sfc_main as default
};
