Permalink
Browse files

Add a clearfix to full-end comments

  • Loading branch information...
1 parent 5026a2d commit f60ef14047a6b34a017d64281aa9d115172bd09f Steve Klise committed Nov 21, 2012
Showing with 7 additions and 0 deletions.
  1. +7 −0 helpers/codepostprocessing.rb
@@ -9,6 +9,9 @@ def formatCodeCommentPairs(code, comment)
response = "<div class='code-comment-pair #{comment_type(comment)}'>"
response += look_for_multiline(comment)
response += "<code><pre>#{parseCode(code)}</pre></code>"
+ if is_multiline(comment)
+ response += "<div style='position:relative;clear:both;display:block;height:1px;width:100%;'></div>"
+ end
response += "</div>"
response
end
@@ -28,6 +31,10 @@ def comment_type(comment)
end
end
+def is_multiline(comment)
+ comment.match(/\[full\]/)
+end
+
def look_for_multiline(comment)
clean_comment = comment
.gsub(/\[\S*?\]/,'')

0 comments on commit f60ef14

Please sign in to comment.