mirror of
https://github.com/0rangebananaspy/authelia.git
synced 2024-09-14 22:47:21 +07:00
23 lines
660 B
HTML
23 lines
660 B
HTML
{{ $fillImage := .Scratch.Get "fillImageCard" }}
|
|
{{ if not $fillImage -}}
|
|
{{ $fillImage = site.Params.fillImage }}
|
|
{{ end -}}
|
|
|
|
{{ $image := .Resources.GetMatch (printf "**%s" (index .Params.images 0)) }}
|
|
{{ if not $image -}}
|
|
{{ $image = resources.Get (printf "%s%s" "images/" site.Params.defaultImage) }}
|
|
{{ end -}}
|
|
|
|
{{ $webp := printf "%s%s" $fillImage " webp" }}
|
|
{{ $image = $image.Resize $webp}}
|
|
|
|
{{ $lqip := $image.Resize site.Params.lqipWidth -}}
|
|
|
|
<img
|
|
class="card-img-top img-fluid lazyload blur-up"
|
|
src="{{ $lqip.Permalink }}"
|
|
data-src="{{ $image.Permalink }}"
|
|
width="{{ $image.Width }}"
|
|
height="{{ $image.Height }}"
|
|
alt="{{ .Title }}">
|