forked from rust-lang/rust
-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Rollup merge of rust-lang#83393 - GuillaumeGomez:codeblock-tooltip-po…
…sition, r=Nemo157 Codeblock tooltip position The codeblocks tooltips were misplaced. Normally, there is no top margin applied to a tooltip unless the codeblock is the first element of the doc block. The CSS rule was too vague though, applying it to all tooltips where the codeblock was the first child of its parent. Which can be easily seen with lists: Before: ![Screenshot from 2021-03-22 22-05-16](https://user-images.githubusercontent.com/3050060/112059812-a667ba80-8b5c-11eb-88dd-1c598ceb3766.png) After: ![Screenshot from 2021-03-22 22-06-31](https://user-images.githubusercontent.com/3050060/112059815-a7005100-8b5c-11eb-9e40-8fc57513e498.png) r? `@Nemo157`
- Loading branch information
Showing
3 changed files
with
24 additions
and
5 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,9 @@ | ||
goto: file://|DOC_PATH|/index.html | ||
goto: ./fn.check_list_code_block.html | ||
// If the codeblock is the first element of the docblock, the information tooltip must have | ||
// have some top margin to avoid going over the toggle (the "[+]"). | ||
assert: (".docblock > .information > .compile_fail", { "margin-top": "16px" }) | ||
// Checks that the other codeblocks don't have this top margin. | ||
assert: ("ol > li > .information > .compile_fail", { "margin-top": "0px" }) | ||
assert: ("ol > li > .information > .ignore", { "margin-top": "0px" }) | ||
assert: (".docblock > .information > .ignore", { "margin-top": "0px" }) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters