import { computed as u, useGun as p, reactive as f, openBlock as r, createElementBlock as a, createBaseVNode as o, createVNode as m, unref as g, toDisplayString as c, createCommentVNode as y } from "./composables-Ci32s3jE.js";
import { RoomFeatureIcon as b } from "./components.js";
const h = ["title"], x = { class: "text-4xl" }, _ = { class: "px-1 font-bold" }, k = {
  key: 0,
  class: "i-la-lock-open text-xs absolute top-1 right-1 opacity-30"
}, v = { class: "absolute bottom-1 right-1 text-xs opacity-30" }, D = {
  __name: "RoomFeature",
  props: {
    cert: { type: String, default: "" },
    open: { type: [Boolean, String], default: !1 },
    title: { type: String, default: "" },
    type: { type: String, default: "" },
    pub: { type: String, default: "OKrDaDeD8VeA27d673RqlodSnebnaDq6Ci23Ys_ABWE.q8fI2lkxO46R8TMjeUeAf7I0yBS5mdH_Cb9_285Wkqk" }
  },
  emits: ["browse"],
  setup(e) {
    const n = e, i = u(() => {
      const s = p(), t = f({});
      return s.user(n.pub).get(n.type).map().once((l, d) => {
        l && (t[d] = !0);
      }), t;
    });
    return (s, t) => (r(), a("div", {
      class: "cursor-pointer flex-1 flex flex-col items-center p-4 relative bg-light-700 dark-bg-dark-200 rounded-lg shadow-sm transition hover-shadow-lg",
      title: e.cert
    }, [
      o("div", x, [
        m(g(b), { icon: e.type }, null, 8, ["icon"])
      ]),
      o("div", _, c(e.title), 1),
      e.open ? (r(), a("div", k)) : y("", !0),
      o("div", v, c(Object.keys(i.value).length), 1)
    ], 8, h));
  }
};
export {
  D as default
};
//# sourceMappingURL=RoomFeature-CIj-BDWq.js.map
