Add optional 'class' attribute to image shortcode
This commit is contained in:
parent
41d1444b3a
commit
e79e038b51
|
@ -1,4 +1,4 @@
|
|||
<figure>
|
||||
<img src="{{ .Get "src" }}" alt="{{ .Get "alt" }}">
|
||||
<img{{ with .Get "class" }} class="{{ . }}"{{ end }} src="{{ .Get "src" }}" alt="{{ .Get "alt" }}">
|
||||
<figcaption>{{ .Get "alt" }}</figcaption>
|
||||
</figure>
|
||||
|
|
Loading…
Reference in New Issue