OSDN Git Service

bug fix: broken indents fixed in markdown rendered statements
authorKei Kubo <keikubo@gmail.com>
Wed, 11 Apr 2012 19:36:52 +0000 (19:36 +0000)
committerKei Kubo <keikubo@gmail.com>
Wed, 11 Apr 2012 19:36:52 +0000 (19:36 +0000)
app/views/issues/show.html.haml
app/views/milestones/show.html.haml
app/views/notes/_show.html.haml
app/views/refs/_tree.html.haml
app/views/wikis/show.html.haml

index 14d4930..37ccd9c 100644 (file)
@@ -42,7 +42,8 @@
       
   - if @issue.description.present?
     .bottom_box_content
-      = markdown @issue.description
+      = preserve do
+        = markdown @issue.description
 
 
 .issue_notes#notes= render "notes/notes", :tid => @issue.id, :tt => "issue"
index bac48aa..38b198a 100644 (file)
@@ -39,7 +39,8 @@
 
   - if @milestone.description.present?
     .bottom_box_content
-      = markdown @milestone.description
+      = preserve do
+        = markdown @milestone.description
 
 
 :javascript
index 916fda0..77b1573 100644 (file)
@@ -9,7 +9,8 @@
       %strong= link_to "Remove", [@project, note], :confirm => 'Are you sure?', :method => :delete, :remote => true, :class => "cred delete-note btn small"
 
   %div.note-title
-    = markdown(note.note)
+    = preserve do
+      = markdown(note.note)
     - if note.attachment.url
       .right
         %div.file
index 389a5a9..ee2f278 100644 (file)
@@ -41,7 +41,8 @@
         %h3= content.name
         .readme
           - if content.name =~ /\.(md|markdown)$/i
-            = markdown(content.data)
+            = preserve do
+              = markdown(content.data)
           - else
             = simple_format(content.data)
 
index 1b66fd3..8ac4994 100644 (file)
@@ -8,7 +8,8 @@
         Edit
 %hr
 .wiki_content
-  = markdown_to_html @wiki.content
+  = preserve do
+    = markdown_to_html @wiki.content
 
 %p.time Last edited by #{@wiki.user.name}, in #{time_ago_in_words @wiki.created_at}
 - if can? current_user, :admin_wiki, @project