From 91eefc520f6e79da8f712c3605cae84b654afa21 Mon Sep 17 00:00:00 2001 From: Julien Oculi Date: Wed, 19 Jun 2024 10:26:48 +0200 Subject: [PATCH] refactor(ui): :recycle: update demo profil page --- routes/profil/index.tsx | 29 ++++++++++++++++++++++++++--- 1 file changed, 26 insertions(+), 3 deletions(-) diff --git a/routes/profil/index.tsx b/routes/profil/index.tsx index a609590..1230b4a 100644 --- a/routes/profil/index.tsx +++ b/routes/profil/index.tsx @@ -1,8 +1,31 @@ -export default function Profil() { +import { Button } from 'univoq' +import LoginForm from '../../islands/LoginForm.tsx' +import PassKeyRegister from '../../islands/PassKeyRegister.tsx' +import type { SessionPageProps } from '../../src/session/mod.ts' +import type { User } from '@cohabit/ressources_manager/mod.ts' + +export default function Profil({ state }: SessionPageProps) { + const user = state.session?.get('user') + + if (user) { + return ( + <> +

Mon compte

+
+
{ JSON.stringify(user, null, 2) }
+
+
+ + +
+ + ) + } + return ( <> -

Profil

-
+

Accéder à mon compte

+ ) }