import type { FC, PropsWithChildren, ReactElement } from "react";
import { useContext } from "react";
import type { TModalContext } from "../config/types";
import { ModalContext } from "../context";

/**
 * Тело модального окна
 * @returns {ReactElement}
 */
export const ModalContent: FC<PropsWithChildren> = ({ children }): ReactElement => {

  const { getCN } = useContext<TModalContext>(ModalContext);

  return (
    <article className={getCN("content")}>
      {children}
    </article>
  );

};
