2017-07-13 12:40:16 +03:00
|
|
|
// THIS FILE EXISTS FOR UPSTREAM COMPATIBILITY & SHOULDN'T BE USED !!
|
|
|
|
// SEE INSTEAD : glitch/components/notification/container
|
|
|
|
|
2017-07-12 11:10:17 +03:00
|
|
|
import { connect } from 'react-redux';
|
|
|
|
import { makeGetNotification } from '../../../selectors';
|
|
|
|
import Notification from '../components/notification';
|
2017-10-06 02:07:59 +03:00
|
|
|
import { mentionCompose } from '../../../actions/compose';
|
2017-07-12 11:10:17 +03:00
|
|
|
|
|
|
|
const makeMapStateToProps = () => {
|
|
|
|
const getNotification = makeGetNotification();
|
|
|
|
|
|
|
|
const mapStateToProps = (state, props) => ({
|
|
|
|
notification: getNotification(state, props.notification, props.accountId),
|
|
|
|
});
|
|
|
|
|
|
|
|
return mapStateToProps;
|
|
|
|
};
|
|
|
|
|
2017-10-06 02:07:59 +03:00
|
|
|
const mapDispatchToProps = dispatch => ({
|
|
|
|
onMention: (account, router) => {
|
|
|
|
dispatch(mentionCompose(account, router));
|
|
|
|
},
|
|
|
|
});
|
|
|
|
|
|
|
|
export default connect(makeMapStateToProps, mapDispatchToProps)(Notification);
|