newbthenewbd / grav-plugin-tinymce-editor

TinyMCE Editor Integration Plugin for Grav
Other
60 stars 10 forks source link

Intermittent Blank Editing Field on 1.7.0-rc.13 #51

Open thekenshow opened 3 years ago

thekenshow commented 3 years ago

Just updated a site to the latest 1.7 RC and the TinyMCE editing field often shows up blank whether or not there is any content in it. Inspecting, it shows an empty <body> tag. It isn't possible to click or tab into the editing region when this happens. It might get restored by re-saving the page or leaving and returning, sometimes multiple times. Replicated on Firefox and Chrome latest.

Examples below.

Blank textarea even though content was inserted and saved previously

Screen Shot 2020-07-08 at 8 22 03 AM

Same page after saving (or leaving and returning) with no changes applied

Screen Shot 2020-07-08 at 8 22 18 AM

thekenshow commented 3 years ago

I was able to restore functionality be replacing the plugin's js/tinymce folder with the version in the most recent TinyMCE community release. The formatting of the toolbar and text content is different though, with a much larger font size.

Screen Shot 2020-07-08 at 9 13 20 AM

thekenshow commented 3 years ago

FWIW, I've been able to reproduce the blank page error on a Grav RC-15 default installation + tinymce-editor (Apache/PHP 7.3) on my local Mac dev system but not with the same code on my remote Plesk host. So this may be a local problem, continuing to test.

kutulus commented 3 years ago

Hi, I'm new here at Grav... But I can confirm the same behavior described in the ticket.

Many greetings Stefano

ferdynator commented 3 years ago

Having the same problem. It looks similar to this one: https://github.com/tinymce/tinymce-vue/issues/223 Technologies differ except for tinymce. Issue relates to a non-visible input area (maybe because of grav admin input tabs?)

ferdynator commented 3 years ago

Wrapping tinymce.init into a window.setTimeout resolves the issue for me here too.

@newbthenewbd you want me to open a PR for this?