Restructures the templates
This commit is contained in:
parent
6b929ff8e0
commit
f4aa888a5c
14 changed files with 108 additions and 128 deletions
|
@ -1,14 +1,11 @@
|
|||
<!-- Disqus-->
|
||||
{{ if .Site.DisqusShortname -}}
|
||||
{{ if ne .Params.showcomments false }}
|
||||
{{- if and (not .Site.BuildDrafts) (ne .Params.showcomments false) -}}
|
||||
{{ if .Site.DisqusShortname -}}
|
||||
<hr>
|
||||
<h2>Comments</h2>
|
||||
{{ partial "commenting_disqus.html" . }}
|
||||
{{ end }}
|
||||
{{ else if .Site.Params.GraphCommentId -}}
|
||||
{{ if ne .Params.showcomments false }}
|
||||
{{- partial "commenting/disqus.html" . -}}
|
||||
{{- else if .Site.Params.GraphCommentId -}}
|
||||
<hr>
|
||||
<h2>Comments</h2>
|
||||
{{ partial "commenting_graph.html" . }}
|
||||
{{ end }}
|
||||
{{- end }}
|
||||
{{- partial "commenting/graphcomment.html" . -}}
|
||||
{{- end -}}
|
||||
{{- end }}
|
||||
|
|
|
@ -1,9 +1,9 @@
|
|||
<h1 class="title">{{ .Title }}</h1>
|
||||
<ul class="posts">
|
||||
{{ range .Data.Pages -}}
|
||||
{{- range .Data.Pages -}}
|
||||
<li>
|
||||
<span>
|
||||
<a href="{{ .Permalink }}">{{ .Title }}</a>
|
||||
<a href="{{ .RelPermalink }}">{{ .Title }}</a>
|
||||
{{ if not .Date.IsZero }}
|
||||
<time class="pull-right post-list">
|
||||
{{- .Date.Format (.Site.Params.dateformat | default "Jan 02, 2006") -}}
|
||||
|
|
|
@ -1,7 +1,7 @@
|
|||
{{ if .Site.Params.highlightjs -}}
|
||||
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/highlight.min.js"></script>
|
||||
{{ range .Site.Params.highlightjslanguages }}
|
||||
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/languages/{{.}}.min.js"></script>
|
||||
{{ with .Site.Params.highlightjslanguages }}
|
||||
<script src="//cdnjs.cloudflare.com/ajax/libs/highlight.js/9.12.0/languages/{{.}}.min.js"></script>
|
||||
{{ end }}
|
||||
<script type="text/javascript">
|
||||
hljs.configure({languages: []});
|
||||
|
|
|
@ -1,15 +1,16 @@
|
|||
{{ "<!-- Sidebar -->" | safeHTML }}
|
||||
<div class="sidebar">
|
||||
<div class="container text-center {{ if .Site.Params.sidebarSticky }}sidebar-sticky{{ end }}">
|
||||
<div class="sidebar-about text-center">
|
||||
<a href="{{ .Site.BaseURL }}"><h1 class="brand">{{ .Site.Title }}</h1></a>
|
||||
{{ with .Site.Params.authorimage }} <img src="{{.}}" alt="Author Image" class="img-circle headshot center"> {{ end }}
|
||||
{{ with .Site.Params.authorimage }} <img src="/{{.}}" alt="Author Image" class="img-circle headshot center"> {{ end }}
|
||||
<p class="lead">
|
||||
{{ with .Site.Params.description }} {{.}} {{ else }} Your site's description {{end}}
|
||||
</p>
|
||||
</div>
|
||||
{{ partial "sidebar_menu.html" . }}
|
||||
{{ partial "sidebar/menu.html" . }}
|
||||
<p>
|
||||
{{ partial "sidebar_social.html" . }}
|
||||
{{ partial "sidebar/social.html" . }}
|
||||
</p>
|
||||
<p class="copyright">{{ with .Site.Params.copyright }}{{.|safeHTML}}{{ else }}© {{ now.Format "2006"}} {{.Site.Params.author}}.
|
||||
<a href="https://creativecommons.org/licenses/by/4.0">Some Rights Reserved</a>.<br/>Built with <a href="https://gohugo.io/">Hugo</a> & <a href="https://github.com/htr3n/hyde-hyde">hyde-hyde</a>.{{end}}
|
||||
|
|
|
@ -1,19 +1,18 @@
|
|||
<!-- sidebar start -->
|
||||
<div>
|
||||
<ul class="sidebar-nav">
|
||||
{{ $currentPage := . }}
|
||||
{{ range .Site.Menus.main -}}
|
||||
{{- range .Site.Menus.main -}}
|
||||
{{ if .HasChildren -}}
|
||||
<li class="{{ if $currentPage.HasMenuCurrent "main" . }}active{{ end }}">
|
||||
<a href="#">{{ .Pre }}<span>{{ .Name }}</span></a>
|
||||
<ul class="sidebar-nav">
|
||||
{{ range .Children -}}
|
||||
{{- range .Children -}}
|
||||
<li class="{{ if $currentPage.IsMenuCurrent "main" . }}active{{ end }}">
|
||||
<a href="{{ .URL }}">{{ .Name | title }}</a>
|
||||
</li>
|
||||
{{- end -}}
|
||||
</ul>
|
||||
{{- else -}} <!-- No Children-->
|
||||
{{- else -}}
|
||||
<li>
|
||||
<a href="{{.URL}}">{{ .Pre }} <span>{{ .Name | title }}</span></a>
|
||||
</li>
|
|
@ -1,38 +1,38 @@
|
|||
<section class="row text-center">
|
||||
{{ with .Site.Params.social.twitter }}
|
||||
{{ with .Site.Params.social.twitter -}}
|
||||
<a href="https://twitter.com/{{.}}"><i class="fab fa-twitter fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{ with .Site.Params.social.facebook }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.facebook -}}
|
||||
<a href="https://facebook.com/{{.}}"><i class="fab fa-facebook-f"></i></a>
|
||||
{{ end }}
|
||||
{{ with .Site.Params.social.github }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.github -}}
|
||||
<a href="https://github.com/{{.}}"><i class="fab fa-github fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{ with .Site.Params.social.bitbucket }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.bitbucket -}}
|
||||
<a href="https://bitbucket.org/{{.}}"><i class="fab fa-bitbucket fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{ with .Site.Params.social.gitlab }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.gitlab -}}
|
||||
<a href="https://gitlab.com/{{.}}"><i class="fab fa-gitlab fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{ with .Site.Params.social.instagram }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.instagram -}}
|
||||
<a href="https://instagram.com/{{.}}"><i class="fab fa-instagram fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{ with .Site.Params.social.linkedin }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.linkedin -}}
|
||||
<a href="https://linkedin.com/in/{{.}}"><i class="fab fa-linkedin fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{ with .Site.Params.social.stackoverflow }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.stackoverflow -}}
|
||||
<a href="https://stackoverflow.com/users/{{.}}"><i class="fab fa-stack-overflow fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.medium}}
|
||||
<a href="https://medium.com/{{.}}"><i class="fab fa-medium fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{ with .Site.Params.social.xing }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.xing -}}
|
||||
<a href="https://www.xing.com/profile/{{.}}"><i class="fab fa-xing fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{ with .Site.Params.social.keybase }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.keybase -}}
|
||||
<a href="https://keybase.io/{{.}}"><i class="fab fa-keybase fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{ with .Site.Params.social.email }}
|
||||
{{- end }}
|
||||
{{ with .Site.Params.social.email -}}
|
||||
<a href="mailto:{{.}}"><i class="fas fa-at fa-lg" aria-hidden="true"></i></a>
|
||||
{{ end }}
|
||||
{{- end }}
|
||||
</section>
|
Loading…
Add table
Add a link
Reference in a new issue