fix(docker): truncate long image names in container table

Fixes #825

Long Docker image names (like Immich postgres containers) were expanding
the entire table row, requiring horizontal scrolling to see CPU/Memory.

Changed the image cell to use:
- Inline style max-width (more reliable in table layouts)
- Block span with truncate class
- overflow-hidden on parent container

Images now truncate with ellipsis at 200px, with full name in tooltip.
This commit is contained in:
rcourtman 2025-12-14 22:05:38 +00:00
parent b004f6d017
commit 3948652a21

View file

@ -1290,10 +1290,15 @@ const DockerContainerRow: Component<{
case 'image':
return (
<div
class="px-2 py-0.5 text-xs text-gray-700 dark:text-gray-300 truncate max-w-[200px]"
title={container.image || undefined}
class="px-2 py-0.5 text-xs text-gray-700 dark:text-gray-300 overflow-hidden"
style={{ "max-width": "200px" }}
>
{container.image || '—'}
<span
class="block truncate"
title={container.image || undefined}
>
{container.image || '—'}
</span>
</div>
);
case 'status':