Small fix to TOC regexp.

git-svn-id: http://redmine.rubyforge.org/svn/trunk@719 e93f8b46-1217-0410-a6f0-8f06a7374b81
This commit is contained in:
Jean-Philippe Lang 2007-09-09 10:41:02 +00:00
parent f3364b9dce
commit f6fe15716e
1 changed files with 1 additions and 1 deletions

View File

@ -56,7 +56,7 @@ module Redmine
alias :textile_h3 :textile_p_withtoc alias :textile_h3 :textile_p_withtoc
def inline_toc(text) def inline_toc(text)
text.gsub!(/<p>\{\{(<>?)toc\}\}<\/p>/i) do text.gsub!(/<p>\{\{([<>]?)toc\}\}<\/p>/i) do
div_class = 'toc' div_class = 'toc'
div_class << ' right' if $1 == '>' div_class << ' right' if $1 == '>'
out = "<div class=\"#{div_class}\">" out = "<div class=\"#{div_class}\">"