Switching tabs breaks TinyMCE

Switching tabs in multiview Tabbar causes trouble with TinyMCE.

Let me explain a little more. I have a datatable of products on one tab and a list of products on another tab. I also have form bound to the list on that second tab. When a product is selected from the list the form is populated accordingly so I may edit the product. One of the elements in the form is a description rendered in a tinymce-editor view. At first it works fine. I can select various products from the list and the form with the name, code and description binds correctly. But when I switch to the first tab (datatable) and come back to the second tab (product list + form), the tinymce-editor view in the form does not bind the description anymore, although the name of code of the product does still bind in the form.

Any ideas?

Hi,

It’s a known issue, but there’s no quick workaround. We’ll consider how to fix it.

Ok, I will try a different layout that does not involve TinyMCE in a multiview Tabbar. Thank you.

Hi, I’m facing the same with CKEditor.
Is there any solution already avaliable?
Thanks

You can use keepViews property to preserve iframe based components, such as CKEditor and TinyMCE, during tab switch

Check

http://docs.webix.com/api__ui.multiview_keepviews_config.html

http://webix.com/snippet/8b9f24ea

Hi, any updates with this? When add add the keepViews switch, it does preserve the editor, however other components don’t show. I have a tableview in another tab (that is initially hidden) that doesn’t display? odd…

If the issue is still actual, please provide a snippet or any other kind of sample where the issue can be reconstructed.

Looks like similar issue when I replace view back and forth with webix.ui({…new config…}, $$('view)).

As workaround I need to remove the editor with tinymce.remove(selector) when replacing the views.

Yep, moving complex text editors from one container to another will not work ( moving or detaching from DOM will unload iframes and will break editors )

Recreating must work though ( destroying old view and creating new one in the same place )