UNPKG

fui-fancyui

Version:
44 lines (43 loc) 819 B
"use client"; import { jsxs as u, Fragment as h, jsx as $ } from "react/jsx-runtime"; import { css as i } from "styled-components"; import g from "react"; import { StyledFlexBox as y } from "./FancyFlexBox.style.js"; function C(n) { const { children: t, separator: e, externalStyle: o, align: l, direction: a, justify: s, fitBox: m, gap: c, as: d = "div", ...f } = n, p = e ? g.Children.map(t, (r, x) => x === 0 ? r : /* @__PURE__ */ u(h, { children: [ e, r ] })) : t; return /* @__PURE__ */ $( y, { as: d, $align: l, $direction: a, $justify: s, $gap: c, $externalStyle: i` ${m && i` height: 100%; `} ${o} `, ...f, children: p } ); } export { C as default };