diff options
author | Renaud Hager <renaud.hager@gmail.com> | 2019-08-12 01:02:24 +0300 |
---|---|---|
committer | Renaud Hager <renaud.hager@gmail.com> | 2019-08-12 01:02:24 +0300 |
commit | c4bc1120fe765908f7c5c13f239a465e77719fc4 (patch) | |
tree | 591ec6716bb68cd4cc895365fd4744eae9d92f02 | |
parent | 781875e2ee424a4bc5dae3fdb3c32ac8cdbc38bb (diff) |
Added a possibility to display icons for socials items.
-rw-r--r-- | layouts/partials/home.html | 12 |
1 files changed, 11 insertions, 1 deletions
diff --git a/layouts/partials/home.html b/layouts/partials/home.html index 6c70cf4..2ee0cda 100644 --- a/layouts/partials/home.html +++ b/layouts/partials/home.html @@ -8,7 +8,17 @@ {{ with .Site.Params.social }} <ul> {{ range sort .}} - <li><a href="{{ .url }}">{{ .name }}</a></li> + {{ if .icon }} + <li> + <a href="{{ .url }}" aria-label="{{ .name }}" {{ if .rel }}rel="{{ .rel }}"{{ end }}> + <i class="{{ .icon }}" aria-hidden="true"></i> + </a> + </li> + {{ else }} + <li> + <a href="{{ .url }}" aria-label="{{ .name }}" {{ if .rel }}rel="{{ .rel }}"{{ end }}>{{ .name }}</a> + </li> + {{ end }} {{ end }} </ul> {{ end }} |