vendor/gems/BlueCloth-1.0.0/lib/bluecloth.rb
### Transform list items in a copy of the given +str+ and return it.
Transform list items in a copy of the given +str+ and return it.
Transform list items in a copy of the given + str + and return it .
def transform_list_items( str, rs )
		@log.debug " Transforming list items"
		str = str.sub( /\n{2,}\z/, "\n" )
		str.gsub( ListItemRegexp ) {|line|
			@log.debug "  Found item line %p" % line
			leading_line, item = $1, $4
			if leading_line or /\n{2,}/.match( item )
				@log.debug "   Found leading line or item has a blank"
				item = apply_block_transforms( outdent(item), rs )
			else
				@log.debug "   Recursing for sublist"
				item = transform_lists( outdent(item), rs ).chomp
				item = apply_span_transforms( item, rs )
			end
			%{<li>%s</li>\n} % item
		}
	end
def transform_list_items ( str , rs ) @log . debug " Transforming list items" str = str . sub ( / \n {2,} \z / , "\n" ) str . gsub ( ListItemRegexp ) { | line | @log . debug "  Found item line %p" % line leading_line , item = $1 , $4 if leading_line or / \n {2,} / . match ( item ) @log . debug "   Found leading line or item has a blank" item = apply_block_transforms ( outdent ( item ) , rs ) else @log . debug "   Recursing for sublist" item = transform_lists ( outdent ( item ) , rs ) . chomp item = apply_span_transforms ( item , rs ) end %{<li>%s</li>\n} % item } end
Transform list items in a copy of the given +str+ and return it.
Transform list items in a copy of the given + str + and return it .
# Trim trailing blank lines # Recursion for sub-lists
str
<not_specific>
rs
<not_specific>