diff options
| author | bors <bors@rust-lang.org> | 2018-12-15 06:42:27 +0000 |
|---|---|---|
| committer | bors <bors@rust-lang.org> | 2018-12-15 06:42:27 +0000 |
| commit | 7f04a646c68acb7f964e113d145f9bb28bfbb48a (patch) | |
| tree | ed67ebe577135427dc2d74f893770806682fa2e2 /src/librustdoc/html/static/rustdoc.css | |
| parent | 91857a3c82362c9572d280397001f02d86c416be (diff) | |
| parent | b8c1726f267ce24b773f04c7d161c62f6fbc05fb (diff) | |
| download | rust-7f04a646c68acb7f964e113d145f9bb28bfbb48a.tar.gz rust-7f04a646c68acb7f964e113d145f9bb28bfbb48a.zip | |
Auto merge of #56005 - GuillaumeGomez:speedup-doc-render, r=QuietMisdreavus
Greatly improve rustdoc rendering speed issues Fixes #55900. So a few improvements here: * we're switching to `DOMTokenList` API when available providing a replacement if it isn't (should only happen on safari and IE I think...) * hide doc sections by default to allow the whole HTML generation to happen in the background to avoid triggering DOM redraw all the times (which killed the performances) r? @QuietMisdreavus
Diffstat (limited to 'src/librustdoc/html/static/rustdoc.css')
| -rw-r--r-- | src/librustdoc/html/static/rustdoc.css | 4 |
1 files changed, 4 insertions, 0 deletions
diff --git a/src/librustdoc/html/static/rustdoc.css b/src/librustdoc/html/static/rustdoc.css index cd5a8a739d1..d1336b1e8eb 100644 --- a/src/librustdoc/html/static/rustdoc.css +++ b/src/librustdoc/html/static/rustdoc.css @@ -368,6 +368,10 @@ body:not(.source) .example-wrap > pre { #main > .docblock h2 { font-size: 1.15em; } #main > .docblock h3, #main > .docblock h4, #main > .docblock h5 { font-size: 1em; } +#main > h2 + div, #main > h2 + h3, #main > h3 + div { + display: none; +} + .docblock h1 { font-size: 1em; } .docblock h2 { font-size: 0.95em; } .docblock h3, .docblock h4, .docblock h5 { font-size: 0.9em; } |
