mirror of
https://github.com/hugo-fixit/FixIt.git
synced 2026-08-24 15:28:57 +00:00
💄 Style: update code element style for headings and toc items
This commit is contained in:
@@ -63,6 +63,24 @@ img,video {
|
||||
height: auto;
|
||||
}
|
||||
|
||||
%code {
|
||||
padding: 0.2em 0.4em;
|
||||
margin: 0;
|
||||
font-size: $code-font-size;
|
||||
font-family: $code-font-family;
|
||||
color: $code-color;
|
||||
background-color: rgba(175, 184, 193, 0.2);
|
||||
text-decoration: inherit;
|
||||
@include border-radius($global-border-radius);
|
||||
@include overflow-wrap(break-word);
|
||||
@include line-break(auto);
|
||||
|
||||
[data-theme='dark'] & {
|
||||
color: $code-color-dark;
|
||||
background-color: rgba(99, 110, 123, 0.4);
|
||||
}
|
||||
}
|
||||
|
||||
@include link(true, true);
|
||||
|
||||
@import '../_partials/scrollbar';
|
||||
|
||||
@@ -166,11 +166,6 @@
|
||||
font-weight: bolder;
|
||||
}
|
||||
|
||||
code {
|
||||
padding: 0 .2em;
|
||||
font-size: inherit;
|
||||
}
|
||||
|
||||
&:hover,
|
||||
&:target {
|
||||
> .heading-mark {
|
||||
|
||||
@@ -1,20 +1,6 @@
|
||||
// inline code
|
||||
code {
|
||||
padding: 0.2em 0.4em;
|
||||
margin: 0;
|
||||
font-size: $code-font-size;
|
||||
font-family: $code-font-family;
|
||||
color: $code-color;
|
||||
background-color: rgba(175, 184, 193, 0.2);
|
||||
text-decoration: inherit;
|
||||
@include border-radius($global-border-radius);
|
||||
@include overflow-wrap(break-word);
|
||||
@include line-break(auto);
|
||||
|
||||
[data-theme='dark'] & {
|
||||
color: $code-color-dark;
|
||||
background-color: rgba(99, 110, 123, 0.4);
|
||||
}
|
||||
@extend %code;
|
||||
}
|
||||
|
||||
// indented code
|
||||
@@ -23,7 +9,7 @@ pre:not(.mermaid[data-processed='true']) {
|
||||
line-height: 1.45em;
|
||||
padding: 0.5rem;
|
||||
overflow: auto;
|
||||
font-size: $code-font-size;
|
||||
font-size: $code-block-font-size;
|
||||
font-family: $code-font-family;
|
||||
@include border-radius($global-border-radius);
|
||||
@include tab-size(4);
|
||||
@@ -54,7 +40,7 @@ pre:not(.mermaid[data-processed='true']) {
|
||||
|
||||
.highlight,
|
||||
.gist {
|
||||
font-size: $code-font-size;
|
||||
font-size: $code-block-font-size;
|
||||
font-family: $code-font-family;
|
||||
|
||||
.table-wrapper {
|
||||
|
||||
@@ -8,6 +8,10 @@
|
||||
.toc-content {
|
||||
font-size: $toc-content-font-size;
|
||||
|
||||
code {
|
||||
@extend %code;
|
||||
}
|
||||
|
||||
ul {
|
||||
text-indent: -0.8em;
|
||||
padding-left: 0.8em;
|
||||
|
||||
@@ -164,7 +164,8 @@ $code-info-color: #9c9c9c !default;
|
||||
$code-info-color-dark: #b1b0b0 !default;
|
||||
|
||||
// Font size of the code
|
||||
$code-font-size: 0.875rem !default;
|
||||
$code-font-size: 0.875em !default;
|
||||
$code-block-font-size: 0.875rem !default;
|
||||
|
||||
// Font family of the code
|
||||
$code-font-family: Source Code Pro, Menlo, Consolas, Monaco, monospace, $global-font-family !default;
|
||||
|
||||
Reference in New Issue
Block a user