<script lang="ts">
	import Header from '$lib/Header.svelte';
	import { QueryClient, QueryClientProvider } from '@tanstack/svelte-query';
	import './layout.css';
	import 'nprogress/nprogress.css';
	import NProgress from 'nprogress';
	import { SvelteQueryDevtools } from '@tanstack/svelte-query-devtools';
	import { Toaster } from 'svelte-sonner';

	let { children } = $props();
	const queryClient = new QueryClient();
	NProgress.configure({ showSpinner: false });
</script>

<Header />
<Toaster position="top-center" theme="dark" />

<QueryClientProvider client={queryClient}>
	{@render children()}
	<SvelteQueryDevtools />
</QueryClientProvider>
