import { j as f } from "../../../../../_virtual/jsx-runtime.js";
import { CollisionPriority as m } from "../../../../../node_modules/.pnpm/@dnd-kit_abstract@0.1.21/node_modules/@dnd-kit/abstract/index.js";
import { directionBiased as d } from "../../../../../node_modules/.pnpm/@dnd-kit_collision@0.1.21/node_modules/@dnd-kit/collision/dist/index.js";
import { useDroppable as c } from "../../../../../node_modules/.pnpm/@dnd-kit_react@0.1.21_react-dom@18.3.0-canary-3d9b20132-20240124_react@18.3.0-canary-3d_d5e73c0d556c94305a83c95cc0a8798b/node_modules/@dnd-kit/react/index.js";
import { tx as x } from "../../../../style-system/dist/twind.js";
function j({
  as: t,
  children: e,
  manifest: i,
  className: l,
  editable: n,
  brick: o,
  ...p
}) {
  const a = c({
    id: o.id,
    data: { brick: o, manifest: i },
    disabled: !n || !i.isContainer,
    type: "brick",
    accept: (r) => r.type === "brick" || r.type === "library",
    collisionDetector: d,
    collisionPriority: m.High
  }), s = t || "div";
  return /* @__PURE__ */ f.jsx(
    s,
    {
      ...p,
      ref: a.ref,
      className: x(
        !i.isContainer && "min-h-fit min-w-fit",
        "flex flex-1 rounded-[inherit] w-fill h-fill flex-wrap",
        l
      ),
      children: e
    }
  );
}
export {
  j as default
};
//# sourceMappingURL=BrickRoot.js.map
