feat: complete complex junction transition editing

This commit is contained in:
que01 committed 2026-09-09 16:57:47 +08:00
1 parent 801d8be980
commit 79f83412e6
18 files changed
+400 -59

No files matched your search

+17
View File
@@ -379,3 +379,20 @@ projectJunctionStructure({ model, layers });
projectJunctionStructure({ model, layers, trafficSignals,
junctionRef: { type: 'cluster', id: selectedClusterId } });
```
## Complex carriageway transition length
`cluster-carriageway-transition-length` uses the source-checked
`cluster-carriageway` anchor and `value.transitionLengthMeters`. Replay verifies
source road/node membership before solving. The resolved `clusterTransitions`
map is separate from `clusterCutbacks`: the outer source seam is fixed, and the
inner station is `outerStation - transitionLengthMeters` along the source
polyline. Radial distance differences are not lengths on curved approaches.
The maximum is the available outer station; the minimum is the smaller of the
configured minimum and the existing source-derived transition (short existing
approaches remain representable). Impossible surface geometry still requires
compiler validation. A saved transition is never silently clamped.
Regression evidence: solver rejects out-of-range/source-mismatched values;
API preview measures the requested length and preserves the outer seam;
save/read/replay reproduces preview geometry; browser input sends the new kind.
@@ -318,3 +318,17 @@ Map capability reason codes into user-facing Chinese descriptions.
Required checks: opposite node/cluster scopes with equal raw IDs, unknown scope,
list-to-feature grouping and feature-to-list identity, foreign-cluster exclusion,
raw signal UID selection, map identity preservation, and reload stability.
### Junction workspace save and grouped ranges
Workspace actions must include `EditSession.dirty`, `canUndo`, and `canRedo`;
`JunctionSession.dirty` alone misses settled grouped edits. Reuse the global
commands and expose save status in the junction route, where the main header is
hidden. The edit render revision is not a persisted document version: a save
changes it, so comparing a captured render revision after saving can crash React.
The API owns version conflict checks.
A grouped scalar is available only if the individual ranges intersect. Otherwise
show why a common value is unavailable and expand individual controls; never
render a minimum larger than the maximum. Transition length uses the same input,
preview, history, and persistence path as other geometry parameters.