From 783a697d953b0328219b82d39768f28f76ee86e0 Mon Sep 17 00:00:00 2001 From: Maurice Date: Sun, 15 Nov 2026 12:23:27 +0100 Subject: [PATCH] fix(dashboard): a long trip name in an upcoming booking ends in an ellipsis The badge holds its text in an element of its own, which the ellipsis needs inside a flex badge, and the row's middle column may shrink below its content. --- client/src/pages/DashboardPage.tsx | 2 +- client/src/styles/dashboard.css | 4 +++- 2 files changed, 4 insertions(+), 2 deletions(-) diff --git a/client/src/pages/DashboardPage.tsx b/client/src/pages/DashboardPage.tsx index 3e50d1ec3..c202b873e 100644 --- a/client/src/pages/DashboardPage.tsx +++ b/client/src/pages/DashboardPage.tsx @@ -773,7 +773,7 @@ function UpcomingTool({ items, locale, onOpen }: {
{timeStr && {timeStr}} {(moment || r.location || r.place_name || r.trip_title) && ( - {moment ? t(moment) : (r.location || r.place_name || r.trip_title)} + {moment ? t(moment) : (r.location || r.place_name || r.trip_title)} )}
diff --git a/client/src/styles/dashboard.css b/client/src/styles/dashboard.css index c58327040..d6596fae0 100644 --- a/client/src/styles/dashboard.css +++ b/client/src/styles/dashboard.css @@ -642,7 +642,7 @@ .trek-dash .tz-del:hover { background: var(--bg-2); color: #ef4444; } .trek-dash .tz-empty { font-size: 12px; color: var(--ink-3); } .trek-dash .upc-list { display: flex; flex-direction: column; gap: 12px; } -.trek-dash .upc-item { display: grid; grid-template-columns: 56px 1fr auto; gap: 14px; padding: 12px; border-radius: 14px; align-items: center; transition: background .12s; cursor: pointer; } +.trek-dash .upc-item { display: grid; grid-template-columns: 56px minmax(0, 1fr) auto; gap: 14px; padding: 12px; border-radius: 14px; align-items: center; transition: background .12s; cursor: pointer; } .trek-dash .upc-item:hover { background: var(--surface-2); } .trek-dash .upc-date { background: var(--surface-2); border-radius: 10px; padding: 8px 4px; text-align: center; } .trek-dash .upc-date .d { font-size: 18px; font-weight: 600; letter-spacing: -0.02em; line-height: 1; } @@ -655,6 +655,8 @@ .trek-dash .upc-info .s { font-size: 12px; color: var(--ink-3); display: flex; align-items: center; gap: 5px; margin-top: 3px; min-width: 0; } .trek-dash .upc-info .s .upc-chip:first-child { flex-shrink: 0; } .trek-dash .upc-info .s .upc-chip { min-width: 0; } +/* A long trip name ends in an ellipsis inside its badge. */ +.trek-dash .upc-chip-text { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } /* The time and the where as soft badges instead of a line strung together with dots. */ .trek-dash .upc-chip { display: inline-flex; align-items: center; gap: 4px; max-width: 100%; padding: 2px 8px; border-radius: 999px; background: var(--bg-2); color: var(--ink-2); font-size: 11.5px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; } .trek-dash .upc-info .s svg { width: 11px; height: 11px; }