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 ModalFooter: FC<PropsWithChildren> = ({ children }): ReactElement => {

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

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

};
