Loading js/maxlength.js +7 −0 Original line number Diff line number Diff line Loading @@ -349,6 +349,12 @@ // Sets the data into a ckeditor. ml.ckeditorSetData = function(e, data) { // WYSIWYG can convert '\r\n' to '\n' and insert '\n' after some tags, this // can result in circular changes as what is attempted to be inserted and // what is actually inserted is different. We save the last inserted value // on the editor to stop this issue. if (e.editor.mlLastBeforeInsert !== e.editor.getData()) { e.editor.mlLastBeforeInsert = e.editor.getData(); // Calling setData() will place the cursor at the beginning, so we need to // implement a callback to place it at the end, which is where the text is // being truncated. Loading @@ -359,5 +365,6 @@ e.editor.getSelection().selectRanges([range]); }}); } } })(jQuery, Drupal); Loading
js/maxlength.js +7 −0 Original line number Diff line number Diff line Loading @@ -349,6 +349,12 @@ // Sets the data into a ckeditor. ml.ckeditorSetData = function(e, data) { // WYSIWYG can convert '\r\n' to '\n' and insert '\n' after some tags, this // can result in circular changes as what is attempted to be inserted and // what is actually inserted is different. We save the last inserted value // on the editor to stop this issue. if (e.editor.mlLastBeforeInsert !== e.editor.getData()) { e.editor.mlLastBeforeInsert = e.editor.getData(); // Calling setData() will place the cursor at the beginning, so we need to // implement a callback to place it at the end, which is where the text is // being truncated. Loading @@ -359,5 +365,6 @@ e.editor.getSelection().selectRanges([range]); }}); } } })(jQuery, Drupal);