]> git.localhorst.tv Git - alttp.git/blob - resources/js/components/rounds/EditDialog.js
svg dungeon tracker
[alttp.git] / resources / js / components / rounds / EditDialog.js
1 import PropTypes from 'prop-types';
2 import React from 'react';
3 import { Modal } from 'react-bootstrap';
4 import { withTranslation } from 'react-i18next';
5
6 import EditForm from './EditForm';
7 import i18n from '../../i18n';
8
9 const EditDialog = ({
10         onHide,
11         round,
12         show,
13 }) =>
14 <Modal className="edit-dialog" onHide={onHide} show={show}>
15         <Modal.Header closeButton>
16                 <Modal.Title>
17                         {i18n.t('rounds.edit')}
18                 </Modal.Title>
19         </Modal.Header>
20         <EditForm
21                 onCancel={onHide}
22                 round={round}
23         />
24 </Modal>;
25
26 EditDialog.propTypes = {
27         onHide: PropTypes.func,
28         round: PropTypes.shape({
29         }),
30         show: PropTypes.bool,
31         tournament: PropTypes.shape({
32         }),
33 };
34
35 export default withTranslation()(EditDialog);