diff --git a/lib/docs/filters/yii/clean_html.rb b/lib/docs/filters/yii/clean_html.rb index 92d24d7a..5adebcc6 100644 --- a/lib/docs/filters/yii/clean_html.rb +++ b/lib/docs/filters/yii/clean_html.rb @@ -3,7 +3,7 @@ module Docs class CleanHtmlFilter < Filter def call - #remove meaningless content + #remove irrelevant content css('div').each do |node| if node['class'] == "layout-main-header" node.remove @@ -27,22 +27,17 @@ module Docs end end - #remove javascript show links - css('b').each do |node| - if node['class'] == "show" - node.remove - end - end - # Put code blocks in
tags css('.code').each do |node| node.name = 'pre' end - #remove Hide inherited methods / properties + #remove Hide inherited methods / properties and show links css('a').each do |node| if node['class'] == 'toggle' node.remove + elsif node['class'] == 'show' + node.remove end end