Explorar o código

Update HTML documentation ()

Simon Legner %!s(int64=3) %!d(string=hai) anos
pai
achega
617448e688
Modificáronse 2 ficheiros con 4 adicións e 5 borrados
  1. 3 4
      lib/docs/filters/html/entries.rb
  2. 1 1
      lib/docs/scrapers/mdn/html.rb

+ 3 - 4
lib/docs/filters/html/entries.rb

@@ -1,7 +1,6 @@
 module Docs
   class Html
     class EntriesFilter < Docs::EntriesFilter
-      OBSOLETE = %w(frame frameset hgroup noframes)
       ADDITIONAL_ENTRIES = { 'Element/Heading_Elements' => (1..6).map { |n| ["h#{n}"] } }
 
       def get_name
@@ -15,10 +14,10 @@ module Docs
       def get_type
         return 'Miscellaneous' if slug.include?('CORS') || slug.include?('Using')
 
-        if slug.start_with?('Global_attr')
+        if at_css('.deprecated', '.non-standard', '.obsolete')
+        'Obsolete'
+        elsif slug.start_with?('Global_attr')
           'Attributes'
-        elsif at_css('#deprecated', '#non-standard', '#obsolete') || OBSOLETE.include?(slug.remove('Element/'))
-          'Obsolete'
         elsif slug.start_with?('Element/')
           'Elements'
         else

+ 1 - 1
lib/docs/scrapers/mdn/html.rb

@@ -2,7 +2,7 @@ module Docs
   class Html < Mdn
     prepend FixInternalUrlsBehavior
 
-    # release = '2021-12-21'
+    # release = '2022-01-22'
     self.name = 'HTML'
     self.base_url = 'https://developer.mozilla.org/en-US/docs/Web/HTML'