summary refs log tree commit diff
path: root/src/librustdoc/html/static/css/themes
AgeCommit message (Collapse)AuthorLines
2022-07-27Rollup merge of #99812 - GuillaumeGomez:fix-headings-colors, r=jsha,notriddleGuillaume Gomez-4/+0
Fix headings colors Fixes #99797. ![image](https://user-images.githubusercontent.com/3050060/181260966-49faf9d3-f6b8-4de4-bc7d-ed9f0467cf68.png) cc `@jsha` r? `@notriddle`
2022-07-27Fix headings borderGuillaume Gomez-4/+0
2022-07-24Satisfy theme checkMaybe Waffle-0/+1
2022-07-24Add support for `#[rustc_must_implement_one_of]` to rustdocMaybe Waffle-1/+4
2022-07-20Fix CSS on search input focusGuillaume Gomez-3/+21
2022-07-14Remove unused CSSGuillaume Gomez-44/+5
2022-07-11Continue themes CSS migration over CSS variablesGuillaume Gomez-130/+16
2022-07-11Remove unused CSS rulesGuillaume Gomez-33/+0
2022-07-10Group .test-arrow CSS rules and fix rgb/rgba propertyGuillaume Gomez-7/+3
2022-07-03Rollup merge of #98773 - notriddle:notriddle/source-sidebar-details, ↵Ralf Jung-7/+9
r=GuillaumeGomez rustdoc: use <details> tag for the source code sidebar This fixes the extremely poor accessibility of the old system, making it possible to navigate the sidebar by keyboard, and also implicitly gives the sidebar items the correct ARIA roles. Split out separately from #98772
2022-07-01rustdoc cleanup: remove unused functionMichael Howell-4/+3
2022-07-01rustdoc: use <details> tag for the source code sidebarMichael Howell-3/+6
This fixes the extremely poor accessibility of the old system, making it possible to navigate the sidebar by keyboard, and also implicitly gives the sidebar items the correct ARIA roles.
2022-06-28Simplify CSS theming by setting CSS variablesGuillaume Gomez-199/+18
2022-06-28Remove unused CSS rulesGuillaume Gomez-12/+0
2022-06-26Rollup merge of #98297 - GuillaumeGomez:help-pocket-menu, r=notriddleMatthias Krüger-12/+15
Transform help popup into a pocket menu Just like we moved the settings menu into a "pocket menu", it's doing the same to the help popup. You can test it [here](https://rustdoc.crud.net/imperio/help-pocket-menu/doc/foo/index.html) and here is a screenshot: ![Screenshot from 2022-06-20 20-58-29](https://user-images.githubusercontent.com/3050060/174663718-538e9d11-3bf9-48b2-8909-f9bfe75af135.png) r? ``````````@jsha``````````
2022-06-25Fix CSS rule for selected and hovered items in the source sidebarGuillaume Gomez-6/+6
2022-06-23Move help popup into a pocket menu as wellGuillaume Gomez-12/+15
2022-05-31Fix theme checksGuillaume Gomez-0/+3
2022-05-31Display empty impl blocks if they have documentationsGuillaume Gomez-1/+4
2022-05-30Move theme rules out of settings.cssGuillaume Gomez-7/+39
2022-05-30Improve display of settings radio buttonsGuillaume Gomez-6/+57
2022-05-17Fix display of search crate filter selectGuillaume Gomez-5/+6
2022-05-14Remove theme picker buttonGuillaume Gomez-28/+7
2022-05-14Improve settings menu displayGuillaume Gomez-3/+15
2022-03-27Add scrape examples help pageWill Crichton-6/+6
2022-03-27Improve styling on scrape examples help buttonWill Crichton-10/+10
2022-03-27Improve alignment of additional scraped examples, add scrape examples help pageWill Crichton-4/+57
2022-02-07Fix hover effects in sidebarJacob Hoffman-Andrews-21/+11
The dark and ayu themes have a menu-like highlight on sidebar items. The light theme used to, but it was accidentally lost in the sidebar unification. The change brings back the hover effect in the light theme. It also makes the hover effect apply consistently to all links in the sidebar, including headings. It also simplifies the "In _path_" heading so it's one big link. The breadcrumbs are still readily available at the top of the page.
2022-01-31Rollup merge of #93444 - camelid:rustdoc-css-cleanup, r=GuillaumeGomez,jshaMatthias Krüger-6/+8
Fix some CSS warnings and errors from VS Code There's no such CSS rule as `box-shadow-color`, so I instead copied the whole `box-shadow` property to each rule to make it actually apply. r? `@jsha`
2022-01-29rustdoc: small fixes to mobile navigationJacob Hoffman-Andrews-0/+3
- Make sure the mobile-topbar doesn't overflow its height if the user sets a bigger font. - Make sure the sidebar can be scrolled all the way to the bottom by shortening it to accommodate the mobile-topbar. - Make the item name in the mobile-topbar clickable to go to the top of the page. - Remove excess padding sidebar in mobile mode.
2022-01-29Fix some CSS warnings and errors from VS CodeNoah Lev-6/+8
There's no such CSS rule as `box-shadow-color`, so I instead copied the whole `box-shadow` property to each rule to make it actually apply.
2022-01-25give light-theme fns the correct orange-brown colourConrad Ludgate-1/+1
2022-01-24Rollup merge of #93231 - conradludgate:doc-link-brightness, r=notriddleMatthias Krüger-0/+67
adjust sidebar link brightness Fairly simple change. I've taken the existing link colour and main body background colours, and made sure that the sidebar+link contrast is the same. ayu: - [main content contrast](https://colourcontrast.cc/0f1419/39afd7) - 7.31 - [current sidebar contrast](https://colourcontrast.cc/14191f/39afd7) - 6.97 - [new sidebar contrast](https://colourcontrast.cc/14191f/56b1d9) - 7.30 dark: - [main content contrast](https://colourcontrast.cc/353535/d2991d) - 4.86 - [current sidebar contrast](https://colourcontrast.cc/14191f/d2991d) - 3.19 - [new sidebar contrast](https://colourcontrast.cc/14191f/fdbf35) - 4.87 light: - [main content contrast](https://colourcontrast.cc/ffffff/3873ad) - 4.97 - [current sidebar contrast](https://colourcontrast.cc/f5f5f5/3873ad) - 4.56 - [new sidebar contrast](https://colourcontrast.cc/f5f5f5/356da4) - 4.97
2022-01-23remove duplicate ruleConrad Ludgate-6/+0
2022-01-23tweak all sidebar coloursConrad Ludgate-3/+67
2022-01-23adjust sidebar link brightnessConrad Ludgate-0/+9
2022-01-21Unify search input and buttons sizeGuillaume Gomez-31/+5
2022-01-18Remove horizontal lines at top of pageJacob Hoffman-Andrews-9/+0
They are not needed to separate the search bar and the title, which are visually distinct on their own.
2022-01-18Simplify and unify rustdoc sidebar stylesJacob Hoffman-Andrews-72/+9
This switches to just use size, weight, and spacing to distinguish headings in the sidebar. We no longer use boxes, horizontal bars, or centering to distinguish headings. This makes it much easier to understand the hierarchy of headings, and reduces visual noise. I also refactored how the mobile topbar works. Previously, we tried to shift around elements from the sidebar to make the topbar. Now, the topbar gets its own elements, which can be styled on their own. This makes styling and reasoning about those elements simpler. Because the heading font sizes are bigger, increase the sidebar width slightly. As a very minor change, removed version from the "All types" page. It's now only on the crate page.
2022-01-17Rustdoc style cleanupsJacob Hoffman-Andrews-2/+9
- Make "since" version numbers grey again (regressed in #92602). - Remove unneeded selectors for when crate filter dropdown is a sibling of search-input. - Crate filter dropdown doesn't need to be 100% width on mobile. - Only build crate filter dropdown when there is more than one crate. - Remove unused addCrateDropdown.
2022-01-12Rollup merge of #92764 - GuillaumeGomez:fix-rust-logo-style, r=jshaMatthias Krüger-3/+3
Fix rust logo style The style on the rust logo is currently broken: ![Screenshot from 2022-01-11 13-36-30](https://user-images.githubusercontent.com/3050060/148946754-a1a57253-bed0-44cf-a41c-83e0eecbd6b5.png) With this fix, we're back to normal: ![Screenshot from 2022-01-11 13-42-07](https://user-images.githubusercontent.com/3050060/148946778-99f44678-aac1-419f-bb8c-ffa837e0c1ee.png) I also used a GUI test to prevent future silent regressions. r? ```@jsha```
2022-01-11Fix style for rust logoGuillaume Gomez-3/+3
2022-01-10Rollup merge of #92602 - jsha:source-link-2, r=GuillaumeGomezMatthias Krüger-7/+3
Make source links look cleaner Change from syntaxy-looking [src] to the plain word "source". Change the syntaxy-looking `[-]` at the top of the page to say "collapse". Reduce opacity of rightside content. Part of #59851 r? `@GuillaumeGomez` Demo: https://rustdoc.crud.net/jsha/source-link-2/std/string/struct.String.html [Discussed on Zulip](https://rust-lang.zulipchat.com/#narrow/stream/266220-rustdoc/topic/display.20of.20source.20link).
2022-01-08Make source links look cleanerJacob Hoffman-Andrews-7/+3
Change from syntaxy-looking [src] to the plain word "source".
2022-01-05Simplify :target CSS selectorGuillaume Gomez-12/+3
2021-12-31Rollup merge of #91480 - jsha:fewer-colors, r=GuillaumeGomezMatthias Krüger-59/+73
rustdoc: use smaller number of colors to distinguish items This reduces visual distractions when reading method signatures. As discussed in https://github.com/rust-lang/rust/issues/59845#issuecomment-974757191, this categorizes items into one of six colors (down from thirteen): - method, function (ochre `#AD7C37`) - trait, trait alias (dark slate blue `#6E4FC9`) - enum, struct, type alias, union, primitive (maroon `#AD378A`) - static, module, keyword, associated type, foreign type (steel blue `#3873AD`) - macro (green `#068000`) - generic params, self, Self (unmarked black `#000000`) I slightly tweaked the actual color values so they'd have the same lightness (previously the trait color stood out much more than the others). And I made the color for links in general consistently use steel blue (previously there was a slightly different color for "search-failed"). The ayu and dark themes have been updated according to the same logic. I haven't changed any of the color values in those themes, just their assignment to types. Demo: https://rustdoc.crud.net/jsha/fewer-colors/std/string/struct.String.html https://rustdoc.crud.net/jsha/fewer-colors/std/vec/struct.Vec.html https://rustdoc.crud.net/jsha/fewer-colors/std/io/trait.Read.html https://rustdoc.crud.net/jsha/fewer-colors/std/iter/trait.Iterator.html
2021-12-10Split CSS classes for "typedef" vs "associatedtype".Jacob Hoffman-Andrews-7/+23
2021-12-08Rollup merge of #91534 - jsha:heading-color, r=GuillaumeGomezMatthias Krüger-3/+3
Make rustdoc headings black, and markdown blue Demo: https://rustdoc.crud.net/jsha/heading-color/std/string/index.html#structs https://rustdoc.crud.net/jsha/heading-color/std/string/struct.String.html#examples Fixes #91304 r? ```@camelid``` /cc ```@GuillaumeGomez``` (Note: we may want to make rustdoc headings and markdown headings the same color -- #90245 -- but we would want to do that intentionally; this is fixing up a change that did so accidentally)
2021-12-08Change associated type to use link colorJacob Hoffman-Andrews-5/+5
2021-12-04Make rustdoc headings black, and markdown blueJacob Hoffman-Andrews-3/+3