summaryrefslogtreecommitdiff
path: root/layouts/partials/blog/cross-site-post.html
blob: 7684410462285f1be25bcda8adbb51c2dc78c957 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26

<article class="link">
  {{- $img := resources.Get "blog/assets/arrow.gif" }}
  {{- $img1x := $img.Resize "32x webp" }}
  {{- $img2x := $img.Resize "64x webp" }}
  <div class="img">
  <a href="{{ .Permalink }}"><img
                               alt="Arrow"
                               loading="lazy"
                               src="{{ $img1x.Permalink }}" 
                               srcset="
                                       {{ $img1x.Permalink }} 1x,
                                       {{ $img2x.Permalink }} 2x
                                       "
                               width="{{ $img1x.Width }}" 
                               height="{{ $img1x.Height }}"
                               ></a>
  </div>
  <div class="text">
    <time datetime="{{.PublishDate.Format "2006-01-02" }}">
      {{ .PublishDate.Format "January 2, 2006" }}
    </time><br>
    
    {{ partial "external_link" . }}
  </div>
</article>