Skip to content

Commit

Permalink
Style suggestions for sphinx13
Browse files Browse the repository at this point in the history
As a suggestion:

- increase paragraph line-height to 1.5 to give text a bit more room to breathe.
  1.5 is a common choice in web page typography; e.g. rtd-sphinx-theme, furo and
  GitHub use this (pydata sphinx theme goes even to 1.65).
- Don't shrink the text in admonitions. They are equally important and thus should
  have the same size as regular paragraphs.
- Adapt the border color for all warning/error like admonitions. Warnings had a
  fixed color that did not fit well to the new admonition style.
  • Loading branch information
timhoffm committed Jul 11, 2024
1 parent 41ee3be commit 7a5afa4
Showing 1 changed file with 10 additions and 3 deletions.
13 changes: 10 additions & 3 deletions doc/_themes/sphinx13/static/sphinx13.css
Original file line number Diff line number Diff line change
Expand Up @@ -241,6 +241,7 @@ div.footer a {

p {
margin: 0.8em 0 0.5em 0;
line-height: 1.5;
}

a {
Expand Down Expand Up @@ -395,7 +396,6 @@ table td, table th {
}

div.admonition, div.warning {
font-size: 0.9em;
margin: 1em 0 1em 0;
border: 1px solid #86989B;
border-radius: var(--admonition-radius);
Expand Down Expand Up @@ -451,6 +451,7 @@ p.admonition-title::before {
content: "";
height: 1rem;
left: .5rem;
top: .5rem;
position: absolute;
width: 1rem;
background-color: #5f5f5f;
Expand Down Expand Up @@ -516,9 +517,15 @@ div.warning > p.admonition-title::before {
-webkit-mask-image: var(--icon-warning);
mask-image: var(--icon-warning);
}

div.caution,
div.important,
div.warning {
border: 1px solid #940000;
border-color: var(--colour-warning-fg);
}
div.attention,
div.danger,
div.error {
border-color: var(--colour-error-fg);
}

div.admonition > ul,
Expand Down

0 comments on commit 7a5afa4

Please sign in to comment.