Skip to content

Commit 34c0f24

Browse files
committed
fixes linear angle drag being off if starting from a named angle
1 parent bbb367a commit 34c0f24

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

src/components/LinearOverlay.svelte

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -114,6 +114,12 @@
114114
}
115115
else if (isRotator) {
116116
try { node.setPointerCapture(e.pointerId) } catch {}
117+
// If starting rotation from a named angle, normalize numeric angle first to avoid a visual jump
118+
if ($linear_named_angle !== '--') {
119+
// Align the numeric store with the visual angle immediately
120+
$linear_angle = visualAngleDeg
121+
$linear_named_angle = '--'
122+
}
117123
// Initialize rotation anchor from current pointer so the first delta starts from here
118124
const previewRect = isRotator.closest('.preview')?.getBoundingClientRect()
119125
if (previewRect) {

0 commit comments

Comments
 (0)