This commit is contained in:
Santiago Lo Coco 2024-05-18 17:01:04 +02:00
parent 63f8f81321
commit 16647fb3e1
3 changed files with 4 additions and 4 deletions

View File

@ -2,7 +2,7 @@
import { enhance } from "$app/forms"
import type { Theme, User } from "$lib"
import ThemePicker from "./ThemePicker.svelte"
import { page } from '$app/stores';
import { page } from "$app/stores"
let { theme, user } = $props<{ theme: Theme; user: User }>()

View File

@ -8,7 +8,7 @@ export const load = async ({ locals, url }) => {
throw redirect(302, "/")
}
let from = url.searchParams.get('from')
let from = url.searchParams.get("from")
return { from }
}

View File

@ -3,7 +3,7 @@
let { form, data } = $props()
const from = data.from || "/";
const from = data.from || "/"
</script>
<form action="?/login" method="POST" use:enhance>
@ -12,7 +12,7 @@
<input id="username" name="username" type="text" required />
</div>
<input id="from" name="from" type="hidden" value={from}>
<input id="from" name="from" type="hidden" value={from} />
<div>
<label for="password">Password</label>