From 55f8a0656023e433661f260f5ef3824c4bf0456e Mon Sep 17 00:00:00 2001 From: mAi Date: Sat, 16 May 2026 19:32:14 +0200 Subject: [PATCH] fix(ui): frame label is a clickable drag grip MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Frame rect interior is occluded by devices/cables in SVG render order, so clicking the frame to select/drag it was unreliable. Drop pointer-events:none from .frame-label and bind the same pointerdown→startDrag('frame',id) as the rect — the top-left label text is now a deterministic grip. --- web/static/main.js | 1 + web/static/style.css | 2 +- 2 files changed, 2 insertions(+), 1 deletion(-) diff --git a/web/static/main.js b/web/static/main.js index 7cf789f..08834e3 100644 --- a/web/static/main.js +++ b/web/static/main.js @@ -482,6 +482,7 @@ function renderCanvas() { g.append(rect, label); gFrames.append(g); rect.addEventListener("pointerdown", (e) => startDrag(e, "frame", f.id)); + label.addEventListener("pointerdown", (e) => startDrag(e, "frame", f.id)); } const portsByDevice = new Map(); diff --git a/web/static/style.css b/web/static/style.css index c2950c1..97ba34c 100644 --- a/web/static/style.css +++ b/web/static/style.css @@ -180,7 +180,7 @@ body { fill: var(--accent); font-size: 13px; font-weight: 600; - pointer-events: none; + cursor: grab; } /* Stroke + fill come from the device's user-set colour, written as