Permalink
Browse files

Quasi-dropdown menu

  • Loading branch information...
1 parent ae9020f commit e4a3028cff7ecce9f717c3c97147ad7dda550a87 @thedjpetersen committed Jun 14, 2011
Showing with 70 additions and 14 deletions.
  1. +48 −10 main/templates/application.html
  2. +0 −1 main/templates/scheduler/index.html
  3. +22 −3 site_media/stylesheets/application.css
View
58 main/templates/application.html
@@ -12,6 +12,19 @@
<link rel="stylesheet" type="text/css" href="/site_media/stylesheets/ie.css" />
<link rel="stylesheet" type="text/css" href="/site_media/stylesheets/sticky_footer.css" />
<link rel="stylesheet" type="text/css" href="/site_media/stylesheets/application.css" />
+ <script type="text/javascript" src="/site_media/javascripts/jquery-min.js" ></script>
+ <script>
+ $(document).ready(function(){
+ $("#navigation > ul > li").hover(
+ function(){
+ $(this).find("div").css("display", "block");
+ },
+ function(){
+ $(this).find("div").css("display", "none");
+ }
+ );
+ });
+ </script>
{% block header %}
{% endblock %}
</head>
@@ -27,18 +40,43 @@
<div class="span-20 last">
{% block navigation %}
- <div id="navigation" style="float: right;">
+ <div id="navigation" style="float: right">
{% ifnotequal no_show_nav 1 %}
- <a href="/main"><span>Home</span></a>
- <a href="/course"><span>Courses</span></a>
- <a href="/schedule"><span>Schedule</span></a>
- <a href="/scheduler"><span>Scheduler</span></a>
- <a href="/planner"><span>Planner</span></a>
- <a href="/transcript"><span>Transcript</span></a>
- <a href="/logout"><span>Logout</span></a>
+ <ul>
+ <li>
+ <span>Past</span>
+ <div>
+ <ul>
+ <li><a href="/transcript"><span>Transcript</span></a></li>
+ </ul>
+ </div>
+ </li>
+
+ <li>
+ <span>Present</span>
+ <div>
+ <ul>
+ <li><a href="/schedule"><span>Schedule</span></a></li>
+ <li><a href="/course"><span>Courses</span></a></li>
+ </ul>
+ </div>
+ </li>
+
+ <li>
+ <span>Future</span>
+ <div>
+ <ul>
+ <li><a href="/scheduler"><span>Scheduler</span></a></li>
+ <li><a href="/planner"><span>Planner</span></a></li>
+ </ul>
+ </div>
+ </li>
+
+ <li><a href="/logout"><span>Logout</span></a></li>
+ </ul>
{% endifnotequal %}
- </div>
- {% endblock %}
+ </div>
+ {% endblock %}
</div>
</div>
View
1 main/templates/scheduler/index.html
@@ -29,7 +29,6 @@
{% block header %}
<link rel="stylesheet" type="text/css" href="/site_media/stylesheets/make_schedule.css" />
- <script type="text/javascript" src="/site_media/javascripts/jquery-min.js" ></script>
<script>
combinations = {{json|safe}}
</script>
View
25 site_media/stylesheets/application.css
@@ -36,18 +36,37 @@
padding-bottom: 170px;
}
+#navigation ul{
+ list-style:none;
+}
+
+#navigation ul li{
+ display:inline;
+ list-style-type:none;
+}
+
+#navigation ul li div{
+ display:none;
+ position:absolute;
+}
+
+#navigation ul li div ul{
+ padding-left:0px;
+ margin-top:20px;
+}
+
#navigation a{
text-decoration: none;
- color:white;
}
-#navigation a span{
+#navigation span{
background: #06276F;
padding:8px;
border-radius:6px;
+ color:white;
margin-right: 4px;
}
-#navigation a span:hover{
+#navigation span:hover{
background:#6C8DD5;
}

0 comments on commit e4a3028

Please sign in to comment.