lbry-desktop/ui/page/listBlocked/index.js

32 lines
1.2 KiB
JavaScript
Raw Normal View History

import { connect } from 'react-redux';
2021-06-16 04:27:58 +02:00
import { doFetchModBlockedList, doFetchCommentModAmIList } from 'redux/actions/comments';
import { selectMutedChannels } from 'redux/selectors/blocked';
2021-06-16 04:27:58 +02:00
import {
selectModerationBlockList,
selectAdminBlockList,
selectModeratorBlockList,
selectModeratorBlockListDelegatorsMap,
selectFetchingModerationBlockList,
selectModerationDelegatorsById,
} from 'redux/selectors/comments';
import { selectMyChannelClaims } from 'lbry-redux';
import ListBlocked from './view';
const select = (state) => ({
mutedUris: selectMutedChannels(state),
2021-06-16 04:27:58 +02:00
personalBlockList: selectModerationBlockList(state),
adminBlockList: selectAdminBlockList(state),
moderatorBlockList: selectModeratorBlockList(state),
moderatorBlockListDelegatorsMap: selectModeratorBlockListDelegatorsMap(state),
delegatorsById: selectModerationDelegatorsById(state),
myChannelClaims: selectMyChannelClaims(state),
fetchingModerationBlockList: selectFetchingModerationBlockList(state),
});
const perform = (dispatch) => ({
fetchModBlockedList: () => dispatch(doFetchModBlockedList()),
2021-06-16 04:27:58 +02:00
fetchModAmIList: () => dispatch(doFetchCommentModAmIList()),
});
export default connect(select, perform)(ListBlocked);