projects
/
rails.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
|
inline
| side by side
Mobile layout improvements
[rails.git]
/
app
/
views
/
site
/
_sidebar.html.erb
diff --git
a/app/views/site/_sidebar.html.erb
b/app/views/site/_sidebar.html.erb
index dd15ef7ba64b2e00ac17de7da3066d3a11c38f0f..3b1b547b62f1d97d6bd27b96fbfaaae4a3b38b66 100644
(file)
--- a/
app/views/site/_sidebar.html.erb
+++ b/
app/views/site/_sidebar.html.erb
@@
-1,8
+1,8
@@
<div id="sidebar">
<table class="sidebar_title" width="100%">
<tr>
<div id="sidebar">
<table class="sidebar_title" width="100%">
<tr>
- <td
align="left"
id="sidebar_title"><% t 'site.sidebar.search_results' %></td>
- <td
align="right
"><a href="javascript:closeSidebar()"><%= t 'site.sidebar.close' %></a></td>
+ <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 id="sidebar_content">
</tr>
</table>
<div id="sidebar_content">
@@
-21,10
+21,12
@@
onclose = null;
}
onclose = null;
}
- if (options.width) { $("sidebar").style.width = options.width; }
- else { $("sidebar").style.width = "30%"; }
+ if (options.title) { $("#sidebar_title").html(options.title); }
- $("sidebar").style.display = "block";
+ if (options.width) { $("#sidebar").width(options.width); }
+ else { $("#sidebar").width("30%"); }
+
+ $("#sidebar").css("display", "block");
<%= onopen %>
<%= onopen %>
@@
-32,7
+34,7
@@
}
function closeSidebar() {
}
function closeSidebar() {
- $("
sidebar").style.display = "none"
;
+ $("
#sidebar").css("display", "none")
;
<%= onclose %>
<%= onclose %>
@@
-43,13
+45,8
@@
}
function updateSidebar(title, content) {
}
function updateSidebar(title, content) {
- $("sidebar_title").innerHTML = title;
- $("sidebar_content").innerHTML = content;
- }
-
- function sidebarOpen(title) {
- return $("sidebar").style.display == "block" &&
- $("sidebar_title").innerHTML == title;
+ $("#sidebar_title").html(title);
+ $("#sidebar_content").html(content);
}
// -->
</script>
}
// -->
</script>