export validEmojiNames for autocomplete
This commit is contained in:
parent
527e7edbc4
commit
88114c41fb
2 changed files with 3 additions and 2 deletions
|
@ -55,4 +55,5 @@ export {
|
||||||
getUnicodeSupportMap,
|
getUnicodeSupportMap,
|
||||||
isEmojiNameValid,
|
isEmojiNameValid,
|
||||||
isEmojiUnicodeSupported,
|
isEmojiUnicodeSupported,
|
||||||
|
validEmojiNames,
|
||||||
};
|
};
|
||||||
|
|
|
@ -1,5 +1,5 @@
|
||||||
import { glEmojiTag } from './behaviors/gl_emoji';
|
import { glEmojiTag } from './behaviors/gl_emoji';
|
||||||
import { emojiMap, emojiAliases } from './emoji';
|
import { validEmojiNames } from './emoji';
|
||||||
import glRegexp from './lib/utils/regexp';
|
import glRegexp from './lib/utils/regexp';
|
||||||
import AjaxCache from './lib/utils/ajax_cache';
|
import AjaxCache from './lib/utils/ajax_cache';
|
||||||
|
|
||||||
|
@ -374,7 +374,7 @@ class GfmAutoComplete {
|
||||||
if (this.cachedData[at]) {
|
if (this.cachedData[at]) {
|
||||||
this.loadData($input, at, this.cachedData[at]);
|
this.loadData($input, at, this.cachedData[at]);
|
||||||
} else if (GfmAutoComplete.atTypeMap[at] === 'emojis') {
|
} else if (GfmAutoComplete.atTypeMap[at] === 'emojis') {
|
||||||
this.loadData($input, at, Object.keys(emojiMap).concat(Object.keys(emojiAliases)));
|
this.loadData($input, at, validEmojiNames);
|
||||||
} else {
|
} else {
|
||||||
AjaxCache.retrieve(this.dataSources[GfmAutoComplete.atTypeMap[at]], true)
|
AjaxCache.retrieve(this.dataSources[GfmAutoComplete.atTypeMap[at]], true)
|
||||||
.then((data) => {
|
.then((data) => {
|
||||||
|
|
Loading…
Reference in a new issue