Wysiwyg-editor: Editor scrolls up on pressing enter when using two editor instances

Created on 4 Feb 2021  路  2Comments  路  Source: froala/wysiwyg-editor

Expected behavior.

Enter a new line or paragraph and do not scroll when not needed

Actual behavior.

When having two editor instances with longer content, pressing enter in second one scrolls up onto first editor instance.
Discovered when testing fixed BUG #4096

Steps to reproduce the problem.

Add two instances of Froala editor on a page
Enter any longer content in both of them (several paragraphs of a lorem ipsum)
Place cursor anywhere in the second editor instance and press enter

You can also use pre prepared jsFiddle

Editor version.

3.2.6

OS.

Windows 10 (Ver. 1909, build 18363.1316)

Browser.

Google Chrome Version 88.0.4324.146 (Official Build) (64-bit)

Recording.

scrollingAway

Most helpful comment

I have exact "scrolling to the first instance" behaviour when clicking Save button after editing NOT first instance. Text blocks is short btw. Looks like the issue is wider and related with multiple editors on the same page.

All 2 comments

We have the same issue. For me even when there is just one editor, once I have 10 lines (pressing enter 10 times). Then pressing enter for the 11th line will scroll to top.

I have exact "scrolling to the first instance" behaviour when clicking Save button after editing NOT first instance. Text blocks is short btw. Looks like the issue is wider and related with multiple editors on the same page.

Was this page helpful?
0 / 5 - 0 ratings

Related issues

Krisell picture Krisell  路  3Comments

cksachdev picture cksachdev  路  4Comments

adilsonb picture adilsonb  路  3Comments

Nucs picture Nucs  路  4Comments

lohiaad picture lohiaad  路  4Comments