Allow icons for tags by setting "tagicons = true" in their config. (#126)

This commit is contained in:
Vighnesh Shenoy
2019-06-24 07:46:50 +05:30
committed by Michael Noronha
parent 403871be5e
commit 55588aeba1
2 changed files with 25 additions and 1 deletions

View File

@@ -23,7 +23,11 @@
{{ if not .Site.Params.noreadingtime }}
<div class="reading-time middot">{{ .ReadingTime }} minute read</div>
{{ end }}
<div class="tags">
{{ if .Site.Params.tagicons }}
<div class="tags tag-icons">
{{ else }}
<div class="tags">
{{ end }}
<ul>
{{ range .Params.tags }}
<li class="middot"><a href="{{ "/tags/" | relLangURL }}{{ . | urlize }}">{{ . }}</a> </li>

View File

@@ -359,6 +359,26 @@ div.main .content .front-matter .tags ul li:hover {
div.main .content .front-matter .tags ul li a {
color: #666666;
}
{{ if .Site.Params.tagicons }}
div.main .content .front-matter .tags.tag-icons .middot {
margin-left: 8px;
}
div.main .content .front-matter .tags.tag-icons .middot a {
display: inline-block;
padding: 0 5px;
background: #eee;
border-radius: 0 5px 5px 0;
position: relative;
}
div.main .content .front-matter .tags.tag-icons .middot a:after {
content: " ";
position: absolute;
right: 100%;
border-top: 11.2px solid transparent;
border-right: 11.2px solid #eee;
border-bottom: 11.2px solid transparent;
}
{{ end }}
div.main .container.f04 {
-webkit-justify-content: center;
-moz-justify-content: center;