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

github.com/vickylaixy/hugo-theme-introduction.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--layouts/404.html37
-rw-r--r--layouts/_default/baseof.html35
-rw-r--r--layouts/_default/list.html43
-rw-r--r--layouts/_default/single.html37
-rw-r--r--layouts/_default/taxonomy.html43
-rw-r--r--layouts/_default/terms.html32
-rw-r--r--layouts/blog/list.html76
-rw-r--r--layouts/blog/single.html113
-rw-r--r--layouts/index.html195
-rw-r--r--layouts/partials/footer.html27
-rw-r--r--layouts/partials/footer/scripts.html21
-rw-r--r--layouts/partials/footer/text.html11
-rw-r--r--layouts/partials/head/css.html15
-rw-r--r--layouts/partials/head/favicons.html2
-rw-r--r--layouts/partials/head/metadata.html24
-rw-r--r--layouts/partials/header.html64
-rw-r--r--layouts/partials/home/blog.html (renamed from layouts/partials/blogsection.html)0
-rw-r--r--layouts/partials/home/projects.html (renamed from layouts/partials/projects.html)23
-rw-r--r--layouts/partials/home/social.html (renamed from layouts/partials/social.html)0
-rw-r--r--layouts/partials/li.html3
-rw-r--r--layouts/partials/nav.html8
-rw-r--r--layouts/projects/list.html67
-rw-r--r--layouts/projects/single.html14
-rw-r--r--static/js/index.js22
24 files changed, 399 insertions, 513 deletions
diff --git a/layouts/404.html b/layouts/404.html
index c70b17e..a4f98ab 100644
--- a/layouts/404.html
+++ b/layouts/404.html
@@ -1,26 +1,13 @@
-{{ partial "header.html" . }}
-<body>
-<!-- Parent section -->
-<div class="section" id="top">
- <!-- Begin Title -->
- <div class="container hero is-medium has-text-centered {{ if .Site.Params.fadeIn }} fade-in one {{ end }}">
- <h1 class="bold-title is-1">
- {{ i18n "404_title" . }}
- </h1>
+{{ define "title" }}
+ <h1 class="bold-title is-1">{{ i18n "404_title" . }}</h1>
+{{ end }}
+
+{{ define "main" }}
+ <div class="container markdown top-pad">
+ {{ i18n "404_description" . | markdownify }}
</div>
- <!-- End Title -->
- <!-- Everything below fades in two! -->
- <div class="section {{ if .Site.Params.fadeIn }} fade-in two {{ end }}">
- {{ partial "nav.html" . }}
- <!-- Begin blurb -->
- <div class="container {{ if .Site.Params.fadeIn }} fade-in two {{ end }} top-pad">
- {{ i18n "404_description" . | markdownify }}
- </div>
- <!-- End blurb -->
- <div class="container top-pad">
- <hr>
- </div>
- </div>
- {{ partial "footer.html" . }}
-</div>
-<!-- End parent section -->
+{{ end }}
+
+{{ define "footer" }}
+ {{ partial "footer/text.html" . }}
+{{ end }}
diff --git a/layouts/_default/baseof.html b/layouts/_default/baseof.html
new file mode 100644
index 0000000..c3f6407
--- /dev/null
+++ b/layouts/_default/baseof.html
@@ -0,0 +1,35 @@
+<!DOCTYPE html>
+<html lang="{{ .Site.LanguageCode }}">
+ <head>
+ {{ block "head" . }}
+ {{ partial "head/metadata.html" . }}
+ {{ partial "head/favicons.html" . }}
+ {{ partial "head/css.html" . }}
+ {{ end }}
+ </head>
+ <body>
+ <div class="section" id="top">
+ <!-- Begin Title -->
+ <div class="container hero {{ if .Site.Params.fadeIn | default true }} fade-in one {{ end }}">
+ {{ block "title" . }}
+ <h1 class="bold-title is-1">{{ .Title }}</h1>
+ {{ end }}
+ </div>
+ <!-- End Title -->
+ <div class="section {{ if .Site.Params.fadeIn | default true }} fade-in two {{ end }}">
+ {{ partial "nav.html" . }}
+
+ {{ block "main" . }}
+ {{ end }}
+
+ {{ block "footer" . }}
+ {{ partial "top-icon-with-hr.html" . }}
+ {{ partial "footer/text.html" . }}
+ {{ end }}
+ </div>
+ </div>
+ {{ block "js-include" . }}
+ {{ partial "footer/scripts.html" . }}
+ {{ end }}
+ </body>
+</html>
diff --git a/layouts/_default/list.html b/layouts/_default/list.html
index a43cdb6..f102ef5 100644
--- a/layouts/_default/list.html
+++ b/layouts/_default/list.html
@@ -1,33 +1,16 @@
-{{ partial "header.html" . }}
-<body>
-<!-- Parent section -->
-<div class="section" id="top">
- <!-- Begin Title -->
- <div class="container hero {{ if .Site.Params.fadeIn }} fade-in one {{ end }}">
- <h1 class="bold-title is-1">{{ .Title }}</h1>
+{{ define "main" }}
+ <div class="container markdown top-pad">
+ {{ .Content }}
</div>
- <!-- End Title -->
- <!-- Everything below fades in two! -->
- <div class="section no-padding {{ if .Site.Params.fadeIn }} fade-in two {{ end }}">
- {{ partial "nav.html" . }}
- <div class="container markdown {{ if .Site.Params.fadeIn | default true }}fade-in two{{ end }} top-pad">
- {{ .Content }}
- </div>
- <!-- Begin container -->
- <div class="container">
- <ul>
- {{ range .Pages.ByPublishDate }}
- <li>
- <a href="{{.Permalink}}">{{.Date.Format (.Site.Params.dateform | default "Jan 02, 2006") }} | {{.Title}}</a>
- </li>
- {{ end }}
- </ul>
- </div>
- <!-- End container -->
- {{ partial "top-icon-with-hr.html" . }}
- {{ partial "footer.html" . }}
+ <!-- Begin container -->
+ <div class="container">
+ <ul>
+ {{ range .Pages.ByPublishDate }}
+ <li>
+ <a href="{{.Permalink}}">{{.Date.Format (.Site.Params.dateform | default "Jan 02, 2006") }} | {{.Title}}</a>
+ </li>
+ {{ end }}
+ </ul>
</div>
- <!-- End fade in two -->
-</div>
-<!-- End parent section -->
</body>
+{{ end }}
diff --git a/layouts/_default/single.html b/layouts/_default/single.html
index 2c8f5d8..2b7793f 100644
--- a/layouts/_default/single.html
+++ b/layouts/_default/single.html
@@ -1,32 +1,9 @@
-{{ partial "header.html" . }}
-<body>
-<!-- Parent section -->
-<div class="section" id="top">
- <!-- Begin Title -->
- <div class="container hero {{ if .Site.Params.fadeIn }} fade-in one {{ end }}">
- <h1 class="bold-title is-1">{{ .Title }}</h1>
+{{ define "main" }}
+ <div class="container markdown top-pad">
+ {{ .Content }}
</div>
- <!-- End Title -->
- <!-- Everything below fades in two! -->
- <div class="section {{ if .Site.Params.fadeIn }} fade-in two {{ end }}">
- {{ partial "nav.html" . }}
- <!-- Begin post content -->
- <div class="container markdown {{ if .Site.Params.fadeIn }} fade-in two {{ end }} top-pad">
- {{ if .Params.image }}
- <div class="has-text-centered">
- <img src="{{ .Params.image | relURL }}" class="img-responsive" alt="{{ .Title }}">
- </div>
- {{ end }}
- {{ .Content }}
- </div>
- <!-- End post content -->
- <div class="disqus">
- {{ template "_internal/disqus.html" . }}
- </div>
- {{ partial "top-icon-with-hr.html" . }}
- {{ partial "footer.html" . }}
+ <!-- End post content -->
+ <div class="disqus">
+ {{ template "_internal/disqus.html" . }}
</div>
- <!-- End fade in two -->
-</div>
-<!-- End parent section -->
-</body>
+{{ end }}
diff --git a/layouts/_default/taxonomy.html b/layouts/_default/taxonomy.html
index 5ce80cd..786676b 100644
--- a/layouts/_default/taxonomy.html
+++ b/layouts/_default/taxonomy.html
@@ -1,33 +1,18 @@
-{{ partial "header.html" . }}
-<body>
-<!-- Parent section -->
-<div class="section" id="top">
- <!-- Begin Title -->
- <div class="container hero {{ if .Site.Params.fadeIn }} fade-in one {{ end }}">
- <h1 class="bold-title is-1">Tagged "{{ lower .Title }}"</h1>
- </div>
- <!-- End Title -->
- <!-- Everything below fades in two! -->
- <div class="section no-padding {{ if .Site.Params.fadeIn }} fade-in two {{ end }}">
- {{ partial "nav.html" . }}
+{{ define "title" }}
+ <h1 class="bold-title is-1">Tagged "{{ lower .Title }}"</h1>
+{{ end }}
+
+{{ define "main" }}
+ <div class="container">
<article>
{{ .Content }}
</article>
- <!-- Begin Blog container -->
- <div class="container">
- <ul>
- {{ range .Pages.ByPublishDate }}
- <li>
- <a href="{{.Permalink}}">{{.Date.Format (.Site.Params.dateform | default "Jan 02, 2006") }} | {{.Title}}</a>
- </li>
- {{ end }}
- </ul>
- </div>
- <!-- End Blog container -->
- {{ partial "top-icon-with-hr.html" . }}
- {{ partial "footer.html" . }}
+ <ul>
+ {{ range .Pages.ByPublishDate }}
+ <li>
+ <a href="{{.Permalink}}">{{.Date.Format (.Site.Params.dateform | default "Jan 02, 2006") }} | {{.Title}}</a>
+ </li>
+ {{ end }}
+ </ul>
</div>
- <!-- End fade in two -->
-</div>
-<!-- End parent section -->
-</body>
+{{ end }}
diff --git a/layouts/_default/terms.html b/layouts/_default/terms.html
index ee7ac1f..9a9a796 100644
--- a/layouts/_default/terms.html
+++ b/layouts/_default/terms.html
@@ -1,30 +1,12 @@
-{{ partial "header.html" . }}
-<body>
-<!-- Parent section -->
-<div class="section" id="top">
- <!-- Begin Title -->
- <div class="container hero {{ if .Site.Params.fadeIn }} fade-in one {{ end }}">
- <h1 class="bold-title is-1">{{ .Title }}</h1>
- </div>
- <!-- End Title -->
-
- <!-- Everything below fades in two! -->
- <div class="section no-padding {{ if .Site.Params.fadeIn }} fade-in two {{ end }}">
- {{ partial "nav.html" . }}
+{{ define "main" }}
+ <div class="container">
<article>
{{ .Content }}
</article>
- <div class="container">
- <div class="section tags-list">
- {{ range $name, $taxonomy := .Site.Taxonomies.tags }}
- <a class="tag-cloud" href="{{"tags/" | relLangURL }}{{ $name | urlize }}">{{ lower $name }} ({{ len $taxonomy }})</a>
- {{ end }}
- </div>
+ <div class="section tags-list">
+ {{ range $name, $taxonomy := .Site.Taxonomies.tags }}
+ <a class="tag-cloud" href="{{"tags/" | relLangURL }}{{ $name | urlize }}">{{ lower $name }}&nbsp;({{ len $taxonomy }})</a>
+ {{ end }}
</div>
- {{ partial "top-icon-with-hr.html" . }}
- {{ partial "footer.html" . }}
</div>
- <!-- End fade in two -->
-</div>
-<!-- End parent section -->
-</body>
+{{ end }}
diff --git a/layouts/blog/list.html b/layouts/blog/list.html
index 9c162f7..fe351b6 100644
--- a/layouts/blog/list.html
+++ b/layouts/blog/list.html
@@ -1,50 +1,34 @@
-{{ partial "header.html" . }}
-<body>
-<!-- Parent section -->
-<div class="section" id="top">
- <!-- Begin Title -->
- <div class="container hero {{ if .Site.Params.fadeIn | default true }}fade-in one{{ end }}">
- <h1 class="bold-title is-1">{{ .Title }}</h1>
+{{ define "main" }}
+ <div class="container markdown top-pad">
+ {{ .Content }}
</div>
- <!-- End Title -->
- <!-- Everything below fades in two! -->
- <div class="section no-padding {{ if .Site.Params.fadeIn | default true }}fade-in two{{ end }}">
- {{ partial "nav.html" . }}
- <div class="container markdown {{ if .Site.Params.fadeIn | default true }}fade-in two{{ end }} top-pad">
- {{ .Content }}
- </div>
- <!-- Begin Blog container -->
- <div class="container">
- {{ if .Site.Params.showLatest }}
- <h2 class="title is-2 top-pad">{{ i18n "index_blog_latestPosts" . }}</h2>
- {{ range first 1 .Pages.ByPublishDate.Reverse }}
- <div class="summary">{{ .Date.Format (.Site.Params.dateForm | default "Jan 02, 2006") }}
- <h3 class="title is-3 strong-post-title">
- <a href="{{ .RelPermalink }}">
- {{ .Title }}
- </a>
- </h3>
- <div class="markdown">
- {{ .Summary }}
- {{ if .Truncated }}
- <a href="{{ .RelPermalink }}">{{ i18n "index_blog_readMore" . }}</a>
- {{ end }}
- </div>
+ <div class="container">
+ {{ if .Site.Params.showLatest }}
+ <h2 class="title is-2 top-pad">{{ i18n "index_blog_latestPosts" . }}</h2>
+ {{ range first 1 .Pages.ByPublishDate.Reverse }}
+ <div class="summary">{{ .Date.Format (.Site.Params.dateForm | default "Jan 02, 2006") }}
+ <h3 class="title is-3 strong-post-title">
+ <a href="{{ .RelPermalink }}">
+ {{ .Title }}
+ </a>
+ </h3>
+ <div class="markdown">
+ {{ .Summary }}
+ {{ if .Truncated }}
+ <a href="{{ .RelPermalink }}">{{ i18n "index_blog_readMore" . }}</a>
+ {{ end }}
</div>
- {{ end }}
- {{ end }}
- <h2 class="title is-2 top-pad">{{ i18n "index_blog_allPosts" . }}</h2>
- <ul>
- {{ range .Pages.ByPublishDate.Reverse }}
- {{ partial "li.html" . }}
- {{ end }}
- </ul>
</div>
- <!-- End Blog container -->
- {{ partial "top-icon-with-hr.html" . }}
- {{ partial "footer.html" . }}
+ {{ end }}
+
+ {{ end }}
+ <h2 class="title is-2 top-pad">{{ i18n "index_blog_allPosts" . }}</h2>
+ <ul>
+ {{ range .Pages.ByPublishDate.Reverse }}
+ <li class="post-item">
+ <span><a href="{{ .Permalink }}">{{ .Title }}</a></span> - <span>{{ .Date.Format (.Site.Params.dateform | default "Jan 02, 2006") }}</span>
+ </li>
+ {{ end }}
+ </ul>
</div>
- <!-- End fade in two -->
-</div>
-<!-- End parent section -->
-</body>
+{{ end }}
diff --git a/layouts/blog/single.html b/layouts/blog/single.html
index 6a24536..273dcdc 100644
--- a/layouts/blog/single.html
+++ b/layouts/blog/single.html
@@ -1,67 +1,52 @@
-{{ partial "header.html" . }}
-<body>
-<!-- Parent section -->
-<div class="section" id="top">
- <!-- Begin Title -->
- <div class="container hero {{ if .Site.Params.fadeIn | default true }}fade-in one{{ end }}">
- <h1 class="bold-title is-1">{{ (.Site.GetPage "section" "blog").Title }}</h1>
- </div>
- <!-- End Title -->
- <!-- Everything below fades in two! -->
- <div class="section {{ if .Site.Params.fadeIn | default true }}fade-in two{{ end }}">
- {{ partial "nav.html" . }}
- <!-- Begin blog title container -->
- <div class="container {{ if .Site.Params.fadeIn | default true }}fade-in two{{ end }}">
- <h2 class="title is-1 top-pad strong-post-title">
- <a href="{{ .Permalink }}">{{ .Title }}</a>
- </h2>
- <div class="post-data">
- {{ .Date.Format (.Site.Params.dateForm | default "Jan 02, 2006") }} |
- {{ i18n "blog_readingTime" .ReadingTime }}
- </div>
- {{ if .Site.Params.shareButtons }}
- <div class="blog-share">
- {{ i18n "blog_shareThis" . }}:
- {{ if .Site.Params.shareTwitter }}
- <a class="twitter-share-button" href="https://twitter.com/intent/tweet?text=Read%20{{ .Title }}%20{{ .Permalink }}" onclick="window.open(this.href, 'twitter-share', 'width=550,height=235');return false;">
- <i class="fa fa-twitter"></i>
- <span class="hidden">Twitter</span>
- </a>
- {{ end }}
- {{ if .Site.Params.shareFacebook }}
- <a class="icon-facebook" href="https://www.facebook.com/sharer/sharer.php?u={{ .Permalink }}" onclick="window.open(this.href, 'facebook-share','width=580,height=296');return false;">
- <i class="fa fa-facebook"></i>
- <span class="hidden">Facebook</span>
- </a>
- {{ end }}
- {{ if .Site.Params.sharePinterest }}
- <a class="icon-pinterest" href="http://pinterest.com/pin/create/button/?url={{ .Permalink }}{{ if .Params.pinterestMedia }}&amp;media={{ .Site.BaseURL }}{{ .Params.pinterestMedia }}{{ end }}&amp;description={{ .Title | safeHTML}}" onclick="window.open(this.href, 'pinterest-share','width=580,height=296');return false;">
- <i class="fa fa-pinterest"></i>
- <span class="hidden">Pinterest</span>
- </a>
- {{ end }}
- {{ if .Site.Params.shareGooglePlus }}
- <a class="icon-google-plus" href="https://plus.google.com/share?url={{ .Permalink }}" onclick="window.open(this.href, 'google-plus-share', 'width=490,height=530');return false;">
- <i class="fa fa-google-plus"></i>
- <span class="hidden">Google+</span>
- </a>
- {{ end }}
- </div>
- {{ end }}
- </div>
- <!-- End blog title container -->
- <!-- Begin blog post content -->
- <div class="container markdown {{ if .Site.Params.fadeIn | default true }}fade-in two{{ end }} top-pad">
- {{ .Content }}
+{{ define "title" }}
+ <h1 class="bold-title is-1">{{ (.Site.GetPage "section" "blog").Title }}</h1>
+{{ end }}
+
+{{ define "main" }}
+ <div class="container">
+ <h2 class="title is-1 top-pad strong-post-title">
+ <a href="{{ .Permalink }}">{{ .Title }}</a>
+ </h2>
+ <div class="post-data">
+ {{ .Date.Format (.Site.Params.dateForm | default "Jan 02, 2006") }} |
+ {{ i18n "blog_readingTime" .ReadingTime }}
</div>
- <!-- End blog post content -->
- <div class="disqus">
- {{ template "_internal/disqus.html" . }}
+ {{ if .Site.Params.shareButtons }}
+ <div class="blog-share">
+ {{ i18n "blog_shareThis" . }}:
+ {{ if .Site.Params.shareTwitter }}
+ <a class="twitter-share-button" href="https://twitter.com/intent/tweet?text=Read%20{{ .Title }}%20{{ .Permalink }}" onclick="window.open(this.href, 'twitter-share', 'width=550,height=235');return false;">
+ <i class="fa fa-twitter"></i>
+ <span class="hidden">Twitter</span>
+ </a>
+ {{ end }}
+ {{ if .Site.Params.shareFacebook }}
+ <a class="icon-facebook" href="https://www.facebook.com/sharer/sharer.php?u={{ .Permalink }}" onclick="window.open(this.href, 'facebook-share','width=580,height=296');return false;">
+ <i class="fa fa-facebook"></i>
+ <span class="hidden">Facebook</span>
+ </a>
+ {{ end }}
+ {{ if .Site.Params.sharePinterest }}
+ <a class="icon-pinterest" href="http://pinterest.com/pin/create/button/?url={{ .Permalink }}{{ if .Params.pinterestMedia }}&amp;media={{ .Site.BaseURL }}{{ .Params.pinterestMedia }}{{ end }}&amp;description={{ .Title | safeHTML}}" onclick="window.open(this.href, 'pinterest-share','width=580,height=296');return false;">
+ <i class="fa fa-pinterest"></i>
+ <span class="hidden">Pinterest</span>
+ </a>
+ {{ end }}
+ {{ if .Site.Params.shareGooglePlus }}
+ <a class="icon-google-plus" href="https://plus.google.com/share?url={{ .Permalink }}" onclick="window.open(this.href, 'google-plus-share', 'width=490,height=530');return false;">
+ <i class="fa fa-google-plus"></i>
+ <span class="hidden">Google+</span>
+ </a>
+ {{ end }}
</div>
- {{ partial "top-icon-with-hr.html" . }}
- {{ partial "footer.html" . }}
+ {{ end }}
+ </div>
+ <!-- Begin blog post content -->
+ <div class="container markdown top-pad">
+ {{ .Content }}
+ </div>
+ <!-- End blog post content -->
+ <div class="disqus">
+ {{ template "_internal/disqus.html" . }}
</div>
- <!-- End fade in two -->
-</div>
-<!-- End parent section -->
-</body>
+{{ end }}
diff --git a/layouts/index.html b/layouts/index.html
index 3b8faaf..6d20825 100644
--- a/layouts/index.html
+++ b/layouts/index.html
@@ -1,110 +1,91 @@
-{{ partial "header.html" . }}
-<body>
-
-<div id="top"> <!-- Where all the awesome begins -->
-
-<div class="hero is-{{ .Site.Params.introHeight | default "fullheight" }}">
-<!-- Possible hero-head not used -->
- <!-- Super sweet Hero body title -->
- <div class="hero-body">
- <div class="container has-text-centered">
- <!-- Title and tagline -->
- <h1 class="bold-title {{ if .Site.Params.fadeIn | default true }}fade-in one{{ end }}">
- {{ .Site.Params.firstName | default "Introduction" }}.
- </h1>
- <h3 class="subtitle is-3 {{ if .Site.Params.fadeIn | default true }}fade-in two{{ end }}">
- {{ .Site.Params.tagLine }}
- </h3>
- <!-- End title and tagline -->
- <!-- Some social icons -->
- <div class=" {{ if .Site.Params.fadeIn | default true }}fade-in three{{ end }}">
- {{ partial "social.html" . }}
+<!DOCTYPE html>
+<html lang="{{ .Site.LanguageCode }}">
+ <head>
+ {{ partial "head/metadata.html" . }}
+ {{ partial "head/favicons.html" . }}
+ {{ partial "head/css.html" . }}
+ </head>
+ <body>
+ <div id="top">
+ <div class="hero is-{{ .Site.Params.introHeight | default "fullheight" }}">
+ <!-- Super sweet Hero body title -->
+ <div class="hero-body">
+ <div class="container has-text-centered">
+ <!-- Title and tagline -->
+ <h1 class="bold-title {{ if .Site.Params.fadeIn | default true }}fade-in one{{ end }}">
+ {{ .Site.Params.firstName | default "Introduction" }}.
+ </h1>
+ <h3 class="subtitle is-3 {{ if .Site.Params.fadeIn | default true }}fade-in two{{ end }}">
+ {{ .Site.Params.tagLine }}
+ </h3>
+ <!-- End title and tagline -->
+ <!-- Some social icons -->
+ <div class=" {{ if .Site.Params.fadeIn | default true }}fade-in three{{ end }}">
+ {{ partial "home/social.html" . }}
+ </div>
+ <!-- End top social icons -->
+ </div>
+ </div>
+ <!-- Hero body title end -->
</div>
- <!-- End top social icons -->
- </div>
- </div>
- <!-- Hero body title end -->
-
- <div class="hero-foot {{ if .Site.Params.fadeIn | default true }}fade-in three{{ end }}">
- {{ partial "nav.html" . }}
- </div>
-</div>
-<!-- Done with Hero -->
-
-<!-- Everything below fades in three! -->
-<div class="section no-padding {{ if .Site.Params.fadeIn | default true }}fade-in three{{ end }}">
-
-<!-- Tell them all about it! -->
-{{ with .Site.GetPage "page" "about" }}
-<div class="section" id="{{ .Title | urlize }}">
- <div class="container">
- <h2 class="title is-2 has-text-centered">{{ .Title }}</h2>
- <div class="columns"><!-- Avatar and about.md side by side except mobile -->
- {{ if .Site.Params.avatar }}
- <div class="column is-one-third has-text-centered">
- <img class="img-responsive avatar" src="{{ .Site.Params.avatar | relURL }}" alt="{{ i18n "index_avatarAlt" . }}">
- </div>
- {{ end }}
- <div class="column markdown">
- {{.Content}}
+ <!-- Done with Hero -->
+ <!-- Everything below fades in three! -->
+ <div class="section no-padding {{ if .Site.Params.fadeIn | default true }}fade-in three{{ end }}">
+ <!-- Tell them all about it! -->
+ {{ partial "nav.html" . }}
+ {{ with .Site.GetPage "page" "about" }}
+ <div class="section" id="{{ .File.TranslationBaseName }}">
+ <div class="container">
+ <h2 class="title is-2 has-text-centered">{{ .Title }}</h2>
+ <div class="columns"><!-- Avatar and about.md side by side except mobile -->
+ {{ if .Site.Params.avatar }}
+ <div class="column is-one-third has-text-centered">
+ <img class="img-responsive avatar" src="{{ .Site.Params.avatar | relURL }}" alt="{{ i18n "index_avatarAlt" . }}">
+ </div>
+ {{ end }}
+ <div class="column markdown">
+ {{.Content}}
+ </div>
+ </div>
+ </div>
+ <!-- End About container-->
+ {{ partial "top-icon.html" . }}
+ </div>
+ <div class="container"><hr></div>
+ <!-- End About section -->
+ {{ end }}
+ <!-- Now for some cool projects -->
+ {{ partial "home/projects.html" . }}
+ <!-- Let's show some blog posts -->
+ {{ partial "home/blog.html" . }}
+ <!-- Let's chat, shall we? -->
+ {{ with .Site.GetPage "page" "contact" }}
+ <div class="section" id="{{ .File.TranslationBaseName }}">
+ <div class="container has-text-centered">
+ <h2 class="title is-2">{{ .Title }}</h2>
+ <div class="markdown">
+ {{.Content}}
+ </div>
+ {{ if .Site.Params.localTime }}
+ <p>{{ i18n "index_currentTime" . }} <span id='time'></span>.</p>
+ {{ end }}
+ {{ if .Site.Params.email }}
+ <h3 class="subtitle is-3 has-text-centered top-pad">
+ <a href="mailto:{{ .Site.Params.email }}">{{ .Site.Params.email }}</a>
+ </h3>
+ {{ end }}
+ {{ partial "home/social.html" . }}
+ </div>
+ <!-- End Contact container -->
+ {{ partial "top-icon.html" . }}
+ </div>
+ <div class="container"><hr></div>
+ {{ end }}
+ <!-- End Contact section -->
+ {{ partial "footer/text.html" . }}
</div>
</div>
- </div>
- <!-- End About container-->
- {{ partial "top-icon.html" . }}
-</div>
-<!-- End About section -->
-
-<div class="container"><hr></div>
-{{ end }}
-
-<!-- Now for some cool projects -->
-{{ partial "projects.html" . }}
-
-<!-- Let's show some blog posts -->
-{{ partial "blogsection.html" . }}
-
-<!-- Let's chat, shall we? -->
-{{ with .Site.GetPage "page" "contact" }}
-<div class="section" id="{{ .Title | urlize }}">
- <div class="container has-text-centered">
- <h2 class="title is-2">{{ .Title }}</h2>
- <div class="markdown">
- {{.Content}}
- </div>
-
- {{ if .Site.Params.localTime }}
- <p>{{ i18n "index_currentTime" . }} <span id='time'></span>.</p>
- <script type="text/javascript" src="{{ "/js/moment.js" | relURL }}"></script>
- <script type="text/javascript" src="{{ "/js/moment-timezone.js" | relURL }}"></script>
- <script type="text/javascript" src="{{ "/js/moment-timezone-with-data-2012-2022.js" | relURL }}"></script>
-
- <script>
- $(document).ready(function() {
- var time = moment().tz("{{ .Site.Params.timeZone }}").format("h:mm A");
- $('#time').html(time);
- })
- </script>
- {{ end }}
-
- {{ if .Site.Params.email }}
- <h3 class="subtitle is-3 has-text-centered top-pad"><a href="mailto:{{ .Site.Params.email }}">{{ .Site.Params.email }}</a></h3>
- {{ end }}
-
- {{ partial "social.html" . }}
- </div>
- <!-- End Contact container -->
- {{ partial "top-icon.html" . }}
-</div>
-<!-- End Contact section -->
-
-<div class="container"><hr></div>
-{{ end }}
-
-<!-- Nice clean finish -->
-{{ partial "footer.html" . }}
-<!-- Footer done! -->
-</div>
-<!-- End of fade in three section -->
-<!-- Where all the awesome ends. Aww. -->
-</body>
+ <!-- End of fade in three section -->
+ {{ partial "footer/scripts.html" . }}
+ </body>
+</html>
diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html
deleted file mode 100644
index 1668009..0000000
--- a/layouts/partials/footer.html
+++ /dev/null
@@ -1,27 +0,0 @@
-<!-- Begin Footer section -->
-<div class="section" id="footer">
- <!-- Begin Footer container -->
- <div class="container has-text-centered">
- {{ with .Site.Params.footerText }}
- {{ . | markdownify }}
- {{ else }}
- <span class="footer-text">
- {{ i18n "footer_text" . | markdownify }}
- </span>
- {{ end }}
- </div>
- <!-- End Footer container -->
-</div>
-<!-- End Footer section -->
-
-<!-- Bitty scrolling links script -->
-<script>
-$('a[href^="#"]').click(function(e) {
- e.preventDefault();
- var target = this.hash;
- $('html, body').animate({
- scrollTop: $(target).offset().top
- }, 500);
- return false;
-})
-</script>
diff --git a/layouts/partials/footer/scripts.html b/layouts/partials/footer/scripts.html
new file mode 100644
index 0000000..5989686
--- /dev/null
+++ b/layouts/partials/footer/scripts.html
@@ -0,0 +1,21 @@
+<!-- jQuery -->
+<script type="text/javascript" src="{{ "/js/jquery-3.3.1.min.js" | relURL }}"></script>
+
+<!-- index.js -->
+<script type="text/javascript" src="{{ "/js/index.js" | relURL }}"></script>
+
+<!-- local time -->
+{{ if .Site.Params.localTime }}
+<script type="text/javascript" src="{{ "/js/moment.js" | relURL }}"></script>
+<script type="text/javascript" src="{{ "/js/moment-timezone.js" | relURL }}"></script>
+<script type="text/javascript" src="{{ "/js/moment-timezone-with-data-2012-2022.js" | relURL }}"></script>
+<script>
+ $(document).ready(function() {
+ var time = moment().tz("{{ .Site.Params.timeZone }}").format("h:mm A");
+ $('#time').html(time);
+ })
+</script>
+{{ end }}
+
+<!-- Google Analytics -->
+{{ template "_internal/google_analytics_async.html" . }}
diff --git a/layouts/partials/footer/text.html b/layouts/partials/footer/text.html
new file mode 100644
index 0000000..c356329
--- /dev/null
+++ b/layouts/partials/footer/text.html
@@ -0,0 +1,11 @@
+<div class="section" id="footer">
+ <div class="container has-text-centered">
+ {{ with .Site.Params.footerText }}
+ {{ . | markdownify }}
+ {{ else }}
+ <span class="footer-text">
+ {{ i18n "footer_text" . | markdownify }}
+ </span>
+ {{ end }}
+ </div>
+</div>
diff --git a/layouts/partials/head/css.html b/layouts/partials/head/css.html
new file mode 100644
index 0000000..2813437
--- /dev/null
+++ b/layouts/partials/head/css.html
@@ -0,0 +1,15 @@
+<!-- Fonts and icon CSS -->
+<link rel="stylesheet" href="{{ "/css/font-awesome.min.css" | relURL }}">
+<link rel="stylesheet" href="{{ "/css/nunito_sans.css" | relURL }}">
+
+<!-- Main css -->
+{{ if .Site.Params.cacheBuster }}
+ <link rel="stylesheet" href="{{ (printf "css/%s-style.css?t=%d" (.Site.Params.themeStyle | default "dark") now.Unix) |relURL }}">
+{{ else }}
+ <link rel="stylesheet" href="{{ (printf "css/%s-style.css" .Site.Params.themeStyle | default "dark") | relURL }}">
+{{ end }}
+
+<!-- Custom css -->
+{{ range .Site.Params.customCSS -}}
+ <link rel="stylesheet" href="{{ . | relURL }}">
+{{- end }}
diff --git a/layouts/partials/head/favicons.html b/layouts/partials/head/favicons.html
new file mode 100644
index 0000000..c6813e9
--- /dev/null
+++ b/layouts/partials/head/favicons.html
@@ -0,0 +1,2 @@
+<!-- Icon -->
+<link rel="shortcut icon" href="{{ .Site.Params.faviconFile | default "img/favicon.ico" | relURL }}">
diff --git a/layouts/partials/head/metadata.html b/layouts/partials/head/metadata.html
new file mode 100644
index 0000000..1d97aa2
--- /dev/null
+++ b/layouts/partials/head/metadata.html
@@ -0,0 +1,24 @@
+<meta charset="utf-8">
+<meta http-equiv="X-UA-Compatible" content="chrome=1">
+<meta name="HandheldFriendly" content="True">
+<meta name="MobileOptimized" content="320">
+<meta name="viewport" content="width=device-width, initial-scale=1.0">
+<meta name="referrer" content="no-referrer">
+{{ if .Site.Params.description }}<meta name="description" content="{{ .Site.Params.description }}">{{ end }}
+<title>
+{{ .Title }}{{ if ne .Title .Site.Title }} - {{ .Site.Title }}{{ end }}
+</title>
+<!-- RSS -->
+{{ if .RSSLink }}
+ <link href="{{ .RSSLink }}" rel="alternate" type="application/rss+xml" title="{{ .Site.Title }}" />
+{{ end }}
+<!-- HTTPS -->
+{{ if .Site.Params.enforce_ssl }}
+<script type="text/javascript">
+ var baseURL = '{{ .Site.BaseURL }}';
+ var host = baseURL.substring(0, baseURL.length - 1).replace(/\//g, '');
+ if ((host === window.location.host) && (window.location.protocol !== 'https:')) {
+ window.location.protocol = 'https:';
+ }
+</script>
+{{ end }}
diff --git a/layouts/partials/header.html b/layouts/partials/header.html
deleted file mode 100644
index 82ff72b..0000000
--- a/layouts/partials/header.html
+++ /dev/null
@@ -1,64 +0,0 @@
-<!DOCTYPE html>
-<html lang="{{ .Site.LanguageCode }}">
-
-<head>
-<meta charset="utf-8">
-<meta http-equiv="X-UA-Compatible" content="chrome=1">
-<meta name="HandheldFriendly" content="True">
-<meta name="MobileOptimized" content="320">
-<meta name="viewport" content="width=device-width, initial-scale=1.0">
-<meta name="referrer" content="no-referrer">
-{{ if .Site.Params.description }}<meta name="description" content="{{ .Site.Params.description }}">{{ end }}
-
-<title>
-{{ $url := replace .Permalink ( printf "%s" .Site.BaseURL) "" }}
-{{ if eq $url "/" }}
- {{ .Site.Title }}
-{{ else }}
- {{ if .Params.heading }} {{ .Params.heading }} {{ else }} {{ .Title }} {{ end }}
-{{ end }}
-</title>
-<link rel="canonical" href="{{ .Permalink }}">
-
-<!-- HTTPS -->
-
-{{ if .Site.Params.enforce_ssl }}
-<script type="text/javascript">
- var baseURL = '{{ .Site.BaseURL }}';
- var host = baseURL.substring(0, baseURL.length - 1).replace(/\//g, '');
- if ((host === window.location.host) && (window.location.protocol !== 'https:')) {
- window.location.protocol = 'https:';
- }
-</script>
-{{ end }}
-
-<!-- jQuery -->
-<script type="text/javascript" src="{{ "/js/jquery-3.3.1.min.js" | relURL }}"></script>
-
-<!-- Fonts and icon CSS -->
-<link rel="stylesheet" href="{{ "/css/font-awesome.min.css" | relURL }}">
-<link rel="stylesheet" href="{{ "/css/nunito_sans.css" | relURL }}">
-
-{{ if .Site.Params.cacheBuster }}
- <link rel="stylesheet" href="{{ (printf "css/%s-style.css?t=%d" (.Site.Params.themeStyle | default "dark") now.Unix) |relURL }}">
-{{ else }}
- <link rel="stylesheet" href="{{ (printf "css/%s-style.css" .Site.Params.themeStyle | default "dark") | relURL }}">
-{{ end }}
-
-<!-- Custom css -->
-{{ range .Site.Params.customCSS -}}
- <link rel="stylesheet" href="{{ . | relURL }}">
-{{- end }}
-
-<!-- Icon -->
-<link rel="shortcut icon" href="{{ .Site.Params.faviconFile | default "img/favicon.ico" | relURL }}">
-
-<!-- Google Analytics -->
-{{ template "_internal/google_analytics_async.html" . }}
-
-<!-- RSS -->
-{{ if .RSSLink }}
- <link href="{{ .RSSLink }}" rel="alternate" type="application/rss+xml" title="{{ .Site.Title }}" />
-{{ end }}
-
-</head>
diff --git a/layouts/partials/blogsection.html b/layouts/partials/home/blog.html
index bb323c9..bb323c9 100644
--- a/layouts/partials/blogsection.html
+++ b/layouts/partials/home/blog.html
diff --git a/layouts/partials/projects.html b/layouts/partials/home/projects.html
index 4a09ca6..8e2c057 100644
--- a/layouts/partials/projects.html
+++ b/layouts/partials/home/projects.html
@@ -41,8 +41,9 @@
</div>
<!-- End Projects container -->
<!-- Projects modals -->
- {{ range $index, $element := .Pages.ByWeight | first $numberOfProjectsToShow }} {{ if not .Params.external_link }}
- <div class="modal" id="modal-{{ $index }}">
+ {{ range $index, $element := .Pages.ByWeight | first $numberOfProjectsToShow }}
+ {{ if not .Params.external_link }}
+ <div class="modal" id="project-{{ $index }}">
<div class="modal-background"></div>
<div class="modal-card">
{{ with .Title }}
@@ -59,22 +60,10 @@
</section>
{{ end }}
</div>
- <button class="modal-close is-large" aria-label="close" id="close-{{ $index }}"></button>
+ <button class="modal-close is-large" aria-label="close"></button>
</div>
- <script>
- $('#project-{{ $index }}').click(function () {
- $('#modal-{{ $index }}').addClass('is-active');
- });
- $('#close-{{ $index }}').click(function () {
- $('#modal-{{ $index }}').removeClass('is-active');
- });
- $(document).keypress(function(e) {
- if(e.which == 0) {
- $('#modal-{{ $index }}').removeClass('is-active');
- }
- });
- </script>
- {{ end }} {{ end }}
+ {{ end }}
+ {{ end }}
{{ partial "top-icon.html" . }}
</div>
<!-- End Projects section -->
diff --git a/layouts/partials/social.html b/layouts/partials/home/social.html
index 6092ab1..6092ab1 100644
--- a/layouts/partials/social.html
+++ b/layouts/partials/home/social.html
diff --git a/layouts/partials/li.html b/layouts/partials/li.html
deleted file mode 100644
index 1e26736..0000000
--- a/layouts/partials/li.html
+++ /dev/null
@@ -1,3 +0,0 @@
-<li class="post-item">
- <span><a href="{{ .Permalink }}">{{ .Title }}</a></span> - <span>{{ .Date.Format (.Site.Params.dateform | default "Jan 02, 2006") }}</span>
-</li>
diff --git a/layouts/partials/nav.html b/layouts/partials/nav.html
index e6cf4c9..f358b9b 100644
--- a/layouts/partials/nav.html
+++ b/layouts/partials/nav.html
@@ -3,19 +3,19 @@
<hr>
<nav class="nav nav-center">
{{ $isHome := .Page.IsHome }}
- {{ if not $isHome }}
+ {{/* if not $isHome */}}
<span id="nav-toggle" class="nav-toggle" onclick="document.getElementById('nav-menu').classList.toggle('is-active');">
<span></span>
<span></span>
<span></span>
</span>
<div id="nav-menu" class="nav-left nav-menu">
- {{ end }}
+ {{/* end */}}
{{ if not $isHome }}
<a class="nav-item" href="{{ "/" | relLangURL }}">{{ i18n "nav_main" . }}</a>
{{ end }}
{{ with .Site.GetPage "page" "about" }}
- <a class="nav-item" href="{{ if $isHome }}#{{ .Title | urlize }}{{ else }}{{ printf "/#%s" (.Title | urlize) | relLangURL }}{{ end }}">{{ .Title }}</a>
+ <a class="nav-item" href="{{ if $isHome }}#{{ .File.TranslationBaseName }}{{ else }}{{ printf "/#%s" .File.TranslationBaseName | relLangURL }}{{ end }}">{{ .Title }}</a>
{{ end }}
{{ $pageIsInProjects := eq .Page.Section "projects"}}
@@ -53,7 +53,7 @@
{{ end }}
{{ with .Site.GetPage "page" "contact" }}
- <a class="nav-item" href="{{ if $isHome }}#{{ .Title | urlize }}{{ else }}{{ printf "/#%s" (.Title | urlize) | relLangURL }}{{ end }}">{{ .Title }}</a>
+ <a class="nav-item" href="{{ if $isHome }}#{{ .File.TranslationBaseName }}{{ else }}{{ printf "/#%s" .File.TranslationBaseName | relLangURL }}{{ end }}">{{ .Title }}</a>
{{ end }}
{{ range $.Site.Home.AllTranslations.ByWeight }}
diff --git a/layouts/projects/list.html b/layouts/projects/list.html
index 61ecf2c..1977c46 100644
--- a/layouts/projects/list.html
+++ b/layouts/projects/list.html
@@ -1,51 +1,34 @@
-{{ partial "header.html" . }}
-<body>
-<!-- Parent section -->
-<div class="section" id="top">
- <!-- Begin Title -->
- <div class="container hero {{ if .Site.Params.fadeIn }} fade-in one {{ end }}">
- <h1 class="bold-title is-1">{{ .Title }}</h1>
+{{ define "main" }}
+ <div class="container markdown top-pad">
+ {{ .Content }}
</div>
- <!-- End Title -->
- <!-- Everything below fades in two! -->
- <div class="section no-padding {{ if .Site.Params.fadeIn }} fade-in two {{ end }}">
- {{ partial "nav.html" . }}
- <div class="container markdown {{ if .Site.Params.fadeIn | default true }}fade-in two{{ end }} top-pad">
- {{ .Content }}
- </div>
- <div class="container">
- <div class="section is-small">
- <div class="columns is-multiline">
- {{ $numberOfPages := len .Pages}}
- {{ range .Pages.ByWeight }}
- {{ if eq (mod $numberOfPages 2) 0 }}
- <div class="column is-half">
- {{ else }}
- <div class="column is-one-third">
- {{ end }}
- <div class="card">
- <div class="card-image">
- <figure class="image is-3by2">
- <a href="{{ if .Params.external_link }}{{ .Params.external_link }}{{ else }}{{.Permalink}}{{ end }}">
- <img src="{{ if .Params.image }}{{ .Params.image | relURL }}{{ else }}{{ (.Site.Params.placeHolderimg | default "/img/workday.jpg") | relURL }}{{ end }}" alt="{{ .Title }}">
- </a>
- </figure>
- </div>
- <div class="card-content has-text-centered top-pad">
+ <div class="container">
+ <div class="section is-small">
+ <div class="columns is-multiline">
+ {{ $numberOfPages := len .Pages}}
+ {{ range .Pages.ByWeight }}
+ {{ if eq (mod $numberOfPages 2) 0 }}
+ <div class="column is-half">
+ {{ else }}
+ <div class="column is-one-third">
+ {{ end }}
+ <div class="card">
+ <div class="card-image">
+ <figure class="image is-3by2">
<a href="{{ if .Params.external_link }}{{ .Params.external_link }}{{ else }}{{.Permalink}}{{ end }}">
- {{ .Title }}
+ <img src="{{ if .Params.image }}{{ .Params.image | relURL }}{{ else }}{{ (.Site.Params.placeHolderimg | default "/img/workday.jpg") | relURL }}{{ end }}" alt="{{ .Title }}">
</a>
- </div>
+ </figure>
+ </div>
+ <div class="card-content has-text-centered top-pad">
+ <a href="{{ if .Params.external_link }}{{ .Params.external_link }}{{ else }}{{.Permalink}}{{ end }}">
+ {{ .Title }}
+ </a>
</div>
</div>
- {{ end }}
</div>
+ {{ end }}
</div>
</div>
- {{ partial "top-icon-with-hr.html" . }}
- {{ partial "footer.html" . }}
</div>
- <!-- End fade in two -->
-</div>
-<!-- End parent section -->
-</body>
+{{ end }}
diff --git a/layouts/projects/single.html b/layouts/projects/single.html
new file mode 100644
index 0000000..05bc6d6
--- /dev/null
+++ b/layouts/projects/single.html
@@ -0,0 +1,14 @@
+{{ define "main" }}
+ <div class="container markdown top-pad">
+ {{ if .Params.image }}
+ <div class="has-text-centered">
+ <img src="{{ .Params.image | relURL }}" class="img-responsive" alt="{{ .Title }}">
+ </div>
+ {{ end }}
+ {{ .Content }}
+ </div>
+ <!-- End post content -->
+ <div class="disqus">
+ {{ template "_internal/disqus.html" . }}
+ </div>
+{{ end }}
diff --git a/static/js/index.js b/static/js/index.js
new file mode 100644
index 0000000..847d6a4
--- /dev/null
+++ b/static/js/index.js
@@ -0,0 +1,22 @@
+// Bitty scrolling links script
+$('a[href^="#"]').click(function(e) {
+ e.preventDefault();
+ $('html, body').animate({
+ scrollTop: $(this.hash).offset().top
+ }, 500);
+ $("#nav-menu").removeClass("is-active");
+ return true;
+})
+
+// Modal closer
+$('.card').click(function () {
+ $('#'+this.id+'.modal').addClass('is-active');
+});
+$('.modal-close').click(function () {
+ $('#'+$(this).parent('.modal').get(0).id+'.modal').removeClass('is-active');
+});
+$(document).keypress(function(e) {
+ if(e.which == 0) {
+ $('.modal.is-active').removeClass('is-active');
+ }
+});