diff options
Diffstat (limited to 'assets/sass/_partial/_post/content/_highlight.scss')
-rw-r--r-- | assets/sass/_partial/_post/content/_highlight.scss | 29 |
1 files changed, 29 insertions, 0 deletions
diff --git a/assets/sass/_partial/_post/content/_highlight.scss b/assets/sass/_partial/_post/content/_highlight.scss new file mode 100644 index 0000000..6f200ec --- /dev/null +++ b/assets/sass/_partial/_post/content/_highlight.scss @@ -0,0 +1,29 @@ +.highlight { + position: relative; + margin: 1em 0; + overflow-x: auto; + border: 2px solid #dddddd; + line-height: 1.6; + + code { + all: unset; + } + + pre { + margin: 0; /* remove normal pre margin */ + } + + table { + padding: 1em 0.3em !important; + + td:nth-child(2) code{ + &::after { + position: absolute; + top: 0; + right: 0.5em; + font-weight: bold; + content: attr(data-lang); + } + } + } +} |