The umap.js old papa js style is now moved to modules, and split in two, as we did for layers and features: one module is for the data part, and the other is for the rendering part, and this one inherits from Leaflet.
Sadly, the split between those two modules is not as clear as I'd like it to be, as some functions my be interpreted or not as rendering.
What is now moved to the rendering module is all elements that inherit from Leaflet, so what concerns the map itself, but also controls in of the Leaflet world (inheriting from L.Control). In the other hand, UI elements that does not inherit from Leaflet are kept on the umap.js module (panels, tooltip, contextmenu…).
Also, Umap as a properties key, to follow geojson spec, and distinguish from LeafletMap.options.
This is a first step, that will need more work, but as tests pass, I'd suggest to merge if we agree on the choices and continue working with other (smaller) PRs (and I'll take care of rebasing current other PRs).
Some specific points I've in mind that does not smell good:
umap.js module still uses some Leaflet utils
Umap and LeafletMap have a reference to each other
umap.js module still need Leaflet events
layers and feature still need to have reference to both Umap and LeafletMap
Long awaited step! Very intrusive change!
The
umap.js
old papa js style is now moved to modules, and split in two, as we did for layers and features: one module is for the data part, and the other is for the rendering part, and this one inherits from Leaflet.Sadly, the split between those two modules is not as clear as I'd like it to be, as some functions my be interpreted or not as rendering.
What is now moved to the rendering module is all elements that inherit from Leaflet, so what concerns the map itself, but also controls in of the Leaflet world (inheriting from L.Control). In the other hand, UI elements that does not inherit from Leaflet are kept on the
umap.js
module (panels, tooltip, contextmenu…).Also,
Umap
as aproperties
key, to follow geojson spec, and distinguish fromLeafletMap.options
.This is a first step, that will need more work, but as tests pass, I'd suggest to merge if we agree on the choices and continue working with other (smaller) PRs (and I'll take care of rebasing current other PRs).
Some specific points I've in mind that does not smell good: