import { jsx } from "react/jsx-runtime";
import classNames from "classnames";
import { getSpacingClasses, getSemanticTypeFromTextVariant } from "../utils/utils.mjs";
/* empty css           */
const TypographyText = ({
  children,
  as,
  size,
  variant,
  weight,
  spacing,
  className,
  ...rest
}) => {
  const BodyElement = as || getSemanticTypeFromTextVariant(variant);
  return /* @__PURE__ */ jsx(
    BodyElement,
    {
      className: classNames(
        "eds-text",
        variant && `eds-text--${variant}`,
        size && `eds-text--${size}`,
        weight && `eds-text--weight-${weight}`,
        getSpacingClasses(spacing, "eds-text"),
        className
      ),
      ...rest,
      children
    }
  );
};
const Text = TypographyText;
export {
  Text
};
//# sourceMappingURL=Text.mjs.map
