import React from 'react';
import { Modal, CloseButton } from 'react-bootstrap'

import './generic.modal.styles.scss'

const GenericModalComponent = ({ children, title ,...props}) => {
    
    return (
        <Modal
                {...props}
                size="md"
                aria-labelledby="contained-modal-title-vcenter"
                centered
            >
                <Modal.Header>
                    <Modal.Title id="contained-modal-title-vcenter">
                        <h3 className="modal-title">{title}</h3>                                            
                    </Modal.Title>
                    <CloseButton variant="white" onClick={props.onHide}/>
                </Modal.Header>
            <Modal.Body>
                {children}
            </Modal.Body>
            
      </Modal>        
    )
}

export default GenericModalComponent