Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge branch 'design_prettification' of git://github.com/brianflanaga…

…n/heel into brianflanagan-design_prettification

Merge Brian's design in with the changes for templates.
  • Loading branch information...
commit 2b06116dbbeaf1e8d9c89ec9ca53e4231d3c09e5 2 parents 42c4d33 + bc2a57c
@copiousfreetime authored
View
115 data/css/error.css
@@ -1,38 +1,79 @@
-body { font-family: Verdana, Arial, Helvetica, sans-serif; background-color: #e0e0e0;}
-div.wrap {
- background: transparent;
- text-align: left;
- width: 400px;
- margin-top: 100px;
- margin-left: auto;
- margin-right: auto;
-}
-div.box {
- border-left: 1px solid #333;
- border-right: 1px solid #333;
- background: #FFF;
- display: block;
-}
-img { padding-right: 20px;}
-h1 { display: inline; font-weight: bold; }
-h2 { display: inline; font-weight: bold; padding-left: 25px;text-align: center;}
-div.header { font-size: x-large; }
-div.content { font-size: x-large; border: 0; padding: 10px 25px 10px 25px;}
-div.footer { text-align: right; width: 400px; }
+html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, font, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, center, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td {
+ margin: 0;
+ padding: 0;
+ font-size: 100%;
+ vertical-align: baseline;
+ border: 0;
+ outline: 0;
+ background: transparent;
+ -webkit-font-smoothing: optimizeLegibility; }
-.curved { background: transparent;}
-.curved .c1, .curved .c2, .curved .c3, .curved .c4 {
- display: block;
- overflow: hidden;
- height: 1px;
- font-size: 1px;
-}
-.curved .c2, .curved .c3, .curved .c4 {
- background: #fff;
- border-left: 1px solid #000;
- border-right: 1px solid #000;
-}
-.c1 { margin: 0 5px 0 5px; background: #000; }
-.c2 { margin: 0 3px 0 3px; border-left: 2px solid #000; border-right: 2px solid #000; }
-.c3 { margin: 0 2px 0 2px; }
-.c4 { margin: 0 1px 0 1px; }
+blockquote, q {
+ quotes: none; }
+
+:focus {
+ outline: 0; }
+
+table {
+ border-collapse: collapse;
+ border-spacing: 0; }
+
+ul, ol {
+ list-style: none; }
+
+cite {
+ font-style: normal; }
+
+* {
+ -moz-box-sizing: border-box;
+ -webkit-box-sizing: border-box;
+ -ms-box-sizing: border-box;
+ box-sizing: border-box;
+ *behavior: url(image-path("boxsizing.htc")); }
+
+body {
+ background: #e7c9ae;
+ color: #47423b;
+ font-family: "Open Sans", sans-serif;
+ font-size: 14px;
+ line-height: 19.6px;
+ padding: 14px; }
+ body a, body a:link, body a:visited {
+ color: #3b619b;
+ text-decoration: none; }
+ body a:hover, body a:link:hover, body a:visited:hover {
+ color: #4d79bc; }
+ body > [role='wrapper'] {
+ background: white;
+ -webkit-border-radius: 3px;
+ -moz-border-radius: 3px;
+ border-radius: 3px;
+ -webkit-box-shadow: 0 1px 5px rgba(0, 0, 0, 0.125);
+ -moz-box-shadow: 0 1px 5px rgba(0, 0, 0, 0.125);
+ box-shadow: 0 1px 5px rgba(0, 0, 0, 0.125);
+ width: 100%;
+ max-width: 360px;
+ margin: 0 auto; }
+ body > [role='wrapper'] > header, body > [role='wrapper'] > footer {
+ padding: 7px; }
+ body > [role='wrapper'] > header {
+ background: #df5256;
+ color: white;
+ -webkit-border-top-left-radius: 3px;
+ -webkit-border-top-right-radius: 3px;
+ -moz-border-radius-topleft: 3px;
+ -moz-border-radius-topright: 3px;
+ border-top-left-radius: 3px;
+ border-top-right-radius: 3px; }
+ body > [role='wrapper'] > footer p {
+ font-size: 11.2px;
+ line-height: 14.56px;
+ text-align: right; }
+ body > [role='wrapper'] > [role='content'] {
+ background: #f9f9f9;
+ -webkit-box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.1);
+ -moz-box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.1);
+ box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.1); }
+ body > [role='wrapper'] > [role='content'] > [role='message'] {
+ padding: 28px 14px;
+ text-align: center; }
View
77 data/css/index.css
@@ -0,0 +1,77 @@
+html, body, div, span, applet, object, iframe, h1, h2, h3, h4, h5, h6, p, blockquote, pre, a, abbr, acronym, address, big, cite, code, del, dfn, em, font, img, ins, kbd, q, s, samp, small, strike, strong, sub, sup, tt, var, b, u, i, center, dl, dt, dd, ol, ul, li, fieldset, form, label, legend, table, caption, tbody, tfoot, thead, tr, th, td {
+ margin: 0;
+ padding: 0;
+ font-size: 100%;
+ vertical-align: baseline;
+ border: 0;
+ outline: 0;
+ background: transparent;
+ -webkit-font-smoothing: optimizeLegibility; }
+
+blockquote, q {
+ quotes: none; }
+
+:focus {
+ outline: 0; }
+
+table {
+ border-collapse: collapse;
+ border-spacing: 0; }
+
+ul, ol {
+ list-style: none; }
+
+cite {
+ font-style: normal; }
+
+* {
+ -moz-box-sizing: border-box;
+ -webkit-box-sizing: border-box;
+ -ms-box-sizing: border-box;
+ box-sizing: border-box;
+ *behavior: url(image-path("boxsizing.htc")); }
+
+body {
+ background: #e7c9ae;
+ color: #47423b;
+ font-family: "Open Sans", sans-serif;
+ font-size: 14px;
+ line-height: 19.6px;
+ padding: 14px; }
+ body a, body a:link, body a:visited {
+ color: #3b619b;
+ text-decoration: none; }
+ body a:hover, body a:link:hover, body a:visited:hover {
+ color: #4d79bc; }
+ body > [role='wrapper'] {
+ background: white;
+ -webkit-border-radius: 3px;
+ -moz-border-radius: 3px;
+ border-radius: 3px;
+ -webkit-box-shadow: 0 1px 5px rgba(0, 0, 0, 0.125);
+ -moz-box-shadow: 0 1px 5px rgba(0, 0, 0, 0.125);
+ box-shadow: 0 1px 5px rgba(0, 0, 0, 0.125);
+ width: 100%;
+ max-width: 960px;
+ margin: 0 auto; }
+ body > [role='wrapper'] > header, body > [role='wrapper'] > footer {
+ padding: 7px; }
+ body > [role='wrapper'] > footer p {
+ font-size: 11.2px;
+ line-height: 14.56px;
+ text-align: right; }
+ body > [role='wrapper'] > [role='content'] {
+ background: #f9f9f9;
+ -webkit-box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.1);
+ -moz-box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.1);
+ box-shadow: inset 0 0 4px rgba(0, 0, 0, 0.1); }
+ body > [role='wrapper'] > [role='content'] > table {
+ width: 100%; }
+ body > [role='wrapper'] > [role='content'] > table thead {
+ border-bottom: 2px solid #f3f3f3; }
+ body > [role='wrapper'] > [role='content'] > table th, body > [role='wrapper'] > [role='content'] > table td {
+ text-align: left;
+ padding: 3.5px 7px;
+ color: #71695e; }
+ body > [role='wrapper'] > [role='content'] > table tr:nth-child(even) {
+ background: whitesmoke; }
View
29 data/css/listing.css
@@ -1,29 +0,0 @@
-a, a:active { text-decoration: none; color: blue;}
-a:visited { color: purple;}
-a:hover, a:focus { text-decoration: underline; color: red;}
-body { font-family: Verdana, Arial, Helvetica, sans-serif; background-color: #eee; }
-.c { text-align: center; }
-table { border-collapse: collapse; border-spacing: 0px; width: 100%;}
-tr { background-color: #ccf;}
-tr:hover { background-color: #faa;}
-td, th {
- border-bottom: 1px solid #ccc;
- padding: 0em .3em 0em .3em ;
- color: #666;
- text-align: left;
- vertical-align: middle;
-}
-thead th {
- border-top: 2px solid #666;
- border-bottom: 2px solid #666;
- font-weight: bold;
- background: #aaa;
- color: #fff;
- text-transform: uppercase;
-}
-tr.odd { background-color: #cfc; color: #333;}
-tr.odd:hover { background-color: #faa; color: #333;}
-td.n { text-align: right; padding-right: 2em;}
-div.header { }
-div.content { background: #FFF; width: 100%;}
-div.footer { border-top: 2px solid #333; text-align: right;}
View
38 data/error.rhtml
@@ -1,29 +1,27 @@
<!DOCTYPE html>
<html lang="en">
<head>
- <title>Error <%= status %> </title>
- <meta charset="utf-8">
- <link rel="stylesheet" href="/heel_css/error.css" type="text/css" />
+ <title>Error <%= status %></title>
+ <meta charset='utf-8'>
+ <link href='/heel_css/error.css' rel='stylesheet' type='text/css'>
+ <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700' rel='stylesheet' type='text/css'>
+ <!--[if IE]>
+ <script src='//html5shiv.googlecode.com/svn/trunk/html5.js'></script>
+ <![endif]-->
</head>
<body>
- <div class="wrap">
- <div class="header">
- Requested URL: <%= base_uri %>
- </div>
- <div class="curved">
- <b class="c1"></b><b class="c2"></b><b class="c3"></b><b class="c4"></b>
- <div class="box">
- <div class="content">
- <img src="/heel_icons/error.png" alt=""/><h1>Error <%= status %></h1>
- <br />
- <h2><%= message %></h2>
- </div>
- </div>
- <b class="c4"></b><b class="c3"></b><b class="c2"></b><b class="c1"></b>
- </div>
- <div class="footer">
- <a href="<%= homepage %>">heel</a>/v<%= ::Heel::VERSION %>
+ <div role='wrapper'>
+ <header>
+ <h1>Requested URL: <%= base_uri %></h1>
+ </header>
+ <div role='content'>
+ <article role='message'><p><%= message %></p></article>
</div>
+ <footer>
+ <p>
+ <a href="http://github.com/copiousfreetime/heel/">heel</a> v<%= Heel::VERSION %>
+ </p>
+ </footer>
</div>
</body>
</html>
View
82 data/listing.rhtml
@@ -1,42 +1,56 @@
<!DOCTYPE html>
-<html lang="en">
+<html lang='en'>
<head>
<title>Index of <%= base_uri %></title>
- <meta charset="utf-8">
- <link rel="stylesheet" href="/heel_css/listing.css" type="text/css" />
+ <meta charset='utf-8'>
+ <link href='/heel_css/index.css' rel='stylesheet' type='text/css'>
+ <link href='http://fonts.googleapis.com/css?family=Open+Sans:400,700' rel='stylesheet' type='text/css'>
+ <!--[if IE]>
+ <script src='//html5shiv.googlecode.com/svn/trunk/html5.js'></script>
+ <![endif]-->
</head>
<body>
- <div class="header">
- <h1>Index of <%= base_uri %></h1>
- </div>
- <div class="content">
- <table>
- <caption>Directory Listing</caption>
- <thead>
- <tr><th class="n">File Name</th><th class="l" >Last Modified Timestamp</th><th class="m">File Size</th><th class="t">File Type</th></tr>
- </thead>
- <tbody>
- <% entries.each_with_index do |entry,i| %>
- <tr<%= i % 2 > 0 ? ' class="odd" ' : '' %>>
- <td>
- <% if entry.icon_url then %>
- <img src="<%= entry.icon_url %>" width="16" height="16" alt="icon for type <%= entry.content_type %>" />
- <% end %>
- <a href="<%= "#{base_uri.chomp('/')}/#{entry.link}" %>"><%= entry.name %></a>
- <% if highlighting? and entry.content_type != 'Directory' then %>
- (<a href="<%= "#{base_uri.chomp('/')}/#{entry.link}?highlighting=false" %>">download</a>)
- <% end %>
- </td>
- <td><%= entry.last_modified %></td>
- <td class="<%= entry.content_type == "Directory" ? 'c' : 'n' %>" ><%= entry.size %></td>
- <td><%= entry.content_type %></td>
- </tr>
- <% end %>
- </tbody>
- </table>
- </div>
- <div class="footer">
- <a href="<%= homepage %>">heel</a>/v<%= Heel::VERSION %>
+ <div role='wrapper'>
+ <header>
+ <h1>Index of <%= base_uri %></h1>
+ </header>
+ <div role='content'>
+ <table>
+ <thead>
+ <tr>
+ <th>Name</th>
+ <th>Last Modified</th>
+ <th>Size</th>
+ <th>Type</th>
+ </tr>
+ </thead>
+ <tbody>
+ <% entries.each do |entry| %>
+ <tr>
+ <td>
+ <a href="<%= "#{base_uri.chomp('/')}/#{entry.link}" %>">
+ <% if entry.icon_url then %>
+ <img src="<%= entry.icon_url %>" width="16" height="16" alt="icon for type <%= entry.content_type %>" />
+ <% end %>
+ <%= entry.name %>
+ </a>
+ <% if highlighting? and entry.content_type != 'Directory' then %>
+ (<a href="<%= "#{base_uri.chomp('/')}/#{entry.link}?highlighting=false" %>">download</a>)
+ <% end %>
+ </td>
+ <td><%= entry.last_modified %></td>
+ <td class="<%= entry.content_type == "Directory" ? 'c' : 'n' %>" ><%= entry.size %></td>
+ <td><%= entry.content_type %></td>
+ </tr>
+ <% end %>
+ </tbody>
+ </table>
+ </div>
+ <footer>
+ <p>
+ <a href="<%= homepage %>">heel</a> v<%= Heel::VERSION %>
+ </p>
+ </footer>
</div>
</body>
</html>
View
1  lib/heel/error_response.rb
@@ -35,6 +35,7 @@ def initialize(base_uri, body, status = 404, header = {})
def finish
template_vars = TemplateVars.new( :status => @response.status,
:message => Rack::Utils::HTTP_STATUS_CODES[@response.status],
+ :base_uri => base_uri,
:homepage => ErrorResponse.homepage )
content = ErrorResponse.template.result( template_vars.binding_for_template )
View
2  tasks/default.rake
@@ -115,7 +115,7 @@ else
end
#------------------------------------------------------------------------------
-# Manifest - We want an explicit list of thos files that are to be packaged in
+# Manifest - We want an explicit list of those files that are to be packaged in
# the gem. Most of this is from Hoe.
#------------------------------------------------------------------------------
namespace 'manifest' do
Please sign in to comment.
Something went wrong with that request. Please try again.