ec24-tips / ec24-tips.github.io

Local tips for Eurocrypt 2024
https://ec24-tips.github.io/
0 stars 4 forks source link

Make polylines easier to touch/click #7

Open defeo opened 2 months ago

defeo commented 2 months ago

With the current stroke: 6 value, the polylines used to represent hikes and walks are difficult to mouse-click and very annoying to touch. One of the few available solution seems to be to lay a larger transparent polyline on top of the original one and make it react to clicks instead. See https://stackoverflow.com/questions/30633416/make-svgpath-easily-clickable. However Leaflet's .geoJSON interface makes this extremely clumsy, because there is no way to override the class associated to polylines.