修改live2d初始化不显示

master 1.0.6
shendongjun 2 years ago
parent 17179e7867
commit 84eb4b2af8

@ -42,7 +42,6 @@ if (screen.width >= 768) {
// apiPath: "https://live2d.fghrsh.net/api/", // apiPath: "https://live2d.fghrsh.net/api/",
cdnPath: "https://npm.elemecdn.com/akilar-live2dapi@latest/" cdnPath: "https://npm.elemecdn.com/akilar-live2dapi@latest/"
// cdnPath: "https://npm.elemecdn.com/shendongjun-live2dapi@latest/" // cdnPath: "https://npm.elemecdn.com/shendongjun-live2dapi@latest/"
// cdnPath: "https://npm.elemecdn.com/shendongjun-live2dapi@latest/"
}); });
}); });
} }

@ -15,7 +15,8 @@ function loadWidget(config) {
console.error("Invalid initWidget argument!"); console.error("Invalid initWidget argument!");
return; return;
} }
localStorage.removeItem("waifu-display"); // localStorage.removeItem("waifu-display"); //页面初始化显示live2d
localStorage.setItem("waifu-display", Date.now());//页面一开始不显示live2d
sessionStorage.removeItem("waifu-text"); sessionStorage.removeItem("waifu-text");
document.body.insertAdjacentHTML("beforeend", `<div id="waifu"> document.body.insertAdjacentHTML("beforeend", `<div id="waifu">
<div id="waifu-tips"></div> <div id="waifu-tips"></div>

Loading…
Cancel
Save