Add option to not open the socials link on a new page, i.e. for an extra email page
I've added a ``nonewpage`` parameter to social links to avoid popping them open on a new page. This is useful, for example, for adding an email page that is resistant to scraping. As an example: `` [[params.social]] name = "email" url = "/email" nonewpage = true `` Where /email.md is a page that says something like ``domain at domain dot tld``.
This commit is contained in:
parent
51e697bea7
commit
04c8f86fdb
1 changed files with 1 additions and 1 deletions
|
@ -1,3 +1,3 @@
|
||||||
{{ range . -}}
|
{{ range . -}}
|
||||||
<a href="{{ .url }}" target="_blank" rel="me noopener {{ .rel }}" title="{{ .name | humanize }}">{{ partial "svg.html" . }}</a>
|
<a href="{{ .url }}" {{if eq .nonewpage 0}} target="_blank" {{end}} rel="me noopener {{ .rel }}" title="{{ .name | humanize }}">{{ partial "svg.html" . }}</a>
|
||||||
{{- end -}}
|
{{- end -}}
|
||||||
|
|
Loading…
Add table
Add a link
Reference in a new issue