Browse Source

Add social media links

master
Adrian Short 7 years ago
parent
commit
ef9989bbda
2 changed files with 33 additions and 1 deletions
  1. +22
    -1
      layouts/partials/header.html
  2. +11
    -0
      static/css/main.css

+ 22
- 1
layouts/partials/header.html View File

@@ -8,7 +8,7 @@
<link rel="stylesheet" href="{{ relURL "/css/main.css" }}">

{{- with .Type -}}
<link rel="stylesheet" href="{{ relURL "/css/" }}{{ . }}.css">
<link rel="stylesheet" href="{{ relURL "/css/" }}{{ . }}.css">
{{ end }}

<link rel="alternate" type="application/rss+xml" title="{{ partial "data/title" . }}"
@@ -17,7 +17,28 @@
{{ with .Params.image }}
<meta name="og:image" content="{{ "/images/" | absURL }}{{ .}}">
{{ end }}
{{- with .Site.Params.twitter -}}
<meta name="twitter:site" content="@{{ . }}">
{{- end -}}
{{ if not .Page.Params.via }}
<meta name="twitter:creator" content="@{{ .Site.Params.twitter }}">
{{ end }}
{{- template "_internal/twitter_cards.html" -}}
</head>
<body>
<h1 id="site-title"><a href="{{ relURL "/" }}">{{ .Site.Title }}</a></h1>
<ul id="site-social">
{{- with .Site.Params.email -}}
<li><a href="mailto:{{ . }}">{{ . }}</a></li>
{{- end -}}
{{- with .Site.Params.twitter -}}
<li><a href="https://twitter.com/{{ . }}">Twitter</a></li>
{{- end -}}
{{- with .Site.Params.medium -}}
<li><a href="https://medium.com/@{{ . }}">Medium</a></li>
{{- end -}}
{{- with .Site.Params.github -}}
<li><a href="https://github.com/{{ . }}">GitHub</a></li>
{{- end -}}
</ul>

+ 11
- 0
static/css/main.css View File

@@ -14,6 +14,17 @@ a:visited {
color: #777;
}

ul#site-social {
margin: 0;
}

ul#site-social li {
list-style-type: none;
display: inline;
margin: 0 10px 0 0;
color: #fff;
}

.quote {
font-family: monospace;
border: 0px #777 solid;


Loading…
Cancel
Save