Skip to content

Commit

Permalink
fix: close virtual keyboard on iOS Safari is message menu is opened
Browse files Browse the repository at this point in the history
  • Loading branch information
szuperaz committed Sep 11, 2024
1 parent 899c48e commit 2d02cf5
Showing 1 changed file with 8 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -601,6 +601,14 @@ export class MessageComponent
return;
} else {
this.shouldPreventMessageMenuClose = !options.fromTouch;
// Fix for iOS Safari: iOS Safari won't close the input if we open message menu
// The virtual keyboard can hide parts of the message menu, so we close the input here
if (
document.activeElement &&
typeof (document.activeElement as HTMLInputElement).blur !==
'undefined'
)
(document.activeElement as HTMLInputElement).blur();
this.messageMenuTrigger?.show();
}
if (this.isViewInited) {
Expand Down

0 comments on commit 2d02cf5

Please sign in to comment.