Browse Source

make text committing cross-platform (#1188)

David Luzar 5 năm trước cách đây
mục cha
commit
8030a167c6
1 tập tin đã thay đổi với 1 bổ sung1 xóa
  1. 1 1
      src/element/textWysiwyg.tsx

+ 1 - 1
src/element/textWysiwyg.tsx

@@ -109,7 +109,7 @@ export function textWysiwyg({
       ev.preventDefault();
       handleSubmit();
     }
-    if (ev.key === KEYS.ENTER && (ev.shiftKey || ev.metaKey)) {
+    if (ev.key === KEYS.ENTER && (ev.shiftKey || ev[KEYS.CTRL_OR_CMD])) {
       ev.preventDefault();
       if (ev.isComposing || ev.keyCode === 229) {
         return;