Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Remove extra whitespace from rustdoc breadcrumbs for copypasting #135946

Merged
merged 1 commit into from
Jan 26, 2025
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
9 changes: 3 additions & 6 deletions src/librustdoc/html/static/css/rustdoc.css
Original file line number Diff line number Diff line change
Expand Up @@ -192,15 +192,12 @@ h1, h2, h3, h4 {
.rustdoc-breadcrumbs {
grid-area: main-heading-breadcrumbs;
line-height: 1.25;
display: flex;
kornelski marked this conversation as resolved.
Show resolved Hide resolved
flex-wrap: wrap;
align-items: end;
padding-top: 5px;
position: relative;
z-index: 1;
}
.rustdoc-breadcrumbs a {
padding: 4px 0;
margin: -4px 0;
z-index: 1;
padding: 5px 0 7px;
}
/* The only headings that get underlines are:
Markdown-generated headings within the top-doc
Expand Down
4 changes: 2 additions & 2 deletions src/librustdoc/html/templates/print_item.html
Original file line number Diff line number Diff line change
@@ -1,13 +1,13 @@
<div class="main-heading">
{% if !path_components.is_empty() %}
<span class="rustdoc-breadcrumbs">
<div class="rustdoc-breadcrumbs">
kornelski marked this conversation as resolved.
Show resolved Hide resolved
{% for (i, component) in path_components.iter().enumerate() %}
{% if i != 0 %}
::<wbr>
{% endif %}
<a href="{{component.path|safe}}index.html">{{component.name}}</a>
{% endfor %}
</span>
</div>
{% endif %}
<h1>
{{typ}}
Expand Down
Loading