ee9f63a161
bugfix wip flow fix cleaning clean
29 lines
1 KiB
JavaScript
29 lines
1 KiB
JavaScript
import { connect } from 'react-redux';
|
|
import {
|
|
makeSelectClaimForUri,
|
|
makeSelectContentTypeForUri,
|
|
makeSelectMetadataForUri,
|
|
makeSelectClaimIsMine,
|
|
} from 'redux/selectors/claims';
|
|
import { makeSelectPendingAmountByUri } from 'redux/selectors/wallet';
|
|
import { makeSelectFileInfoForUri } from 'redux/selectors/file_info';
|
|
import { selectUser } from 'redux/selectors/user';
|
|
import { doOpenModal } from 'redux/actions/app';
|
|
|
|
import FileValues from './view';
|
|
|
|
const select = (state, props) => ({
|
|
claim: makeSelectClaimForUri(props.uri)(state),
|
|
contentType: makeSelectContentTypeForUri(props.uri)(state),
|
|
fileInfo: makeSelectFileInfoForUri(props.uri)(state),
|
|
metadata: makeSelectMetadataForUri(props.uri)(state),
|
|
user: selectUser(state),
|
|
pendingAmount: makeSelectPendingAmountByUri(props.uri)(state),
|
|
claimIsMine: makeSelectClaimIsMine(props.uri)(state),
|
|
});
|
|
|
|
const perform = (dispatch) => ({
|
|
openModal: (modal, props) => dispatch(doOpenModal(modal, props)),
|
|
});
|
|
|
|
export default connect(select, perform)(FileValues);
|