Fossil SCM
Updated the header menu to be consistent with the other skins.
Commit
741ccc956e5a33d74e61e04515ba7c1a61b66c37
Parent
72518c1239131bd…
1 file changed
+28
-20
+28
-20
| --- skins/xekri/header.txt | ||
| +++ skins/xekri/header.txt | ||
| @@ -101,34 +101,42 @@ | ||
| 101 | 101 | } |
| 102 | 102 | updateClock(); |
| 103 | 103 | </script> |
| 104 | 104 | <div class="mainmenu"> |
| 105 | 105 | <th1> |
| 106 | -html "<a href='$home$index_page'>Home</a>\n" | |
| 107 | -html "<a href='$home/help'>Help</a>\n" | |
| 106 | +proc menulink {url name} { | |
| 107 | + upvar current_page current | |
| 108 | + upvar home home | |
| 109 | + if {[string range $url 0 [string length $current]] eq "/$current"} { | |
| 110 | + html "<a href='$home$url' class='active'>$name</a>\n" | |
| 111 | + } else { | |
| 112 | + html "<a href='$home$url'>$name</a>\n" | |
| 113 | + } | |
| 114 | +} | |
| 115 | +menulink $index_page Home | |
| 108 | 116 | if {[anycap jor]} { |
| 109 | - html "<a href='$home/timeline'>Timeline</a>\n" | |
| 110 | -} | |
| 111 | -if {[anoncap oh]} { | |
| 112 | - html "<a href='$home/tree?ci=tip'>Files</a>\n" | |
| 113 | -} | |
| 114 | -if {[anoncap o]} { | |
| 115 | - html "<a href='$home/brlist'>Branches</a>\n" | |
| 116 | - html "<a href='$home/taglist'>Tags</a>\n" | |
| 117 | -} | |
| 118 | -if {[anoncap r]} { | |
| 119 | - html "<a href='$home/ticket'>Tickets</a>\n" | |
| 120 | -} | |
| 121 | -if {[anoncap j]} { | |
| 122 | - html "<a href='$home/wiki'>Wiki</a>\n" | |
| 117 | + menulink /timeline Timeline | |
| 118 | +} | |
| 119 | +if {[hascap oh]} { | |
| 120 | + menulink /dir?ci=tip Files | |
| 121 | +} | |
| 122 | +if {[hascap o]} { | |
| 123 | + menulink /brlist Branches | |
| 124 | + menulink /taglist Tags | |
| 125 | +} | |
| 126 | +if {[hascap r]} { | |
| 127 | + menulink /ticket Tickets | |
| 128 | +} | |
| 129 | +if {[hascap j]} { | |
| 130 | + menulink /wiki Wiki | |
| 123 | 131 | } |
| 124 | 132 | if {[hascap s]} { |
| 125 | - html "<a href='$home/setup'>Admin</a>\n" | |
| 133 | + menulink /setup Admin | |
| 126 | 134 | } elseif {[hascap a]} { |
| 127 | - html "<a href='$home/setup_ulist'>Users</a>\n" | |
| 135 | + menulink /setup_ulist Users | |
| 128 | 136 | } |
| 129 | 137 | if {[info exists login]} { |
| 130 | - html "<a href='$home/login'>Logout</a>\n" | |
| 138 | + menulink /login Logout | |
| 131 | 139 | } else { |
| 132 | - html "<a href='$home/login'>Login</a>\n" | |
| 140 | + menulink /login Login | |
| 133 | 141 | } |
| 134 | 142 | </th1></div> |
| 135 | 143 |
| --- skins/xekri/header.txt | |
| +++ skins/xekri/header.txt | |
| @@ -101,34 +101,42 @@ | |
| 101 | } |
| 102 | updateClock(); |
| 103 | </script> |
| 104 | <div class="mainmenu"> |
| 105 | <th1> |
| 106 | html "<a href='$home$index_page'>Home</a>\n" |
| 107 | html "<a href='$home/help'>Help</a>\n" |
| 108 | if {[anycap jor]} { |
| 109 | html "<a href='$home/timeline'>Timeline</a>\n" |
| 110 | } |
| 111 | if {[anoncap oh]} { |
| 112 | html "<a href='$home/tree?ci=tip'>Files</a>\n" |
| 113 | } |
| 114 | if {[anoncap o]} { |
| 115 | html "<a href='$home/brlist'>Branches</a>\n" |
| 116 | html "<a href='$home/taglist'>Tags</a>\n" |
| 117 | } |
| 118 | if {[anoncap r]} { |
| 119 | html "<a href='$home/ticket'>Tickets</a>\n" |
| 120 | } |
| 121 | if {[anoncap j]} { |
| 122 | html "<a href='$home/wiki'>Wiki</a>\n" |
| 123 | } |
| 124 | if {[hascap s]} { |
| 125 | html "<a href='$home/setup'>Admin</a>\n" |
| 126 | } elseif {[hascap a]} { |
| 127 | html "<a href='$home/setup_ulist'>Users</a>\n" |
| 128 | } |
| 129 | if {[info exists login]} { |
| 130 | html "<a href='$home/login'>Logout</a>\n" |
| 131 | } else { |
| 132 | html "<a href='$home/login'>Login</a>\n" |
| 133 | } |
| 134 | </th1></div> |
| 135 |
| --- skins/xekri/header.txt | |
| +++ skins/xekri/header.txt | |
| @@ -101,34 +101,42 @@ | |
| 101 | } |
| 102 | updateClock(); |
| 103 | </script> |
| 104 | <div class="mainmenu"> |
| 105 | <th1> |
| 106 | proc menulink {url name} { |
| 107 | upvar current_page current |
| 108 | upvar home home |
| 109 | if {[string range $url 0 [string length $current]] eq "/$current"} { |
| 110 | html "<a href='$home$url' class='active'>$name</a>\n" |
| 111 | } else { |
| 112 | html "<a href='$home$url'>$name</a>\n" |
| 113 | } |
| 114 | } |
| 115 | menulink $index_page Home |
| 116 | if {[anycap jor]} { |
| 117 | menulink /timeline Timeline |
| 118 | } |
| 119 | if {[hascap oh]} { |
| 120 | menulink /dir?ci=tip Files |
| 121 | } |
| 122 | if {[hascap o]} { |
| 123 | menulink /brlist Branches |
| 124 | menulink /taglist Tags |
| 125 | } |
| 126 | if {[hascap r]} { |
| 127 | menulink /ticket Tickets |
| 128 | } |
| 129 | if {[hascap j]} { |
| 130 | menulink /wiki Wiki |
| 131 | } |
| 132 | if {[hascap s]} { |
| 133 | menulink /setup Admin |
| 134 | } elseif {[hascap a]} { |
| 135 | menulink /setup_ulist Users |
| 136 | } |
| 137 | if {[info exists login]} { |
| 138 | menulink /login Logout |
| 139 | } else { |
| 140 | menulink /login Login |
| 141 | } |
| 142 | </th1></div> |
| 143 |