FIX: emoji autocomplete not triggering correctly

08044b4f regressed emoji auto complete logic since we (I) forgot to add the
space into the not capturing group at the beginning.

This meant that

`hello 👍t` would not trigger an autocomplete to pick skin tone.
This commit is contained in:
Sam Saffron 2020-07-03 16:56:11 +10:00
parent 8ef782bdbd
commit a9c703c230
No known key found for this signature in database
GPG Key ID: B9606168D2FFD9F5

View File

@ -440,7 +440,7 @@ export default Component.extend({
return false;
}
const matches = /(?:^|[>.,\/#!$%^&*;:{}=\-_`~()])(:(?!:).?[\w-]*:?(?!:)(?:t\d?)?:?) ?$/gi.exec(
const matches = /(?:^|[\s.\?,@\/#!%&*;:\[\]{}=\-_()])(:(?!:).?[\w-]*:?(?!:)(?:t\d?)?:?) ?$/gi.exec(
text.substring(0, cp)
);