Skip to content

Commit a37e23b

Browse files
committed
🎨 The toolbar content cannot be slid on Android #14979
1 parent 084ddfd commit a37e23b

File tree

1 file changed

+3
-1
lines changed

1 file changed

+3
-1
lines changed

app/src/mobile/util/keyboardToolbar.ts

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -521,13 +521,15 @@ export const initKeyboardToolbar = () => {
521521
</div>
522522
<div class="keyboard__util"></div>`;
523523
let startY = 0;
524+
let startX = 0;
524525
let moved = false;
525526
toolbarElement.addEventListener("touchstart", e => {
526527
startY = e.touches[0].clientY;
528+
startX = e.touches[0].clientX;
527529
moved = false;
528530
});
529531
toolbarElement.addEventListener("touchmove", e => {
530-
if (Math.abs(e.touches[0].clientY - startY) > 10) {
532+
if (Math.abs(e.touches[0].clientY - startY) > 10 || Math.abs(e.touches[0].clientX - startX) > 10) {
531533
moved = true;
532534
}
533535
});

0 commit comments

Comments
 (0)