Rollup merge of #74635 - GuillaumeGomez:fix-tooltip-pos, r=Manishearth
Fix tooltip position if the documentation starts with a code block Fixes #74321. Before:  After:  And in case there is text, it is not being applied:  And on mobile it isn't needed so it's not "activated":  r? @rust-lang/rustdoc
This commit is contained in:
commit
05a24661a3
1 changed files with 10 additions and 0 deletions
|
@ -1291,6 +1291,16 @@ h4 > .important-traits {
|
|||
|
||||
/* Media Queries */
|
||||
|
||||
@media (min-width: 701px) {
|
||||
/* In case there is no documentation before a code block, we need to add some margin at the top
|
||||
to prevent an overlay between the "collapse toggle" and the information tooltip.
|
||||
However, it's needed needed with smaller screen width because the doc/code block is always put
|
||||
"one line" below. */
|
||||
.information:first-child > .tooltip {
|
||||
margin-top: 16px;
|
||||
}
|
||||
}
|
||||
|
||||
@media (max-width: 700px) {
|
||||
body {
|
||||
padding-top: 0px;
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue