Closes #548.
Unified · Split
| @@ -18,6 +18,10 @@ module Docs · 17 unmodified lines | ||
| 18 | 18 | end |
| 19 | 19 | end |
| 20 | 20 | |
| 21 | + css('.page-header', 'h1 span').each do |node| | |
| 22 | + node.before(node.children).remove | |
| 23 | + end | |
| 24 | + | |
| 21 | 25 | # Remove useless <header> |
| 22 | 26 | css('.entry-header > .entry-title', 'header > .underline', 'header > h2:only-child').to_a.uniq.each do |node| |
| 23 | 27 | node.parent.replace node |
| @@ -8,12 +8,13 @@ module Docs · 7 unmodified lines | ||
| 8 | 8 | |
| 9 | 9 | def get_name |
| 10 | 10 | name = at_css('h1').content.strip |
| 11 | − name.gsub!(/ [A-Z]/) { |str| str.downcase! } | |
| 11 | + name.gsub!(/ [A-Z]/) { |str| str.downcase! } unless name.start_with?('Category') | |
| 12 | 12 | name.gsub! %r{[“”]}, '"' |
| 13 | 13 | name |
| 14 | 14 | end |
| 15 | 15 | |
| 16 | 16 | def get_type |
| 17 | + return 'Categories' if slug.start_with?('category') | |
| 17 | 18 | return 'Ajax' if slug == 'Ajax_Events' |
| 18 | 19 | categories = css 'span.category' |
| 19 | 20 | types = categories.map { |node| node.at_css('a').content.strip } |
| @@ -8,7 +8,7 @@ module Docs · 7 unmodified lines | ||
| 8 | 8 | options[:title] = false |
| 9 | 9 | options[:container] = '#content' |
| 10 | 10 | options[:trailing_slash] = false |
| 11 | − options[:skip_patterns] = [/category/] | |
| 11 | + options[:skip_patterns] = [/deprecated/, /category\/version/] | |
| 12 | 12 | |
| 13 | 13 | options[:attribution] = <<-HTML |
| 14 | 14 | © The jQuery Foundation and other contributors<br> |
| @@ -1,7 +1,7 @@ | ||
| 1 | 1 | module Docs |
| 2 | 2 | class JqueryCore < Jquery |
| 3 | 3 | self.name = 'jQuery' |
| 4 | − self.release = 'up to 3.1.1' | |
| 4 | + self.release = 'up to 3.2.1' | |
| 5 | 5 | self.base_url = 'https://api.jquery.com/' |
| 6 | 6 | self.initial_paths = %w(/index/index) |
| 7 | 7 | |
| @@ -10,7 +10,7 @@ module Docs · 9 unmodified lines | ||
| 10 | 10 | |
| 11 | 11 | options[:root_title] = 'jQuery Mobile' |
| 12 | 12 | options[:skip] = %w(/tabs /theme) |
| 13 | − options[:skip_patterns].concat [/\A\/icons/, /cdn-cgi/i] | |
| 13 | + options[:skip_patterns] += [/\A\/icons/, /cdn-cgi/i] | |
| 14 | 14 | options[:replace_paths] = { '/select/' => '/selectmenu' } |
| 15 | 15 | |
| 16 | 16 | options[:fix_urls] = ->(url) do |