Przeglądaj źródła

fix: don't jump text to end when out of viewport in safari (#6416)

Aakansha Doshi 2 lat temu
rodzic
commit
d61b3cf83d
1 zmienionych plików z 1 dodań i 0 usunięć
  1. 1 0
      src/element/textWysiwyg.tsx

+ 1 - 0
src/element/textWysiwyg.tsx

@@ -297,6 +297,7 @@ export const textWysiwyg = ({
         filter: "var(--theme-filter)",
         maxHeight: `${editorMaxHeight}px`,
       });
+      editable.scrollTop = 0;
       // For some reason updating font attribute doesn't set font family
       // hence updating font family explicitly for test environment
       if (isTestEnv()) {