Commit 0566c8c1 authored by colemanw's avatar colemanw
Browse files

Merge branch 'fixBlurUpdate' into 'master'

Fix update-on-blur for the sake of Angular pages like CiviMail

Closes #6

See merge request extensions/ckeditor5!7
parents 5c9d12da 0028c608
......@@ -209,6 +209,13 @@
instances[name] = editor;
// Update source element on blur; especially important for javascript-based UIs
editor.editing.view.document.on('blur', function() {
editor.updateSourceElement();
$(item).trigger("blur");
$(item).trigger("change");
});
editor.on('destroy', function(e) {
var name = $(e.source.sourceElement).attr('name') || $(e.source.sourceElement).attr('id');
delete instances[name];
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment