mirror of
https://github.com/loikein/hugo-tufte.git
synced 2024-11-15 04:46:58 +01:00
38139b925b
Fix #48
64 lines
No EOL
1.2 KiB
SCSS
64 lines
No EOL
1.2 KiB
SCSS
$ht-code-border-radius: .4em;
|
|
.highlight {
|
|
width: 55%;
|
|
overflow-x: scroll;
|
|
border-radius: $ht-code-border-radius;
|
|
|
|
&>div.chroma>table.lntable{
|
|
margin: $ht-code-border-radius 0 $ht-code-border-radius 0;
|
|
& td:first-of-type {
|
|
& span:not(& span>span) {
|
|
padding: 0 .75em 0 .5em;
|
|
}
|
|
}
|
|
}
|
|
&>.chroma>code {
|
|
|
|
width: max-content;
|
|
margin-top: .5em;
|
|
margin-bottom: .5em;
|
|
margin-left: .5em;
|
|
&>span.hl{
|
|
margin-left: -.5em;
|
|
padding-left: .5em;
|
|
}
|
|
}
|
|
|
|
.chroma .hl {
|
|
// border-radius: $ht-code-border-radius / 2;
|
|
display: block;
|
|
}
|
|
|
|
&::-webkit-scrollbar {
|
|
border-radius: $ht-code-border-radius;
|
|
width: 10px;
|
|
height: 1rem;
|
|
}
|
|
&::-webkit-scrollbar-thumb {
|
|
border-radius: $ht-code-border-radius;
|
|
}
|
|
}
|
|
|
|
@media screen and (max-width: 760px) {
|
|
.highlight {
|
|
width: 90%;
|
|
}
|
|
}
|
|
|
|
.highlight .lntable {
|
|
overflow: initial;
|
|
}
|
|
|
|
.highlight pre {
|
|
margin: 0;
|
|
}
|
|
|
|
.highlight pre code {
|
|
display: block;
|
|
font-size: 1rem;
|
|
}
|
|
|
|
// fix #48 => https://github.com/slashformotion/hugo-tufte/issues/48
|
|
ul>li>div.highlight {
|
|
width: 100%;
|
|
} |