Merge pull request #243 from cttttt/preserve-newlines-while-copying-values

Try harder to to preserve newlines while copying in the Desktop app
This commit is contained in:
antelle 2016-06-11 12:22:50 +04:00 committed by GitHub
commit e08a104935
1 changed files with 1 additions and 1 deletions

View File

@ -85,7 +85,7 @@ var FieldView = Backbone.View.extend({
range.selectNodeContents(this.valueEl[0]);
selection.removeAllRanges();
selection.addRange(range);
copyRes = CopyPaste.copy(this.valueEl.text());
copyRes = CopyPaste.copy(this.valueEl[0].innerText || this.valueEl.text());
if (copyRes) {
selection.removeAllRanges();
this.trigger('copy', { source: this, copyRes: copyRes });