mirror of
https://github.com/vector-im/element-web.git
synced 2025-08-21 06:21:03 +02:00
update emoji provider regex
Signed-off-by: Michael Telatynski <7t3chguy@gmail.com>
This commit is contained in:
parent
93884cb89b
commit
0075ae2187
@ -34,7 +34,8 @@ import EMOTICON_REGEX from 'emojibase-regex/emoticon';
|
||||
const LIMIT = 20;
|
||||
|
||||
// Match for ascii-style ";-)" emoticons or ":wink:" shortcodes provided by emojibase
|
||||
const EMOJI_REGEX = new RegExp('(' + EMOTICON_REGEX.source + '|:[+-\\w]*:?)$', 'g');
|
||||
// anchored to only match from the start of parts otherwise it'll show emoji suggestions whilst typing matrix IDs
|
||||
const EMOJI_REGEX = new RegExp('(' + EMOTICON_REGEX.source + '|(?:^|\\s):[+-\\w]*:?)$', 'g');
|
||||
|
||||
interface IEmojiShort {
|
||||
emoji: IEmoji;
|
||||
|
Loading…
x
Reference in New Issue
Block a user