lbry-desktop/ui/component/fileReactions/index.js
zeppi ee9f63a161 integrate all the things
bugfix

wip

flow

fix

cleaning

clean
2021-10-15 23:49:41 -04:00

26 lines
935 B
JavaScript

import { connect } from 'react-redux';
import {
makeSelectReactionsForUri,
makeSelectMyReactionForUri,
makeSelectLikeCountForUri,
makeSelectDislikeCountForUri,
} from 'redux/selectors/reactions';
import { doFetchReactions, doReactionLike, doReactionDislike } from 'redux/actions/reactions';
import { selectThemePath } from 'redux/selectors/settings';
import FileViewCount from './view';
import { makeSelectClaimForUri } from 'redux/selectors/claims';
const select = (state, props) => ({
claim: makeSelectClaimForUri(props.uri)(state),
reactions: makeSelectReactionsForUri(props.uri)(state),
myReaction: makeSelectMyReactionForUri(props.uri)(state),
likeCount: makeSelectLikeCountForUri(props.uri)(state),
dislikeCount: makeSelectDislikeCountForUri(props.uri)(state),
theme: selectThemePath(state),
});
export default connect(select, {
doFetchReactions,
doReactionLike,
doReactionDislike,
})(FileViewCount);