a-b-street / osm2lanes

A common library and set of test cases for transforming OSM tags to lane specifications
https://a-b-street.github.io/osm2lanes/
Apache License 2.0
34 stars 2 forks source link

Flesh out the JS editor app a bit more #246

Closed dabreegster closed 2 years ago

dabreegster commented 2 years ago

It's been a few weeks since I made these changes and I honestly forgot everything I did, but looking back, each commit is fairly well contained. The end result adds a few new features to the editor:

https://user-images.githubusercontent.com/1664407/185790674-3453fc42-7c6b-4c51-88d0-dac3da565ca7.mp4

There's plenty of JS style that could be improved; I've been learning more over in osm2streets. I'll clean up any bad patterns here later on

github-actions[bot] commented 2 years ago

Benchmark for 90dddf0

Click to view benchmark | Test | Base | PR | % | |------|--------------|------------------|---| | tests/224637155 | 6.6±0.04µs | **5.8±0.21µs** | **-12.12%** | | tests/380103730 Japanese Expressway | 7.8±0.32µs | 7.6±0.25µs | -2.56% | | tests/389654080 | 10.8±0.01µs | **9.6±0.28µs** | **-11.11%** | | tests/49207928 cycleway:BACKWARD=lane | 7.7±0.32µs | **7.4±0.18µs** | **-3.90%** | | tests/8591383 a bidirectional cycleway, oneway:bicycle | 8.9±0.07µs | **7.8±0.26µs** | **-12.36%** | | tests/bus:lanes=designated\| | 8.2±0.06µs | **7.2±0.20µs** | **-12.20%** | | tests/busway=lane | 7.4±0.06µs | **6.7±0.25µs** | **-9.46%** | | tests/cycleway=lane | 7.2±0.24µs | **6.8±0.20µs** | **-5.56%** | | tests/cycleway=opposite oneway=yes oneway:bicycle=no | 7.0±0.12µs | **6.5±0.23µs** | **-7.14%** | | tests/cycleway=opposite_track oneway=yes, deprecated | 8.3±0.08µs | **7.8±0.22µs** | **-6.02%** | | tests/sidewalk:right=yes | 6.6±0.19µs | **6.1±0.20µs** | **-7.58%** | | tests/sidewalk=both | 6.4±0.20µs | **6.1±0.16µs** | **-4.69%** |