lbry-desktop/ui/component/claimListDiscover/index.js
infinite-persistence 7ea74cfa0d
Fix livestream tiles reloading placeholders then scrolled (#360)
## Issue
9: Wild west + scroll down tries to reload livestreams
2021-11-24 09:35:47 -05:00

38 lines
1.5 KiB
JavaScript

import { connect } from 'react-redux';
import {
selectClaimsByUri,
selectClaimSearchByQuery,
selectClaimSearchByQueryLastPageReached,
selectFetchingClaimSearch,
} from 'redux/selectors/claims';
import { doClaimSearch } from 'redux/actions/claims';
import * as SETTINGS from 'constants/settings';
import { selectFollowedTags } from 'redux/selectors/tags';
import { selectMutedChannels } from 'redux/selectors/blocked';
import { doToggleTagFollowDesktop } from 'redux/actions/tags';
import { selectClientSetting, selectShowMatureContent, selectLanguage } from 'redux/selectors/settings';
import { selectModerationBlockList } from 'redux/selectors/comments';
import ClaimListDiscover from './view';
import { doFetchViewCount } from 'lbryinc';
const select = (state, props) => ({
followedTags: selectFollowedTags(state),
claimSearchByQuery: selectClaimSearchByQuery(state),
claimSearchByQueryLastPageReached: selectClaimSearchByQueryLastPageReached(state),
claimsByUri: selectClaimsByUri(state),
loading: props.loading !== undefined ? props.loading : selectFetchingClaimSearch(state),
showNsfw: selectShowMatureContent(state),
hideReposts: selectClientSetting(state, SETTINGS.HIDE_REPOSTS),
languageSetting: selectLanguage(state),
mutedUris: selectMutedChannels(state),
blockedUris: selectModerationBlockList(state),
searchInLanguage: selectClientSetting(state, SETTINGS.SEARCH_IN_LANGUAGE),
});
const perform = {
doClaimSearch,
doToggleTagFollowDesktop,
doFetchViewCount,
};
export default connect(select, perform)(ClaimListDiscover);