diff --git a/frappe/build.js b/frappe/build.js index 5afe41b266..50e3d7ee8c 100644 --- a/frappe/build.js +++ b/frappe/build.js @@ -272,7 +272,6 @@ function watch_js(ondirty) { if (sources.includes(filename)) { pack(target, sources); ondirty && ondirty(target); - break; } } }); diff --git a/frappe/public/js/frappe/form/control.js b/frappe/public/js/frappe/form/control.js index 7d79bfb130..ef04ec60cb 100755 --- a/frappe/public/js/frappe/form/control.js +++ b/frappe/public/js/frappe/form/control.js @@ -1652,9 +1652,10 @@ frappe.ui.form.ControlTextEditor = frappe.ui.form.ControlCode.extend({ // firefox hack that puts the caret in the wrong position // when div is empty. To fix, seed with a
. // See https://bugzilla.mozilla.org/show_bug.cgi?id=550434 - $(".note-editable[contenteditable='true']").on('focus', function(){ + // this function is executed only once + $(".note-editable[contenteditable='true']").one('focus', function() { var $this = $(this); - $this.html( $this.html() + '
' ); + $this.html($this.html() + '
'); }); }, onChange: function(value) {