##// END OF EJS Templates
html fix
marcink -
r208:c674d994 default
parent child Browse files
Show More
@@ -1,121 +1,121
1 ## -*- coding: utf-8 -*-
1 ## -*- coding: utf-8 -*-
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
2 <!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd">
3 <html xmlns="http://www.w3.org/1999/xhtml" id="mainhtml">
3 <html xmlns="http://www.w3.org/1999/xhtml" id="mainhtml">
4 <head>
4 <head>
5 <link rel="icon" href="/images/hgicon.png" type="image/png" />
5 <link rel="icon" href="/images/hgicon.png" type="image/png" />
6 <meta name="robots" content="index, nofollow"/>
6 <meta name="robots" content="index, nofollow"/>
7 <title>${next.title()}</title>
7 <title>${next.title()}</title>
8 ##<link rel="stylesheet" href="/js/yui/reset-fonts-grids/reset-fonts-grids.css" type="text/css" />
8 ##<link rel="stylesheet" href="/js/yui/reset-fonts-grids/reset-fonts-grids.css" type="text/css" />
9 ${self.css()}
9 ${self.css()}
10 ${self.js()}
10 ${self.js()}
11 </head>
11 </head>
12
12
13 <body class="mainbody">
13 <body class="mainbody">
14 <div id="container">
14 <div id="container">
15 <div class="page-header">
15 <div class="page-header">
16 <h1>${next.breadcrumbs()}</h1>
16 <h1>${next.breadcrumbs()}</h1>
17 ${self.page_nav()}
17 ${self.page_nav()}
18 </div>
18 </div>
19 <div id="main">
19 <div id="main">
20 ${next.main()}
20 ${next.main()}
21 </div>
21 </div>
22 <div class="page-footer">
22 <div class="page-footer">
23 Hg App ${c.hg_app_version} &copy; 2010
23 Hg App ${c.hg_app_version} &copy; 2010
24 </div>
24 </div>
25
25
26 <div id="powered-by">
26 <div id="powered-by">
27 <p>
27 <p>
28 <a href="http://mercurial.selenic.com/" title="Mercurial">
28 <a href="http://mercurial.selenic.com/" title="Mercurial">
29 <img src="/images/hglogo.png" width="75" height="90" alt="mercurial"/></a>
29 <img src="/images/hglogo.png" width="75" height="90" alt="mercurial"/></a>
30 </p>
30 </p>
31 </div>
31 </div>
32
32
33 <div id="corner-top-left"></div>
33 <div id="corner-top-left"></div>
34 <div id="corner-top-right"></div>
34 <div id="corner-top-right"></div>
35 <div id="corner-bottom-left"></div>
35 <div id="corner-bottom-left"></div>
36 <div id="corner-bottom-right"></div>
36 <div id="corner-bottom-right"></div>
37
37
38 </div>
38 </div>
39 </body>
39 </body>
40 </html>
40 </html>
41
41
42 ### MAKO DEFS ###
42 ### MAKO DEFS ###
43
43
44 <%def name="page_nav()">
44 <%def name="page_nav()">
45 ${self.menu()}
45 ${self.menu()}
46 </%def>
46 </%def>
47
47
48 <%def name="menu(current)">
48 <%def name="menu(current)">
49 <%
49 <%
50 def is_current(selected):
50 def is_current(selected):
51 if selected == current:
51 if selected == current:
52 return 'class=current'
52 return "class='current'"
53 %>
53 %>
54 %if current not in ['home','admin']:
54 %if current not in ['home','admin']:
55 <script type="text/javascript">
55 <script type="text/javascript">
56 YAHOO.util.Event.onDOMReady(function(){
56 YAHOO.util.Event.onDOMReady(function(){
57 YAHOO.util.Event.addListener('repo_switcher','click',function(){
57 YAHOO.util.Event.addListener('repo_switcher','click',function(){
58 if(YAHOO.util.Dom.hasClass('repo_switcher','selected')){
58 if(YAHOO.util.Dom.hasClass('repo_switcher','selected')){
59 YAHOO.util.Dom.setStyle('switch_repos','display','none');
59 YAHOO.util.Dom.setStyle('switch_repos','display','none');
60 YAHOO.util.Dom.setStyle('repo_switcher','background','');
60 YAHOO.util.Dom.setStyle('repo_switcher','background','');
61 YAHOO.util.Dom.removeClass('repo_switcher','selected');
61 YAHOO.util.Dom.removeClass('repo_switcher','selected');
62 }
62 }
63 else{
63 else{
64 YAHOO.util.Dom.setStyle('switch_repos','display','');
64 YAHOO.util.Dom.setStyle('switch_repos','display','');
65 YAHOO.util.Dom.setStyle('repo_switcher','background','#FFFFFF');
65 YAHOO.util.Dom.setStyle('repo_switcher','background','#FFFFFF');
66 YAHOO.util.Dom.addClass('repo_switcher','selected');
66 YAHOO.util.Dom.addClass('repo_switcher','selected');
67 }
67 }
68 });
68 });
69 YAHOO.util.Event.addListener('repos_list','change',function(e){
69 YAHOO.util.Event.addListener('repos_list','change',function(e){
70 var wa = YAHOO.util.Dom.get('repos_list').value;
70 var wa = YAHOO.util.Dom.get('repos_list').value;
71
71
72 var url = "${h.url('summary_home',repo_name='__REPLACE__')}".replace('__REPLACE__',wa);
72 var url = "${h.url('summary_home',repo_name='__REPLACE__')}".replace('__REPLACE__',wa);
73 window.location = url;
73 window.location = url;
74 })
74 })
75 });
75 });
76 </script>
76 </script>
77 <ul class="page-nav">
77 <ul class="page-nav">
78 <li>
78 <li>
79 <a id="repo_switcher" title="${_('Switch repository')}" href="#">&darr;</a>
79 <a id="repo_switcher" title="${_('Switch repository')}" href="#">&darr;</a>
80 <div id="switch_repos" style="display:none;position: absolute;width: 150px;height: 25px">
80 <div id="switch_repos" style="display:none;position: absolute;width: 150px;height: 25px">
81 <select id="repos_list" size="=10">
81 <select id="repos_list" size="=10">
82 %for repo in c.cached_repo_list:
82 %for repo in c.cached_repo_list:
83 <option value="${repo['name']}">${repo['name']}</option>
83 <option value="${repo['name']}">${repo['name']}</option>
84 %endfor
84 %endfor
85 </select>
85 </select>
86 </div>
86 </div>
87 </li>
87 </li>
88 <li ${is_current('summary')}>${h.link_to(_('summary'),h.url('summary_home',repo_name=c.repo_name))}</li>
88 <li ${is_current('summary')}>${h.link_to(_('summary'),h.url('summary_home',repo_name=c.repo_name))}</li>
89 <li ${is_current('shortlog')}>${h.link_to(_('shortlog'),h.url('shortlog_home',repo_name=c.repo_name))}</li>
89 <li ${is_current('shortlog')}>${h.link_to(_('shortlog'),h.url('shortlog_home',repo_name=c.repo_name))}</li>
90 <li ${is_current('changelog')}>${h.link_to(_('changelog'),h.url('changelog_home',repo_name=c.repo_name))}</li>
90 <li ${is_current('changelog')}>${h.link_to(_('changelog'),h.url('changelog_home',repo_name=c.repo_name))}</li>
91 <li ${is_current('branches')}>${h.link_to(_('branches'),h.url('branches_home',repo_name=c.repo_name))}</li>
91 <li ${is_current('branches')}>${h.link_to(_('branches'),h.url('branches_home',repo_name=c.repo_name))}</li>
92 <li ${is_current('tags')}>${h.link_to(_('tags'),h.url('tags_home',repo_name=c.repo_name))}</li>
92 <li ${is_current('tags')}>${h.link_to(_('tags'),h.url('tags_home',repo_name=c.repo_name))}</li>
93 <li ${is_current('files')}>${h.link_to(_('files'),h.url('files_home',repo_name=c.repo_name))}</li>
93 <li ${is_current('files')}>${h.link_to(_('files'),h.url('files_home',repo_name=c.repo_name))}</li>
94 </ul>
94 </ul>
95 %else:
95 %else:
96 <ul class="page-nav">
96 <ul class="page-nav">
97 <li ${is_current('home')}>${h.link_to(_('Home'),h.url('/'))}</li>
97 <li ${is_current('home')}>${h.link_to(_('Home'),h.url('/'))}</li>
98 <li ${is_current('admin')}>${h.link_to(_('Admin'),h.url('admin_home'))}</li>
98 <li ${is_current('admin')}>${h.link_to(_('Admin'),h.url('admin_home'))}</li>
99 <li class="logout">${h.link_to(u'Logout',h.url('logout_home'))}</li>
99 <li class="logout">${h.link_to(u'Logout',h.url('logout_home'))}</li>
100 </ul>
100 </ul>
101 %endif
101 %endif
102 </%def>
102 </%def>
103
103
104 <%def name="css()">
104 <%def name="css()">
105 <link rel="stylesheet" href="/css/monoblue_custom.css" type="text/css" />
105 <link rel="stylesheet" href="/css/monoblue_custom.css" type="text/css" />
106 </%def>
106 </%def>
107
107
108 <%def name="js()">
108 <%def name="js()">
109 <script type="text/javascript" src="/js/yui/utilities/utilities.js"></script>
109 <script type="text/javascript" src="/js/yui/utilities/utilities.js"></script>
110 </%def>
110 </%def>
111
111
112 <!-- DEFINITION OF FORM ERROR FETCHER -->
112 <!-- DEFINITION OF FORM ERROR FETCHER -->
113 <%def name="get_form_error(element)">
113 <%def name="get_form_error(element)">
114 %if hasattr(c,'form_errors') and type(c.form_errors) == dict:
114 %if hasattr(c,'form_errors') and type(c.form_errors) == dict:
115 %if c.form_errors.get(element,False):
115 %if c.form_errors.get(element,False):
116 <span class="error-message">
116 <span class="error-message">
117 ${c.form_errors.get(element,'')}
117 ${c.form_errors.get(element,'')}
118 </span>
118 </span>
119 %endif
119 %endif
120 %endif
120 %endif
121 </%def> No newline at end of file
121 </%def>
General Comments 0
You need to be logged in to leave comments. Login now