From 0dc907b75c2a479ed1136073ae05f2e9e4c3d990 Mon Sep 17 00:00:00 2001 From: Madhura68 Date: Sun, 26 Apr 2026 19:37:51 +0200 Subject: [PATCH] feat(ST-507): add email input to settings and surface in user menu Co-Authored-By: Claude Opus 4.7 (1M context) --- app/(app)/layout.tsx | 4 ++-- app/(app)/settings/page.tsx | 3 ++- components/settings/profile-editor.tsx | 20 +++++++++++++++++++- components/shared/nav-bar.tsx | 6 +++--- components/shared/user-menu.tsx | 6 +++--- 5 files changed, 29 insertions(+), 10 deletions(-) diff --git a/app/(app)/layout.tsx b/app/(app)/layout.tsx index 5bc6df2..5bb4999 100644 --- a/app/(app)/layout.tsx +++ b/app/(app)/layout.tsx @@ -17,7 +17,7 @@ export default async function AppLayout({ children }: { children: React.ReactNod const [user, userRoles] = await Promise.all([ prisma.user.findUnique({ where: { id: session.userId }, - select: { username: true, bio: true }, + select: { username: true, email: true }, }), prisma.userRole.findMany({ where: { user_id: session.userId }, @@ -40,7 +40,7 @@ export default async function AppLayout({ children }: { children: React.ReactNod roles={roles} userId={session.userId} username={user.username} - bio={user.bio} + email={user.email} />
diff --git a/app/(app)/settings/page.tsx b/app/(app)/settings/page.tsx index 0c57363..70e0466 100644 --- a/app/(app)/settings/page.tsx +++ b/app/(app)/settings/page.tsx @@ -13,7 +13,7 @@ export default async function SettingsPage() { const [user, userRoles, ownedProducts, memberships] = await Promise.all([ prisma.user.findUnique({ where: { id: session.userId }, - select: { username: true, bio: true, bio_detail: true, avatar_data: true, updated_at: true }, + select: { username: true, email: true, bio: true, bio_detail: true, avatar_data: true, updated_at: true }, }), prisma.userRole.findMany({ where: { user_id: session.userId } }), prisma.product.findMany({ @@ -58,6 +58,7 @@ export default async function SettingsPage() {

Niet beschikbaar in demo-modus.

) : ( ( hasAvatar ? `/api/profile/avatar?v=${avatarVersion}` : null @@ -107,6 +108,23 @@ export function ProfileEditor({ bio, bioDetail, hasAvatar, avatarVersion }: Prof
+
+ + +

Optioneel — wordt getoond in je accountmenu

+
+