-
Notifications
You must be signed in to change notification settings - Fork 13.4k
rustdoc: remove CSS @media (min-width: 701px)
#103164
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Conversation
Some changes occurred in HTML/CSS/JS. cc @GuillaumeGomez, @Folyd, @jsha |
Thanks for the pull request, and welcome! The Rust team is excited to review your changes, and you should hear from @jsha (or someone else) soon. Please see the contribution instructions for more information. |
The two rules within it can and should be done without the separate media query: * There ain't no rule saying a viewport can't be `700.5px` wide, since hardware pixels can be finer than CSS pixels. * The rule for the first example-wrap child should probably apply on mobile. * The rule for the source sidebar is overriden by the mobile rule setting `max-width: 100vw`, so it can be merged with the rest of the styles.
Since it's possible to have a 700.5px viewport width, the JS needs to not switch to mobile mode in such a setup.
b18c351
to
d4e4b08
Compare
assert-css: (".sidebar", {"display": "block", "left": "-1000px"}) | ||
|
||
// Scroll down. | ||
scroll-to: "//h2[@id='blanket-implementations']" | ||
assert-window-property: {"pageYOffset": "651"} | ||
assert-window-property: {"pageYOffset": "627"} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This would benefit from a store-window-property command.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I can add one. :)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks! @bors r+ rollup |
…h, r=GuillaumeGomez rustdoc: remove CSS `@media (min-width: 701px)` The two rules within it can and should be done without the separate media query: * There ain't no rule saying a viewport can't be `700.5px` wide, since hardware pixels can be finer than CSS pixels. <details><summary>Screenshot</summary>  </details> * The rule for the first example-wrap child should probably apply on mobile. <details><summary>Screenshots</summary> ## Before  ## After  </details> * The rule for the source sidebar is overriden by the mobile rule setting `max-width: 100vw`, so it can be merged with the rest of the styles.
…iaskrgr Rollup of 6 pull requests Successful merges: - rust-lang#101889 (doc: rewrite doc for uint::{carrying_add,borrowing_sub}) - rust-lang#102507 (More slice::partition_point examples) - rust-lang#103164 (rustdoc: remove CSS ``@media` (min-width: 701px)`) - rust-lang#103189 (Clean up code-color and headers-color rustdoc GUI tests) - rust-lang#103203 (Retrieve LLVM version from llvm-filecheck binary if it is not set yet) - rust-lang#103204 (Add some more autolabels) Failed merges: r? `@ghost` `@rustbot` modify labels: rollup
The two rules within it can and should be done without the separate media query:
There ain't no rule saying a viewport can't be
700.5px
wide, since hardware pixels can be finer than CSS pixels.Screenshot
The rule for the first example-wrap child should probably apply on mobile.
Screenshots
Before
After
The rule for the source sidebar is overriden by the mobile rule setting
max-width: 100vw
, so it can be merged with the rest of the styles.