import { j as r } from "../../../../../_virtual/jsx-runtime.js";
import { a as c } from "../../../../sdk/dist/shared/chunk-TTTXV7TJ.js";
import "@sinclair/typebox";
import "../../../../sdk/dist/shared/chunk-UU2MSQXY.js";
import "../../../../sdk/dist/shared/chunk-UMHXXXVP.js";
import { useBrickStyle as m } from "../hooks/use-brick-style.js";
import i from "../components/TextContent.js";
import { tx as a } from "../../../../style-system/dist/twind.js";
import { isTextContentEmpty as l } from "../utils/text-content.js";
import x from "../components/BrickRoot.js";
import { useBrickProps as f } from "../hooks/use-brick-props.js";
function B(n) {
  const { brick: t, editable: o, selected: s } = n, e = f(n), p = m(t);
  return /* @__PURE__ */ r.jsxs(
    x,
    {
      brick: t,
      editable: o,
      manifest: c,
      className: a("flex-col gap-[1.5rem] flex-grow", Object.values(p)),
      children: [
        /* @__PURE__ */ r.jsx(
          i,
          {
            as: "h1",
            propPath: "content",
            brickId: t.id,
            content: e.content,
            rawContent: t.props.content,
            textSizeMode: "hero",
            editable: o,
            noTextType: !0
          }
        ),
        /* @__PURE__ */ r.jsx(
          i,
          {
            as: "p",
            propPath: "tagline",
            className: a(
              "tagline text-2xl font-bold text-balance",
              // When editing, hide tagline if empty but show it on hover
              o && l(e.tagline) && !s ? "opacity-0 hover:opacity-80" : "opacity-80"
            ),
            brickId: t.id,
            content: e.tagline,
            rawContent: t.props.tagline,
            editable: o
          }
        )
      ]
    }
  );
}
export {
  B as default
};
//# sourceMappingURL=hero.js.map
