History

Update HTML docs

Thibaut committed 12 years ago

Commit f4b736e1 parent 82739ef4 files · +8 −7Browse files

Unified · Split

4 files
  1. assets/javascripts/templates/pages/about_tmpl.coffee +1 −1
  2. lib/docs/filters/html/entries.rb +6 −2
  3. lib/docs/filters/mdn/clean_html.rb +0 −3
  4. lib/docs/scrapers/mdn/mdn.rb +1 −1
assets/javascripts/templates/pages/about_tmpl.coffee+1−1
@@ -109,7 +109,7 @@ credits = [ · 108 unmodified lines
109109 'https://raw.githubusercontent.com/apache/cordova-docs/master/LICENSE'
110110 ], [
111111 'CSS<br>DOM<br>HTML<br>JavaScript',
112− '2005-2013 Mozilla Developer Network and individual contributors',
112+ '2005-2014 Mozilla Developer Network and individual contributors',
113113 'CC BY-SA',
114114 'http://creativecommons.org/licenses/by-sa/2.5/'
115115 ], [
lib/docs/filters/html/entries.rb+6−2
@@ -1,7 +1,7 @@
11 module Docs
22 class Html
33 class EntriesFilter < Docs::EntriesFilter
4− HTML5 = %w(content element menuitem template)
4+ HTML5 = %w(content element video)
55 OBSOLETE = %w(frame frameset hgroup noframes)
66 ADDITIONAL_ENTRIES = { 'Heading_Elements' => (1..6).map { |n| ["h#{n}"] } }
77
@@ -14,7 +14,7 @@ module Docs · 6 unmodified lines
1414 'Obsolete'
1515 else
1616 spec = css('.standard-table').last.try(:content)
17− if (spec && spec =~ /HTML\s?5/ && spec !~ /HTML\s?4/) || HTML5.include?(slug)
17+ if (spec && html5_spec?(spec)) || HTML5.include?(slug)
1818 'HTML5'
1919 else
2020 'Standard'
@@ -29,6 +29,10 @@ module Docs · 8 unmodified lines
2929 def additional_entries
3030 ADDITIONAL_ENTRIES[slug] || []
3131 end
32+
33+ def html5_spec?(spec)
34+ (spec =~ /HTML\s?5/ || spec.include?('WHATWG HTML Living Standard')) && spec !~ /HTML\s?4/
35+ end
3236 end
3337 end
3438 end
lib/docs/filters/mdn/clean_html.rb+0−3
@@ -6,9 +6,6 @@ module Docs · 5 unmodified lines
66 '.htab', # "Browser compatibility" tabs
77 '.breadcrumbs', # (e.g. CSS/animation)
88 '.Quick_links', # (e.g. CSS/animation)
9− '.HTMLElmNav', # (e.g. HTML/a)
10− '.htmlMinVerHeader', # (e.g. HTML/article)
11− '.geckoVersionNote', # (e.g. HTML/li)
129 '.todo',
1310 '.draftHeader']
1411
lib/docs/scrapers/mdn/mdn.rb+1−1
@@ -11,7 +11,7 @@ module Docs · 10 unmodified lines
1111
1212 options[:trailing_slash] = false
1313 options[:attribution] = <<-HTML
14− &copy; 2013 Mozilla Contributors<br>
14+ &copy; 2014 Mozilla Contributors<br>
1515 Licensed under the Creative Commons Attribution-ShareAlike License v2.5 or later.
1616 HTML
1717