From 8cee8282125ce7ff28002ab8cc4d51d94363c585 Mon Sep 17 00:00:00 2001 From: BOHA Date: Sun, 7 Jun 2026 15:48:39 +0200 Subject: [PATCH] fix(attendance): stop the page + leave modal overflowing (grid minmax + minWidth:0) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Two overflow fixes on Attendance.tsx: (1) the leave-request modal's Od/Do date row used a bare gridTemplateColumns '1fr 1fr', whose minmax(auto,1fr) tracks couldn't shrink below the two DatePickers' min-content, overflowing the narrow modal (horizontal scroll, 'Do' clipped) — now minmax(0,1fr). (2) On phones the whole page overflowed: the main two-column grid used { xs: '1fr' }, and the left column's 5-col 'Dnešní dokončené směny' table forced a 477px min-content (the TableContainer's overflow-x:auto never engaged because the grid item had min-width:auto). Now the grid uses minmax(0,1fr) and both columns get minWidth:0, so the table scrolls inside its container and the page fits the viewport. Verified at 390px width via DOM measurement. Co-Authored-By: Claude Opus 4.8 (1M context) --- src/admin/pages/Attendance.tsx | 13 +++++++++---- 1 file changed, 9 insertions(+), 4 deletions(-) diff --git a/src/admin/pages/Attendance.tsx b/src/admin/pages/Attendance.tsx index 2c94ca7..142fe5c 100644 --- a/src/admin/pages/Attendance.tsx +++ b/src/admin/pages/Attendance.tsx @@ -630,13 +630,16 @@ export default function Attendance() { {/* Left Column - Clock In/Out */} - + {/* Right Column - Stats & Quick Links */} - + {/* Leave Balance Card */}