Merge remote-tracking branch 'refs/remotes/halogenica/master'
# Conflicts: # layouts/index.html
This commit is contained in:
commit
b9d04230d9
@ -1,6 +1,6 @@
|
|||||||
+++
|
---
|
||||||
title = ""
|
subtitle: ""
|
||||||
subtitle = ""
|
comments:
|
||||||
date = "2014-07-11T10:54:24+02:00"
|
tags: []
|
||||||
bigimg = ""
|
bigimg: [{}]
|
||||||
+++
|
---
|
||||||
|
@ -2,6 +2,7 @@ baseurl = "https://username.github.io"
|
|||||||
languageCode = "en-us"
|
languageCode = "en-us"
|
||||||
title = "Beautiful Hugo"
|
title = "Beautiful Hugo"
|
||||||
theme = "beautifulhugo"
|
theme = "beautifulhugo"
|
||||||
|
metaDataFormat = "yaml"
|
||||||
pygmentsUseClasses = true
|
pygmentsUseClasses = true
|
||||||
pygmentCodeFences = true
|
pygmentCodeFences = true
|
||||||
#disqusShortname = "XXX"
|
#disqusShortname = "XXX"
|
||||||
@ -16,6 +17,16 @@ pygmentCodeFences = true
|
|||||||
rss = true
|
rss = true
|
||||||
comments = true
|
comments = true
|
||||||
|
|
||||||
|
#[[Params.bigimg]]
|
||||||
|
# src = "img/triangle.jpg"
|
||||||
|
# desc = "Triangle"
|
||||||
|
#[[Params.bigimg]]
|
||||||
|
# src = "img/sphere.jpg"
|
||||||
|
# desc = "Sphere"
|
||||||
|
#[[Params.bigimg]]
|
||||||
|
# src = "img/hexagon.jpg"
|
||||||
|
# desc = "Hexagon"
|
||||||
|
|
||||||
[Author]
|
[Author]
|
||||||
name = "Some Person"
|
name = "Some Person"
|
||||||
email = "youremail@domain.com"
|
email = "youremail@domain.com"
|
||||||
@ -50,22 +61,22 @@ pygmentCodeFences = true
|
|||||||
name = "Samples"
|
name = "Samples"
|
||||||
weight = 2
|
weight = 2
|
||||||
|
|
||||||
|
[[menu.main]]
|
||||||
|
parent = "samples"
|
||||||
|
name = "Big Image Sample"
|
||||||
|
url = "/post/2017-03-07-bigimg-sample"
|
||||||
|
weight = 1
|
||||||
|
|
||||||
[[menu.main]]
|
[[menu.main]]
|
||||||
parent = "samples"
|
parent = "samples"
|
||||||
name = "Math Sample"
|
name = "Math Sample"
|
||||||
url = "/post/2017-03-05-math-sample"
|
url = "/post/2017-03-05-math-sample"
|
||||||
weight = 1
|
weight = 2
|
||||||
|
|
||||||
[[menu.main]]
|
[[menu.main]]
|
||||||
parent = "samples"
|
parent = "samples"
|
||||||
name = "Code Sample"
|
name = "Code Sample"
|
||||||
url = "/post/2016-03-08-code-sample"
|
url = "/post/2016-03-08-code-sample"
|
||||||
weight = 2
|
|
||||||
|
|
||||||
[[menu.main]]
|
|
||||||
parent = "samples"
|
|
||||||
name = "Test Markdown"
|
|
||||||
url = "/post/2015-02-20-test-markdown"
|
|
||||||
weight = 3
|
weight = 3
|
||||||
|
|
||||||
[[menu.main]]
|
[[menu.main]]
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
title: Flake it till you make it
|
title: Flake it till you make it
|
||||||
subtitle: Excerpt from Soulshaping by Jeff Brown
|
subtitle: Excerpt from Soulshaping by Jeff Brown
|
||||||
date: 2015-02-26
|
date: 2015-02-26
|
||||||
bigimg: /img/path.jpg
|
bigimg: [{src: "/img/path.jpg", desc: "Path"}]
|
||||||
---
|
---
|
||||||
|
|
||||||
Under what circumstances should we step off a path? When is it essential that we finish what we start? If I bought a bag of peanuts and had an allergic reaction, no one would fault me if I threw it out. If I ended a relationship with a woman who hit me, no one would say that I had a commitment problem. But if I walk away from a seemingly secure route because my soul has other ideas, I am a flake?
|
Under what circumstances should we step off a path? When is it essential that we finish what we start? If I bought a bag of peanuts and had an allergic reaction, no one would fault me if I threw it out. If I ended a relationship with a woman who hit me, no one would say that I had a commitment problem. But if I walk away from a seemingly secure route because my soul has other ideas, I am a flake?
|
||||||
|
40
exampleSite/content/post/2017-03-07-bigimg-sample.md
Normal file
40
exampleSite/content/post/2017-03-07-bigimg-sample.md
Normal file
@ -0,0 +1,40 @@
|
|||||||
|
---
|
||||||
|
title: Big Image Sample
|
||||||
|
subtitle: Using Multiple Images
|
||||||
|
date: 2017-03-07
|
||||||
|
tags: ["example", "bigimg"]
|
||||||
|
bigimg: [{src: "/img/triangle.jpg", desc: "Triangle"}, {src: "/img/sphere.jpg", desc: "Sphere"}, {src: "/img/hexagon.jpg", desc: "Hexagon"}]
|
||||||
|
---
|
||||||
|
|
||||||
|
The image banners at the top of the page are refered to as "bigimg" in this theme. They are optional, and one more more can be specified. If more than one is specified, the images rotate every 10 seconds. In the front matter, bigimgs are specified using an array of hashes.
|
||||||
|
|
||||||
|
<!--more-->
|
||||||
|
|
||||||
|
A single bigimg can be specified in the front matter by the following YAML:
|
||||||
|
```
|
||||||
|
bigimg: [{src: "/img/triangle.jpg", desc: "Triangle"}]
|
||||||
|
```
|
||||||
|
|
||||||
|
Multiple bigimgs can be specified in the front matter by the following YAML:
|
||||||
|
```
|
||||||
|
bigimg: [{src: "/img/triangle.jpg", desc: "Triangle"},
|
||||||
|
{src: "/img/sphere.jpg", desc: "Sphere"},
|
||||||
|
{src: "/img/hexagon.jpg", desc: "Hexagon"}]
|
||||||
|
```
|
||||||
|
|
||||||
|
Also note that the description field is optional, and images could instead be specified by:
|
||||||
|
```
|
||||||
|
bigimg: [{src: "/img/triangle.jpg"},
|
||||||
|
{src: "/img/sphere.jpg"},
|
||||||
|
{src: "/img/hexagon.jpg"}]
|
||||||
|
```
|
||||||
|
|
||||||
|
The above YAML array of hashes were written in "flow" style. However when generating a new page or post with `hugo new post/mypost.md`, hugo may interpret the archetype for bigimg in the default YAML style. Defining multiple bigimg's complete with descriptions in this style would be specified by:
|
||||||
|
```
|
||||||
|
bigimg:
|
||||||
|
- {src: "/img/triangle.jpg", desc: "Triangle"}
|
||||||
|
- {src: "/img/sphere.jpg", desc: "Sphere"}
|
||||||
|
- {src: "/img/hexagon.jpg", desc: "Hexagon"}
|
||||||
|
```
|
||||||
|
|
||||||
|
Additional information can be found [in this YAML tutorial](https://rhnh.net/2011/01/31/yaml-tutorial/).
|
@ -7,12 +7,12 @@
|
|||||||
|
|
||||||
{{ partial "nav.html" . }}
|
{{ partial "nav.html" . }}
|
||||||
|
|
||||||
{{ if .Site.Params.bigimg }}
|
{{ if isset .Site.Params.bigimg 1 }}
|
||||||
<div id="header-big-imgs" data-num-img={{len .Site.Params.bigimg}} {{range $i, $img := .Site.Params.bigimg}}data-img-src-{{add $i 1}}="{{$img.src}}" data-img-desc-{{add $i 1}}="{{$img.desc}}"{{end}}></div>
|
<div id="header-big-imgs" data-num-img={{len .Site.Params.bigimg}} {{range $i, $img := .Site.Params.bigimg}}data-img-src-{{add $i 1}}="{{$img.src}}" data-img-desc-{{add $i 1}}="{{$img.desc}}"{{end}}></div>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
<header class="header-section {{ if .Site.Params.bigimg }}has-img{{ end }}">
|
<header class="header-section {{ if isset .Site.Params.bigimg 1 }}has-img{{ end }}">
|
||||||
<div class="intro-header {{ if .Site.Params.bigimg }}big-img{{ else }}no-img{{ end }}">
|
<div class="intro-header {{ if isset .Site.Params.bigimg 1 }}big-img{{ else }}no-img{{ end }}">
|
||||||
<div class="container">
|
<div class="container">
|
||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">
|
<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">
|
||||||
|
@ -1,4 +1,4 @@
|
|||||||
{{ if (.Params.comments) | or (and (not (isset .Params "comments")) (.Site.Params.comments)) }}
|
{{ if (.Params.comments) | or (and (or (not (isset .Params "comments")) (eq .Params.comments nil)) (.Site.Params.comments)) }}
|
||||||
{{ if .Site.DisqusShortname }}
|
{{ if .Site.DisqusShortname }}
|
||||||
<div class="comments">
|
<div class="comments">
|
||||||
{{ template "_internal/disqus.html" . }}
|
{{ template "_internal/disqus.html" . }}
|
||||||
|
@ -165,7 +165,7 @@
|
|||||||
{{ end }}
|
{{ end }}
|
||||||
{{ if .Site.Params.rss }}
|
{{ if .Site.Params.rss }}
|
||||||
<li>
|
<li>
|
||||||
<a href="{{ .Site.BaseURL}}index.xml" title="RSS">
|
<a href="{{ .Site.BaseURL}}/index.xml" title="RSS">
|
||||||
<span class="fa-stack fa-lg">
|
<span class="fa-stack fa-lg">
|
||||||
<i class="fa fa-circle fa-stack-2x"></i>
|
<i class="fa fa-circle fa-stack-2x"></i>
|
||||||
<i class="fa fa-rss fa-stack-1x fa-inverse"></i>
|
<i class="fa fa-rss fa-stack-1x fa-inverse"></i>
|
||||||
|
@ -44,7 +44,6 @@
|
|||||||
<meta property="og:type" content="website" />
|
<meta property="og:type" content="website" />
|
||||||
|
|
||||||
{{ if .Params.id }}
|
{{ if .Params.id }}
|
||||||
<<<<<<< HEAD
|
|
||||||
<meta property="og:url" content="{{ .URL | absURL }}" />
|
<meta property="og:url" content="{{ .URL | absURL }}" />
|
||||||
<link rel="canonical" href="{{ .URL | absURL }}" />
|
<link rel="canonical" href="{{ .URL | absURL }}" />
|
||||||
{{ else }}
|
{{ else }}
|
||||||
@ -58,21 +57,6 @@
|
|||||||
<meta property="og:image" content="{{ .Params.bigimg | absURL }}" />
|
<meta property="og:image" content="{{ .Params.bigimg | absURL }}" />
|
||||||
{{ else if .Site.Params.logo }}
|
{{ else if .Site.Params.logo }}
|
||||||
<meta property="og:image" content="{{ .Site.Params.logo | absURL }}" />
|
<meta property="og:image" content="{{ .Site.Params.logo | absURL }}" />
|
||||||
=======
|
|
||||||
<meta property="og:url" content="{{ .URL | absURL }}" />
|
|
||||||
<link rel="canonical" href="{{ .URL | absURL }}" />
|
|
||||||
{{ else }}
|
|
||||||
<meta property="og:url" content="{{ .URL | absURL }}" />
|
|
||||||
<link rel="canonical" href="{{ .URL | absURL }}" />
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
{{ if .Params.share_img }}
|
|
||||||
<meta property="og:image" content="{{ .Params.share_img | absURL }}" />
|
|
||||||
{{ else if .Params.bigimg }}
|
|
||||||
<meta property="og:image" content="{{ .Params.bigimg | absURL }}" />
|
|
||||||
{{ else if .Site.Params.logo }}
|
|
||||||
<meta property="og:image" content="{{ .Site.Params.logo | absURL }}" />
|
|
||||||
>>>>>>> refs/remotes/halogenica/master
|
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
<!-- Twitter summary cards -->
|
<!-- Twitter summary cards -->
|
||||||
@ -81,30 +65,6 @@
|
|||||||
<meta name="twitter:creator" content="@{{ .Site.Author.twitter }}" />
|
<meta name="twitter:creator" content="@{{ .Site.Author.twitter }}" />
|
||||||
|
|
||||||
{{ if .Params.meta_title }}
|
{{ if .Params.meta_title }}
|
||||||
<<<<<<< HEAD
|
|
||||||
<meta name="twitter:title" content="{{ .Params.meta_title }}" />
|
|
||||||
{{ else if .Title }}
|
|
||||||
<meta name="twitter:title" content="{{ .Title }}" />
|
|
||||||
{{ else }}
|
|
||||||
<meta name="twitter:title" content="{{ .Site.Title }}" />
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
{{ if .Params.meta_description }}
|
|
||||||
<meta name="twitter:description" content="{{ .Params.meta_description }}">
|
|
||||||
{{ else if .Params.subtitle }}
|
|
||||||
<meta name="twitter:description" content="{{ .Params.subtitle }}">
|
|
||||||
{{ else }}
|
|
||||||
<meta name="twitter:description" content="{{ .Content | plainify | htmlEscape | truncate 200 }}">
|
|
||||||
{{ end }}
|
|
||||||
|
|
||||||
{{ if .Params.share_img }}
|
|
||||||
<meta name="twitter:image" content="{{ .Params.share_img }}" />
|
|
||||||
{{ else if .Params.bigimg }}
|
|
||||||
<meta name="twitter:image" content="{{ .Params.bigimg | absURL }}" />
|
|
||||||
{{ else if .Site.Params.logo }}
|
|
||||||
<meta name="twitter:image" content="{{ .Site.Params.logo | absURL }}" />
|
|
||||||
{{ end }}
|
|
||||||
=======
|
|
||||||
<meta name="twitter:title" content="{{ .Params.meta_title }}" />
|
<meta name="twitter:title" content="{{ .Params.meta_title }}" />
|
||||||
{{ else if .Title }}
|
{{ else if .Title }}
|
||||||
<meta name="twitter:title" content="{{ .Title }}" />
|
<meta name="twitter:title" content="{{ .Title }}" />
|
||||||
@ -127,6 +87,5 @@
|
|||||||
{{ else if .Site.Params.logo }}
|
{{ else if .Site.Params.logo }}
|
||||||
<meta name="twitter:image" content="{{ .Site.Params.logo | absURL }}" />
|
<meta name="twitter:image" content="{{ .Site.Params.logo | absURL }}" />
|
||||||
{{ end }}
|
{{ end }}
|
||||||
>>>>>>> refs/remotes/halogenica/master
|
|
||||||
|
|
||||||
</head>
|
</head>
|
||||||
|
@ -1,17 +1,12 @@
|
|||||||
{{ if or .Params.bigimg .Title }}
|
{{ if or .Params.bigimg .Title }}
|
||||||
{{ if .Params.bigimg }}
|
{{ if isset .Params.bigimg 1 }}
|
||||||
<div id="header-big-imgs" data-num-img=1 data-img-src-1="{{.Params.bigimg}}"></div>
|
<div id="header-big-imgs" data-num-img={{len .Params.bigimg}} {{range $i, $img := .Params.bigimg}}data-img-src-{{add $i 1}}="{{$img.src}}" {{ if $img.desc}}data-img-desc-{{add $i 1}}="{{$img.desc}}"{{end}}{{end}}></div>
|
||||||
{{ end }}
|
{{ end }}
|
||||||
|
|
||||||
<header class="header-section {{ if .Params.bigimg }}has-img{{ end }}">
|
<header class="header-section {{ if isset .Params.bigimg 1 }}has-img{{ end }}">
|
||||||
{{ if .Params.bigimg }}
|
<div class="intro-header {{ if isset .Params.bigimg 1 }}big-img{{ else }}no-img{{ end }}">
|
||||||
<div class="big-img intro-header">
|
|
||||||
{{ partial "header.html" . }}
|
|
||||||
<span class='img-desc'></span>
|
|
||||||
</div>
|
|
||||||
{{ end }}
|
|
||||||
<div class="intro-header no-img">
|
|
||||||
{{ partial "header.html" . }}
|
{{ partial "header.html" . }}
|
||||||
|
<span class="img-desc" style="display: inline;"></span>
|
||||||
</div>
|
</div>
|
||||||
</header>
|
</header>
|
||||||
{{ else }}
|
{{ else }}
|
||||||
|
@ -2,7 +2,7 @@
|
|||||||
<div class="row">
|
<div class="row">
|
||||||
<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">
|
<div class="col-lg-8 col-lg-offset-2 col-md-10 col-md-offset-1">
|
||||||
{{ .Content }}
|
{{ .Content }}
|
||||||
{{ if (.Params.comments) | or (and (not (isset .Params "comments")) (.Site.Params.comments)) }}
|
{{ if (.Params.comments) | or (and (or (not (isset .Params "comments")) (eq .Params.comments nil)) (.Site.Params.comments)) }}
|
||||||
{{ if .Site.DisqusShortname }}
|
{{ if .Site.DisqusShortname }}
|
||||||
<div class="disqus-comments">
|
<div class="disqus-comments">
|
||||||
{{ template "_internal/disqus.html" . }}
|
{{ template "_internal/disqus.html" . }}
|
||||||
|
@ -18,7 +18,7 @@
|
|||||||
{{ end }}
|
{{ end }}
|
||||||
</ul>
|
</ul>
|
||||||
|
|
||||||
{{ if (.Params.comments) | or (and (not (isset .Params "comments")) (.Site.Params.comments)) }}
|
{{ if (.Params.comments) | or (and (or (not (isset .Params "comments")) (eq .Params.comments nil)) (.Site.Params.comments)) }}
|
||||||
{{ if .Site.DisqusShortname }}
|
{{ if .Site.DisqusShortname }}
|
||||||
<div class="disqus-comments">
|
<div class="disqus-comments">
|
||||||
{{ template "_internal/disqus.html" . }}
|
{{ template "_internal/disqus.html" . }}
|
||||||
|
BIN
static/img/hexagon.jpg
Normal file
BIN
static/img/hexagon.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 170 KiB |
BIN
static/img/sphere.jpg
Normal file
BIN
static/img/sphere.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 48 KiB |
BIN
static/img/triangle.jpg
Normal file
BIN
static/img/triangle.jpg
Normal file
Binary file not shown.
After Width: | Height: | Size: 133 KiB |
Loading…
Reference in New Issue
Block a user