From 4aa3ba34eae79b147ec2df8575fa234a277582b4 Mon Sep 17 00:00:00 2001 From: Timon Date: Sun, 25 Oct 2026 22:03:24 +0000 Subject: [PATCH] Fix Layers panel node chains (ellip)sizing incorrectly with fractional UI scales in Chromium (#4813) Fix layer chain overflow at fractional UI scales --- frontend/src/components/panels/Layers.svelte | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/frontend/src/components/panels/Layers.svelte b/frontend/src/components/panels/Layers.svelte index 98d8cb3308..a02cabb772 100644 --- a/frontend/src/components/panels/Layers.svelte +++ b/frontend/src/components/panels/Layers.svelte @@ -156,7 +156,8 @@ const chainResizeObserver = new ResizeObserver((entries) => { entries.forEach((entry) => { const rowIndex = Number(entry.target.closest("[data-layer]")?.getAttribute("data-index")); - if (!Number.isNaN(rowIndex)) chainWidths[rowIndex] = entry.contentRect.width; + // Rounded to avoid issue for fractional device pixel ratio + if (!Number.isNaN(rowIndex)) chainWidths[rowIndex] = Math.round(entry.contentRect.width); }); chainWidths = chainWidths; });