Spaces:
Running on Zero
Running on Zero
Commit ·
648fb30
1
Parent(s): ffb505c
Fix Japanese IME exits on iPhone by checking e.isComposing
Browse filesSkip the Gradio sync while an IME composition is active so that
iOS Safari does not kill the keyboard session mid-kanji input.
Co-Authored-By: Claude Sonnet 4.6 <noreply@anthropic.com>
- static/gallery.js +1 -1
static/gallery.js
CHANGED
|
@@ -185,7 +185,7 @@ function init() {
|
|
| 185 |
if (e.dataTransfer.files.length) processFiles(e.dataTransfer.files);
|
| 186 |
});
|
| 187 |
|
| 188 |
-
if (promptInput) promptInput.addEventListener('input', syncPromptToGradio);
|
| 189 |
|
| 190 |
window.__setPrompt = function(text) {
|
| 191 |
if (promptInput) { promptInput.value = text; syncPromptToGradio(); }
|
|
|
|
| 185 |
if (e.dataTransfer.files.length) processFiles(e.dataTransfer.files);
|
| 186 |
});
|
| 187 |
|
| 188 |
+
if (promptInput) promptInput.addEventListener('input', (e) => { if (!e.isComposing) syncPromptToGradio(); });
|
| 189 |
|
| 190 |
window.__setPrompt = function(text) {
|
| 191 |
if (promptInput) { promptInput.value = text; syncPromptToGradio(); }
|