Why does text lose its formatting?

What the issue is

You may have noticed that in some cases, if you highlight text in the Text Editor within a Text content block, delete it, and start typing, the text loses its previous formatting.

This can be frustrating and we have received many support requests about it.

This article provides some context about this issue and some simple tips to get around it.

 

Why it exists

This is not a bug in BEE, but rather a default behavior in the text editor that BEE uses in the Text content block, called TinyMCE. Specifically:

  1. If there is only one paragraph (e.g. a title with a large font), when you highlight all the text and start typing, the behavior is the one described. The formatting is lost.
  2. If there are two or more paragraphs (e.g. same title, but followed by other paragraphs with other formatting), then the issue does not occur: the formatting of the title is preserved.

In other words, in this scenario...

bee_text_editor_scenario1.PNG

... if the users were to start typing after selecting "BOOK YOUR NEXT VISIT TODAY", the formatting of the title would be lost. Notice that the Text content block here only contains one paragraph, the large title.

On the other hand, in this other scenario, where there is a second paragraph in the same Text content block, below the large title...

bee_text_editor_scenario2.PNG

... the title formatting will NOT be lost.

 

How to avoid the problem

So, to avoid losing the formatting of paragraph of text that you are selecting and need to replace with new text, you have a few options:

  1. Don't remove the entire text in the paragraph. Keep a bit of it, type what you need, then remove the text that should not be there.
  2. Press "Enter" to create a new paragraph, highlight and type. Then remove the new paragraph (an empty paragraph is fine).

We hope this helps!

Have more questions? Submit a request

Comments