about summary refs log tree commit diff
path: root/src/librustdoc/html/static/css
AgeCommit message (Collapse)AuthorLines
2025-08-28Add new `doc(attribute = "...")` attributeGuillaume Gomez-0/+9
2025-08-23Make macro expansion feature buttons accessibleGuillaume Gomez-8/+6
2025-08-23Go around firefox bugGuillaume Gomez-1/+7
2025-08-23Correctly handle multiple macro expansions on a same lineGuillaume Gomez-4/+6
2025-08-23Add support for macro expansion in rustdoc source code pagesGuillaume Gomez-9/+48
2025-08-15rustdoc-search: search backend with partitioned suffix treeMichael Howell-91/+317
2025-08-04Fix wrong font being used for tooltips `i` iconsGuillaume Gomez-0/+4
2025-07-01Improve CSS for source code block line numbersGuillaume Gomez-68/+30
2025-05-16rustdoc: on mobile, make the sidebar full width and linewrapbinarycat-1/+4
this is because the mobile sidebar cannot be resized, unlike on desktop.
2025-05-09rustdoc: use a different style of grip trackMichael Howell-39/+19
2025-05-09rustdoc: add a handle that makes sidebar resizing more obviousMichael Howell-7/+53
This change is based on some discussion on [lolbinarycat's idea], but with a more "traditional" design. Specifically, this is the closest thing I could find to a consensus across many systems I looked at for inspiration: - In Jira, resizable sidebars have a stack of four dots. - In The GIMP, resizable sidebars have a stack of three dots. - In [old Windows], "panes" are defined to have the same border style as a window, which has a raised appearance. - In [NeXT], a drag point usually had an innie, whether the line in a slider or the circle in a scroller; I can also hide and show the favorites bar in Workspace by dragging on a circular "grip spot" - In [old Mac], drag handles for things usually had a "grip track" of parallel lines. - [OSX] kept that, but the "Source List" part of the Finder still had the circle grip for a time the same way Workspace did [lolbinarycat's idea]: https://github.com/rust-lang/rust/pull/139420 [old Windows]: https://archive.org/details/windowsinterface00micr/page/n9/mode/2up [old Mac]: https://archive.org/details/apple-hig/1996_Human_Interface_Guidelines_for_Mac_OS_8_%28WWDC_Release%29/page/16/mode/2up [NeXT]: https://archive.org/details/apple-hig/1993%20NeXTSTEP%20User%20Interface%20Guidelines%20-%20Release%203/page/145/mode/2up [OSX]: https://dn721903.ca.archive.org/0/items/apple-hig/MacOSX_HIG_2005_09_08.pdf#page=267
2025-05-06Rollup merge of #140135 - GuillaumeGomez:sidebars-image, r=rustdocGuillaume Gomez-21/+22
Unify sidebar buttons to use the same image Part of https://github.com/rust-lang/rust/issues/139832. The source sidebar looks like this with the new image: ![image](https://github.com/user-attachments/assets/df4fee52-fb71-4794-91b7-3afc6d2aab70) You can test it [here](https://rustdoc.crud.net/imperio/sidebar-images/src/foo/foo.rs.html). r? `@notriddle`
2025-04-24Fix indent of impl docsGuillaume Gomez-1/+4
2025-04-23Unify sidebar buttons to use the same imageGuillaume Gomez-21/+22
2025-04-21Use correct annotation for CSS pseudo elementsGuillaume Gomez-20/+20
2025-04-07Fix CSSGuillaume Gomez-1/+1
2025-04-02rustdoc: make settings checkboxes always squarebinarycat-0/+3
2025-02-22Rename feature into `Word wrap source code`Guillaume Gomez-13/+13
2025-02-14Add new setting to wrap source code lines when too longGuillaume Gomez-41/+66
2025-02-12rustdoc: use better, consistent SVG icons for scraped examplesMichael Howell-1/+42
This continues two ongoing projects: - Replacing ascii art with real icons that don't look like syntax, are understandable to people who're familiar with desktop computers and smart devices, and aren't ugly. - Using labels and tooltips to clarify these icons, when the limits of popular iconography hit us. In this case, I've added tooltips, because, unfortunately, there's not room for always-visible labels.
2025-02-11Correctly handle `user-select: none`Guillaume Gomez-0/+5
2025-02-10Move line numbers into the `<code>` directlyGuillaume Gomez-18/+40
2025-01-29Add SemiBold for SourceSerif4Guillaume Gomez-2/+10
2025-01-29Add italic for newly added sans serif fontsGuillaume Gomez-2/+18
2025-01-29Add new setting allowing to switch to sans serif fontsGuillaume Gomez-2/+25
2025-01-25Remove extra whitespace from rustdoc breadcrumbs for copypastingKornel-6/+3
2025-01-24Fix indent of trait items on mobileGuillaume Gomez-3/+7
2025-01-19Remove unused `item-row` CSS classGuillaume Gomez-1/+1
2025-01-18Remove more CSS classesGuillaume Gomez-11/+11
2025-01-17Handle reexports items list a bit differently since they cannot have ↵Guillaume Gomez-1/+1
documentation
2025-01-17Replace ul/li list with dl/dd/dt elementsGuillaume Gomez-14/+18
2025-01-14fix underlining of hovered intra-doc links.binarycat-0/+2
fixes https://github.com/rust-lang/rust/issues/133484
2024-12-05Improve positioning of "..." in collapsed impl blockGuillaume Gomez-3/+8
2024-12-05Use text ellipsis instead of bottom blurringGuillaume Gomez-11/+16
2024-12-05Always display first line of impl blocks even when collapsedGuillaume Gomez-0/+23
2024-11-13Align impl doc block with `impl` keywordGuillaume Gomez-1/+1
2024-11-12Increase impl items indent and decrease documentation indent for impl blockGuillaume Gomez-15/+35
2024-10-30rustdoc-search: show types signatures in resultsMichael Howell-5/+16
2024-10-28Unify variant struct fields margins with struct fieldsGuillaume Gomez-1/+1
2024-10-26Rollup merge of #132183 - GuillaumeGomez:code-in-docblock, r=notriddleJubilee-1/+1
Fix code HTML items making big blocks if too long Encountered this bug randomly where `code` item in docblocks would look like this: ![Screenshot from 2024-10-26 15-44-46](https://github.com/user-attachments/assets/a9c1df9d-5007-49eb-a7dd-a2c381b2511e) With this fix it looks like this: ![image](https://github.com/user-attachments/assets/ea918595-5434-4781-b68c-6abd38689365) r? ``@notriddle``
2024-10-26Fix code HTML items making big blocks if too longGuillaume Gomez-1/+1
2024-10-24Rollup merge of #131906 - notriddle:notriddle/spacing, r=GuillaumeGomezMatthias Krüger-2/+8
rustdoc: adjust spacing and typography in header Fixes #131589 Preview: https://notriddle.com/rustdoc-html-demo-12/spacing/std/index.html | Before | After | |--|--| | ![image](https://github.com/user-attachments/assets/b5c5132d-1e5e-402e-ba19-1dea9e70ea6f) | ![image](https://github.com/user-attachments/assets/72570b93-bb16-4553-9da7-fc4f29b98873) | ![image](https://github.com/user-attachments/assets/264983f0-5aec-4120-8a03-f62e52d4360d) | ![image](https://github.com/user-attachments/assets/b6925945-95e6-4858-8e91-4cfd90c164f0) | ![image](https://github.com/user-attachments/assets/df96bfe7-195d-4aaf-97f1-a45ade34cab2) | ![image](https://github.com/user-attachments/assets/c6fe2d57-bd8a-42aa-b3cf-4f635809b9b4) | ![image](https://github.com/user-attachments/assets/7519faa5-d6b2-41ba-9d95-6000d1dd89d1) | ![image](https://github.com/user-attachments/assets/7233c2d6-82d9-4820-bb63-dc4776a34601) First of all, we put 4px additional margin below the search box, and 4px margin below the header to balance it out. The bigger problem we have to solve is making the lines look logically spaced. This is troublesome, because Fira Sans (the typeface we use here) wants to look good on average, and to avoid breaking, with text that uses [ascenders and descenders](https://www.w3.org/TR/css-inline-3/images/text-edge.png). If the text we're putting in happens to not have any, things look weird (strictly speaking, there’s hand-tuning here, because the Copy Path button messes with stuff, but the overall point is that there is no true, one perfect layout). In order to play nicely with the font, I've tweaked the text to use that space. The word "Source" for the link is now capitalized, and the Since version number now uses oldstyle nums with descenders.
2024-10-23rustdoc: adjust spacing and typography in headerMichael Howell-2/+8
2024-10-19rustdoc: Switch from FxHash to sha256 for static file hashing.Alona Enraght-Moony-9/+9
2024-10-11Rollup merge of #131394 - ↵Matthias Krüger-0/+3
ismailarilik:fix/rustdoc/add-space-between-struct-fields-and-their-descriptions, r=GuillaumeGomez fix(rustdoc): add space between struct fields and their descriptions Stolen from #128541. Fixes #128260. <table> <thead> <tr> <th scope="col">Before</th> <th scope="col">After</th> </tr> </thead> <tbody> <tr> <td scope="row"> <img src="https://github.com/user-attachments/assets/b1d3cb47-77c9-4897-a5d2-2192b11cb8a3" /> </td> <td> <img src="https://github.com/user-attachments/assets/0b104672-d2be-49f4-ac9b-3506526fe2f1" /> </td> </tr> </tbody> </table> <table> <thead> <tr> <th scope="col">Before</th> <th scope="col">After</th> </tr> </thead> <tbody> <tr> <td scope="row"> <img src="https://github.com/user-attachments/assets/650c3e74-a067-492a-9ba3-557f9214f875" /> </td> <td> <img src="https://github.com/user-attachments/assets/413ef9b0-8fca-4e16-978a-7b88d05299dc" /> </td> </tr> </tbody> </table> Unlike original PR, I didn't add space between field headers; I put it between headers and descriptions. So if there are only headers, the space is not changed. Otherwise, I put a space like the space between paragraphs (.75em) which makes sense for me but feel free to adjust it or ask me to do so. r? `@GuillaumeGomez`
2024-10-09Fix methods alignment on mobileGuillaume Gomez-1/+1
2024-10-08fix(rustdoc): add space between struct fields and their descriptionsismailarilik-0/+3
2024-10-04Fix list marginsGuillaume Gomez-3/+6
2024-10-01Rollup merge of #130933 - lolbinarycat:rustdoc-li-p, r=GuillaumeGomez,notriddleMatthias Krüger-0/+7
rustdoc: lists items that contain multiple paragraphs are more clear fixes https://github.com/rust-lang/rust/issues/130622 before: ![before](https://github.com/user-attachments/assets/fe54d8ee-8a1a-45fc-9434-2737c5c6f4d5) after: ![after](https://github.com/user-attachments/assets/095be365-1bfc-4001-8664-59bc4125bb05)
2024-09-29Adjust spacings and sizing to improve behavior with over-long namesFrank Steffahn-6/+12