X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/e83d43ca822a30b6074834233064613ea6478f88..824a474d933a3f5010717dd41097e65a25f8130c:/app/assets/javascripts/edit.js diff --git a/app/assets/javascripts/edit.js b/app/assets/javascripts/edit.js index f5ada1508..0b2b329b5 100644 --- a/app/assets/javascripts/edit.js +++ b/app/assets/javascripts/edit.js @@ -28,5 +28,16 @@ function minimiseMap() { handleResize(); } -$(document).ready(handleResize); -$(window).resize(handleResize); +$(document).ready(function () { + $(window).resize(handleResize); + handleResize(); + + $("#search_form").submit(function () { + $("#sidebar_title").html(I18n.t('site.sidebar.search_results')); + $("#sidebar_content").load($(this).attr("action"), { + query: $("#query").val() + }, openSidebar); + + return false; + }); +});