浏览代码

fix(compose_from): Do not autofocus on mobile (#4344)

master
Sorin Davidoi 6 年前
committed by Eugen Rochko
父节点
当前提交
32fa312b2a
共有 1 个文件被更改,包括 2 次插入1 次删除
  1. +2
    -1
      app/javascript/mastodon/features/compose/components/compose_form.js

+ 2
- 1
app/javascript/mastodon/features/compose/components/compose_form.js 查看文件

@@ -15,6 +15,7 @@ import SensitiveButtonContainer from '../containers/sensitive_button_container';
import EmojiPickerDropdown from './emoji_picker_dropdown';
import UploadFormContainer from '../containers/upload_form_container';
import WarningContainer from '../containers/warning_container';
import { isMobile } from '../../../is_mobile';
import ImmutablePureComponent from 'react-immutable-pure-component';
import { length } from 'stringz';

@@ -179,7 +180,7 @@ export default class ComposeForm extends ImmutablePureComponent {
onSuggestionsClearRequested={this.onSuggestionsClearRequested}
onSuggestionSelected={this.onSuggestionSelected}
onPaste={onPaste}
autoFocus={!showSearch}
autoFocus={!showSearch && !isMobile(window.innerWidth)}
/>

<EmojiPickerDropdown onPickEmoji={this.handleEmojiPick} />


正在加载...
取消
保存