2020-07-23 16:22:57 +02:00
|
|
|
import { connect } from 'react-redux';
|
|
|
|
import {
|
|
|
|
selectNotifications,
|
|
|
|
selectIsFetchingNotifications,
|
|
|
|
selectUnreadNotificationCount,
|
|
|
|
} from 'redux/selectors/notifications';
|
2020-08-10 22:47:39 +02:00
|
|
|
import { doReadNotifications } from 'redux/actions/notifications';
|
2020-07-23 16:22:57 +02:00
|
|
|
import NotificationsPage from './view';
|
|
|
|
|
|
|
|
const select = state => ({
|
|
|
|
notifications: selectNotifications(state),
|
|
|
|
fetching: selectIsFetchingNotifications(state),
|
|
|
|
unreadCount: selectUnreadNotificationCount(state),
|
|
|
|
});
|
|
|
|
|
2020-08-10 22:47:39 +02:00
|
|
|
export default connect(select, {
|
|
|
|
doReadNotifications,
|
|
|
|
})(NotificationsPage);
|