cleanup readme
[iankelling.org] / b.rb
diff --git a/b.rb b/b.rb
index b5e2aa9..391a0ed 100644 (file)
--- a/b.rb
+++ b/b.rb
@@ -75,15 +75,14 @@ EOF
   <head>
     <meta charset="utf-8">
     <title>#{title}</title>
-    <link rel="stylesheet" href="/main.css">
-    <link rel="stylesheet" href="/common.css">
+    <link rel="stylesheet" href="/css/main.css">
     <link rel="shortcut icon" href="/assets/favicon.png" />
     <meta name="description" content="#{o[:description] || DESCRIPTION}">
 #{o[:head]}
     <meta name="viewport" content="width=device-width, initial-scale=1">
   </head>
   <body>
-    <header>
+    <header class="page_header">
       <h3><a href="/">iankelling.org</a>#{o[:header]}</h3>
     </header>
     <div class="main-content-stripe">
@@ -91,12 +90,12 @@ EOF
         #{content}
       </div>
     </div>
-    <div id="comment-stripe">
+    <div class="comment-stripe">
 #{o[:comments]}
     </div>
     <footer>
 #{o[:footer]}
-      <p>This site has a <a href="/git/?p=iankelling.org;a=summary">git repo</a>. Unless stated otherwise, <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/"><img id="cc-by-sa" alt="Creative Commons License" src="/assets/cc-by-sa-4.0-80x15.png" /></a></p>
+      <p>This site has a <a href="/git/?p=iankelling.org;a=summary">git repo</a>. Unless stated otherwise, <a rel="license" href="http://creativecommons.org/licenses/by-sa/4.0/"><img class="cc-by-sa" alt="Creative Commons License" src="/assets/cc-by-sa-4.0-80x15.png" /></a></p>
       <p><address><a href="mailto:ian@iankelling.org">ian@iankelling.org</a> let me know what you think</address></p>
     </footer>
   </body>
@@ -126,15 +125,14 @@ EOF
   end
 
   def comment_html(comment, date)
-    inner = Redcarpet::Markdown.new(Redcarpet::Render::Safe, fenced_code_blocks: true).render(<<EOF)
-#{comment}
-<span class="comment-date">#{Time.at(date).strftime("%b %-d '%y")}</span>
-EOF
     # I tried putting the time,  %I:%M %p UTC, but it looks kinda
     # clunky, going against my simple theme.
+    user_input = Redcarpet::Markdown.new(Redcarpet::Render::Safe,
+                                   fenced_code_blocks: true).render(comment)
     <<EOF
 <div class="comment">
-  #{inner}
+  #{user_input}
+  <p class="comment-date">#{Time.at(date).strftime("%b %-d '%y")}</p>
 </div>
 EOF
   end
@@ -222,8 +220,8 @@ EOF
         comment_html("Note: there #{text} pending approval.", NOW)
     end
     com_section = <<-EOF
-      <form class="comment" action="/cgi/comment" method="post">
-        <input class="misc" type="text" name="url">
+      <form action="/cgi/comment" method="post">
+        <input class="misc-comment-input" type="text" name="url">
         <input name="goto" type="hidden" value="#{rel_path}">
         <textarea rows="10" name="comment" placeholder="markdown" maxlength="1000"></textarea>
         <input type="submit" value="Leave a comment">
@@ -244,7 +242,7 @@ EOF
     blog_toc_entry = "<li><a href=\"#{rel_path}\">#{title}</a></li>"
 
     com_section = <<EOF
-<div id="comment-section">
+<div id="comment-section" class="comment-section">
   #{com_section}
 </div>
 EOF