We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 3ecd1dd commit 1f12f42Copy full SHA for 1f12f42
dist/autoload.js
@@ -25,16 +25,17 @@ function loadExternalResource(url, type) {
25
});
26
}
27
28
-// 加载 live2d.min.js waifu.css waifu-tips.js
29
// 如果担心手机上显示效果不佳,可以通过 `if (screen.width >= 768)` 来判断是否加载
30
(async () => {
+ // 避免图片资源跨域问题
31
const OriginalImage = window.Image;
32
window.Image = function(...args) {
33
const img = new OriginalImage(...args);
34
img.crossOrigin = "anonymous";
35
return img;
36
};
37
window.Image.prototype = OriginalImage.prototype;
38
+ // 加载 waifu.css waifu-tips.js
39
await Promise.all([
40
loadExternalResource(live2d_path + 'waifu.css', 'css'),
41
loadExternalResource(live2d_path + 'waifu-tips.js', 'js')
0 commit comments