Fix scrolling in code blocks

This commit is contained in:
Shadowfacts 2019-09-16 17:52:38 -04:00
parent 6b276fdbe0
commit 3c5995cf02
Signed by: shadowfacts
GPG Key ID: 94A5AB95422746E5
2 changed files with 9 additions and 16 deletions

View File

@ -114,17 +114,11 @@ article {
font-family: $monospace;
color: var(--secondary-ui-text-color);
}
pre {
&::before, &::after {
content: "```";
display: block;
background: none;
color: var(--secondary-ui-text-color);
}
code::before, code::after {
content: "";
display: none;
}
pre code::before,
pre code::after {
// we don't show the decorations for pre blocks, because it can interfere with scrolling horizontally
content: "";
display: none;
}
strong::before, strong::after {
content: "**";
@ -285,7 +279,7 @@ a {
}
pre {
overflow: scroll;
overflow-x: scroll;
-moz-tab-size: 4;
-o-tab-size: 4;

View File

@ -8,11 +8,10 @@ Modified to use colors from CSS vars, defined in theme.scss
overflow-x: auto;
padding: 0.5em;
color: var(--atom-mono-1);
background: var(--atom-base);
}
.hljs > code {
background: var(--atom-base);
display: block;
}