Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/calintat/minimal.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorJames Tharpe <james@brainbytescreative.com>2017-09-18 14:37:41 +0300
committerJames Tharpe <james@brainbytescreative.com>2017-09-18 14:37:41 +0300
commit6082ea0a59574c147d8385dcce7e99f1be0fc715 (patch)
tree91af81bffc7b7d5eb6ff1a0c8c9ca28eb6a6916f
parent1181f4a98c91cdae24dd5307519389d9b5e1e898 (diff)
parenta1b371cf9ca00a61c77176d7f9963d81dde2b948 (diff)
Merge branch 'master' of github.com:calintat/minimal
-rw-r--r--exampleSite/config.toml1
-rw-r--r--layouts/_default/single.html12
-rw-r--r--layouts/partials/header.html14
-rw-r--r--layouts/partials/js.html3
-rw-r--r--layouts/partials/list-item.html12
-rw-r--r--static/css/main.css4
6 files changed, 33 insertions, 13 deletions
diff --git a/exampleSite/config.toml b/exampleSite/config.toml
index 300e50d..ab5db12 100644
--- a/exampleSite/config.toml
+++ b/exampleSite/config.toml
@@ -2,6 +2,7 @@ baseURL = "http://example.com/"
languageCode = "en-us"
title = "Minimal"
theme = "minimal"
+disqusShortname = "username" # delete this to disable disqus comments
[params]
author = "Calin Tataru"
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
index b385aea..7a6ba5f 100644
--- a/layouts/_default/single.html
+++ b/layouts/_default/single.html
@@ -17,10 +17,14 @@
{{ end }}
-</main>
+ {{ if and .Site.DisqusShortname (not .Params.disableComments) }}
+
+ <h4 class="page-header">Comments</h4>
+
+ {{ template "_internal/disqus.html" . }}
-{{ if .Site.DisqusShortname }}
- {{ template "_internal/disqus.html" . }}
-{{ end }}
+ {{ end }}
+
+</main>
{{ partial "footer.html" . }}
diff --git a/layouts/partials/header.html b/layouts/partials/header.html
index 3d09225..5db3b6b 100644
--- a/layouts/partials/header.html
+++ b/layouts/partials/header.html
@@ -1,16 +1,14 @@
<!DOCTYPE html>
<html lang="{{ .Site.LanguageCode }}">
-
<head>
-
- <title>{{ .Title }}</title>
-
- {{ partial "css" . }} {{ partial "js" . }} {{ .Hugo.Generator }}
-
<meta charset="utf-8">
-
<meta name="viewport" content="width=device-width, initial-scale=1">
-
+ <title>{{ .Title }}</title>
+ {{ partial "css" . }} {{ partial "js" . }} {{ .Hugo.Generator }}
+ {{ if .RSSLink }}
+ <link href="{{ .RSSLink }}" rel="alternate" type="application/rss+xml" title="{{ .Site.Title }}" />
+ <link href="{{ .RSSLink }}" rel="feed" type="application/rss+xml" title="{{ .Site.Title }}" />
+ {{ end }}
</head>
<body>
diff --git a/layouts/partials/js.html b/layouts/partials/js.html
index c3fd50d..dcfe7ed 100644
--- a/layouts/partials/js.html
+++ b/layouts/partials/js.html
@@ -17,3 +17,6 @@
<!-- bootstrap -->
<script src="https://maxcdn.bootstrapcdn.com/bootstrap/3.3.7/js/bootstrap.min.js" integrity="sha384-Tc5IQib027qvyjSMfHjOMaLkfuWVxZxUPnCJA7l2mCWNIpG9mGCD8wGNIcPD7Txa" crossorigin="anonymous"></script>
+
+<!-- dismiss expanded navigation bar with click -->
+<script>$(document).on('click', function() { $('.collapse').collapse('hide'); })</script>
diff --git a/layouts/partials/list-item.html b/layouts/partials/list-item.html
index 3d6f795..93a993b 100644
--- a/layouts/partials/list-item.html
+++ b/layouts/partials/list-item.html
@@ -1,7 +1,17 @@
<div class="item">
{{ $.Scratch.Set "link" .RelPermalink }}
- {{ with .Params.repo }} {{ printf "https://github.com/%s/%s/" $.Site.Params.githubUsername . | $.Scratch.Set "link" }} {{ end }}
+ {{ with .Params.repo }}
+ {{ $repoHost := default "github" $.Params.repoHost }}
+ {{ if eq "github" $repoHost }}
+ {{ printf "https://github.com/%s/%s/" $.Site.Params.githubUsername . | $.Scratch.Set "link" }}
+ {{ else if eq "gitlab" $repoHost }}
+ {{ printf "https://gitlab.com/%s/%s/" $.Site.Params.gitlabUsername . | $.Scratch.Set "link" }}
+ {{ else if eq "bitbucket" $repoHost }}
+ {{ printf "https://bitbucket.org/%s/%s/" $.Site.Params.bitbucketUsername . | $.Scratch.Set "link" }}
+ {{ end }}
+ {{ end }}
+ {{ with .Params.link }} {{ $.Scratch.Set "link" . }} {{ end }}
{{ .Date.Format (.Site.Params.dateFormat | default "January 2, 2006") | $.Scratch.Set "subtitle" }}
{{ with .Description }} {{ $.Scratch.Set "subtitle" . }} {{ end }}
diff --git a/static/css/main.css b/static/css/main.css
index 726c843..70d8ac4 100644
--- a/static/css/main.css
+++ b/static/css/main.css
@@ -88,3 +88,7 @@ a:hover {
footer {
border-bottom: var(--border-width) solid var(--accent);
}
+
+img {
+ max-width: 100%;
+} \ No newline at end of file