diff --git a/layouts/shortcodes/img-simple.html b/layouts/shortcodes/img-simple.html deleted file mode 100644 index 117bc81..0000000 --- a/layouts/shortcodes/img-simple.html +++ /dev/null @@ -1,7 +0,0 @@ -{{ $image := .Page.Resources.GetMatch (printf "*%s*" (.Get "src")) -}} -{{ $lqip := $image.Resize $.Site.Params.lqipWidth -}} -{{ if eq .Site.Params.options.lazySizes true -}} - -{{ else -}} - -{{ end -}} \ No newline at end of file diff --git a/layouts/shortcodes/img.html b/layouts/shortcodes/img.html deleted file mode 100644 index 51a6a9d..0000000 --- a/layouts/shortcodes/img.html +++ /dev/null @@ -1,27 +0,0 @@ -{{ $image := .Page.Resources.GetMatch (printf "*%s*" (.Get "src")) -}} -{{ $lqip := $image.Resize $.Site.Params.lqipWidth -}} - -{{ $imgSrc := "" -}} -{{ $imgSrcSet := slice -}} - -{{ $widths := $.Site.Params.landscapePhotoWidths -}} -{{ if gt $image.Height $image.Width -}} - {{ $widths = $.Site.Params.portraitPhotoWidths -}} -{{ end -}} - -{{ range $widths -}} - {{ $srcUrl := (printf "%dx" . | $image.Resize).Permalink -}} - {{ if eq $imgSrc "" -}}{{ $imgSrc = $srcUrl -}}{{ end -}} - {{ $imgSrcSet = $imgSrcSet | append (printf "%s %dw" $srcUrl .) -}} -{{ end -}} -{{ $imgSrcSet = (delimit $imgSrcSet ",") -}} - - - {{ if eq .Site.Params.options.lazySizes true -}} - - {{ else -}} - - {{ end -}} - - {{ with .Get "caption" }}
{{ . | safeHTML }}
{{ end }} -