diff --git a/CHANGELOG.md b/CHANGELOG.md index aba5b7d4df..28b7e1a169 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -21,8 +21,13 @@ For a list of issues targeted for the next release, see the [23Q1][] milestone. - Dropped `$primary-light`. - Dropped `color-diff()`. -- **[Adaptation of shortcode 'cardpane'][1376]. renamed CSS class `td-card-deck` - to `td-card-group`. +- **[Adaptation of shortcodes for diplay of cards (#1376)][1376]: + - shortcode `cardpane`: renamed CSS class `td-card-deck` to `td-card-group`. + - shortcode `card`, `card-code`: markup of inner content (html/markdown) + now depends on the syntax of the calling shortcode, not on extension + of page file any more [#906][906]. + - shortcode `card-code` is now deprecated, use shortcode `card` with named + parameter `code=true` instead. **Other changes**: @@ -30,6 +35,7 @@ For a list of issues targeted for the next release, see the [23Q1][] milestone. - Draw.io diagram edit button: replace custom colors by BS's outline primary. [470]: https://github.com/google/docsy/issues/470 +[906]: https://github.com/google/docsy/issues/906 [bsv5mig]: https://getbootstrap.com/docs/5.2/migration/ ## [0.6.0][] diff --git a/layouts/shortcodes/card-code.html b/layouts/shortcodes/card-code.html index 0e1b668e05..1039147024 100644 --- a/layouts/shortcodes/card-code.html +++ b/layouts/shortcodes/card-code.html @@ -1,20 +1,15 @@ +{{ $lang := default "" ($.Get "lang") -}} +{{ $highlight := default "" ($.Get "highlight") -}} +
- {{ if eq $.Page.File.Ext "md" }} - {{ $.Inner | markdownify }} - {{ else }} - {{ $.Inner | htmlUnescape | safeHTML }} - {{ end }} + {{ . -}}
- {{ end }} + {{ end -}} + {{ end -}}