import { defineComponent as c, resolveComponent as i, unref as m, openBlock as p, createElementBlock as u, normalizeClass as r, renderSlot as s, createElementVNode as n, createVNode as f } from "vue";
import { useCoreStore as _ } from "@feedmepos/mf-common";
import { _ as b } from "./_plugin-vue_export-helper-CHgC5LLL.js";
const v = { class: "fm-typo-en-body-sm-400 justify-center flex items-center w-full" }, y = /* @__PURE__ */ c({
  __name: "FmAdminBadge",
  props: {
    class: { default: void 0 },
    selectable: { type: Boolean, default: !1 }
  },
  setup(a) {
    const e = a, d = _();
    return (o, g) => {
      var t;
      const l = i("FmIcon");
      return (t = m(d).sessionUser.value) != null && t.role.isAdmin ? (p(), u("div", {
        key: 0,
        class: r([
          "group gap-8 inline-flex items-center relative border-1 border-dashed rounded-md border-red-500 hover:border-opacity-30 transition-opacity",
          { "select-none": !e.selectable }
        ])
      }, [
        s(o.$slots, "default", {}, void 0, !0),
        n("div", {
          class: r([
            "fm-admin-badge",
            "group-hover:opacity-20",
            e.class,
            {
              absolute: !0,
              "bottom-[-5px] right-[-8px] px-4 h-[25px] w-[25px] border-2 border-red-800": !0
            }
          ])
        }, [
          n("span", v, [
            f(l, {
              name: "support_agent",
              size: "sm",
              outline: ""
            })
          ])
        ], 2)
      ], 2)) : s(o.$slots, "non-admin", { key: 1 }, void 0, !0);
    };
  }
}), F = /* @__PURE__ */ b(y, [["__scopeId", "data-v-309cdb5a"]]);
export {
  F
};
