diff options
Diffstat (limited to 'trivium.rb')
-rw-r--r-- | trivium.rb | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/trivium.rb b/trivium.rb index 77d7fcf..2680a6e 100644 --- a/trivium.rb +++ b/trivium.rb @@ -69,7 +69,9 @@ class Dots < String else src = %{<span class="source">— #{args.strip}</span>} end - %{<div class="quote">#{BlueCloth.new((body + src).gsub(/^.*$/, '> \& ')).to_html}</div>} + text = (body + src).gsub(/^ +/) { " " * $&.size }. + gsub(/^.*$/, '> \& ') + %{<div class="quote">#{BlueCloth.new(text).to_html}</div>} when "math" body << "\\eqno{#{args.strip}}" unless args.strip.empty? %{<div class="math"><img alt="#{CGI.escapeHTML body}" src="#{MATH_TEX}#{CGI.escape(body).gsub('+', '%20')}"></div>} |