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

github.com/htr3n/hyde-hyde.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorHuy Tran <hoang.huy.tran@gmail.com>2018-06-06 04:24:24 +0300
committerGitHub <noreply@github.com>2018-06-06 04:24:24 +0300
commitea1fcd379a235832d5a103c6a2d1cadc108db93d (patch)
treeafd1443a504af7cc6554adc9e2324668245924ee
parent5665044a9484e3fed9a7564bd83f70ba70b4d4f0 (diff)
parent4a0dd77a0bcaab5c19c51133fed4ab2e6c6538da (diff)
Merge pull request #10 from tun/masterv1.0.0
Improvements for layoutReverse and sidebarSticky
-rw-r--r--exampleSite/config.toml4
-rw-r--r--layouts/_default/baseof.html4
-rw-r--r--layouts/partials/sidebar.html36
-rw-r--r--static/css/hyde.css4
4 files changed, 25 insertions, 23 deletions
diff --git a/exampleSite/config.toml b/exampleSite/config.toml
index 2afbf10..5143036 100644
--- a/exampleSite/config.toml
+++ b/exampleSite/config.toml
@@ -19,7 +19,9 @@ theme = "hyde-hyde"
highlightjs = true
# highlightjsstyle = "github"
# please choose either GraphComment or Disqus
- # GraphCommentId = "your-graph-comment-id"
+ # GraphCommentId = "your-graph-comment-id"
+ # layoutReverse = true
+ # sidebarSticky = true
## Social Accounts
[params.social]
diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html
index 7cacb9f..42e4538 100644
--- a/layouts/_default/baseof.html
+++ b/layouts/_default/baseof.html
@@ -3,7 +3,7 @@
<head>
{{ block "header" . -}}{{- end }}
</head>
- <body {{- if .Site.Params.themeColor }} class="{{ .Site.Params.themeColor }} {{if .Site.Params.layoutReverse}}layout-reverse{{end}}" {{ end }}>
+ <body class="{{- if .Site.Params.themeColor }}{{ .Site.Params.themeColor }}{{ end }} {{if .Site.Params.layoutReverse}}layout-reverse{{end}}">
{{ partial "sidebar.html" . }}
<div class="content container">
{{ block "content" . }}{{ end }}
@@ -14,6 +14,6 @@
<!-- Google Analytics -->
{{ if .Site.GoogleAnalytics -}}
{{ template "_internal/google_analytics_async.html" . }}
- {{- end }}
+ {{- end }}
</body>
</html>
diff --git a/layouts/partials/sidebar.html b/layouts/partials/sidebar.html
index 7027a50..b7ae794 100644
--- a/layouts/partials/sidebar.html
+++ b/layouts/partials/sidebar.html
@@ -1,20 +1,20 @@
<div class="sidebar">
- <div class="container text-center sidebar-sticky">
- <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 }}
- <p class="lead">
- {{ with .Site.Params.description }} {{.}} {{ else }} Your site's description {{end}}
- </p>
- </div>
- {{ partial "sidebar_menu.html" . }}
- <p>
- {{ partial "sidebar_social.html" . }}
- </p>
- <p class="copyright">{{ with .Site.Params.copyright }}{{.}}{{ else }}&copy; {{ 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> &amp; <a href="https://github.com/htr3n/hyde-hyde">hyde-hyde</a>.{{end}}
- </p>
- </div>
- <div>
- </div>
+ <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 }}
+ <p class="lead">
+ {{ with .Site.Params.description }} {{.}} {{ else }} Your site's description {{end}}
+ </p>
+ </div>
+ {{ partial "sidebar_menu.html" . }}
+ <p>
+ {{ partial "sidebar_social.html" . }}
+ </p>
+ <p class="copyright">{{ with .Site.Params.copyright }}{{.|safeHTML}}{{ else }}&copy; {{ 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> &amp; <a href="https://github.com/htr3n/hyde-hyde">hyde-hyde</a>.{{end}}
+ </p>
+ </div>
+ <div>
+ </div>
</div>
diff --git a/static/css/hyde.css b/static/css/hyde.css
index 46cc0ae..3c30818 100644
--- a/static/css/hyde.css
+++ b/static/css/hyde.css
@@ -121,7 +121,7 @@ a.sidebar-nav-item:focus {
.sidebar-sticky {
position: absolute;
right: 1rem;
- top: 1rem;
+ bottom: 1rem;
left: 1rem;
}
}
@@ -167,7 +167,7 @@ a.sidebar-nav-item:focus {
display:inline;
vertical-align: bottom;
}
-
+
.badges {
float: right;
}