X-Git-Url: https://git.r.bdr.sh/rbdr/forum/blobdiff_plain/58f7d52150456713d3132408668a92d0f6f3d084..47b0bfe47e6f13d549897149b0abc4a72ba8ac88:/src/routes/%24layout.svelte

diff --git a/src/routes/$layout.svelte b/src/routes/$layout.svelte
index 49ceb49..8fd2ae0 100644
--- a/src/routes/$layout.svelte
+++ b/src/routes/$layout.svelte
@@ -1,6 +1,12 @@
 <script>
 	import '$/config/i18n';
+
 	import { isLoading } from 'svelte-i18n';
+	import { _ } from 'svelte-i18n';
+
+	import { forums } from '$/stores/forums';
+
+	import ErrorBlock from '$/components/error_block/error_block.svelte';
 	import ForumList from '$/components/forum_list/forum_list.svelte';
 	import Header from '$/components/header/header.svelte';
 	import Loader from '$/components/loader/loader.svelte';
@@ -14,6 +20,24 @@
 	<main>
 		<slot />
 	</main>
-	<ForumList />
+  <nav title={$_('forum_list.title')}>
+    {#if $forums.loading}
+      <Loader />
+    {/if}
+    {#if $forums.error}
+      <ErrorBlock message={$_('forum_list.error.unavailable')} />
+    {/if}
+    {#if $forums.data}
+      <ForumList forums={$forums.data} />
+    {/if}
+  </nav>
 	<Footer />
 {/if}
+
+<style>
+	nav {
+		grid-column: col-start 1;
+		grid-row: 2;
+		border-right: 1px solid black;
+	}
+</style>
