mirror of
https://github.com/misskey-dev/misskey
synced 2024-12-13 22:29:05 +09:00
Fix bug caused by Chrome 71 (#3535)
* Update emoji.vue * Update autocomplete.vue * Update emoji.vue * Update autocomplete.vue * Update emoji.vue
This commit is contained in:
parent
93b599dc8e
commit
9f09afc824
@ -44,8 +44,9 @@ const lib = Object.entries(emojilib.lib).filter((x: any) => {
|
|||||||
});
|
});
|
||||||
|
|
||||||
const char2file = (char: string) => {
|
const char2file = (char: string) => {
|
||||||
let codes = [...char].map(x => x.codePointAt(0).toString(16));
|
let codes = Array.from(char).map(x => x.codePointAt(0).toString(16));
|
||||||
if (!codes.includes('200d')) codes = codes.filter(x => x != 'fe0f');
|
if (!codes.includes('200d')) codes = codes.filter(x => x != 'fe0f');
|
||||||
|
codes = codes.filter(x => x && x.length);
|
||||||
return codes.join('-');
|
return codes.join('-');
|
||||||
};
|
};
|
||||||
|
|
||||||
|
@ -66,8 +66,9 @@ export default Vue.extend({
|
|||||||
}
|
}
|
||||||
|
|
||||||
if (this.char) {
|
if (this.char) {
|
||||||
let codes = [...this.char].map(x => x.codePointAt(0).toString(16));
|
let codes = Array.from(this.char).map(x => x.codePointAt(0).toString(16));
|
||||||
if (!codes.includes('200d')) codes = codes.filter(x => x != 'fe0f');
|
if (!codes.includes('200d')) codes = codes.filter(x => x != 'fe0f');
|
||||||
|
codes = codes.filter(x => x && x.length);
|
||||||
|
|
||||||
this.url = `https://twemoji.maxcdn.com/2/svg/${codes.join('-')}.svg`;
|
this.url = `https://twemoji.maxcdn.com/2/svg/${codes.join('-')}.svg`;
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user