From 04402c6b6584095f38bd350d1a3bd21df06031f5 Mon Sep 17 00:00:00 2001 From: NotiBot Date: Tue, 3 Feb 2026 23:25:57 +0100 Subject: [PATCH] fix: right-side content cutoff on tasks page - SidebarInset: use min-w-0 + overflow-x-hidden instead of w-full - Calendar: measure container width instead of viewport width - Remove unnecessary max-w-screen-2xl from main content area --- client/src/App.tsx | 2 +- client/src/components/TasksWithCalendar.tsx | 14 ++++++++------ client/src/components/ui/sidebar.tsx | 2 +- 3 files changed, 10 insertions(+), 8 deletions(-) diff --git a/client/src/App.tsx b/client/src/App.tsx index 3608ef8..8c69ea1 100644 --- a/client/src/App.tsx +++ b/client/src/App.tsx @@ -360,7 +360,7 @@ function AppContent() { {t('app.title')} -
+
(null); useEffect(() => { const calculateVisibleDays = () => { - const screenWidth = window.innerWidth; - // Subtract margins and padding (approximately 32px total) - const availableWidth = screenWidth - 32; + // Use actual container width (accounts for sidebar) instead of window.innerWidth + const containerWidth = containerRef.current?.offsetWidth ?? window.innerWidth; + // Subtract padding (approximately 32px total) + const availableWidth = containerWidth - 32; // Minimum width per day card (including gaps): ~120px const minDayWidth = 120; const maxDays = Math.floor(availableWidth / minDayWidth); @@ -257,7 +259,7 @@ export default function TasksWithCalendar({ tasks, onTaskUpdate, onTaskEdit, onT }; return ( -
+
{/* Header and Search Filters - Fixed at Top */}
diff --git a/client/src/components/ui/sidebar.tsx b/client/src/components/ui/sidebar.tsx index 496e40d..bedbf62 100644 --- a/client/src/components/ui/sidebar.tsx +++ b/client/src/components/ui/sidebar.tsx @@ -310,7 +310,7 @@ function SidebarInset({ className, ...props }: React.ComponentProps<"main">) {