import { h as e } from "./chunk.BlbRoQQ3.js";
import { af as t } from "./use-page-data.Cb2SuuwJ.js";
import "./chunk-LSPN22SI.D75E3zS-.js";
import { c as n } from "./twind.BiM9xcCd.js";
import { b as r } from "./jsx-runtime.DF4K5VCp.js";
import "./chroma-js.Dcir27CH.js";
import "./color-system.Dp99zR0T.js";
import "./react.BZZIbN3T.js";
import "./schema-resolver.p7B_pu36.js";
import { c as i } from "./iconify.BzZOJCu5.js";
import { b as a } from "./use-brick-style.DDPl-_C1.js";
import "./use-brick-manifest.Iv9SG-7-.js";
import { b as o } from "./BrickRoot.DbISziyH.js";
var s = /* @__PURE__ */ e(r());
function c({ brick: e, editable: r }) {
	let c = a(e), { props: l } = e, u = Array.isArray(l.links) ? l.links : [];
	return /* @__PURE__ */ (0, s.jsxs)(o, {
		brick: e,
		editable: r,
		manifest: t,
		className: n("flex justify-start items-start gap-2", Object.values(c)),
		children: [r && u.length === 0 && /* @__PURE__ */ (0, s.jsx)("div", {
			className: "flex items-center justify-center p-4 border-2 border-dashed border-gray-300 dark:border-gray-600 rounded-md",
			children: /* @__PURE__ */ (0, s.jsx)("span", {
				className: "text-sm text-gray-500 dark:text-gray-400",
				children: "Add social links to get started"
			})
		}), u.map((e, t) => /* @__PURE__ */ (0, s.jsxs)("a", {
			href: e.href,
			"data-prevented-by-editor": r ? "true" : "false",
			onClick: (e) => {
				r && e.preventDefault();
			},
			className: n("grow flex items-center gap-0.5 hover:opacity-80"),
			title: e.label || e.href,
			children: [e.icon && /* @__PURE__ */ (0, s.jsx)(i, {
				icon: e.icon,
				className: "text-[100%]"
			}), !l.icononly && e.label && /* @__PURE__ */ (0, s.jsx)("span", {
				className: "ml-1 text-nowrap",
				children: e.label
			})]
		}, t))]
	});
}
export { c as default };

//# sourceMappingURL=social-links.BYIMGZg5.js.map