From 1fc17a8039a59373af028914a3ffaf1919d438d1 Mon Sep 17 00:00:00 2001 From: taogaetz <59668529+taogaetz@users.noreply.github.com> Date: Sun, 14 Sep 2025 15:10:10 -0400 Subject: [PATCH] Update layout to include access management and adjust input type for PIN authentication - Added hasAccess property to layout server load for improved access control. - Updated layout to check for hasAccess instead of authenticated for rendering the LogoutButton. - Changed input type for access PIN from password to tel for better user experience and input handling. --- src/routes/+layout.server.ts | 3 ++- src/routes/+layout.svelte | 2 +- src/routes/access/+page.svelte | 4 +++- 3 files changed, 6 insertions(+), 3 deletions(-) diff --git a/src/routes/+layout.server.ts b/src/routes/+layout.server.ts index 9908f86..1f7ee7f 100644 --- a/src/routes/+layout.server.ts +++ b/src/routes/+layout.server.ts @@ -21,6 +21,7 @@ export const load: LayoutServerLoad = async ({ locals }) => { return { recipes, - authenticated: locals.authenticated + authenticated: locals.authenticated, + hasAccess: locals.hasAccess }; }; diff --git a/src/routes/+layout.svelte b/src/routes/+layout.svelte index 3318848..e404177 100644 --- a/src/routes/+layout.svelte +++ b/src/routes/+layout.svelte @@ -47,7 +47,7 @@ © 2025 Birbante - Italian Apericena & Dolce Vita