From 84b4a5f049a12bb22941dac733044d90a01fe052 Mon Sep 17 00:00:00 2001
From: Luca <102960244+Luca-Timo@users.noreply.github.com>
Date: Sat, 6 Jun 2026 23:17:29 +0200
Subject: [PATCH] fix(projects): make the whole email row clickable (opens
preview)
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
Document rows navigate on click, but email rows only had clickable action
buttons — the row itself was dead, which read as inconsistent. The whole
email row now opens the preview; the action buttons stopPropagation so
Resend/Cancel/Retry/Send-now still fire without also opening the preview.
Every actionable feed row is now uniformly clickable.
---
.../src/pages/admin/projects/ProjectCockpitPage.tsx | 12 +++++++++---
1 file changed, 9 insertions(+), 3 deletions(-)
diff --git a/frontend/src/pages/admin/projects/ProjectCockpitPage.tsx b/frontend/src/pages/admin/projects/ProjectCockpitPage.tsx
index e3088830..9b064e64 100644
--- a/frontend/src/pages/admin/projects/ProjectCockpitPage.tsx
+++ b/frontend/src/pages/admin/projects/ProjectCockpitPage.tsx
@@ -357,11 +357,17 @@ export const ProjectCockpitPage: React.FC = () => {
{feed.map((item) => {
const Icon = KIND_ICON[item.kind];
+ // Whole-row click: documents navigate to their detail page,
+ // emails open the preview (so the row behaves like its buttons,
+ // not a dead strip next to them). Hours have neither → static.
+ const onRowClick = item.href
+ ? () => navigate(item.href as string)
+ : (item.kind === 'email' && item.emailId != null ? () => openPreview(item.emailId as number) : undefined);
return (