import { ref as f, openBlock as i, createElementBlock as a, createBaseVNode as o, createVNode as l, withCtx as p, unref as r, Fragment as m } from "./composables-Ci32s3jE.js";
import { GiftForm as d, UiLayer as v } from "./components.js";
const g = { class: "p-2" }, b = {
  __name: "GiftButton",
  props: {
    gift: {
      type: Object,
      default: () => ({
        project: "",
        from: "",
        to: "",
        qn: 0,
        ql: ""
      })
    }
  },
  emits: ["sent"],
  setup(s) {
    const e = f();
    return (u, t) => (i(), a(m, null, [
      o("button", {
        class: "button",
        onClick: t[0] || (t[0] = (n) => e.value = !0)
      }, "Fund it now!"),
      l(r(v), {
        open: e.value,
        onClose: t[2] || (t[2] = (n) => e.value = !1)
      }, {
        default: p(() => [
          o("div", g, [
            l(r(d), {
              gift: s.gift,
              onSent: t[1] || (t[1] = (n) => {
                e.value = !1, u.$emit("sent", n);
              })
            }, null, 8, ["gift"])
          ])
        ]),
        _: 1
      }, 8, ["open"])
    ], 64));
  }
};
export {
  b as default
};
//# sourceMappingURL=GiftButton-BEzNm6dj.js.map
