Add initial profile background image handling

This commit is contained in:
Johannes Zellner
2025-03-25 15:05:08 +01:00
parent 1f8cdbaf62
commit 23dd575ce1
6 changed files with 53 additions and 6 deletions

View File

@@ -186,6 +186,11 @@ onMounted(async () => {
window.document.title = result.cloudronName;
document.getElementById('favicon').href = `${API_ORIGIN}/api/v1/cloudron/avatar?ts=${Date.now()}`;
if (profile.value.hasBackgroundImage) {
window.document.body.style.backgroundImage = `url('${profile.value.backgroundImageUrl}')`;
window.document.body.classList.add('has-background');
}
ready.value = true;
});