mirror of
https://git.adityakumar.xyz/hugo-theme-introduction.git
synced 2024-11-21 19:42:52 +00:00
Use baseof temple to dry code
This commit is contained in:
parent
11587f7efe
commit
daca1fe109
24 changed files with 399 additions and 513 deletions
|
@ -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 }}
|
||||
|
|
35
layouts/_default/baseof.html
Normal file
35
layouts/_default/baseof.html
Normal file
|
@ -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>
|
|
@ -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 }}
|
||||
|
|
|
@ -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 }}
|
||||
|
|
|
@ -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 }}
|
||||
|
|
|
@ -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 }} ({{ 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 }}
|
||||
|
|
|
@ -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 }}
|
||||
|
|
|
@ -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 }}&media={{ .Site.BaseURL }}{{ .Params.pinterestMedia }}{{ end }}&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>
|
||||
{{ 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>
|
||||
{{ 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 }}&media={{ .Site.BaseURL }}{{ .Params.pinterestMedia }}{{ end }}&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 blog title container -->
|
||||
<!-- Begin blog post content -->
|
||||
<div class="container markdown {{ if .Site.Params.fadeIn | default true }}fade-in two{{ end }} top-pad">
|
||||
{{ .Content }}
|
||||
</div>
|
||||
<!-- End blog post content -->
|
||||
<div class="disqus">
|
||||
{{ template "_internal/disqus.html" . }}
|
||||
</div>
|
||||
{{ partial "top-icon-with-hr.html" . }}
|
||||
{{ partial "footer.html" . }}
|
||||
{{ end }}
|
||||
</div>
|
||||
<!-- End fade in two -->
|
||||
</div>
|
||||
<!-- End parent section -->
|
||||
</body>
|
||||
<!-- 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 }}
|
||||
|
|
|
@ -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>
|
||||
|
|
|
@ -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>
|
21
layouts/partials/footer/scripts.html
Normal file
21
layouts/partials/footer/scripts.html
Normal file
|
@ -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" . }}
|
11
layouts/partials/footer/text.html
Normal file
11
layouts/partials/footer/text.html
Normal file
|
@ -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>
|
15
layouts/partials/head/css.html
Normal file
15
layouts/partials/head/css.html
Normal file
|
@ -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 }}
|
2
layouts/partials/head/favicons.html
Normal file
2
layouts/partials/head/favicons.html
Normal file
|
@ -0,0 +1,2 @@
|
|||
<!-- Icon -->
|
||||
<link rel="shortcut icon" href="{{ .Site.Params.faviconFile | default "img/favicon.ico" | relURL }}">
|
24
layouts/partials/head/metadata.html
Normal file
24
layouts/partials/head/metadata.html
Normal file
|
@ -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 }}
|
|
@ -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>
|
|
@ -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 -->
|
|
@ -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>
|
|
@ -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 }}
|
||||
|
|
|
@ -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 }}
|
||||
|
|
14
layouts/projects/single.html
Normal file
14
layouts/projects/single.html
Normal file
|
@ -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 }}
|
22
static/js/index.js
Normal file
22
static/js/index.js
Normal file
|
@ -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');
|
||||
}
|
||||
});
|
Loading…
Reference in a new issue