add queue button in sidebar

This commit is contained in:
2026-03-07 03:14:34 +01:00
parent 665e3ac3dd
commit 43692ae4e9
4 changed files with 142 additions and 67 deletions

View File

@@ -3,6 +3,8 @@
import Sidebar from '$lib/components/Sidebar.svelte';
import Header from '$lib/components/Header.svelte';
import { page } from '$app/state';
import { onMount } from 'svelte';
import { startPolling, stopPolling } from '$lib/stores/queue.svelte';
let { children } = $props();
@@ -18,6 +20,12 @@
PICKING: 'Picking',
PLAYING: 'Playing'
};
onMount(() => {
if (!user) return;
startPolling();
return () => stopPolling();
});
</script>
{#if user}