From 90abb398faecd2f3032b76e893bb9dcf97e64f69 Mon Sep 17 00:00:00 2001 From: kovakmedya Date: Thu, 21 May 2026 22:40:44 +0300 Subject: [PATCH] fix(ui): Card gets min-w-0 so children inside grid tracks can shrink MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Even after switching the page-level grid columns to minmax(0,1fr), the Card primitive itself was still bringing its intrinsic min-content into the column — every Card defaults to 'min-width: auto', and a Card with a wide table inside resolves min-content to the table width. That meant the column still couldn't collapse and the table's overflow-x-auto wrapper never saw a constrained parent, so the action buttons spilled past the Card border. Added 'min-w-0' to Card and CardContent so: - the Card collapses to whatever the grid track allows; - CardContent collapses inside the Card, letting the Table wrapper finally enforce its overflow-x-auto scroll. Also fixed two inner form grids that had the same '1fr' overflow trap: ProstheticForm and ProstheticsTable's edit dialog both use a [price][currency] split, switched to minmax(0,1fr)_100px so the 'Para birimi' label / TRY value no longer get pushed past the form edge. --- src/app/(dashboard)/products/components/prosthetic-form.tsx | 2 +- src/app/(dashboard)/products/components/prosthetics-table.tsx | 2 +- src/components/ui/card.tsx | 4 ++-- 3 files changed, 4 insertions(+), 4 deletions(-) diff --git a/src/app/(dashboard)/products/components/prosthetic-form.tsx b/src/app/(dashboard)/products/components/prosthetic-form.tsx index 72b31ce..bd71bdf 100644 --- a/src/app/(dashboard)/products/components/prosthetic-form.tsx +++ b/src/app/(dashboard)/products/components/prosthetic-form.tsx @@ -65,7 +65,7 @@ export function ProstheticForm({ defaultCurrency }: { defaultCurrency: string }) )} -
+
-
+
) {
) { return (
)