Skip to content

Commit

Permalink
Merge branch 'develop'
Browse files Browse the repository at this point in the history
* develop:
  Fix #28 (Value should be inside double quotes)
  Add Roboto Mono as new font for code
  Update FontAwesome to version 5.14.0
  Update content links with relURL feature
  Delete taxnomoie settings for homepage.md
  • Loading branch information
dataCobra committed Aug 29, 2020
2 parents 9ec5e11 + 55c5428 commit 94a28ba
Show file tree
Hide file tree
Showing 11 changed files with 97 additions and 87 deletions.
4 changes: 2 additions & 2 deletions exampleSite/config.toml
Original file line number Diff line number Diff line change
Expand Up @@ -57,8 +57,8 @@ googleAnalytics = ""
# Deactivate Taxonomies for specific page types
#disableTaxoTypes = [""]

# Custom CSS applied to default styles. (Path is static/css/)
#customCSS = "custom.css"
# Custom CSS applied to default styles. (Path could be "static/css/")
#customCSS = "css/custom.css"

# Comments
[params.comments]
Expand Down
6 changes: 3 additions & 3 deletions layouts/_default/single.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,15 @@
<div class="post">
{{ if isset .Params "image" }}
<div class="post-image">
<img src="{{ .Params.image }}" {{ if isset .Params "imagetext" }}alt="{{ .Params.imagetext }}"{{ end }}>
<img src="{{ relURL .Params.image }}" {{ if isset .Params "imagetext" }}alt="{{ .Params.imagetext }}"{{ end }}>
</div>
{{ end }}
<div class="author">
{{ if eq .Site.Params.listAuthor true}}
{{ if isset .Params "author" }}
<p>
{{ if isset .Params "authorlink" }}
{{ i18n "authorpretext" }} <a href="{{ .Params.authorlink }}">{{ .Params.author }}</a>
{{ i18n "authorpretext" }} <a href="{{ relURL .Params.authorlink }}">{{ .Params.author }}</a>
{{ else }}
{{ i18n "authorpretext" }} {{ .Params.author }}
{{ end }}
Expand Down Expand Up @@ -53,7 +53,7 @@ <h1 class="title">{{ .Title }}</h1>
{{ range $key, $value := $taxonomy }}
{{ range $value.Pages }}
{{ if eq .LinkTitle $pagename }}
<a href="{{ .Site.BaseURL }}{{ $taxonomyname }}/{{ $key }}/"> {{ $key }} </a>
<a href="{{ relURL $taxonomyname }}/{{ $key }}/"> {{ $key }} </a>
{{ end }}
{{ end }}
{{ end }}
Expand Down
34 changes: 2 additions & 32 deletions layouts/index.html
Original file line number Diff line number Diff line change
Expand Up @@ -4,15 +4,15 @@
<div class="post">
{{ if isset .Params "image" }}
<div class="post-image">
<img src="{{ .Params.image }}" {{ if isset .Params "imagetext" }}alt="{{ .Params.imagetext }}"{{ end }}>
<img src="{{ relURL .Params.image }}" {{ if isset .Params "imagetext" }}alt="{{ .Params.imagetext }}"{{ end }}>
</div>
{{ end }}
<div class="author">
{{ if eq .Site.Params.listAuthor true}}
{{ if isset .Params "author" }}
<p>
{{ if isset .Params "authorlink" }}
{{ i18n "authorpretext" }} <a href="{{ .Params.authorlink }}">{{ .Params.author }}</a>
{{ i18n "authorpretext" }} <a href="{{ relURL .Params.authorlink }}">{{ .Params.author }}</a>
{{ else }}
{{ i18n "authorpretext" }} {{ .Params.author }}
{{ end }}
Expand All @@ -38,36 +38,6 @@ <h1 class="title">{{ .Title }}</h1>
<div class="markdown">
{{ .Content }}
</div>
{{ if ne (in .Site.Params.disableTaxoTypes .Type) true }}
{{ $pagename := .Page.Title }}
{{ $notaxo := .Params.notaxonomy }}
{{ range $taxonomyname, $taxonomy := .Site.Taxonomies }}
{{ with index $.Params $taxonomyname }}
{{ with ($.Site.GetPage (printf "/%s" $taxonomyname)) }}
{{ if in $notaxo $taxonomyname }}
{{ else }}
<div class="tags">
<div class="taxosfloating_left">
<p>{{ $taxonomyname | humanize }}</p>
</div>
<div class="termsfloating_right">
<p>
{{ range $key, $value := $taxonomy }}
{{ range $value.Pages }}
{{ if eq .LinkTitle $pagename }}
<a href="/{{ $taxonomyname }}/{{ $key }}/"> {{ $key }} </a>
{{ end }}
{{ end }}
{{ end }}
</p>
</div>
<div class="clearit"></div>
{{ end }}
{{ end }}
{{ end }}
{{ end }}
{{ end }}
</div>
{{- if eq .Site.Params.comments.enabled true -}}
{{- $.Scratch.Set "comments" true -}}
{{- if and (isset .Params "type") (in .Site.Params.comments.disableOnTypes .Params.type) -}}
Expand Down
18 changes: 9 additions & 9 deletions layouts/partials/head.html
Original file line number Diff line number Diff line change
Expand Up @@ -20,26 +20,26 @@
{{- template "_internal/twitter_cards.html" . -}}
<!-- If favicon is true in config use the favicon files-->
{{- if eq .Site.Params.favicon true -}}
<link rel="icon" type="image/png" href="/favicon-32x32.png" sizes="32x32">
<link rel="icon" type="image/png" href="/favicon-16x16.png" sizes="16x16">
<link rel="icon" type="image/png" href="{{ relURL "/favicon-32x32.png" }}" sizes="32x32">
<link rel="icon" type="image/png" href="{{ relURL "/favicon-16x16.png" }}" sizes="16x16">
{{- end -}}
<!-- Add rss+xml functionality -->
{{- with .OutputFormats.Get "rss" -}}
{{ printf `<link rel="%s" type="%s" href="%s" title="%s">` .Rel .MediaType.Type .Permalink $.Site.Title | safeHTML }}
{{- end -}}
<!-- Add all css files that are necessary -->
<link rel="stylesheet" type="text/css" media="screen" href="{{ .Site.BaseURL }}css/normalize.css" />
<link rel="stylesheet" type="text/css" media="screen" href="{{ .Site.BaseURL }}css/main.css" />
<link rel="stylesheet" type="text/css" media="screen" href="{{ .Site.BaseURL }}css/all.css" />
<link rel="stylesheet" type="text/css" media="screen" href="{{ relURL "/css/normalize.css" }}" />
<link rel="stylesheet" type="text/css" media="screen" href="{{ relURL "/css/main.css" }}" />
<link rel="stylesheet" type="text/css" media="screen" href="{{ relURL "/css/all.css" }}" />
<!-- Add math typesetting with KaTeX if math is set -->
{{- if or .Params.math .Site.Params.math -}}
<link rel="stylesheet" href="{{ .Site.BaseURL }}css/katex.min.css" crossorigin="anonymous">
<script defer src="{{ .Site.BaseURL }}js/katex.min.js" integrity="sha384-y23I5Q6l+B6vatafAwxRu/0oK/79VlbSz7Q9aiSZUvyWYIYsd+qj+o24G5ZU2zJz" crossorigin="anonymous"></script>
<script defer src="{{ .Site.BaseURL }}js/auto-render.min.js" integrity="sha384-kWPLUVMOks5AQFrykwIup5lo0m3iMkkHrD0uJ4H5cjeGihAutqP0yW0J6dpFiVkI" crossorigin="anonymous" onload="renderMathInElement(document.body);"></script>
<link rel="stylesheet" href="{{ relURL "/css/katex.min.css" }}" crossorigin="anonymous">
<script defer src="{{ relURL "js/katex.min.js" }}" integrity="sha384-y23I5Q6l+B6vatafAwxRu/0oK/79VlbSz7Q9aiSZUvyWYIYsd+qj+o24G5ZU2zJz" crossorigin="anonymous"></script>
<script defer src="{{ relURL "js/auto-render.min.js" }}" integrity="sha384-kWPLUVMOks5AQFrykwIup5lo0m3iMkkHrD0uJ4H5cjeGihAutqP0yW0J6dpFiVkI" crossorigin="anonymous" onload="renderMathInElement(document.body);"></script>
{{- end -}}
<!-- Use customcss if you like -->
{{- if isset .Site.Params "customcss" -}}
<link rel="stylesheet" type="text/css" media="screen" href="{{ .Site.BaseURL }}css/{{ .Site.Params.customCSS }}" />
<link rel="stylesheet" type="text/css" media="screen" href="{{ relURL .Site.Params.customCSS }}" />
{{- end -}}
<!-- Use a SEO friendly title tag-->
{{- if .IsHome -}}
Expand Down
6 changes: 3 additions & 3 deletions layouts/partials/header.html
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,7 @@
{{ if .Site.Params.Avatar }}
<div id="avatar">
<a href="{{ .Site.BaseURL }}">
<img src="{{ .Site.Params.Avatar }}" alt="{{ .Site.Title }}">
<img src="{{ relURL .Site.Params.Avatar }}" alt="{{ .Site.Title }}">
</a>
</div>
{{ end }}
Expand All @@ -17,11 +17,11 @@ <h2 id="title"><a href="{{ .Site.BaseURL }}">{{ .Site.Title }}</a></h2>
{{- if isset .Site.Params "subtitle" -}}
<p id="subtitle">{{ .Site.Params.Subtitle | markdownify }}</p>
{{- end -}}
<div id=social>
<div id="social">
<nav>
<ul>
{{- range $index, $key := .Site.Params.Social -}}
<li><a href="{{ $key.url }}"><i title="{{ $key.name }}" class="icons {{ $key.icon }}"></i></a></li>
<li><a href="{{ relURL $key.url }}"><i title="{{ $key.name }}" class="icons {{ $key.icon }}"></i></a></li>
{{- end -}}
</ul>
</nav>
Expand Down
Loading

0 comments on commit 94a28ba

Please sign in to comment.