"use strict";

import { forwardRef } from "react";
import { useIOTheme } from "../../context";
import { IOText } from "./IOText";
import { jsx as _jsx } from "react/jsx-runtime";
export const h2FontSize = 26;
export const h2LineHeight = 34;

/**
 * `H2` typographic style
 */
export const H2 = /*#__PURE__*/forwardRef(({
  weight: customWeight,
  color: customColor,
  ...props
}, ref) => {
  const theme = useIOTheme();
  const H2Props = {
    ...props,
    dynamicTypeRamp: "title1",
    // iOS only
    weight: customWeight ?? "Semibold",
    size: h2FontSize,
    lineHeight: h2LineHeight,
    color: customColor ?? theme["textHeading-default"]
  };
  return /*#__PURE__*/_jsx(IOText, {
    ref: ref,
    ...H2Props,
    children: props.children
  });
});
//# sourceMappingURL=H2.js.map