Commits

Anonymous committed 52f72c3

TracMac: `mainnav` is ready (only the apple is missing ;o).

  • Participants
  • Parent commits aeded09

Comments (0)

Files changed (3)

+
+Outstanding tasks are :
+
+- Add icon for `more` item in metanav.
+- Add icon (apple) for active item in navs.
+- Change icon for `About Trac` item in metanav.
+

File tracmacos/htdocs/mac.css

 Trac custom stylesheet for Example theme 
 */
 
-#mainnav {
-  background: #FFFFCC none repeat scroll 0pt 0pt;
-}
-
 #tabs {
   background: #E0ECFF none repeat scroll 0% 0%;
 }
   font-weight: bold;
 }
 
-.nav :link, .nav :visited, .nav :hover {
+:link:hover, :visited:hover, .nav li:hover, 
+.nav li:hover :link, .nav li:hover :visited {
+  background-color: #3366ff;
+  color: white;
+}
+
+:visited {
+  background-color: #FFFFCC;
+}
+
+:visited, :link {
+  color: #0000cc;
+}
+
+.nav :link, .nav :visited {
   color: #000000;
   border: none;
-}
-
-:link:hover, :visited:hover, .nav li:hover {
-  background-color: #E0ECFF;
+  background-color: transparent;
 }
 
 .nav li {
   top: 15px;
 }
 
+/* Drop down menus */
+
+#mainmenu {
+  display: block;
+  padding: 0px;
+  position: absolute;
+  top: 5px;
+  z-index: 1;
+}
+
+#mainmenu:hover {
+  background-color: transparent;
+}
+
+#mainmenu:hover>ul.menu {
+  display: block;
+}
+
+#mainmenu>ul.menu {
+  display: none;
+}
+
+.menu, .menu ul {
+  border: none !important;
+  display: block;
+  list-style-type: none;
+  margin: 0px !important;
+  opacity: 0.95;
+  padding: 0 1px 1px 0;
+}
+
+.menu {
+  background: #999999 none repeat scroll 0pt 0pt;
+  z-index: 1;
+}
+
+.menu ul {
+  background: #EEEEEE none repeat scroll 0pt 0pt;
+}
+
+.menu li {
+  background: #EEEEEE none repeat scroll 0pt 0pt;
+  display: block;
+  text-align: left;
+  width: 100%;
+}
+
+#mainnav {
+  border: none;
+  margin: 0;
+}
+
+#mainnav :link, #mainnav :visited,
+#mainnav .active :link, #mainnav .active :visited {
+  background: none no-repeat scroll 0 0 transparent ;
+  border: medium none;
+}
+
+#mainnav .active :link, #mainnav .active :visited {
+  color: #000000;
+  font-weight: bold;
+}
+
+#mainnav li:hover :link, #mainnav li:hover :visited, 
+#mainnav .active :link:hover, #mainnav .active :visited:hover {
+  background-color: transparent;
+  border: none;
+  color: white;
+}
+
 /* Round boxes */
 
 .round1 {
 
 #mainbutton {
   background-color: #E1E1E1;
+  display: block; 
+  padding: 0px; 
+/*
   position: absolute;
   top:5px;
+*/
+  width: 34px;
 }
 
 #mainbutton:hover {
 /* Meta navigation */
 
 .more {
-  padding
+  height: auto;
 }
 
 #metanav>ul>li {

File tracmacos/templates/mac_theme.html

       xmlns:py="http://genshi.edgewall.org/"
       py:strip="">
 
-  <div py:def="navigation(category)" id="${category}" class="nav">
-    <ul py:if="chrome.nav[category]">
-      <li py:for="idx, item in  enumerate(chrome.nav[category])"
-          class="${classes(first_last(idx, chrome.nav[category]), active=item.active)}">${item.label}</li>
-    </ul>
-  </div>
+  <ul py:def="navigation(category)" class="menu">
+    <li id="${category}" class="nav">
+      <ul py:if="chrome.nav[category]">
+        <li py:for="idx, item in  enumerate(chrome.nav[category])"
+            class="${classes(first_last(idx, chrome.nav[category]), active=item.active)}">${item.label}</li>
+      </ul>
+    </li>
+  </ul>
 
   <py:match path="body" once="true" buffer="false"><body>
     <div id="mainpanel" class="nav">
-      <span id="mainbutton">
-        <div class="round4"></div>
-        <div class="round2"></div>
-        <div class="round1"></div>
-        <div class="box-inner"></div>
-        <div class="round1"></div>
-        <div class="round2"></div>
-        <div class="round4"></div>
+      <span> 
+        <ul style="padding: 0px;">
+          <li id="mainmenu"> 
+            <div id="mainbutton">
+              <div class="round4"></div>
+              <div class="round2"></div>
+              <div class="round1"></div>
+              <div class="box-inner"></div>
+              <div class="round1"></div>
+              <div class="round2"></div>
+              <div class="round4"></div>
+            </div>
+            ${navigation("mainnav")}
+          </li>
+        </ul>
       </span>
       <span id="navitem" class="active">
         <py:with vars="active = [item.label for item in chrome.nav.get('mainnav', []) if item.active]">
     <div id="outer-wrapper">
       <div id="content-wrapper">
 
-        ${navigation('mainnav')}
-
         <div id="main-wrapper">
           <!-- >
           <div id="ctxtnav" class="nav">