Make <pre> and <code> elements scale with dynamic type

This commit is contained in:
Nate Weaver 2020-01-10 15:44:04 -06:00
parent 4ab5c25844
commit a409242cdb
1 changed files with 6 additions and 3 deletions

View File

@ -1,9 +1,12 @@
:root {
font: -apple-system-body;
}
body { body {
margin-top: 3px; margin-top: 3px;
margin-bottom: 20px; margin-bottom: 20px;
margin-left: 20px; margin-left: 20px;
margin-right: 20px; margin-right: 20px;
font: -apple-system-body;
word-wrap: break-word; word-wrap: break-word;
word-break: break-word; word-break: break-word;
@ -125,7 +128,7 @@ pre {
margin: 0; margin: 0;
overflow: auto; overflow: auto;
overflow-y: hidden; overflow-y: hidden;
line-height: 20px; line-height: 1.4286em;
border: 1px solid var(--secondary-accent-color); border: 1px solid var(--secondary-accent-color);
padding: 5px; padding: 5px;
word-wrap: normal; word-wrap: normal;
@ -137,7 +140,7 @@ pre {
} }
code, pre { code, pre {
font-family: "SF Mono", Menlo, "Courier New", Courier, monospace; font-family: "SF Mono", Menlo, "Courier New", Courier, monospace;
font-size: 14px; font-size: .8235rem;
} }
img, figure, video, iframe, div { img, figure, video, iframe, div {
max-width: 100%; max-width: 100%;