Changeset 88
- Timestamp:
- 04/05/07 01:39:51 (3 years ago)
- Location:
- veekun/branches/layout
- Files:
-
- 11 added
- 3 modified
-
lib/Vee/Controller/Style.pm (modified) (1 diff)
-
root/images/bg-fade.png (added)
-
root/images/bg.png (added)
-
root/images/h1-ground.png (added)
-
root/images/h2-ground.png (added)
-
root/images/h3-ground.png (added)
-
root/images/hr.png (added)
-
root/images/pawprint.png (added)
-
root/images/pokedex-fade.png (added)
-
root/images/youarehere.png (added)
-
templates/style (added)
-
templates/style/global.tt (added)
-
templates/wrapper.tt (modified) (6 diffs)
-
vee.yml (modified) (1 diff)
Legend:
- Unmodified
- Added
- Removed
-
veekun/branches/layout/lib/Vee/Controller/Style.pm
r87 r88 29 29 30 30 $c->stash->{template} = 'style/' . $filename . '.tt'; 31 $c->stash->{skip_wrapper} = 1; 31 32 $c->res->content_type('text/css'); 32 33 } -
veekun/branches/layout/templates/wrapper.tt
r70 r88 1 [% UNLESS skip_wrapper %] 1 2 [% DEFAULT link_name = template.link_name %] 2 3 [% DEFAULT link_name = '' %] … … 12 13 <title>[% page_title %] - [% c.site_opts.site_title %]</title> 13 14 <link rel="shortcut icon" type="image/png" href="/images/favicon.png"/> 14 <link rel="stylesheet" type="text/css" href="/style/midnight.css"/>15 <link rel="search" type="application/opensearchdescription+xml" title="Veekun Pokédex" href="/files/mozsearch.pokedex.xml"/>16 15 [% IF extra_css %] 17 16 [% FOREACH css IN extra_css %] 18 <link rel="stylesheet" type="text/css" href="/style/[% css %] .css"/>17 <link rel="stylesheet" type="text/css" href="/style/[% css %]"/> 19 18 [% END %] 20 19 [% END %] 21 20 [% extra_headers.join("\n") %] 21 <link rel="stylesheet" type="text/css" href="/style/global"/> 22 <link rel="search" type="application/opensearchdescription+xml" title="Veekun Pokédex" href="/files/mozsearch.pokedex.xml"/> 22 23 <script type="text/javascript" src="/script/jquery.js"></script> 23 24 <script type="text/javascript" src="/script/dexsuggest.js"></script> 24 25 </head> 25 26 <body> 27 <div id="header"> 28 <a href="/"><img src="/images/veehead.png" alt="[logo]" id="logo"/></a> 29 <div id="site-title">[% c.site_opts.site_title %]</div> 30 <div id="page-title">[% page_header %]</div> 31 <form action="/dex" method="get" id="dex-lookup" class="tinyform"> <p> 32 Pokédex lookup: <input type="text" name="entry"/> 33 </p> </form> 26 34 [% IF c.user %] 27 <div id="login"> Logged in as <a href="[% c.uri('Users', 'info', c.user.obj.id) %]">[% c.user.name %]</a>. <form action="[% c.uri('Users', 'logout') %]" method="POST" class="chibiform"><p><input type="submit" value="Logout"/></p></form> </div>35 <div id="login"> <form action="[% c.uri('Users', 'logout') %]" method="POST" class="tinyform"><p>Logged in as <a href="[% c.uri('Users', 'info', c.user.obj.id) %]">[% c.user.name %]</a>. <input type="submit" value="Logout"/></p></form> </div> 28 36 [% ELSE %] 29 <div id="login"> <a href="[% c.uri('Users', 'login') %]">Login</a> or <a href="[% c.uri('Users', 'register') %]">register</a> </div>37 <div id="login"> <a href="[% c.uri('Users', 'login') %]">Login</a> or <a href="[% c.uri('Users', 'register') %]">register</a> </div> 30 38 [% END %] 31 <div id="header">32 <a href="/"><img src="/images/veehead.png" alt="[logo]" id="logo"/></a>33 <div id="googleads">34 [% IF c.req.user_agent.match('MSIE (.+);') %]35 <script type="text/javascript"><!--36 google_ad_client = "pub-4065035407704486";37 google_ad_width = 120;38 google_ad_height = 60;39 google_ad_format = "120x60_as_rimg";40 google_cpa_choice = "CAAQn4Oy0QEaCKNo8-guCDanKI-293M";41 //--></script>42 <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>43 [% google_ad_width = 234 %]44 [% ELSE %]45 [% google_ad_width = 468 %]46 [% END %]47 <script type="text/javascript"><!--48 google_ad_client = "pub-4065035407704486";49 google_ad_width = [% google_ad_width %];50 google_ad_height = 60;51 google_ad_format = "[% google_ad_width %]x60_as";52 google_ad_type = "text_image";53 google_ad_channel ="";54 google_color_border = "07509B";55 google_color_bg = "AAC1D8";56 google_color_link = "07509B";57 google_color_url = "0066CC";58 google_color_text = "000000";59 //--></script>60 <script type="text/javascript" src="http://pagead2.googlesyndication.com/pagead/show_ads.js"></script>61 </div>62 <div id="site-title">[% c.site_opts.site_title %]</div>63 <div id="page-title">[% page_header %]</div>64 39 </div> 65 <form action="/dex" method="get" id="dexlookup"> <p>66 Pokédex lookup: <input type="text" name="entry"/>67 </p> </form>68 40 69 70 [% cur_link_category = link_name %] 71 [% IF (matches = cur_link_category.match('^(.+)/')); cur_link_category = matches.0; END %] 72 <ul id="linkbar"> 73 <!-- TODO: don't show a link at all if there are no sublinks you're allowed to see? --> 74 [% FOREACH link IN c.site_opts.link_list %] 75 [%# NEXT IF link.permission && !allowed(link.permission) %] 76 [%# IF link.category == cur_link_category; cur_link = link; END %] 77 [%# TODO: this is an ugly IF block; clean it up %] 78 <li[% IF link == cur_link %] class="link-selected"[% END %]> 79 [% IF link.url # && link.category != link_name %] 80 <a href="[% link.url %]">[% IF link.icon %]<img src="/images/icons/linklist/[% link.icon %]" alt=""/>[% END %][% link.text %]</a> 81 [% ELSE %] 82 <span>[% IF link.icon %]<img src="/images/icons/linklist/[% link.icon %]" alt=""/>[% END %][% link.text %]</span> 83 [% END %] 84 [% IF link != cur_link %] 85 [% ulopen = 0 %] 86 [% FOREACH sublink IN link.sublinks %] 87 [% NEXT IF sublink.permission && !allowed(sublink.permission) %] 88 [% IF !ulopen %] 89 <ul> 90 [% END %] 91 [% ulopen = 1 %] 92 <li><a href="[% sublink.url %]">[% IF sublink.icon %]<img src="/images/icons/linklist/[% sublink.icon %]" alt=""/>[% END %][% sublink.text %]</a></li> 93 [% END %] 94 [% IF ulopen %] 95 </ul> 96 [% END %] 97 [% END %] 98 </li> 99 [% END %] 100 </ul> 101 102 [% IF cur_link.keys.size %] 103 [% ulopen = 0 %] 104 [% IF cur_link.sublinks.size %] 105 [% FOREACH sublink IN cur_link.sublinks %] 106 [% NEXT IF sublink.permission && !allowed(sublink.permission) %] 107 [% IF !ulopen %] 108 <ul id="sublinks"> 109 [% END %] 110 <li><a href="[% sublink.url %]">[% IF sublink.icon %]<img src="/images/icons/linklist/[% sublink.icon %]" alt=""/>[% END %][% sublink.text %]</a></li> 111 [% ulopen = 1 %] 112 [% END %] 113 [% IF ulopen %] 114 </ul> 115 [% END %] 116 [% END %] 117 [% END %] 41 <div id="statusline"> 42 43 <!-- nothing yet! --> 44 </div> 118 45 119 46 [% IF 0 AND c.req.user_agent.match('MSIE (.+);') && matches.0 < 7 %] … … 136 63 [% END %] 137 64 138 <div id="body"> 65 <!-- It would be very nice to have this below the content in the source. --> 66 <!-- Low-priority TODO. --> 67 <div id="left"> 68 [% cur_link_category = link_name %] 69 [% IF (matches = cur_link_category.match('^(.+)/')); cur_link_category = matches.0; END %] 70 <ul id="linkbar"> 71 <!-- TODO: don't show a link at all if there are no sublinks you're allowed to see? --> 72 [% FOREACH link IN c.site_opts.link_list %] 73 [%# NEXT IF link.permission && !allowed(link.permission) %] 74 [%# IF link.category == cur_link_category; cur_link = link; END %] 75 [%# TODO: this is an ugly IF block; clean it up %] 76 <li[% IF link == cur_link %] class="link-selected"[% END %]> 77 [% IF link.url # && link.category != link_name %] 78 <a href="[% link.url %]">[% IF link.icon %]<img src="/images/icons/linklist/[% link.icon %]" alt=""/>[% END %][% link.text %]</a> 79 [% ELSE %] 80 <span>[% IF link.icon %]<img src="/images/icons/linklist/[% link.icon %]" alt=""/>[% END %][% link.text %]</span> 81 [% END %] 82 [% IF link != cur_link %] 83 [% ulopen = 0 %] 84 [% FOREACH sublink IN link.sublinks %] 85 [% NEXT IF sublink.permission && !allowed(sublink.permission) %] 86 [% IF !ulopen %] 87 <ul> 88 [% END %] 89 [% ulopen = 1 %] 90 <li><a href="[% sublink.url %]">[% IF sublink.icon %]<img src="/images/icons/linklist/[% sublink.icon %]" alt=""/>[% END %][% sublink.text %]</a></li> 91 [% END %] 92 [% IF ulopen %] 93 </ul> 94 [% END %] 95 [% END %] 96 </li> 97 [% END %] 98 </ul> 99 </div> 100 101 <div id="content"> 139 102 [% IF error %]<div class="error"><div class="error-header">Internal <code>[% error.type %]</code> error</div><div class="error-content">[% error.info %]</div></div>[% END %] 140 103 [% IF error_msg %]<div class="error"><div class="error-header">Error</div><div class="error-content">[% error_msg.join('<br/>') %]</div></div>[% END %] … … 142 105 [% IF success_msg %]<div class="success"><div class="success-header">Success!</div><div class="success-content">[% success_msg.join('<br/>') %]</div></div>[% END %] 143 106 [% IF crumbs %]<div class="breadcrumbs">You are here: [% crumbs.join(' :: ') %]</div>[% END %] 107 [% END # skip_wrapper %] 144 108 [% content %] 109 [% UNLESS skip_wrapper %] 145 110 </div> 111 146 112 [% IF c.debug AND querylog.count %] 147 113 <div id="debug"> … … 161 127 </div> 162 128 [% END %] 129 163 130 <div id="footer"> 164 131 <a href="http://www.catalystframework.org/" style="display: block; float: right;"><img src="/images/catalyst.png" alt="Powered by Catalyst"/></a> … … 178 145 </body> 179 146 </html> 147 [% END # skip_wrapper %] -
veekun/branches/layout/vee.yml
r25 r88 29 29 static: 30 30 dirs: 31 - style32 31 - images 33 32 - stuff
