Skip to content

Commit

Permalink
Auto merge of rust-lang#86589 - JohnTitor:add-triangle-to-summary, r=…
Browse files Browse the repository at this point in the history
…jsha

Show triangle on the "Details" disclosure element in all cases

Re-submission of rust-lang#82805, fixes the style issue by applying the same margin as `<p>`.

<details><summary>Before</summary>

![before 1](https://user-images.githubusercontent.com/25030997/123215032-e4c99880-d502-11eb-9ccc-6df58f3a6b0b.png)
![before 2](https://user-images.githubusercontent.com/25030997/123215035-e5622f00-d502-11eb-9275-6c6dfcfdf72e.png)
</details>

<details><summary>After</summary>

![after 1](https://user-images.githubusercontent.com/25030997/123215037-e5fac580-d502-11eb-9b49-c99d1eafb1b4.png)
![after 2](https://user-images.githubusercontent.com/25030997/123215040-e5fac580-d502-11eb-8afc-ab713d3dc658.png)
</details>

r? `@GuillaumeGomez`
  • Loading branch information
bors committed Jun 27, 2021
2 parents e8cb1a4 + 14413ad commit 3e9d7ec
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions src/librustdoc/html/static/rustdoc.css
Original file line number Diff line number Diff line change
Expand Up @@ -200,6 +200,12 @@ summary {
outline: none;
}

/* FIXME: Remove after normalize.css is either upgraded or removed (#86629) */
details:not(.rustdoc-toggle) summary {
margin-bottom: .6em;
display: list-item;
}

code, pre, a.test-arrow {
font-family: "Source Code Pro", monospace;
}
Expand Down Expand Up @@ -897,10 +903,6 @@ body.blur > :not(#help) {
display: inline;
}

.stab summary {
display: list-item;
}

.stab .emoji {
font-size: 1.5em;
}
Expand Down

0 comments on commit 3e9d7ec

Please sign in to comment.