lbry-desktop/ui/component/fileValues/index.js
jessopb 2895e93323
Sync pre cleanup (#7635)
* missing yarn lock

* rm modal youtube welcome

* prune some isAuthenticated

* remove invite components

* remove reward/verify components

* more odysee feature cleanup
2022-07-08 14:51:53 -04:00

31 lines
983 B
JavaScript

import { connect } from 'react-redux';
import {
selectClaimForUri,
makeSelectContentTypeForUri,
makeSelectMetadataForUri,
selectClaimIsMine,
} from 'redux/selectors/claims';
import { makeSelectPendingAmountByUri } from 'redux/selectors/wallet';
import { makeSelectFileInfoForUri } from 'redux/selectors/file_info';
import { doOpenModal } from 'redux/actions/app';
import FileValues from './view';
const select = (state, props) => {
const claim = selectClaimForUri(state, props.uri);
return {
claim,
contentType: makeSelectContentTypeForUri(props.uri)(state),
fileInfo: makeSelectFileInfoForUri(props.uri)(state),
metadata: makeSelectMetadataForUri(props.uri)(state),
pendingAmount: makeSelectPendingAmountByUri(props.uri)(state),
claimIsMine: selectClaimIsMine(state, claim),
};
};
const perform = (dispatch) => ({
openModal: (modal, props) => dispatch(doOpenModal(modal, props)),
});
export default connect(select, perform)(FileValues);