Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/nextcloud/mail.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristoph Wurst <christoph@winzerhof-wurst.at>2019-10-28 16:59:08 +0300
committerChristoph Wurst <christoph@winzerhof-wurst.at>2019-10-28 17:27:55 +0300
commitaa6d671548e290117a9d1e3366d9a8117d360093 (patch)
treee9aab987016cd7d02e52c6eb6fbd18493938c688
parent1fbbd31d1f5a17e5b7d1495c5f38f93d57f7f447 (diff)
Fix HTML handling when switching from plain text to HTML mode
Signed-off-by: Christoph Wurst <christoph@winzerhof-wurst.at>
-rw-r--r--src/components/Composer.vue4
-rw-r--r--src/components/TextEditor.vue2
2 files changed, 3 insertions, 3 deletions
diff --git a/src/components/Composer.vue b/src/components/Composer.vue
index 66f09920e..118759aec 100644
--- a/src/components/Composer.vue
+++ b/src/components/Composer.vue
@@ -177,10 +177,10 @@ import Vue from 'vue'
import ComposerAttachments from './ComposerAttachments'
import {findRecipient} from '../service/AutocompleteService'
+import {htmlToText, textToSimpleHtml} from '../util/HtmlHelper'
import Loading from './Loading'
import Logger from '../logger'
import TextEditor from './TextEditor'
-import {textToSimpleHtml} from '../util/HtmlHelper'
const debouncedSearch = debouncePromise(findRecipient, 500)
@@ -327,7 +327,7 @@ export default {
bcc: this.selectBcc.map(this.recipientToRfc822).join(', '),
draftUID: uid,
subject: this.subjectVal,
- body: this.bodyVal,
+ body: this.editorPlainText ? htmlToText(this.bodyVal) : this.bodyVal,
attachments: this.attachments,
folderId: this.replyTo ? this.replyTo.folderId : undefined,
messageId: this.replyTo ? this.replyTo.messageId : undefined,
diff --git a/src/components/TextEditor.vue b/src/components/TextEditor.vue
index 98276cc9b..b4f227621 100644
--- a/src/components/TextEditor.vue
+++ b/src/components/TextEditor.vue
@@ -137,7 +137,7 @@ export default {
}
},
onInput() {
- this.$emit('input', this.html ? this.text : htmlToText(this.text))
+ this.$emit('input', this.text)
},
},
}