diff options
author | Eugen Rochko <eugen@zeonfederated.com> | 2017-01-09 14:12:00 +0100 |
---|---|---|
committer | Eugen Rochko <eugen@zeonfederated.com> | 2017-01-09 14:12:00 +0100 |
commit | d6a456dc714337a696e206c31d182630a94f89cd (patch) | |
tree | 86b3a2f45798f2a69c66a16a5052585583f4265c /app/assets/javascripts/components/features/account/index.jsx | |
parent | 75f80bef107cfe9e9c0e6ba3dc51ef86c89e40cc (diff) | |
parent | 3bddd647e02b4b831316e893ad756e6cf5d74c0b (diff) |
Merge branch 'blackle-dropdown'
Diffstat (limited to 'app/assets/javascripts/components/features/account/index.jsx')
-rw-r--r-- | app/assets/javascripts/components/features/account/index.jsx | 8 |
1 files changed, 8 insertions, 0 deletions
diff --git a/app/assets/javascripts/components/features/account/index.jsx b/app/assets/javascripts/components/features/account/index.jsx index c2cc58bb2..2a9eba28a 100644 --- a/app/assets/javascripts/components/features/account/index.jsx +++ b/app/assets/javascripts/components/features/account/index.jsx @@ -20,6 +20,7 @@ import LoadingIndicator from '../../components/loading_indicator'; import ActionBar from './components/action_bar'; import Column from '../ui/components/column'; import ColumnBackButton from '../../components/column_back_button'; +import { isMobile } from '../../is_mobile' const makeMapStateToProps = () => { const getAccount = makeGetAccount(); @@ -34,6 +35,10 @@ const makeMapStateToProps = () => { const Account = React.createClass({ + contextTypes: { + router: React.PropTypes.object + }, + propTypes: { params: React.PropTypes.object.isRequired, dispatch: React.PropTypes.func.isRequired, @@ -71,6 +76,9 @@ const Account = React.createClass({ handleMention () { this.props.dispatch(mentionCompose(this.props.account)); + if (isMobile(window.innerWidth)) { + this.context.router.push('/statuses/new'); + } }, render () { |