2018-03-26 23:32:43 +02:00
|
|
|
import { connect } from 'react-redux';
|
2018-10-29 18:23:53 +01:00
|
|
|
import { doHideModal } from 'redux/actions/app';
|
2019-06-25 06:05:46 +02:00
|
|
|
import ModalPublishSuccess from './view';
|
2021-03-24 06:22:02 +01:00
|
|
|
import { doClearPublish, makeSelectClaimForUri } from 'lbry-redux';
|
2019-04-10 23:27:12 +02:00
|
|
|
import { push } from 'connected-react-router';
|
2018-03-26 23:32:43 +02:00
|
|
|
|
2021-03-24 06:22:02 +01:00
|
|
|
const select = (state, props) => ({
|
|
|
|
claim: makeSelectClaimForUri(props.uri)(state),
|
|
|
|
});
|
|
|
|
|
|
|
|
const perform = (dispatch) => ({
|
2018-10-29 18:23:53 +01:00
|
|
|
closeModal: () => dispatch(doHideModal()),
|
2018-03-26 23:32:43 +02:00
|
|
|
clearPublish: () => dispatch(doClearPublish()),
|
2021-03-24 06:22:02 +01:00
|
|
|
navigate: (path) => dispatch(push(path)),
|
2018-03-26 23:32:43 +02:00
|
|
|
});
|
|
|
|
|
2021-03-24 06:22:02 +01:00
|
|
|
export default connect(select, perform)(ModalPublishSuccess);
|