- When drawing an Area, the leading edge is allowed to temporarily be in an invalid position (see #4655)..
.. Finishing a drawing is disabled if doing so would close with the invalid leading edge
(closes#4844)
The maxDistance was previously hardcoded to 30 meters.
Now we pass it in as a parameter when creating the intersection.
But we need to honor that same maxDistance later when walking the graph
to find turns from.
Before, it was drawing svg path elements for all the segments,
even those that were clipped out of view (getPath returns null).
This was putting a lot of junk into the DOM.
(closes#4841)
Before, first/last keyboard shortcuts only worked if you had a vertex selected.
Now you can navigate to the first/last vertices even if you have the way selected.
- change the "Up to {num} ways" to "Up to 2 ways"
(we don't plan to go above 2 for now)
- enumerate all the turn types No/Only/Allowed x Left/Right/Straight/U
- Add a line for "Click for" to let user know they can click to toggle
see https://github.com/openstreetmap/iD/pull/4768#pullrequestreview-100256196
- actionRestrictTurn will no longer "infer" the turn type
- restrictionType *must* be passed in - this is ok because the only code
we use this action (restrictions.js) already has inferred the type
- this simplifies what the action actually does
- moved the tests from restrict_turn.js that were really just testing
the restriction type inferrence over to intersection.js
(and added a few more tests for iD.osmInferRestriction)
This was used to decide whether to show the "Max Via" control.
(It's not really needed for a simple intersection)
However since we added the "Max Distance" control, it just makes
sense to show both sliders, since the distance can affect the
complexity.
"indirect only" means an only restriction elsewhere in the intersection
that affects the selected from way.
| |
---+--F--+---
A |
---v--T--+---
B |
In the above example
- 'only_straight_on' restriction "FROM way A VIA node V TO way B"
- way F is selected
This would indirectly prevent a u-turn "FROM way F VIA way A TO way T"
We want to display the straight on restriction in the UI as
"only_straight_on FROM way A VIA node V TO way B"
not
"only_left_turn FROM way F VIA way A TO way B"
When they are on the enter selection, they can stay "sticky" which has
the effect where you might move a slider and it puts the intersection
back to how it previously was (or returns to a previous intersection)