I've converted the improveOSM errors to use this new generic QA error
structure which should allow for more general code to be used in
behaviour and UI.
Sidebar preview is currently broken, but will be fixed shortly.
Javascript is not my usual domain so still getting used to how scope
works and working with callbacks. Believe this code is now written as
intended.
As a bonus a response status to the error update request which isn't the
expected 200 now returns before visibly removing the error and adding it
to the closed cache.
Potential for multiple missing turn restrictions on one node and I've
also seen a case of missing one-way along the same stretch of road in
opposite directions!
Missing geometry is tile based so can't really be coincident, but
doesn't hurt to check in case they happen to land on a one-way or turn
restriction.
The direction of travel in the description was misleading as the way
segment wasn't necessary linear and so the direction could change as you
travel along the way. This is more explicit as it specifies the detected
start/end nodes (also useful to show that it's not the whole way that
might be one-way).
The position is now taken as the central node in the `feature.points`
list (or the average of the central two when there are an even number of
points).
This allows more diverse representation of the error subject at a glance
than relying on colour alone.
However, it would be good to have a generic error icon that can contain
icons which is differentiated from the point icon for clarity.
Sidebar header currently still uses the bolt icon until I figure out
how to deal with that. Also the font awesome icons don't seem to work,
perhaps there's additional code needed for those that I've missed.
This could result in error updates getting aborted when new errors are
loaded as their individual ids are never going to match tile IDs (see
`abortUnwantedRequests` function).
Root cause was the `select` mode removing the "selected" class from all
elements upon `exit()`. Easy fix is to use a different class (here
"currentView") for street imagery elements.
Fixes:
- Selecting a bubble then enabling a second imagery layer removes the hovered and selected highlighting
- If multiple imagery layers are enabled and you select a bubble it only temporarily becomes highlighted
- If multiple imagery layers are enabled and a bubble is highlighted, hovering over another imagery layer's bubble will remove the selected and hovered highlighting
Basically these all came down to style updates resetting all layers for
cases other than when the viewport was changed (where doing so makes
sense because the selected bubble/sequence needs to update as a result).
See #5494
(closes#5722, re: #5637, re: #5618)
dispatched with a value() string instead of a datum, which
causes issues for code expecting a datum always.
(such as localized.js brand picker or "Add Field" combo)
Fix for this coming in next commit.
This feature requires P31 property to be present
in the data item. For an example, see
https://wiki.openstreetmap.org/wiki/Item:Q104#P31
Once the bot populates them in the data items,
it will automatically work for all existing keys/tags.