import React from 'react';
import PropTypes from 'prop-types';

import { Flex } from '@ui/components';

// Style
let classes = {};
/* istanbul ignore next */
if (typeof window !== 'undefined') classes = require('./style.module.scss');

const ModalFooter = ({ children, className, ...attrs }) => (
  <Flex className={[classes['Modal-Footer'], className || ''].join(' ')} justify="end" tag="footer" {...attrs}>
    {children}
  </Flex>
);

ModalFooter.propTypes = {
  children: PropTypes.any,
  className: PropTypes.node,
};

export default ModalFooter;
