ui: Change the window title according to the viewed domain

This commit is contained in:
nemunaire 2023-11-23 12:19:30 +01:00
parent 33f4656761
commit 409cfe3956
1 changed files with 9 additions and 1 deletions

View File

@ -3,6 +3,7 @@
import "bootstrap-icons/font/bootstrap-icons.css";
import { goto } from '$app/navigation';
import { page } from '$app/stores';
import {
Col,
@ -35,10 +36,17 @@
});
}
}
let title = 'happyDomain';
$: if ($page.data.selectedDomain) {
title = $page.data.selectedDomain.domain.substring(0, $page.data.selectedDomain.domain.length - 1) + ' - happyDomain';
} else {
title = 'happyDomain';
}
</script>
<svelte:head>
<title>happyDomain</title>
<title>{title}</title>
</svelte:head>
<!--Styles /-->