From ef8f1c963647964b0f12a95685db46eff47f629e Mon Sep 17 00:00:00 2001 From: Jakob Wennberg <149234542+jakobwennberg@users.noreply.github.com> Date: Thu, 14 May 2026 11:57:44 +0200 Subject: [PATCH] fix(invoices/new): revert grid row alignment, restore 2-col stacking (#477) MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit The row-aligned grid created visible gaps in the left column because Fakturadetaljer (5+ form fields, ~650px) is much taller than Kund + Fakturarader combined (~500px). Even with lg:row-span-2 on Fakturadetaljer, CSS Grid distributed the extra ~150px as whitespace in the left column's rows, which looked broken. Reverting to the original two-column independent-stacking layout — each column flows its cards naturally, no row alignment. Anteckningar won't be perfectly horizontally aligned with Summering, but the page won't have weird internal gaps either. Independent stacking is the right call when column heights legitimately differ. - Outer grid: lg:grid-cols-3 (drop auto-rows-min and items-start) - Left wrapper restored:
- Right wrapper restored:
- All Card / Button col-start / row-start / row-span / col-span classes removed Co-authored-by: Claude Opus 4.7 (1M context) --- app/(dashboard)/invoices/new/page.tsx | 78 ++++++++++++++------------- 1 file changed, 42 insertions(+), 36 deletions(-) diff --git a/app/(dashboard)/invoices/new/page.tsx b/app/(dashboard)/invoices/new/page.tsx index d13340ef..4ac46f07 100644 --- a/app/(dashboard)/invoices/new/page.tsx +++ b/app/(dashboard)/invoices/new/page.tsx @@ -473,9 +473,11 @@ export default function NewInvoicePage() { )}
-
- {/* Customer selection */} - +
+ {/* Main content */} +
+ {/* Customer selection */} + Kund Välj vilken kund fakturan ska skickas till @@ -516,10 +518,10 @@ export default function NewInvoicePage() { - {/* Invoice items */} - - - Fakturarader + {/* Invoice items */} + + + Fakturarader Lägg till produkter eller tjänster @@ -667,24 +669,27 @@ export default function NewInvoicePage() { - {/* Notes */} - - - Anteckningar + {/* Notes */} + + + Anteckningar Valfritt meddelande på fakturan - -