mirror of
https://github.com/siyuan-note/siyuan.git
synced 2026-02-22 15:04:07 +01:00
This commit is contained in:
parent
6806392b41
commit
51b4b26426
11 changed files with 7 additions and 43981 deletions
|
|
@ -105,7 +105,7 @@ export const loadAssets = (data: IAppearance) => {
|
|||
while (svgElement.tagName === "svg") {
|
||||
const currentSvgElement = svgElement;
|
||||
svgElement = svgElement.nextElementSibling;
|
||||
if (currentSvgElement.id !== "emojiScriptSvg" && !currentSvgElement.getAttribute("data-name")) {
|
||||
if (!currentSvgElement.getAttribute("data-name")) {
|
||||
currentSvgElement.remove();
|
||||
}
|
||||
}
|
||||
|
|
@ -116,15 +116,8 @@ export const loadAssets = (data: IAppearance) => {
|
|||
};
|
||||
|
||||
export const initAssets = () => {
|
||||
const emojiElement = document.getElementById("emojiScript");
|
||||
const loadingElement = document.getElementById("loading");
|
||||
if (!emojiElement && !window.siyuan.config.appearance.nativeEmoji && !isMobile()) {
|
||||
addScript("/appearance/emojis/twitter-emoji.js?v=1.0.1", "emojiScript").then(() => {
|
||||
if (loadingElement) {
|
||||
loadingElement.remove();
|
||||
}
|
||||
});
|
||||
} else if (loadingElement) {
|
||||
if (loadingElement) {
|
||||
setTimeout(() => {
|
||||
loadingElement.remove();
|
||||
}, 160);
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue