import { defineComponent, openBlock, createElementBlock, createElementVNode, toDisplayString, unref, withDirectives, createTextVNode, Fragment, renderList, createVNode } from "vue";
import SvgIcon from "../common/base/SvgIcon.vue.mjs";
import copyIcon from "../common/icons/CopyIcon.vue.mjs";
import useRoomInvite from "./useRoomInviteHooks.mjs";
import vTap from "../../directives/vTap.mjs";
const _hoisted_1 = { class: "invite-container" };
const _hoisted_2 = { class: "invite-container-main" };
const _hoisted_3 = { class: "invite-title-main" };
const _hoisted_4 = { class: "cancel" };
const _hoisted_5 = { class: "invite-title" };
const _hoisted_6 = { class: "invite-content" };
const _hoisted_7 = { class: "invite-bottom" };
const _sfc_main = /* @__PURE__ */ defineComponent({
  __name: "indexH5",
  emits: ["on-close-invite"],
  setup(__props, { emit: __emit }) {
    const { t, onCopy, visibleInviteContentList, inviteBarTitle } = useRoomInvite();
    const emit = __emit;
    function handleCloseInvite() {
      emit("on-close-invite");
    }
    return (_ctx, _cache) => {
      return openBlock(), createElementBlock("div", _hoisted_1, [
        createElementVNode("div", _hoisted_2, [
          createElementVNode("div", _hoisted_3, [
            createElementVNode("div", null, toDisplayString(unref(t)("Invite")), 1),
            withDirectives((openBlock(), createElementBlock("span", _hoisted_4, [
              createTextVNode(toDisplayString(unref(t)("Cancel")), 1)
            ])), [
              [unref(vTap), handleCloseInvite]
            ])
          ]),
          (openBlock(true), createElementBlock(Fragment, null, renderList(unref(visibleInviteContentList), (item) => {
            return openBlock(), createElementBlock("div", {
              key: item.id,
              class: "invite-content-main"
            }, [
              createElementVNode("span", _hoisted_5, toDisplayString(unref(t)(item.mobileTitle)), 1),
              createElementVNode("span", _hoisted_6, toDisplayString(item.content), 1),
              withDirectives(createVNode(SvgIcon, {
                icon: copyIcon,
                class: "copy"
              }, null, 512), [
                [unref(vTap), () => unref(onCopy)(item.copyLink)]
              ])
            ]);
          }), 128)),
          createElementVNode("span", _hoisted_7, toDisplayString(unref(inviteBarTitle)), 1)
        ])
      ]);
    };
  }
});
export {
  _sfc_main as default
};
