Move up figure caption by one position
This commit is contained in:
@@ -462,8 +462,8 @@ These are the named parameters with positions, listed in the order of their posi
|
|||||||
```go
|
```go
|
||||||
{{< paige/figure
|
{{< paige/figure
|
||||||
src="https://imgs.xkcd.com/comics/sandwich.png"
|
src="https://imgs.xkcd.com/comics/sandwich.png"
|
||||||
link="https://xkcd.com/149"
|
|
||||||
caption="My caption"
|
caption="My caption"
|
||||||
|
link="https://xkcd.com/149"
|
||||||
title="My title"
|
title="My title"
|
||||||
alt="My alt" >}}
|
alt="My alt" >}}
|
||||||
```
|
```
|
||||||
|
@@ -1,5 +1,5 @@
|
|||||||
<figure {{ if eq (.Get `inline`) true }} class="figure"{{ else }} class="align-items-center d-flex flex-column"{{ end }}>
|
<figure {{ if eq (.Get `inline`) true }} class="figure"{{ else }} class="align-items-center d-flex flex-column"{{ end }}>
|
||||||
{{ $link := .Get 1 | default (.Get `link`) }}
|
{{ $link := .Get 2 | default (.Get `link`) }}
|
||||||
{{ with $link }}
|
{{ with $link }}
|
||||||
<a href="{{ . }}">
|
<a href="{{ . }}">
|
||||||
{{ end }}
|
{{ end }}
|
||||||
@@ -14,7 +14,7 @@
|
|||||||
{{ if $link }}
|
{{ if $link }}
|
||||||
</a>
|
</a>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
{{ with (.Get 2 | default (.Get `caption`)) }}
|
{{ with (.Get 1 | default (.Get `caption`)) }}
|
||||||
<figcaption class="figure-caption">{{ . }}</figcaption>
|
<figcaption class="figure-caption">{{ . }}</figcaption>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
</figure>
|
</figure>
|
||||||
|
Reference in New Issue
Block a user