Closed Nattle closed 6 years ago
I have had some rendering issues as well when the page needs to scroll. I have not had time to research it yet. I am more then willing to take a PR if you want to look into it.
My knowledge of Javascript is pretty shaky, though I'm picking up basic react at the moment. I'd wager it'll be a little while before I understand the lifecycle of DOM elements / this library enough to contribute though.
I'm looking to put up a PR soon though, since it would be handy if the autosave code emitted an "autosave" signal(), so that I could also have that write to my datastore.
Have a look at https://github.com/codemirror/CodeMirror/issues/2469. It seems like this is the expected codemirror behaviour.
I came across this behavior too.
Just call refresh, after the editor becomes visible: inscrybmde.codemirror.refresh();
If the textarea/editor is inside a tag which is not open, the contents of the edit area will be blank. Clicking inside the edit area will force an update and render the initialValue properly. If the edit box is in a tag which is open is behaves properly. This is true if you set either the text inside the textarea, the initialValue, or both. Setting the initialValue and a placeholder still shows a blank box.
If there is no content then the placeholder text will display properly in all cases.
detail_closed_bug.html.txt