X-Git-Url: https://git.openstreetmap.org./rails.git/blobdiff_plain/d075fc4c1f3e7a17b4c71e7a06fd6cf318e0ef2f..3b43e4d53a736680bb41a14401244f3445d0c274:/app/views/site/_sidebar.html.erb?ds=inline diff --git a/app/views/site/_sidebar.html.erb b/app/views/site/_sidebar.html.erb index f7e7229c8..3b1b547b6 100644 --- a/app/views/site/_sidebar.html.erb +++ b/app/views/site/_sidebar.html.erb @@ -21,12 +21,12 @@ onclose = null; } - if (options.title) { $("sidebar_title").innerHTML = options.title; } + if (options.title) { $("#sidebar_title").html(options.title); } - if (options.width) { $("sidebar").style.width = options.width; } - else { $("sidebar").style.width = "30%"; } + if (options.width) { $("#sidebar").width(options.width); } + else { $("#sidebar").width("30%"); } - $("sidebar").style.display = "block"; + $("#sidebar").css("display", "block"); <%= onopen %> @@ -34,7 +34,7 @@ } function closeSidebar() { - $("sidebar").style.display = "none"; + $("#sidebar").css("display", "none"); <%= onclose %> @@ -45,8 +45,8 @@ } function updateSidebar(title, content) { - $("sidebar_title").innerHTML = title; - $("sidebar_content").innerHTML = content; + $("#sidebar_title").html(title); + $("#sidebar_content").html(content); } // -->