From 6e400a35e7313051df24ca32e23612f264050560 Mon Sep 17 00:00:00 2001 From: Bernhard Jackiewicz Date: Fri, 2 Oct 2026 18:39:51 +0200 Subject: [PATCH] fix(ui): zoom the architecture scenes toward the cursor Wheel zoom in the Overview, Routes, System structure and Behavior scenes moved the orthographic camera along its view direction only, so scrolling over a corner of the map always zoomed into the screen centre. The installed three-stdlib OrbitControls support zoomToCursor for orthographic cameras: they keep the point under the cursor fixed and move the orbit target with it, which the fit and scope-camera code already reads back. Signed-off-by: Bernhard Jackiewicz --- graph-ui/src/architecture/ArchitectureScene.tsx | 2 +- graph-ui/src/architecture/SystemArchitectureScene.tsx | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/graph-ui/src/architecture/ArchitectureScene.tsx b/graph-ui/src/architecture/ArchitectureScene.tsx index 9884f0785..670be5be2 100644 --- a/graph-ui/src/architecture/ArchitectureScene.tsx +++ b/graph-ui/src/architecture/ArchitectureScene.tsx @@ -340,7 +340,7 @@ export function ArchitectureScene({ model: graphModel, selectedId, selectedEdgeI + minZoom={0.15} maxZoom={60} rotateSpeed={0.5} zoomSpeed={0.8} maxPolarAngle={Math.PI / 2.05} zoomToCursor /> {(adaptiveLabels || model.view === 'hotspots') && } diff --git a/graph-ui/src/architecture/SystemArchitectureScene.tsx b/graph-ui/src/architecture/SystemArchitectureScene.tsx index b28cfab86..279824853 100644 --- a/graph-ui/src/architecture/SystemArchitectureScene.tsx +++ b/graph-ui/src/architecture/SystemArchitectureScene.tsx @@ -286,7 +286,7 @@ export default function SystemArchitectureScene({ model, selectedNode, selectedE + minZoom={0.15} maxZoom={90} rotateSpeed={0.5} zoomSpeed={0.8} maxPolarAngle={Math.PI / 2.05} zoomToCursor /> ;