import { createVNode, render } from 'vue';
import { ElImageViewer } from 'element-plus';

"use strict";
const elContainer = document.createElement("div");
document.body.appendChild(elContainer);
const getProps = (data) => {
  if (typeof data === "string") {
    return {
      "url-list": [data]
    };
  } else if (Array.isArray(data)) {
    return {
      "url-list": data
    };
  } else {
    return data;
  }
};
const MeImageViewer = (props, args = {}) => {
  const vnode = createVNode(ElImageViewer, {
    ...getProps(props),
    onClose: () => {
      render(null, elContainer);
    },
    ...args
  });
  render(vnode, elContainer);
};

export { MeImageViewer };
//# sourceMappingURL=index.mjs.map
