mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-01-19 06:46:09 +01:00
Signed-off-by: Daniel <845765@qq.com>
This commit is contained in:
parent
f8f4b51707
commit
0be7e1d4e0
1 changed files with 2 additions and 0 deletions
|
|
@ -27,8 +27,10 @@ export const unicode2Emoji = (unicode: string, className = "", needSpan = false,
|
|||
let emoji = "";
|
||||
if (unicode.startsWith("api/icon/getDynamicIcon")) {
|
||||
emoji = `<img class="${className}" ${lazy ? "data-" : ""}src="${unicode}"/>`;
|
||||
emoji = Lute.Sanitize(emoji);
|
||||
} else if (unicode.indexOf(".") > -1) {
|
||||
emoji = `<img class="${className}" ${lazy ? "data-" : ""}src="/emojis/${unicode}"/>`;
|
||||
emoji = Lute.Sanitize(emoji);
|
||||
} else {
|
||||
try {
|
||||
unicode.split("-").forEach(item => {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue