mirror of
https://github.com/thegeeklab/hugo-geekdoc.git
synced 2024-11-18 02:40:39 +00:00
16 lines
351 B
HTML
16 lines
351 B
HTML
|
{{ $ref := "" }}
|
||
|
{{ $target := "" }}
|
||
|
|
||
|
{{ with .Get "href" }}
|
||
|
{{ $ref = . }}
|
||
|
{{ $target = "_blank" }}
|
||
|
{{ end }}
|
||
|
|
||
|
{{ with .Get "relref" }}
|
||
|
{{ $ref = relref $ . }}
|
||
|
{{ end }}
|
||
|
|
||
|
<a {{ with $ref }} href="{{.}}" {{ end }} {{ with $target }} target="{{.}}" {{ end }} class="gdoc-btn{{ with .Get "class" }} {{ . }}{{ end }}">
|
||
|
{{ $.Inner }}
|
||
|
</a>
|