Add figure shortcode
This commit is contained in:
parent
dad0cf720e
commit
f3e437d0f2
1 changed files with 10 additions and 0 deletions
10
layouts/shortcodes/figure.html
Normal file
10
layouts/shortcodes/figure.html
Normal file
|
@ -0,0 +1,10 @@
|
|||
{{ if .Inner }}
|
||||
<figure>
|
||||
<img src='{{ .Get "src" }}' class='{{ .Get "class" }}' />
|
||||
<figcaption>
|
||||
<small>{{ .Inner }}</small>
|
||||
</figcaption>
|
||||
</figure>
|
||||
{{ else }}
|
||||
<img src='{{ .Get "src" }}' class='{{ .Get "class" }}' />
|
||||
{{ end }}
|
Loading…
Reference in a new issue