Remove style.css; put all styles in app.css; add post_figure shortcode

This commit is contained in:
Eryn Wells 2021-10-11 17:33:17 -07:00
parent 5aabf75702
commit 8c8f97a607
4 changed files with 57 additions and 48 deletions

View file

@ -16,7 +16,6 @@
{{ end }}
<link rel="preload stylesheet" as="style" href="/app.css" />
<link rel="preload stylesheet" as="style" href="/style.css" />
{{ if .IsHome }}
<link rel="preload stylesheet" as="style" href="/home.css" />
{{ end }}
@ -30,9 +29,6 @@
></script>
{{ end }}
<!-- Preload -->
<link rel="preload" as="image" href="{{ `theme.png` | absURL }}" />
{{ range $.Scratch.Get "social-list" }}
<link rel="preload" as="image" href="{{ printf `%s.svg` . | absURL }}" />
{{ end }}

View file

@ -0,0 +1,12 @@
<figure>
{{ $img := (.Page.Resources.GetMatch (.Get "name")) }}
{{ $resized_img := $img.Fit "576x576" }}
<a href="{{ $img.RelPermalink }}">
<img src="{{ $resized_img.RelPermalink }}" />
</a>
<figcaption>
{{ if $img.Title }}
<h4>{{ $img.Title }}</h4>
{{ end }}
</figcaption>
</figure>