remove dark images

pull/2375/head
Gergely Gombos 1 month ago
parent 2e1f0a0462
commit 7a510f6d8b

@ -13,14 +13,18 @@ module Docs
remove_selectors = [ remove_selectors = [
'div.grid > a', # prev-next links 'div.grid > a', # prev-next links
'button', # "show more" etc. buttons 'button', # "show more" etc. buttons
'div.order-last', # code iframe containers 'div.order-last', # code iframe containers
'a[title="Open in CodeSandbox"]', # codesandbox links 'div.dark-image', # dark images
'a[title="Open in CodeSandbox"]', # codesandbox links
] ]
css(*remove_selectors).each do |node| css(*remove_selectors).each do |node|
node.remove node.remove
end end
# Fix images not loading
css('img').remove_attr('srcset')
# Remove recipe blocks - TODO transform to outgoing link to docs # Remove recipe blocks - TODO transform to outgoing link to docs
css('h4[id^="examples-"]').each do |node| css('h4[id^="examples-"]').each do |node|
node.parent.parent.parent.remove node.parent.parent.parent.remove

Loading…
Cancel
Save