mirror of
https://github.com/mastodon/mastodon.git
synced 2024-11-24 23:01:20 +00:00
22 lines
655 B
JavaScript
22 lines
655 B
JavaScript
import { openModal } from 'flavours/glitch/actions/modal';
|
|
import { connect } from 'react-redux';
|
|
import Header from '../components/header';
|
|
|
|
const mapStateToProps = state => {
|
|
return {
|
|
columns: state.getIn(['settings', 'columns']),
|
|
unreadNotifications: state.getIn(['notifications', 'unread']),
|
|
showNotificationsBadge: state.getIn(['local_settings', 'notifications', 'tab_badge']),
|
|
};
|
|
};
|
|
|
|
const mapDispatchToProps = (dispatch, { intl }) => ({
|
|
onSettingsClick (e) {
|
|
e.preventDefault();
|
|
e.stopPropagation();
|
|
dispatch(openModal('SETTINGS', {}));
|
|
},
|
|
});
|
|
|
|
export default connect(mapStateToProps, mapDispatchToProps)(Header);
|