Implement time bar and update LDB components to handle it

This commit is contained in:
Fred Boniface
2024-07-12 15:04:06 +01:00
parent 7f1dc1ac3f
commit 6d175f300f
6 changed files with 64 additions and 59 deletions

View File

@@ -1,4 +1,4 @@
<script>
<script lang="ts">
import Header from "$lib/navigation/header.svelte";
import Nav from "$lib/navigation/nav-ldb.svelte";
import PublicLdb from "$lib/ldb/public-ldb.svelte";
@@ -12,9 +12,10 @@
return new URLSearchParams(window.location.search).get("station");
}
let station = "";
let staff = false;
let uuidValue = "";
let station: string;
let staff: boolean;
let uuidValue: string;
let blockLoading: boolean = true;
$: uuidValue = $uuid;
@@ -26,17 +27,19 @@
} else {
title = "Public Board";
}
blockLoading = false;
});
</script>
<Header {title} />
<!-- If 'uuid' exists in store then load StaffLdb else load PublicLdb -->
{#if !staff}
<PublicLdb {station} bind:title />
{:else}
<StaffLdb {station} bind:title />
<!--<StaffLdb {station} bind:title={title} /> -- Temporary, Disable StaffLdb - it isn't implemented -->
{#if !blockLoading}
{#if !staff}
<PublicLdb {station} bind:title />
{:else}
<StaffLdb {station} bind:title />
{/if}
{/if}
<Nav />