misc: tweak error pages, fix #159
This commit is contained in:
1 parent
1b4a80ded2
commit
29fa924cb3
3 files changed
+19
-8
No files matched your search
@@ -1,11 +1,22 @@
|
||||
<script lang="ts">
|
||||
import { goto } from '$app/navigation'
|
||||
import { page } from '$app/stores'
|
||||
import { Button } from 'mono-svelte'
|
||||
import { Icon, XMark } from 'svelte-hero-icons'
|
||||
</script>
|
||||
|
||||
<div class="flex flex-col mx-auto gap-4 justify-center items-center h-full">
|
||||
<h1 class="font-black text-5xl">{$page.status}</h1>
|
||||
<p>Failed to fetch that page.</p>
|
||||
<div
|
||||
class="flex flex-col gap-2 mx-auto my-auto items-center h-full justify-center"
|
||||
>
|
||||
<div
|
||||
class="rounded-full bg-red-200 dark:bg-red-900 text-red-600 dark:text-red-300 p-3 w-max"
|
||||
>
|
||||
<Icon src={XMark} size="32" mini />
|
||||
</div>
|
||||
<h1 class="text-red-800 dark:text-red-300 text-4xl font-black">
|
||||
{$page.status}
|
||||
</h1>
|
||||
<p class="text-red-800 dark:text-red-300">Failed to fetch that page.</p>
|
||||
<code>{$page.error?.message}</code>
|
||||
<Button href={$page.url.toString()}>Retry</Button>
|
||||
<Button on:click={() => goto($page.url)}>Retry</Button>
|
||||
</div>
|
||||
Reference in new issue
Block a user