From 272a67d7a8b8752dda3cddf44482e9d85de2c4d0 Mon Sep 17 00:00:00 2001 From: Eltrac Date: Tue, 15 Jul 2025 14:17:39 +0800 Subject: refactor: replace _footer.scss and _shortcode.scss with UnoCSS --- layouts/_shortcodes/callout.html | 6 ++++-- layouts/_shortcodes/link.html | 27 ++++++++++++++------------- layouts/_shortcodes/quotecard.html | 12 ++++++++++-- layouts/_shortcodes/sidenote.html | 4 ---- 4 files changed, 28 insertions(+), 21 deletions(-) delete mode 100644 layouts/_shortcodes/sidenote.html (limited to 'layouts/_shortcodes') diff --git a/layouts/_shortcodes/callout.html b/layouts/_shortcodes/callout.html index 62112390..a432cd4d 100644 --- a/layouts/_shortcodes/callout.html +++ b/layouts/_shortcodes/callout.html @@ -1,6 +1,8 @@ -
+
{{ index .Params 1 }}
{{ index .Params 0 | markdownify }}
-
\ No newline at end of file +
diff --git a/layouts/_shortcodes/link.html b/layouts/_shortcodes/link.html index 1b9c4f79..abd1b1aa 100644 --- a/layouts/_shortcodes/link.html +++ b/layouts/_shortcodes/link.html @@ -1,14 +1,15 @@ - - {{ if and (isset .Params "image") .Params.image }} - - {{ end }} - {{ if ne (.Get "type") "podcast" }} - - {{ end }} +{{ if eq (.Get "type") "podcast" }} + + {{ .Get +{{ else }} + +

{{ .Get "title" }}

+
+{{ end }} diff --git a/layouts/_shortcodes/quotecard.html b/layouts/_shortcodes/quotecard.html index dfaf04e2..f4b4621a 100644 --- a/layouts/_shortcodes/quotecard.html +++ b/layouts/_shortcodes/quotecard.html @@ -1,3 +1,11 @@ -
+
{{ .Inner | markdownify }} -
\ No newline at end of file +
diff --git a/layouts/_shortcodes/sidenote.html b/layouts/_shortcodes/sidenote.html deleted file mode 100644 index bf2a87d3..00000000 --- a/layouts/_shortcodes/sidenote.html +++ /dev/null @@ -1,4 +0,0 @@ -
-

{{ index .Params 0 | markdownify }}

-
{{ index .Params 1 | markdownify }}
-
-- cgit v1.2.3