natcap / global-web-viewer

A web viewer prototype for visualizing and analyzing global data.
GNU General Public License v3.0
3 stars 1 forks source link

Fix geocoder highlighting bug #86

Closed dcdenu4 closed 3 years ago

dcdenu4 commented 3 years ago

Add a callback to the fitbounds function that subscribes to a 'moveend' event so that after the animation move has occurred we then update the highlighting.

Also using the bounding box for searching to get more returned features, and then looking to match the geocoded result name to the feature name to properly highlight. This was an initial fix to the problem that might not be necessary anymore. We could probably go back to using the center location of the geocoding result to get the proper feature to highlight.

63