@shumoku/core · 0.4.0 · function
findDetachedTerminals
Find wires whose polyline does not terminate ON its ports in from→to order (port-attachment constraint). Checks both the position (each terminal within `epsilon` of its port) and the direction contract (`points[0]` is the FROM port specifically — a reversed but touching polyline is reported as detached at both ends). Lines with fewer than two points are skipped: there is no path to check.
findDetachedTerminals(lines: readonly AttachedLineSpec[], epsilon?: number): TerminalDetachment[] Parameters
| Parameter | Type | Description | Default |
|---|---|---|---|
lines | readonly AttachedLineSpec[] | No additional description. | — |
epsilon | number | No additional description. | 0.5 |
Returns
TerminalDetachment[]