From 26f67810a653e41e9a08fa9065ecbeee0ad32648 Mon Sep 17 00:00:00 2001 From: Maksim Karmatskikh Date: Mon, 4 Dec 2023 18:53:51 +0100 Subject: [PATCH] UBERF-4449, UBERF-4343: Mention safari fix and double @ fix (#4135) Signed-off-by: Maxim Karmatskikh --- packages/text-editor/src/components/extension/suggestion.ts | 2 +- packages/theme/styles/_text-editor.scss | 3 +-- 2 files changed, 2 insertions(+), 3 deletions(-) diff --git a/packages/text-editor/src/components/extension/suggestion.ts b/packages/text-editor/src/components/extension/suggestion.ts index 50afe42e15..a9b5bd3680 100644 --- a/packages/text-editor/src/components/extension/suggestion.ts +++ b/packages/text-editor/src/components/extension/suggestion.ts @@ -62,7 +62,7 @@ export function findSuggestionMatch (config: Trigger): SuggestionMatch { // If allowSpaces: true terminates on at least 2 whitespaces const regexp = allowSpaces - ? new RegExp(`${prefix}${escapedChar}.*?(?=\\s{2}|$)`, 'gm') + ? new RegExp(`${prefix}${escapedChar}[^${escapedChar}]*?(?=\\s{2}|$)`, 'gm') : new RegExp(`${prefix}(?:^)?${escapedChar}[^\\s${escapedChar}]*`, 'gm') let text diff --git a/packages/theme/styles/_text-editor.scss b/packages/theme/styles/_text-editor.scss index 841ee550aa..fee68dba66 100644 --- a/packages/theme/styles/_text-editor.scss +++ b/packages/theme/styles/_text-editor.scss @@ -12,8 +12,7 @@ color: var(--theme-text-primary-color); .suggestion { - display: inline-flex; - padding: 0 .25rem; + padding-left: 0.25rem; color: var(--theme-link-color); background-color: var(--theme-mention-bg-color); border-radius: .25rem;