From 1b71b6a1197967271528fd0d5b9ff5fc9a1f3c26 Mon Sep 17 00:00:00 2001
From: Fuwn <contact@fuwn.me>
Date: Thu, 11 Jan 2024 18:45:31 -0800
Subject: feat: notifications

---
 src/routes/+layout.svelte | 28 ++++++++++++++++------------
 1 file changed, 16 insertions(+), 12 deletions(-)

(limited to 'src/routes/+layout.svelte')

diff --git a/src/routes/+layout.svelte b/src/routes/+layout.svelte
index e1df9c9d..52d1b8ba 100644
--- a/src/routes/+layout.svelte
+++ b/src/routes/+layout.svelte
@@ -10,6 +10,8 @@
 	import { fly } from 'svelte/transition';
 	import { readable, type Readable } from 'svelte/store';
 	import { navigating } from '$app/stores';
+	import Notifications from 'svelte-notifications';
+	import Notification from '$lib/Notification/Notification.svelte';
 
 	export let data;
 
@@ -99,18 +101,20 @@
 
 	<p />
 
-	{#key data.url}
-		<div
-			in:fly={{
-				x: way,
-				duration: animationDelay,
-				delay: animationDelay
-			}}
-			out:fly={{ x: -way, duration: animationDelay }}
-		>
-			<slot />
-		</div>
-	{/key}
+	<Notifications item={Notification} zIndex={5000}>
+		{#key data.url}
+			<div
+				in:fly={{
+					x: way,
+					duration: animationDelay,
+					delay: animationDelay
+				}}
+				out:fly={{ x: -way, duration: animationDelay }}
+			>
+				<slot />
+			</div>
+		{/key}
+	</Notifications>
 </div>
 
 <style>
-- 
cgit v1.2.3

