Fix markdown newline handling during IME composition (gitea#36421) (#36424)

Backport of #36421
This commit is contained in:
Tyrone Yeh
2026-01-22 08:56:39 +08:00
committed by GitHub
parent c326369f47
commit d7d6533311

View File

@@ -176,6 +176,7 @@ export function markdownHandleIndention(tvs: TextareaValueSelection): MarkdownHa
}
function handleNewline(textarea: HTMLTextAreaElement, e: Event) {
if ((e as KeyboardEvent).isComposing) return;
const ret = markdownHandleIndention({value: textarea.value, selStart: textarea.selectionStart, selEnd: textarea.selectionEnd});
if (!ret.handled) return;
e.preventDefault();