First standalone version
This commit is contained in:
commit
9d22a63950
49 changed files with 1367 additions and 0 deletions
21
layouts/shortcodes/img.html
Normal file
21
layouts/shortcodes/img.html
Normal file
|
@ -0,0 +1,21 @@
|
|||
{{ $img := $.Page.Resources.GetMatch (.Get "src")}}
|
||||
{{ $test := $img.Permalink }}
|
||||
{{ $name_splitted := split $img.RelPermalink "." }}
|
||||
{{ $name_base := index $name_splitted 0 }}
|
||||
<figure {{ with .Get "class" }} class="{{ . }}"{{ end }}>
|
||||
{{ with .Get "link" }}
|
||||
<a href="{{ . }}">
|
||||
{{ end }}
|
||||
<picture>
|
||||
<source srcset="{{$img.RelPermalink}}" type="image/jpg">
|
||||
<img src="{{ $img.RelPermalink }}" alt="{{.Get "alt" }}" />
|
||||
</picture>
|
||||
{{ with .Get "link" }}
|
||||
</a>
|
||||
{{ end }}
|
||||
{{ with .Get "title" }}
|
||||
<figcaption>
|
||||
<p>{{ . }}</p>
|
||||
</figcaption>
|
||||
{{ end }}
|
||||
</figure>
|
Loading…
Add table
Add a link
Reference in a new issue