fix: table-layout fixed + consistent column widths

- table-layout: fixed on the table wrapper so browser respects explicit widths
- All cells (header + rows) now use the same col.width consistently
- Subject column no longer special-cased for width

Co-Authored-By: Claude Opus 4.8 <noreply@anthropic.com>
This commit is contained in:
Gjermund Høsøien Wiggen
2026-06-09 22:16:49 +02:00
parent 5970e3fe9d
commit dde19f5fab

View File

@@ -891,7 +891,7 @@ function TicketWorkbenchContent() {
) : ( ) : (
<> <>
{/* Table layout for consistent column alignment */} {/* Table layout for consistent column alignment */}
<div style={{ display: "table", width: "100%" }}> <div style={{ display: "table", width: "100%", tableLayout: "fixed" }}>
{/* Column header */} {/* Column header */}
<div className={cn( <div className={cn(
"sticky top-0 z-10 border-b border-border bg-muted/50", "sticky top-0 z-10 border-b border-border bg-muted/50",
@@ -953,7 +953,7 @@ function TicketWorkbenchContent() {
{availableColumns.filter((c) => c.visible).map((col) => { {availableColumns.filter((c) => c.visible).map((col) => {
const cellStyle = { const cellStyle = {
display: "table-cell" as const, display: "table-cell" as const,
width: col.key === "subject" ? undefined : col.width, width: col.width,
verticalAlign: "middle" as const, verticalAlign: "middle" as const,
padding: density === "compact" ? "4px 12px" : "8px 12px", padding: density === "compact" ? "4px 12px" : "8px 12px",
}; };