lbry-desktop/src/ui/component/blockButton/index.js

17 lines
460 B
JavaScript
Raw Normal View History

import { connect } from 'react-redux';
2019-08-02 17:11:31 +02:00
import { selectChannelIsBlocked, doToggleBlockChannel, doToast, makeSelectShortUrlForUri } from 'lbry-redux';
import BlockButton from './view';
const select = (state, props) => ({
channelIsBlocked: selectChannelIsBlocked(props.uri)(state),
2019-08-02 17:11:31 +02:00
shortUrl: makeSelectShortUrlForUri(props.uri)(state),
});
export default connect(
select,
{
toggleBlockChannel: doToggleBlockChannel,
doToast,
}
)(BlockButton);