import ImmutablePureComponent from 'react-immutable-pure-component'; import ImmutablePropTypes from 'react-immutable-proptypes'; import { NavLink, withRouter } from 'react-router-dom'; import { FormattedMessage } from 'react-intl'; import { me } from '../../initial_state'; import NotificationsCounter from '../notification_counter'; import SearchContainer from 'gabsocial/features/compose/containers/search_container'; import Avatar from '../avatar'; import ActionBar from 'gabsocial/features/compose/components/action_bar'; import { openModal } from '../../actions/modal'; import './tabs_bar.scss'; const mapStateToProps = state => { return { account: state.getIn(['accounts', me]), }; }; const mapDispatchToProps = (dispatch) => ({ onOpenCompose() { dispatch(openModal('COMPOSE')); }, }); export default @connect(mapStateToProps, mapDispatchToProps) @withRouter class TabsBar extends ImmutablePureComponent { static propTypes = { history: PropTypes.object.isRequired, onOpenCompose: PropTypes.func.isRequired, account: ImmutablePropTypes.map.isRequired, }; render () { const { account, onOpenCompose } = this.props; if (!account) { return ( ); } return ( ); } }