River label sometimes flips upside down depending on zoom level
URL
https://www.openstreetmap.org/edit#map=17/39.925706/-82.056098
How to reproduce the issue?
- Open map at around this location, go into edit mode
- Zoom in and out one notch at a time via the mouse wheel. On some zooms, the label is upside down, and on some zooms, the label is right side up.
I don't know why this happens. As you can see in the video below it doesn't change position that much per zoom, it just flips upside down for an unknown reason. Where the label is the river isn't bent particularly awkwardly so I don't think it's the geometry of the river line causing it.
Screenshot(s) or anything else?
https://github.com/user-attachments/assets/00a603a4-fbfc-409f-b228-d149a1f5eabd
Which deployed environments do you see the issue in?
Released version at openstreetmap.org/edit
What version numbers does this issue effect?
2.34.1
Which browsers are you seeing this problem on?
Firefox
At counterclockwise turn, label will try to wrap around turn. Characters run into each other when trying to do so. For small subset of z=17, text will try to fully wrap around the turn, except since it is such small section, it falls back to displaying on the section it was previously displayed on, but this will cause it to display upside down.
For a turn where it can wrap either side, see https://www.openstreetmap.org/edit#map=18/39.938168/-82.018724
When zooming in, text can fully wrap around and it will display as usual again.
See also
- https://github.com/osm-americana/openstreetmap-americana/issues/600#issuecomment-1338731144
- https://github.com/osm-americana/openstreetmap-americana/issues/58#issuecomment-980817190
Related #9257