From c680e2463046f4123f6ef3710e5cf9655cf3da57 Mon Sep 17 00:00:00 2001
From: mat <github@matdoes.dev>
Date: Mon, 21 Feb 2022 20:43:55 -0600
Subject: add collections and zones

---
 src/routes/__error.svelte | 53 +++++++++++++++++++++++++++++++++++++++++++++++
 1 file changed, 53 insertions(+)
 create mode 100644 src/routes/__error.svelte

(limited to 'src/routes/__error.svelte')

diff --git a/src/routes/__error.svelte b/src/routes/__error.svelte
new file mode 100644
index 0000000..b49d2a1
--- /dev/null
+++ b/src/routes/__error.svelte
@@ -0,0 +1,53 @@
+<script lang="ts" context="module">
+	import type { ErrorLoad } from '@sveltejs/kit'
+
+	export const load: ErrorLoad = async ({ error, status }) => {
+		return {
+			props: {
+				error,
+				status,
+			},
+		}
+	}
+</script>
+
+<script lang="ts">
+	import Header from '$lib/Header.svelte'
+	import Head from '$lib/Head.svelte'
+
+	export let status: number
+	export let error: Error
+</script>
+
+<Head title={error.message} />
+<Header />
+
+<main>
+	<div>
+		<h1>{status}</h1>
+		<p>{error.message}</p>
+		<a href="/" sveltekit:prefetch>Home</a>
+	</div>
+</main>
+
+<style>
+	main {
+		height: calc(100% - 4rem);
+		/* vertical align */
+		display: grid;
+		align-items: center;
+		justify-content: center;
+	}
+
+	h1 {
+		font-size: 3em;
+		margin: 0;
+	}
+	p {
+		margin: 0;
+	}
+	a {
+		display: block;
+		margin-top: 0.5rem;
+	}
+</style>
-- 
cgit 

