50 lines
877 B
Svelte
50 lines
877 B
Svelte
<script lang="ts">
|
|
import { page } from '$app/state';
|
|
let { error } = $props();
|
|
</script>
|
|
|
|
<div class="error-page">
|
|
<h1>Something went wrong</h1>
|
|
<p>{error?.message || 'An unexpected error occurred.'}</p>
|
|
<div class="hint">
|
|
Try
|
|
<form method="POST" action="/logout" class="inline-form">
|
|
<button type="submit" class="link-button">logging out</button>
|
|
</form>
|
|
and signing in again.
|
|
</div>
|
|
</div>
|
|
|
|
<style>
|
|
.error-page {
|
|
max-width: 480px;
|
|
margin: 4rem auto;
|
|
text-align: center;
|
|
padding: 2rem;
|
|
}
|
|
h1 {
|
|
font-size: 1.5rem;
|
|
color: #111827;
|
|
margin-bottom: 0.5rem;
|
|
}
|
|
p {
|
|
color: #6b7280;
|
|
}
|
|
.hint {
|
|
margin-top: 1.5rem;
|
|
font-size: 0.9rem;
|
|
}
|
|
.inline-form {
|
|
display: inline-block;
|
|
}
|
|
.link-button {
|
|
background: none;
|
|
border: none;
|
|
padding: 0;
|
|
font: inherit;
|
|
color: #6366f1;
|
|
text-decoration: underline;
|
|
cursor: pointer;
|
|
}
|
|
</style>
|