fix(boot): background is moving

This commit is contained in:
무라쿠모 2024-07-25 19:23:09 +09:00
parent 71ee993f05
commit e760b78963
No known key found for this signature in database
GPG key ID: 139D6573F92DA9F7
2 changed files with 20 additions and 4 deletions

View file

@ -137,9 +137,10 @@
document.documentElement.classList.add('useSystemFont');
}
const wallpaper = localStorage.getItem('wallpaper');
const wallpaper = localStorage.getItem('wallpaper') ?? meta.backgroundImageUrl;
if (wallpaper) {
document.documentElement.style.backgroundImage = `url(${wallpaper})`;
document.documentElement.style.background = `url(${wallpaper}) no-repeat fixed center`;
document.documentElement.style.backgroundSize = 'cover';
}
const customCss = localStorage.getItem('customCss');