]> git.openstreetmap.org Git - rails.git/blobdiff - app/views/site/_sidebar.html.erb
Match the other sidebar better
[rails.git] / app / views / site / _sidebar.html.erb
index f7e7229c89432bcb9b0835965534b5c090b58e98..db5f44356c1292d4959268d9bec54b385a995b7e 100644 (file)
@@ -1,52 +1,8 @@
 <div id="sidebar">
-  <table class="sidebar_title" width="100%">
-    <tr>
-      <td id="sidebar_title"><% t 'site.sidebar.search_results' %></td>
-      <td id="sidebar_close"><a href="javascript:closeSidebar()"><%= t 'site.sidebar.close' %></a></td>
-    </tr>
-  </table>
+  <div class="sidebar_heading">
+    <h4 id="sidebar_title"><% t 'site.sidebar.search_results' %></h4>
+    <a class="sidebar_close" href="#"><%= t 'site.sidebar.close' %></a>
+  </div>
   <div id="sidebar_content">
   </div>
 </div>
-
-<script type="text/javascript">
-<!--
-  var onclose;
-
-  function openSidebar(options) {
-    options = options || {};
-
-    if (onclose) {
-       onclose();
-       onclose = null;
-    }
-
-    if (options.title) { $("sidebar_title").innerHTML = options.title; }
-
-    if (options.width) { $("sidebar").style.width = options.width; }
-    else { $("sidebar").style.width = "30%"; }
-
-    $("sidebar").style.display = "block";
-
-    <%= onopen %>
-
-    onclose = options.onclose;
-  }
-
-  function closeSidebar() {
-    $("sidebar").style.display = "none";
-
-    <%= onclose %>
-
-    if (onclose) {
-       onclose();
-       onclose = null;
-    }
-  }
-
-  function updateSidebar(title, content) {
-    $("sidebar_title").innerHTML = title;
-    $("sidebar_content").innerHTML = content;
-  }
-// -->
-</script>