Move theme from subrepo into the main repo
the theme is customized for this site so having it as a sub repo dosent make sense
This commit is contained in:
101
themes/hugo-theme-minos/layouts/partials/article.html
Normal file
101
themes/hugo-theme-minos/layouts/partials/article.html
Normal file
@@ -0,0 +1,101 @@
|
||||
<article class="article article-type-post" itemscope itemprop="blogPost">
|
||||
<div class="article-inner">
|
||||
{{ if .Title }}
|
||||
<header class="article-header">
|
||||
<h1 class="article-title" itemprop="name">{{ .Title }}</h1>
|
||||
</header>
|
||||
{{ end }}
|
||||
<div class="article-meta">
|
||||
{{- if not .Params.omitDate }}
|
||||
<a href="{{ .RelPermalink }}" class="article-date">
|
||||
<time datetime='{{ .Date.Format "2006-01-02T15:04:05.000-07:00" }}' itemprop="datePublished">{{ .Date.Format "2006-01-02" }}</time>
|
||||
</a>
|
||||
{{ end -}}
|
||||
{{ $Site := .Site }}
|
||||
{{ if .Params.categories }}
|
||||
<div class="post-categories">
|
||||
<div class="article-category">
|
||||
{{ range $i, $e := .Params.categories }}
|
||||
{{ if gt $i 0 }}
|
||||
<span>></span>
|
||||
{{ end }}
|
||||
<a class="article-category-link" href="{{ $Site.BaseURL }}/categories/{{ $e | urlize }}">{{ $e }}</a>
|
||||
{{ end }}
|
||||
</div>
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ if .Site.DisqusShortname }}
|
||||
<div class="article-comment-link-wrap">
|
||||
<a href="{{ .RelPermalink }}#disqus_thread" class="article-comment-link">Comments</a>
|
||||
</div>
|
||||
{{ end }}
|
||||
</div>
|
||||
<div class="article-entry" itemprop="articleBody">
|
||||
{{ .Content }}
|
||||
</div>
|
||||
|
||||
{{ if not .Params.notoc }}
|
||||
{{ if .TableOfContents }}
|
||||
<div class="article-toc" {{ if .Site.Params.SmartToc }}style="display:none;"{{ end }}>
|
||||
<h3>{{ T "Contents" }}</h3>
|
||||
{{ .TableOfContents }}
|
||||
</div>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
{{ if .Site.Params.SmartToc }}
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/jquery/3.1.1/jquery.slim.min.js" integrity="sha256-/SIrNqv8h6QGKDuNoLGA4iret+kyesCkHGzVUUV0shc=" crossorigin="anonymous"></script>
|
||||
<script>
|
||||
(function() {
|
||||
var $toc = $('#TableOfContents');
|
||||
if ($toc.length > 0) {
|
||||
var $window = $(window);
|
||||
|
||||
function onScroll(){
|
||||
var currentScroll = $window.scrollTop();
|
||||
var h = $('.article-entry h1, .article-entry h2, .article-entry h3, .article-entry h4, .article-entry h5, .article-entry h6');
|
||||
var id = "";
|
||||
h.each(function (i, e) {
|
||||
e = $(e);
|
||||
if (e.offset().top - 10 <= currentScroll) {
|
||||
id = e.attr('id');
|
||||
}
|
||||
});
|
||||
var active = $toc.find('a.active');
|
||||
if (active.length == 1 && active.eq(0).attr('href') == '#' + id) return true;
|
||||
|
||||
active.each(function (i, e) {
|
||||
$(e).removeClass('active').siblings('ul').hide();
|
||||
});
|
||||
$toc.find('a[href="#' + id + '"]').parentsUntil('#TableOfContents').each(function (i, e) {
|
||||
$(e).children('a').addClass('active').siblings('ul').show();
|
||||
});
|
||||
}
|
||||
|
||||
$window.on('scroll', onScroll);
|
||||
$(document).ready(function() {
|
||||
$toc.find('a').parent('li').find('ul').hide();
|
||||
onScroll();
|
||||
document.getElementsByClassName('article-toc')[0].style.display = '';
|
||||
});
|
||||
}
|
||||
})();
|
||||
</script>
|
||||
{{ end }}
|
||||
|
||||
|
||||
{{ if .Params.tags }}
|
||||
<footer class="article-footer">
|
||||
<ul class="article-tag-list">
|
||||
{{ range .Params.tags }}
|
||||
<li class="article-tag-list-item">
|
||||
<a class="article-tag-list-link" href="{{ "tags/" | absLangURL }}{{ . | urlize }}">{{ . }}
|
||||
</a>
|
||||
</li>
|
||||
{{ end }}
|
||||
</ul>
|
||||
</footer>
|
||||
{{ end }}
|
||||
</div>
|
||||
{{ partial "nav.html" . }}
|
||||
</article>
|
||||
40
themes/hugo-theme-minos/layouts/partials/footer.html
Normal file
40
themes/hugo-theme-minos/layouts/partials/footer.html
Normal file
@@ -0,0 +1,40 @@
|
||||
<footer id="footer">
|
||||
<div class="outer">
|
||||
<div id="footer-info" class="inner">
|
||||
© {{ now.Format "2006"}} {{ or .Site.Author.name .Site.Title }}
|
||||
<br />
|
||||
Powered by <a href="https://gohugo.io" target="_blank">Hugo</a> with theme <a href="https://github.com/carsonip/hugo-theme-minos" target="_blank">Minos</a>
|
||||
</div>
|
||||
<div>
|
||||
<p>
|
||||
<a href="https://web.archive.org/web/19970803104813/http://www.sun.com:80/" target="_blank"><img src="{{ .Site.Home.Permalink }}/img/sun.gif"/></a>
|
||||
<a href="https://sparkylinux.org" target="_blank"><img src="{{ .Site.Home.Permalink }}/img/linux_now.gif"/></a>
|
||||
<a href="https://neovim.io" target="_blank"><img src="{{ .Site.Home.Permalink }}/img/neovim.gif"/></a>
|
||||
<img src="{{ .Site.Home.Permalink }}/img/made_with_love.png"/>
|
||||
<a href="https://ChristianAnswers.Net/"><img src="https://ChristianAnswers.Net/btn-acan.gif" height="31" width="88" alt="Christian Answers Network home" /></a>
|
||||
</p>
|
||||
</div>
|
||||
</div>
|
||||
{{ template "_internal/google_analytics_async.html" . }}
|
||||
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.9.0/styles/tomorrow-night.min.css" integrity="sha256-2wL88NKUqvJi/ExflDzkzUumjUM73mcK2gBvBBeLvTk=" crossorigin="anonymous" />
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/highlight.js/9.9.0/highlight.min.js" integrity="sha256-KbfTjB0WZ8vvXngdpJGY3Yp3xKk+tttbqClO11anCIU=" crossorigin="anonymous"></script>
|
||||
<script>hljs.initHighlightingOnLoad();</script>
|
||||
|
||||
{{ if $.Param "katex" }}
|
||||
<link rel="stylesheet" href="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/katex.min.css" integrity="sha384-wITovz90syo1dJWVh32uuETPVEtGigN07tkttEqPv+uR2SE/mbQcG7ATL28aI9H0" crossorigin="anonymous">
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/katex.min.js" integrity="sha384-/y1Nn9+QQAipbNQWU65krzJralCnuOasHncUFXGkdwntGeSvQicrYkiUBwsgUqc1" crossorigin="anonymous"></script>
|
||||
<script src="https://cdnjs.cloudflare.com/ajax/libs/KaTeX/0.7.1/contrib/auto-render.min.js" integrity="sha256-ExtbCSBuYA7kq1Pz362ibde9nnsHYPt6JxuxYeZbU+c=" crossorigin="anonymous"></script>
|
||||
<script>renderMathInElement(document.body);</script>
|
||||
{{ end }}
|
||||
<script>
|
||||
document.getElementById('main-nav-toggle').addEventListener('click', function () {
|
||||
var header = document.getElementById('header');
|
||||
if (header.classList.contains('mobile-on')) {
|
||||
header.classList.remove('mobile-on');
|
||||
} else {
|
||||
header.classList.add('mobile-on');
|
||||
}
|
||||
});
|
||||
</script>
|
||||
</footer>
|
||||
24
themes/hugo-theme-minos/layouts/partials/head.html
Normal file
24
themes/hugo-theme-minos/layouts/partials/head.html
Normal file
@@ -0,0 +1,24 @@
|
||||
<!DOCTYPE html>
|
||||
<html>
|
||||
<head>
|
||||
<title>{{ .Title }}{{ if ne .Title .Site.Title }} // {{ .Site.Title }}{{ end }}</title>
|
||||
|
||||
{{ partial "meta.html" . }}
|
||||
{{ partial "og.html" . }}
|
||||
|
||||
{{- with .OutputFormats.Get "rss" -}}
|
||||
<link href="{{ .Permalink }}" rel="alternate" type="application/rss+xml" title="{{ $.Site.Title }}" />
|
||||
{{- end }}
|
||||
<link rel="shortcut icon" href="/favicon.ico">
|
||||
|
||||
<link href="{{ "webfonts/ptserif/main.css" | absURL }}" rel='stylesheet' type='text/css'>
|
||||
<link href="{{ "webfonts/source-code-pro/main.css" | absURL }}" rel="stylesheet" type="text/css">
|
||||
|
||||
<link rel="stylesheet" href="{{ "css/style.css" | absURL }}">
|
||||
{{ range .Site.Params.customCss -}}
|
||||
<link rel="stylesheet" href="{{ . | absURL }}">
|
||||
{{- end }}
|
||||
|
||||
|
||||
{{ hugo.Generator }}
|
||||
</head>
|
||||
17
themes/hugo-theme-minos/layouts/partials/header.html
Normal file
17
themes/hugo-theme-minos/layouts/partials/header.html
Normal file
@@ -0,0 +1,17 @@
|
||||
<header id="header">
|
||||
<div id="header-outer" class="outer">
|
||||
<div id="header-inner" class="inner">
|
||||
<a id="main-nav-toggle" class="nav-icon" href="javascript:;"></a>
|
||||
<a id="logo" class="logo-text" href="{{ .Site.Home.Permalink }}"><img src="{{ .Site.Home.Permalink }}home.png"/> {{ .Site.Title }}</a>
|
||||
<nav id="main-nav">
|
||||
{{ range .Site.Menus.main }}
|
||||
<a class="main-nav-link" href="{{ .URL }}">{{ .Name }}</a>
|
||||
{{ end }}
|
||||
</nav>
|
||||
<nav id="sub-nav">
|
||||
<div id="search-form-wrap">
|
||||
</div>
|
||||
</nav>
|
||||
</div>
|
||||
</div>
|
||||
</header>
|
||||
12
themes/hugo-theme-minos/layouts/partials/li.html
Normal file
12
themes/hugo-theme-minos/layouts/partials/li.html
Normal file
@@ -0,0 +1,12 @@
|
||||
<article class="archive-article archive-type-post">
|
||||
<div class="archive-article-inner">
|
||||
<header class="archive-article-header">
|
||||
<a href="{{ .RelPermalink }}" class="archive-article-date">
|
||||
<time datetime='{{ .Date.Format "2006-01-02T15:04:05.000-07:00" }}' itemprop="datePublished">{{ .Date.Format "2006 Jan 2" }}</time>
|
||||
</a>
|
||||
<h1 itemprop="name">
|
||||
<a class="archive-article-title" href="{{ .RelPermalink }}">{{ .Title }}</a>
|
||||
</h1>
|
||||
</header>
|
||||
</div>
|
||||
</article>
|
||||
8
themes/hugo-theme-minos/layouts/partials/meta.html
Normal file
8
themes/hugo-theme-minos/layouts/partials/meta.html
Normal file
@@ -0,0 +1,8 @@
|
||||
{{- $description := or (.Description) (.Site.Params.Description) -}}
|
||||
{{- $keywords := or (.Keywords) (.Site.Params.Keywords) -}}
|
||||
<meta charset="utf-8">
|
||||
<meta http-equiv="content-type" content="text/html; charset=utf-8">
|
||||
<meta name="viewport" content="width=device-width, initial-scale=1.0, maximum-scale=1">
|
||||
{{ with .Site.Params.Author -}}<meta name="author" content="{{ . }}">{{- end }}
|
||||
{{ if $description -}} <meta name="description" content="{{ $description }}"> {{- end }}
|
||||
{{ if $keywords -}} <meta name="keywords" content="{{ range $keywords }}{{ . }},{{ end }}"> {{- end }}
|
||||
16
themes/hugo-theme-minos/layouts/partials/nav.html
Normal file
16
themes/hugo-theme-minos/layouts/partials/nav.html
Normal file
@@ -0,0 +1,16 @@
|
||||
{{ if not .Site.Params.NoPostNavigation }}
|
||||
<nav id="article-nav">
|
||||
{{ if .NextPage }}
|
||||
<a href="{{ .NextPage.RelPermalink }}" id="article-nav-newer" class="article-nav-link-wrap">
|
||||
<div class="article-nav-title"><span><</span>
|
||||
{{ .NextPage.Title }}
|
||||
</div>
|
||||
</a>
|
||||
{{ end }}
|
||||
{{ if .PrevPage }}
|
||||
<a href="{{ .PrevPage.RelPermalink }}" id="article-nav-older" class="article-nav-link-wrap">
|
||||
<div class="article-nav-title">{{ .PrevPage.Title }} <span>></span></div>
|
||||
</a>
|
||||
{{ end }}
|
||||
</nav>
|
||||
{{ end }}
|
||||
8
themes/hugo-theme-minos/layouts/partials/og.html
Normal file
8
themes/hugo-theme-minos/layouts/partials/og.html
Normal file
@@ -0,0 +1,8 @@
|
||||
<meta property="og:title" content="{{ if .Params.ogtitle }}{{ .Params.ogtitle }}{{ else }}{{ .Title }}{{ end }}" />
|
||||
<meta property="og:description" content="{{ if .Params.ogdescription }}{{ .Params.ogdescription }}{{ else }}{{ .Site.Params.Description }}{{ end }}" />
|
||||
<meta property="og:type" content="website" />
|
||||
<meta property="og:locale" content="{{ .Lang }}" />
|
||||
<meta property="og:url" content="{{ .Permalink }}" />
|
||||
{{ if .Params.ogimage -}}
|
||||
<meta property="og:image" content="{{ .Params.ogimage }}" />
|
||||
{{- end }}
|
||||
19
themes/hugo-theme-minos/layouts/partials/pagination.html
Normal file
19
themes/hugo-theme-minos/layouts/partials/pagination.html
Normal file
@@ -0,0 +1,19 @@
|
||||
{{ $pag := $.Paginator }}
|
||||
{{ if gt $pag.TotalPages 1 }}
|
||||
<nav id="page-nav">
|
||||
{{ if $pag.HasPrev }}
|
||||
<a href="{{ $pag.Prev.URL }}" rel="prev" class="extend prev">« {{ T "Prev" }}</a>
|
||||
{{ end }}
|
||||
{{ range $pag.Pagers }}
|
||||
{{ if eq . $pag }}
|
||||
<span class="page-number current">{{ $pag.PageNumber }}</span>
|
||||
{{ else }}
|
||||
<a href="{{ .URL }}">{{ .PageNumber }}</a>
|
||||
{{ end }}
|
||||
{{ end }}
|
||||
|
||||
{{ if $pag.HasNext }}
|
||||
<a href="{{ $pag.Next.URL }}" rel="next" class="extend next">{{ T "Next" }} »</a>
|
||||
{{ end }}
|
||||
</nav>
|
||||
{{ end }}
|
||||
Reference in New Issue
Block a user