fix rust 1.79.0 docs std crate indexing

This commit is contained in:
Virtual256 2024-07-26 16:35:02 -07:00
parent 7d24d973e4
commit 7ff958a491
2 changed files with 2 additions and 0 deletions

View file

@ -19,6 +19,7 @@ module Docs
css('.anchor').remove
css('.main-heading > h1').each do |node|
node.at('button')&.remove
node.parent.name = 'h1'
node.parent.content = node.content
end

View file

@ -9,6 +9,7 @@ module Docs
elsif slug == 'error-index'
'Compiler Errors'
else
at_css('main h1').at_css('button')&.remove
name = at_css('main h1').content.remove(/\A.+\s/).remove('⎘')
mod = slug.split('/').first
name.prepend("#{mod}::") unless name.start_with?(mod)