23 Commits

Author SHA1 Message Date
Quincy Morgan
ba48a861bc Enable curly and block-spacing eslint rules 2020-11-10 14:19:11 -05:00
Quincy Morgan
d247ec3aed Enable brace-style eslint rule 2020-11-10 13:49:48 -05:00
Quincy Morgan
912151ff38 Allow viewing and editing the tags/relations of selected features at any zoom level in 2.x (re: #5001) 2019-12-12 16:54:16 -05:00
Quincy Morgan
d01bb78707 Reduce circular dependencies caused by importing from indexes, the location of the validation models, and the location of areaKeys (close #6237) 2019-04-24 13:45:59 -07:00
Bryan Housel
11bfeaabfc Add browser-polyfills, remove lodash assign, compact, values
(re: #6087)
2019-03-22 17:14:41 -04:00
Bryan Housel
3bc841e95b Adjust layer ordering to draw touch targets above data layers 2018-11-09 21:48:45 -05:00
Bryan Housel
6881205d43 All touch targets are GeoJSON now
This makes the code a bit more consistent and lets us avoid some
hacky and probably non-performant things:
- abusing CSS classes in the draw/drag datum functions (classed `.target`)
  (is this thing target? just check d.properties)
- regexing the id for `-nope$`
  (is this thing a nope target? just check d.properties)
- using context.hasEntity to get a the real entity
  (is this thing a real osmEntity? just check d.properties)
- fixes code like the restriction editor which uses fake ids for split ways
2018-01-01 22:37:10 -05:00
Bryan Housel
96afbbd785 Refactor vector math functions from geo.js to vector.js 2017-12-28 01:08:11 -05:00
Bryan Housel
eafc2b4300 Adjust touch target radii 2017-12-18 17:00:47 -05:00
Bryan Housel
aa68b21d7a Add touch targets for line/area 2017-12-17 22:53:58 -05:00
Bryan Housel
5cb5456869 Implement touch targets for midpoints and points 2017-12-15 22:50:55 -05:00
Bryan Housel
b9e48d1682 WIP: Move layer-hit to layer-points with explict sublayers, update tests
This is more work to further isolate the layers that entities draw to.
It makes it easier to debug what is going on, and can eventually lead to
deferred drawing, if each draw function is in its own place and not dependant
on anything else.

I've started to replace the vertex-hover with an explicit layer for touch
targets.

Also had to change a lot of the svg tests, which are really brittle.
Things would happen like - the surface would be created, it would kick of a
deferred redraw, which would notice that the zoom was 0 and call
editOff, which would remove the osm layers that were just created and
that the tests were trying to draw to. These tests need proper zoom and
projection otherwise nothing works.
2017-12-14 17:38:43 -05:00
Bryan Housel
9edae82673 Convert lodah-es and d3 to named imports for svg 2017-09-25 23:16:24 -04:00
Bryan Housel
5ca4246a6d If drawing a way, don't hover on a node that was just placed
(closes #3974)
2017-04-26 13:33:21 -04:00
Bryan Housel
8520e06c5a Performance: only draw midpoints in select mode 2017-04-26 10:27:38 -04:00
Bryan Housel
0d0e54fdff Fix more namespaces that were missed in the first pass 2016-10-04 21:15:30 -04:00
Bryan Housel
3102a4ae6a Rename all the things to include pseudonamespaces 2016-10-04 19:06:20 -04:00
Bryan Housel
273407da3d Fix svg layer selections, fix and add tests.. 2016-09-09 14:19:13 -04:00
Bryan Housel
afb88f2ae6 Fix rendering selections for all the OSM layers
This includes some renames for clarity.. "surface" -> "selection"
to make it clearer that rendering functions take a selection, and
don't necessarily render to the literal `#surface` node anymore.
2016-09-08 22:37:06 -04:00
Tom MacWright
20962074ba Fix vertices areas midlines 2016-09-06 10:58:07 -04:00
Tom MacWright
604d1e2719 import lodash (#3257) 2016-07-19 12:04:16 -04:00
Kushan Joshi
b3492b17a0 external modules for SVG 2016-07-06 14:39:14 -04:00
Beau Gunderson
fb838645ae refactor svg into ES6 modules for #3118 2016-06-16 11:58:23 -07:00