rename: client -> frontend
This commit is contained in:
parent
db6fff6f26
commit
9384f5399d
592 changed files with 111 additions and 111 deletions
17
packages/frontend/src/scripts/emojilist.ts
Normal file
17
packages/frontend/src/scripts/emojilist.ts
Normal file
|
@ -0,0 +1,17 @@
|
|||
export const unicodeEmojiCategories = ['face', 'people', 'animals_and_nature', 'food_and_drink', 'activity', 'travel_and_places', 'objects', 'symbols', 'flags'] as const;
|
||||
|
||||
export type UnicodeEmojiDef = {
|
||||
name: string;
|
||||
keywords: string[];
|
||||
char: string;
|
||||
category: typeof unicodeEmojiCategories[number];
|
||||
}
|
||||
|
||||
// initial converted from https://github.com/muan/emojilib/commit/242fe68be86ed6536843b83f7e32f376468b38fb
|
||||
import _emojilist from '../emojilist.json';
|
||||
|
||||
export const emojilist = _emojilist as UnicodeEmojiDef[];
|
||||
|
||||
export function getEmojiName(char: string): string | undefined {
|
||||
return emojilist.find(emo => emo.char === char)?.name;
|
||||
}
|
Loading…
Add table
Add a link
Reference in a new issue