]> git.r.bdr.sh - rbdr/forum/blob - app/components/forum_list/forum_list.svelte
905421ee19264eb21f3ae973d3a18dbc07bbe407
[rbdr/forum] / app / components / forum_list / forum_list.svelte
1 <script>
2 import {forums, addForum} from '../../models/forums.js'
3
4 import { fade } from 'svelte/transition';
5 </script>
6
7 <aside>
8 <button on:click="{addForum}">Add a Forum</button>
9 <nav>
10 <ul>
11 {#each $forums as forum}
12 <li transition:fade>
13 <a href="/f/{forum.id}">
14 <span class="navigation-kanji">{forum.kanji}</span>
15 <span class="navigation-label">{forum.label}</span>
16 </a>
17 </li>
18 {/each}
19 </ul>
20 </nav>
21 </aside>