commit a690f79e74a1792c2db12d2e8392cbae00bcc6b8 parent 06b6b9d1f4ee9d50dc197a369a3933f48f533aee Author: Yohanes Bandung <bandungpenting@gmail.com> Date: Sat, 16 May 2020 18:46:53 +0700 style: <code> style outside content Diffstat:
| M | assets/content.scss | | | 22 | ---------------------- |
| M | assets/styles.scss | | | 26 | ++++++++++++++++++++++++-- |
| M | layouts/index.html | | | 2 | +- |
| M | layouts/partials/post/summary.html | | | 2 | +- |
4 files changed, 26 insertions(+), 26 deletions(-)
diff --git a/assets/content.scss b/assets/content.scss @@ -31,11 +31,6 @@ } } - pre { - overflow: auto; - padding: 0.5em; - } - a { &:hover { outline-style: solid; @@ -47,23 +42,6 @@ } } - code { - padding: 0.1em; - font-family: $font-mono; - font-size: 0.9em; - &.language-bash { - &:before { - content: "$ "; - } - } - } - - :not(pre) > code { - @include themify($themes) { - background-color: themed('color-background-hover'); - } - } - table { display: block; overflow-x: auto; diff --git a/assets/styles.scss b/assets/styles.scss @@ -32,6 +32,29 @@ hr { } } +code { + padding: 0.1em; + font-family: $font-mono; + font-size: 0.9em; + @include themify($themes) { + background-color: themed('color-background-hover'); + } + &.language-bash { + &:before { + content: "$ "; + } + } +} + +div.highlight > pre { + @include themify($themes) { + background-color: themed('color-background-hover') !important; + } + overflow: auto; + padding: 0.5em; +} + + @media (max-width: 599px) { html { font-size: 15px; @@ -341,4 +364,4 @@ time { } } } -}- \ No newline at end of file +} diff --git a/layouts/index.html b/layouts/index.html @@ -19,7 +19,7 @@ {{ .Date.Format "02 Jan 2006" }} </time> {{ with .Description }} - <p class="link-white listing__post__description">{{ . }}</p> + <p class="link-white listing__post__description">{{ . | safeHTML }}</p> {{ end }} <p class="listing__post__description">Read More »</p> </a> diff --git a/layouts/partials/post/summary.html b/layouts/partials/post/summary.html @@ -30,7 +30,7 @@ --> {{ $hell := .Type }} {{ if .Params.Description }} - <p> {{ .Params.Description }} </p> + <p> {{ .Params.Description | safeHTML }} </p> <a href="{{ $permalink }}"> <p>Read More »</p> </a>