<script lang="ts">
	import { browser } from "$app/environment";
	import { Toaster } from "$lib/components/ui/sonner";
	import { QueryClient, QueryClientProvider } from "@tanstack/svelte-query";
	import "../app.css";

	let { children } = $props();

	const queryClient = new QueryClient({
		defaultOptions: { queries: { enabled: browser } },
	});
</script>

<svelte:head>
	<title>Checkout</title>
	<meta name="description" content="Checkout" />

	<!-- <script
		async
		src="https://www.googletagmanager.com/gtag/js?id=AW-17085207253"
	></script> -->

	<script>
		// window.dataLayer = window.dataLayer || [];
		// window.gtag = function () {
		// 	dataLayer.push(arguments);
		// };
		// window.gtag("js", new Date());
		// window.gtag("config", "AW-17085207253");
	</script>
</svelte:head>

<Toaster />

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