fix: don't bring up the keyboard when menus open or close on mobile (#31657)

This commit is contained in:
G30 authored and GitHub committed 2026-10-01 03:09:14 +04:00
1 parent aee7c47277
commit e797a44806
2 files changed
+6 -3

No files matched your search

+4 -2
View File
@@ -2330,8 +2330,10 @@
onClose={async () => {
await tick();
const chatInput = document.getElementById('chat-input');
chatInput?.focus();
if (!$mobile) {
const chatInput = document.getElementById('chat-input');
chatInput?.focus();
}
}}
>
<button
+2 -1
View File
@@ -1,6 +1,7 @@
<script lang="ts">
import { flyAndScale } from '$lib/utils/transitions';
import { tick } from 'svelte';
import { mobile } from '$lib/stores';
/** Whether the dropdown is open */
export let show = false;
@@ -275,7 +276,7 @@
if (show) {
closeDropdown();
} else {
openDropdown(true);
openDropdown(!$mobile);
}
}