Interactive interface for browsing global, full-resolution satellite imagery
disable running data when on data tab
Jason Kent3bd443b81282
diff --git a/web/js/map/ui.js b/web/js/map/ui.jsindex f0b8c1707..c0f6e08a6 100644--- a/web/js/map/ui.js+++ b/web/js/map/ui.js@@ -1073,28 +1073,22 @@ export default function mapui(models, config, store, ui) {function createMousePosSel(map, proj) {const throttledOnMouseMove = lodashThrottle((e) => {const state = store.getState();- const { browser } = state;+ const { browser, sidebar } = state;const isMobile = browser.lessThan.medium;if (self.mapIsbeingZoomed) return;if (compareMapUi && compareMapUi.dragging) return;- // if mobile returnif (isMobile) return;- // if measure is active returnif (state.measure.isActive) return;const pixels = map.getEventPixel(e);const coords = map.getCoordinateFromPixel(pixels);if (!coords) return;- // setting a limit on running-data retrieval- if (self.mapIsbeingDragged) {- return;- }+ if (self.mapIsbeingDragged) return;// Don't add data runners if we're on the events or smart handoffs tabs, or if map is animatingconst isEventsTabActive = typeof state.events !== 'undefined' && state.events.active;const isMapAnimating = state.animation.isPlaying;- // TODO handle smart handoffs- if (isEventsTabActive || isMapAnimating) return;+ if (isEventsTabActive || isMapAnimating || sidebar.activeTab === 'download') return;dataRunner.newPoint(pixels, map);}, 300);