Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix/15079: Clicking on the send icon on the compose box closes the Keyboard on mweb chrome #15554

Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
11 changes: 6 additions & 5 deletions src/pages/home/report/ReportActionCompose.js
Original file line number Diff line number Diff line change
Expand Up @@ -691,17 +691,18 @@ class ReportActionCompose extends React.Component {
onEmojiSelected={this.addEmojiToTextBox}
/>
)}
<View style={[styles.justifyContentEnd]}>
<View
style={[styles.justifyContentEnd]}

// Keep focus on the composer when Send message is clicked.
onMouseDown={e => e.preventDefault()}
>
<Tooltip text={this.props.translate('common.send')}>
<TouchableOpacity
style={[styles.chatItemSubmitButton,
(this.state.isCommentEmpty || hasExceededMaxCommentLength) ? undefined : styles.buttonSuccess,
]}
onPress={this.submitForm}

// Keep focus on the composer when Send message is clicked.
// eslint-disable-next-line react/jsx-props-no-multi-spaces
onMouseDown={e => e.preventDefault()}
disabled={this.state.isCommentEmpty || isBlockedFromConcierge || this.props.disabled || hasExceededMaxCommentLength}
hitSlop={{
top: 3, right: 3, bottom: 3, left: 3,
Expand Down