aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorMatthew Somerville <matthew@mysociety.org>2016-03-09 12:47:37 +0000
committerMatthew Somerville <matthew@mysociety.org>2016-03-09 12:47:37 +0000
commitf23470ddccfdf1db6604c99c58a3803fd5ccab4c (patch)
tree7424915b2cf37c3766d78128a7da60af7d36caff
parent17072b3dc80a0cfe285692494768d652ef1d1f4e (diff)
Make sure top of reporting form is shown.
If the list of reports was scrolled and then the map was clicked, the form would be pre-scrolled down. It now makes sure to scroll the form to the top. Fixes #787.
-rw-r--r--web/js/map-OpenLayers.js1
1 files changed, 1 insertions, 0 deletions
diff --git a/web/js/map-OpenLayers.js b/web/js/map-OpenLayers.js
index f2666787a..cc4959b7b 100644
--- a/web/js/map-OpenLayers.js
+++ b/web/js/map-OpenLayers.js
@@ -46,6 +46,7 @@ function fixmystreet_update_pin(lonlat) {
if (!$('#side-form-error').is(':visible')) {
$('#side-form, #site-logo').show();
+ window.scrollTo(0, 0);
}
}