Added a re-usable "yes/no" confirmation modal where the client just sets the question string and gets a callback to handle "OK". It doesn't make sense to create one modal for each confirmation, especially when it's only used in one place. Replaced one of the existing modal as an example.
10 lines
262 B
JavaScript
10 lines
262 B
JavaScript
import { connect } from 'react-redux';
|
|
import { doHideModal } from 'redux/actions/app';
|
|
|
|
import ModalConfirm from './view';
|
|
|
|
const perform = (dispatch) => ({
|
|
doHideModal: () => dispatch(doHideModal()),
|
|
});
|
|
|
|
export default connect(null, perform)(ModalConfirm);
|