|
|
@ -9,12 +9,16 @@ module Docs
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|
# version documentation message
|
|
|
|
# version documentation message
|
|
|
|
at_css('.warning').remove
|
|
|
|
css('.warning').remove
|
|
|
|
|
|
|
|
|
|
|
|
css('header', 'footer', 'aside').remove
|
|
|
|
css('header', 'footer', 'aside').remove
|
|
|
|
|
|
|
|
|
|
|
|
css('pre').each do |node|
|
|
|
|
css('pre').each do |node|
|
|
|
|
node.content = node.content
|
|
|
|
if node.at_css('.line').nil?
|
|
|
|
|
|
|
|
node.content = node.content
|
|
|
|
|
|
|
|
else
|
|
|
|
|
|
|
|
node.content = node.css('.line').map(&:content).join("\n")
|
|
|
|
|
|
|
|
end
|
|
|
|
node['data-language'] = node.content =~ /\A\s*</ ? 'html' : 'javascript'
|
|
|
|
node['data-language'] = node.content =~ /\A\s*</ ? 'html' : 'javascript'
|
|
|
|
end
|
|
|
|
end
|
|
|
|
|
|
|
|
|
|
|
|