From 1cadfb3d27b92497d5ddd88e0982af3be06945c7 Mon Sep 17 00:00:00 2001 From: Diego Mello Date: Wed, 20 May 2020 09:53:40 -0300 Subject: [PATCH] [FIX] Here and all mentions shouldn't refer to users (#2137) --- .../__snapshots__/Storyshots.test.js.snap | 24 ++++++++++++------- app/containers/markdown/AtMention.js | 9 ++++--- 2 files changed, 20 insertions(+), 13 deletions(-) diff --git a/__tests__/__snapshots__/Storyshots.test.js.snap b/__tests__/__snapshots__/Storyshots.test.js.snap index 0b28e1ae..e881064a 100644 --- a/__tests__/__snapshots__/Storyshots.test.js.snap +++ b/__tests__/__snapshots__/Storyshots.test.js.snap @@ -666,17 +666,19 @@ exports[`Storyshots Markdown list Markdown 1`] = ` @@ -709,17 +711,19 @@ exports[`Storyshots Markdown list Markdown 1`] = ` @@ -896,17 +900,19 @@ exports[`Storyshots Markdown list Markdown 1`] = ` @@ -939,17 +945,19 @@ exports[`Storyshots Markdown list Markdown 1`] = ` diff --git a/app/containers/markdown/AtMention.js b/app/containers/markdown/AtMention.js index 513dd880..fcd7a495 100644 --- a/app/containers/markdown/AtMention.js +++ b/app/containers/markdown/AtMention.js @@ -11,11 +11,10 @@ const AtMention = React.memo(({ }) => { let mentionStyle = { ...styles.mention, color: themes[theme].buttonText }; if (mention === 'all' || mention === 'here') { - mentionStyle = { - ...mentionStyle, - ...styles.mentionAll - }; - } else if (mention === username) { + return {mention}; + } + + if (mention === username) { mentionStyle = { ...mentionStyle, backgroundColor: themes[theme].actionTintColor