import { useGun as u, reactive as a, currentRoom as p, computed as l, openBlock as m, createElementBlock as i, toDisplayString as d, createCommentVNode as g } from "./composables-Ci32s3jE.js";
const h = {
  key: 0,
  class: "m-1 flex items-center items-center px-2 py-1 bg-light-700 dark-bg-dark-50 rounded-lg"
}, f = {
  __name: "PostLink",
  props: {
    hash: {
      type: String,
      default: ""
    }
  },
  setup(o) {
    const c = o, r = u(), t = a({});
    r.user(p.pub).get("posts").map().once((n, e) => {
      e.indexOf(c.hash) == 0 && n ? t[e.substring(45, 87)] = n : delete t[e];
    });
    const s = l(() => Object.keys(t).length);
    return (n, e) => s.value > 0 ? (m(), i("button", h, d(s.value), 1)) : g("", !0);
  }
};
export {
  f as default
};
//# sourceMappingURL=PostLink-C1HoMO2O.js.map
