2
0

🚸 (editor) Avoid editor closing when pressing Enter

This caused issue for people using IME (Virtual Keyboard)
This commit is contained in:
Baptiste Arnaud
2024-01-29 18:28:36 +01:00
parent 8d363c0c02
commit 3ab84b7555

View File

@@ -87,7 +87,7 @@ const TextBubbleEditorContent = ({
const handleKeyDown = (e: React.KeyboardEvent<HTMLDivElement>) => {
if (e.shiftKey) return
if (e.key === 'Enter') closeEditor()
if (e.key === 'Enter' && (e.metaKey || e.ctrlKey)) closeEditor()
}
return (