1 import PropTypes from 'prop-types';
2 import React from 'react';
3 import { Alert, Button, Modal } from 'react-bootstrap';
4 import { withTranslation } from 'react-i18next';
6 import List from './List';
7 import i18n from '../../i18n';
9 class Dialog extends React.Component {
12 this.timer = setInterval(() => {
17 componentWillUnmount() {
18 clearInterval(this.timer);
27 return <Modal className="chat-bot-log-dialog" onHide={onHide} show={show} size="lg">
28 <Modal.Header closeButton>
30 {i18n.t('chatBotLog.heading')}
37 <Alert variant="info">
38 {i18n.t('chatBotLog.empty')}
43 <Button onClick={onHide} variant="secondary">
44 {i18n.t('button.close')}
53 log: PropTypes.arrayOf(PropTypes.shape({
55 onHide: PropTypes.func,
59 Dialog.defaultProps = {
65 export default withTranslation()(Dialog);