import React from 'react'; import ImmutablePropTypes from 'react-immutable-proptypes'; import PropTypes from 'prop-types'; import DropdownMenuContainer from 'flavours/glitch/containers/dropdown_menu_container'; import { NavLink } from 'react-router-dom'; import { injectIntl, FormattedMessage, FormattedNumber } from 'react-intl'; import { me, isStaff } from 'flavours/glitch/initial_state'; import { profileLink, accountAdminLink } from 'flavours/glitch/utils/backend_links'; import Icon from 'flavours/glitch/components/icon'; class ActionBar extends React.PureComponent { static propTypes = { account: ImmutablePropTypes.map.isRequired, intl: PropTypes.object.isRequired, }; isStatusesPageActive = (match, location) => { if (!match) { return false; } return !location.pathname.match(/\/(followers|following)\/?$/); }; render () { const { account, intl } = this.props; if (account.get('suspended')) { return (
); } let extraInfo = ''; if (account.get('acct') !== account.get('username')) { extraInfo = (
{' '}
); } return (
{extraInfo}
{ account.get('followers_count') < 0 ? '-' : }
); } } export default injectIntl(ActionBar);