Reactions: skin tone support
This commit is contained in:
parent
6a7d45b6fc
commit
c3ddedfde1
13 changed files with 307 additions and 141 deletions
|
@ -263,9 +263,21 @@ export function convertShortName(
|
|||
}
|
||||
|
||||
export function emojiToImage(emoji: string): string | undefined {
|
||||
if (!Object.prototype.hasOwnProperty.call(imageByEmoji, emoji)) {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
return imageByEmoji[emoji];
|
||||
}
|
||||
|
||||
export function emojiToData(emoji: string): EmojiData | undefined {
|
||||
if (!Object.prototype.hasOwnProperty.call(dataByEmoji, emoji)) {
|
||||
return undefined;
|
||||
}
|
||||
|
||||
return dataByEmoji[emoji];
|
||||
}
|
||||
|
||||
function getCountOfAllMatches(str: string, regex: RegExp) {
|
||||
let match = regex.exec(str);
|
||||
let count = 0;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue