tinymce / tinymce-angular

Official TinyMCE Angular Component
MIT License
324 stars 93 forks source link

Cursor jump back to start when writing in inside the editor and then when we focus out. #169

Closed prakhar-ira closed 4 years ago

prakhar-ira commented 4 years ago

When writing inside the editor, if we focus out the cursor from the editor, the cursor jumps back to start. Giving much of headache to write even a small paragraph.

I am using Angular 9 and updated the tinymce to its latest version 3.6.0

Please suggest solution to my problem,

My code is

 editorOptions['setup'] = (editor) => {
          this.editor = editor;
          // change event is used to detect cut, copy and paste method in tinymce editor
          editor.on('change', () => {
            this.editorChange.emit(editor.getContent());
          });
          editor.on('keyup', () => {
            this.editorChange.emit(editor.getContent());
          });
      };
jscasca commented 4 years ago

Hi @prakhar-ira

What are you trying to achieve? Have you tried using the wrapper events instead? You can find more information here: https://www.tiny.cloud/docs/integrations/angular/

Additionally I would suggest using the NgModel directive to capture the content of the editor

jscasca commented 4 years ago

Closing due to lack of activity