aboutsummaryrefslogtreecommitdiff
path: root/themes/default/layouts/shortcodes/react.rss.xml
blob: 429505d0b329af9254e6005606b24b22a54d45e3 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
{{- $text      := default "react" (.Get "text"      | default (.Get 0)) -}}
{{- $source    := default ""      (.Get "source"    | default (.Get 1)) -}}
{{- $title     := default $text   (.Get "title"     | default (.Get 2)) -}}
{{- $alternate := default $title  (.Get "alternate" | default (.Get 3)) -}}

{{- $author := .Page.Section -}}

{{- $image := partial "function-caches-images.html"
  (dict
    "Context"       .Page
    "Source"        $source
    "Fit"           "100x100"
    "Target"        (print (partial "function-paths.html" "media") "/" $author "/")
    "Copy"          (print (partial "function-paths.html" "media") "/" $author "/react-" (path.Base $source))
    "AlternateCopy" (print (partial "function-paths.html" "media") "/" $author "/react-" (path.BaseName $source) ".webp")
  )
-}}

{{ $text | markdownify }} (<a title="{{ $title }}" href="{{ $image.Permalink }}">reaction</a>)