import { jsxs } from "react/jsx-runtime";
import { Box } from "../../Box/Box.mjs";
import { nowrap } from "./AvoidWidowIcon.css.mjs";
const AvoidWidowIcon = ({
  children,
  iconPosition,
  space = "xxsmall",
  className
}) => /* @__PURE__ */ jsxs(
  Box,
  {
    component: "span",
    paddingRight: iconPosition === "leading" ? space : void 0,
    paddingLeft: iconPosition === "trailing" ? space : void 0,
    className: [nowrap, className],
    "aria-hidden": true,
    children: [
      iconPosition === "leading" ? children : void 0,
      "⁠",
      iconPosition === "trailing" ? children : void 0
    ]
  }
);
export {
  AvoidWidowIcon
};
