Prevent double-click to constrain length on unsupported lines (#5938)

* WIP: Prevent length constraint creation on endAbsolute lines
Fixes #5937

* Typo

Thanks @franknoirot

Co-authored-by: Frank Noirot <frank@zoo.dev>

* length constraint stuff from @lrev-Dev

* Clean up

* Lint

* Add regression test for double click after sketch constraint

---------

Co-authored-by: Frank Noirot <frank@zoo.dev>
Co-authored-by: Kurt Hutten Irev-Dev <k.hutten@protonmail.ch>
This commit is contained in:
Pierre Jacquier
2025-04-02 10:52:36 -04:00
committed by GitHub
parent d168ef94e9
commit 10c1f3a849
7 changed files with 116 additions and 65 deletions

View File

@ -15,6 +15,7 @@ import { createProfileStartHandle } from '@src/clientSideScene/segments'
import type { MachineManager } from '@src/components/MachineManagerProvider'
import type { ModelingMachineContext } from '@src/components/ModelingMachineProvider'
import type { SidebarType } from '@src/components/ModelingSidebar/ModelingPanes'
import { angleLengthInfo } from '@src/components/Toolbar/angleLengthInfo'
import {
applyConstraintEqualAngle,
equalAngleInfo,
@ -41,7 +42,6 @@ import {
applyConstraintHorzVertAlign,
horzVertDistanceInfo,
} from '@src/components/Toolbar/SetHorzVertDistance'
import { angleLengthInfo } from '@src/components/Toolbar/setAngleLength'
import { createLiteral, createLocalName } from '@src/lang/create'
import { updateModelingState } from '@src/lang/modelingWorkflows'
import {