diff options
Diffstat (limited to 'src/components/rich_content')
| -rw-r--r-- | src/components/rich_content/rich_content.jsx | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/src/components/rich_content/rich_content.jsx b/src/components/rich_content/rich_content.jsx index 1353541f..8ab007e3 100644 --- a/src/components/rich_content/rich_content.jsx +++ b/src/components/rich_content/rich_content.jsx @@ -121,6 +121,13 @@ export default Vue.component('RichContent', { // in MentionsLine return currentMentions !== null ? item.trim() : item } + // We add space with mentionsLine, otherwise non-text elements will + // stick to them. + if (currentMentions !== null) { + // single whitespace trim + item = item[0].match(/\s/) ? item.slice(1) : item + } + currentMentions = null if (item.includes(':')) { item = ['', processTextForEmoji( |
