From 99175c9ba7e8fa948bf0287eccd46deaf191c196 Mon Sep 17 00:00:00 2001 From: Patrice Chalin Date: Fri, 12 Aug 2022 08:33:37 -0400 Subject: [PATCH] Card-related shortcode style fixes --- assets/scss/shortcodes/cards-pane.scss | 42 +++++++++++++++----------- layouts/shortcodes/card-code.html | 2 +- layouts/shortcodes/card.html | 2 +- layouts/shortcodes/cardpane.html | 2 +- 4 files changed, 27 insertions(+), 21 deletions(-) diff --git a/assets/scss/shortcodes/cards-pane.scss b/assets/scss/shortcodes/cards-pane.scss index f46cfe1336..f1a66f7759 100644 --- a/assets/scss/shortcodes/cards-pane.scss +++ b/assets/scss/shortcodes/cards-pane.scss @@ -1,19 +1,25 @@ -.card-deck { - @extend .td-max-width-on-larger-screens; -} -.card { - @extend .td-max-width-on-larger-screens; - .highlight { - border: none; - } -} -.card-body.code { - background-color: #f8f9fa; - padding: 0 0 0 1ex; -} -.card-body { - pre { - margin: 0; - padding: 0 1rem 1rem 1rem; - } +.td-card-deck.card-deck { + @extend .td-max-width-on-larger-screens; } + +.td-card { + &.card { + @extend .td-max-width-on-larger-screens; + + .highlight { + border: none; + } + } + + .card-body { + &.code { + background-color: #f8f9fa; + padding: 0 0 0 1ex; + } + + pre { + margin: 0; + padding: 0 1rem 1rem 1rem; + } + } +} \ No newline at end of file diff --git a/layouts/shortcodes/card-code.html b/layouts/shortcodes/card-code.html index 7b0e2e99fc..a7c5465d83 100644 --- a/layouts/shortcodes/card-code.html +++ b/layouts/shortcodes/card-code.html @@ -1,4 +1,4 @@ -
+
{{ $lang := "" }} {{ with $.Get "lang" }} {{ $lang = $.Get "lang" }} diff --git a/layouts/shortcodes/card.html b/layouts/shortcodes/card.html index 94b2bd9244..f0558133b7 100644 --- a/layouts/shortcodes/card.html +++ b/layouts/shortcodes/card.html @@ -1,4 +1,4 @@ -
+
{{ with $.Get "header" }}
{{ if eq $.Page.File.Ext "md" }} diff --git a/layouts/shortcodes/cardpane.html b/layouts/shortcodes/cardpane.html index 1c4e9a284e..2617fdbaa2 100644 --- a/layouts/shortcodes/cardpane.html +++ b/layouts/shortcodes/cardpane.html @@ -1,3 +1,3 @@ -
+
{{- .Inner -}}
\ No newline at end of file