"use strict";

import { forwardRef } from "react";
import { useIOTheme } from "../../context";
import { IOText } from "./IOText";
import { jsx as _jsx } from "react/jsx-runtime";
export const captionFontSize = 12;

/**
 * `Caption` typographic style
 */
export const Caption = /*#__PURE__*/forwardRef(({
  color: customColor,
  ...props
}, ref) => {
  const theme = useIOTheme();
  const CaptionProps = {
    ...props,
    dynamicTypeRamp: "caption1",
    // iOS only
    weight: "Regular",
    size: captionFontSize,
    color: customColor ?? theme["textBody-default"],
    textStyle: {
      textTransform: "uppercase",
      letterSpacing: 0.5
    }
  };
  return /*#__PURE__*/_jsx(IOText, {
    ref: ref,
    ...CaptionProps,
    children: props.children
  });
});
//# sourceMappingURL=Caption.js.map