Sticker Creator
This commit is contained in:
parent
2df1ba6e61
commit
11d47a8eb9
123 changed files with 11287 additions and 1714 deletions
|
@ -4,6 +4,7 @@ import emojiRegex from 'emoji-regex';
|
|||
import {
|
||||
compact,
|
||||
flatMap,
|
||||
get,
|
||||
groupBy,
|
||||
isNumber,
|
||||
keyBy,
|
||||
|
@ -71,8 +72,16 @@ const data = (untypedData as Array<EmojiData>).filter(
|
|||
emoji => emoji.has_img_apple
|
||||
);
|
||||
|
||||
// @ts-ignore
|
||||
const ROOT_PATH = get(
|
||||
// tslint:disable-next-line no-typeof-undefined
|
||||
typeof window !== 'undefined' ? window : null,
|
||||
'ROOT_PATH',
|
||||
''
|
||||
);
|
||||
|
||||
const makeImagePath = (src: string) => {
|
||||
return `node_modules/emoji-datasource-apple/img/apple/64/${src}`;
|
||||
return `${ROOT_PATH}node_modules/emoji-datasource-apple/img/apple/64/${src}`;
|
||||
};
|
||||
|
||||
const imageQueue = new PQueue({ concurrency: 10 });
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue