Version 2.1, used into a dialog. 1. Open the dialog, everything ok 2. Clos

Version 2.1, used into a dialog.

  1. Open the dialog, everything ok
  2. Close the dialog
  3. Opend the dialog again , The editor part is not writable and the content is not loaded.
  4. Reload the browser page and start again working

Have you the same problem ?

Yup, I can see that now. Also if you just add any dialog with editor, it only works on the first opened Dialog. Spent quite a while to debug it, but I have no idea what is happening. No errors on the console, something just silently fails in editor init.

Should somehow check if the issue is in Vaadin Dialog, in the integration or in TinyMCE (and there in the web component or the actual editor). In normal Vaadin layout similar cases seem to work just perfectly, so I’m afraid there is still some shadow dom issue in TinyMCE.

I will also try to find the problem that is blocking me.

Thanks Matti.

With some help from my colleagues, we figured out it is a bug in the TinyMCE itself. We’ll probabbly need to figure out a workaround for it, if it don’t get fixed soon.

https://github.com/tinymce/tinymce-webcomponent/issues/5

A workaround could be to make a proxy that always attaches a new instance of the actual component when component is (re-)attached.

Had to get rid of web component impl and did a re-write on 5.0 with the same system we used with earlier version. That is now available with version 3.0.0. Can you repeat the test with that and let me know how it works.

Hi Matti, thanks for your effort, but the version 3.0.0 has the same behaviour of the 1.4 when used in dialog, the menu editor is not clickable.

I played a while with tinymce & dialog and it looks like an additional shadow dom is needed to make the menu and other pop overs of tinymce to work in Vaadin Dialog. On the other hand it now breaks some features :-(

In version 3.1.0 you can now initiate the editor with a shadow dom hack and it then appears to work in a Dialog. But keep in mind that some config options break wiht it (such as inline editing).

TinyMce editor = new TinyMce(true);

Can you try with that and report if you find any issues.

Hi Matti,

i confirm that the 3.1 version runs properly also in Dialogs.
Inline mode, not running for me. ( Anyway i’m not using it )

Thanks Matty, good job !!

Yup, inline mode don’t work with shadow dom hack → incompatibble with usage inside a Dialog :-(