Feature: first version of clustering at low zoom levels, filters don't update yet (WIP)

This commit is contained in:
Pieter Vander Vennet 2025-07-21 12:57:04 +02:00
parent 4e033a93a5
commit 8360ab9a8b
11 changed files with 562 additions and 262 deletions

View file

@ -255,27 +255,4 @@ export class UserMapFeatureswitchState extends WithUserRelatedState {
}
)
}
/**
* Shows the current GPS-location marker on the given map.
* This is used to show the location on _other_ maps, e.g. on the map to add a new feature.
*
* This is _NOT_ to be used on the main map!
*/
public showCurrentLocationOn(map: Store<MlMap>) {
const id = "gps_location"
const layer = this.theme.getLayer(id)
if (layer === undefined) {
return
}
if (map === this.map) {
throw "Invalid use of showCurrentLocationOn"
}
const features = this.geolocation.currentUserLocation
return new ShowDataLayer(map, {
features,
layer,
metaTags: this.userRelatedState.preferencesAsTags,
})
}
}