2018-03-26 14:32:43 -07:00
|
|
|
import { connect } from 'react-redux';
|
|
|
|
import SelectChannel from './view';
|
2021-10-17 16:36:14 +08:00
|
|
|
import { selectMyChannelClaims, selectFetchingMyChannels } from 'redux/selectors/claims';
|
2022-05-05 09:23:31 -03:00
|
|
|
import { selectActiveChannelClaimId } from 'redux/selectors/app';
|
2021-02-09 11:05:56 -05:00
|
|
|
import { doSetActiveChannel } from 'redux/actions/app';
|
2018-03-26 14:32:43 -07:00
|
|
|
|
2021-10-17 16:36:14 +08:00
|
|
|
const select = (state) => ({
|
2021-02-09 11:05:56 -05:00
|
|
|
myChannelClaims: selectMyChannelClaims(state),
|
2018-03-26 14:32:43 -07:00
|
|
|
fetchingChannels: selectFetchingMyChannels(state),
|
2022-05-05 09:23:31 -03:00
|
|
|
activeChannelClaimId: selectActiveChannelClaimId(state),
|
2018-03-26 14:32:43 -07:00
|
|
|
});
|
|
|
|
|
2022-05-05 09:23:31 -03:00
|
|
|
const perform = {
|
|
|
|
setActiveChannel: doSetActiveChannel,
|
|
|
|
};
|
2018-03-26 14:32:43 -07:00
|
|
|
|
2020-06-15 16:33:03 -04:00
|
|
|
export default connect(select, perform)(SelectChannel);
|