diff options
author | Vicky <vicky@vickylai.com> | 2018-09-03 10:59:49 +0300 |
---|---|---|
committer | Vicky <vicky@vickylai.com> | 2018-09-03 10:59:49 +0300 |
commit | ef92cd4822ea73a7dc06f2a68b8977e49a512921 (patch) | |
tree | 3066969bb4b666c15fc206fcb849058fd32660ed | |
parent | 03e80406a580dc59f5e7c99b8e18c3401462ed74 (diff) | |
parent | fe57f7d294613bce2b2af6ba2e483ddf24bb4170 (diff) |
Merge branch 'next_gen' of https://github.com/Hanzei/hugo-theme-introduction into Hanzei-next_gen
-rw-r--r-- | .travis.yml | 2 | ||||
-rw-r--r-- | assets/.gitattributes | 2 | ||||
-rw-r--r-- | exampleSite/.gitattributes | 2 | ||||
-rw-r--r-- | layouts/partials/home/projects.html | 13 | ||||
-rw-r--r-- | layouts/projects/list.html | 13 | ||||
-rw-r--r-- | static/.gitattributes | 2 | ||||
-rw-r--r-- | theme.toml | 2 |
7 files changed, 20 insertions, 16 deletions
diff --git a/.travis.yml b/.travis.yml index 524d8f3..ed4714c 100644 --- a/.travis.yml +++ b/.travis.yml @@ -2,7 +2,7 @@ git: depth: false env: - - HUGO_VERSION="0.47" + - HUGO_VERSION="0.48" install: - wget -q https://github.com/gohugoio/hugo/releases/download/v${HUGO_VERSION}/hugo_${HUGO_VERSION}_Linux-64bit.tar.gz diff --git a/assets/.gitattributes b/assets/.gitattributes new file mode 100644 index 0000000..cea6c74 --- /dev/null +++ b/assets/.gitattributes @@ -0,0 +1,2 @@ +vendor/** linguist-generated=true +vendor/** -diff -merge diff --git a/exampleSite/.gitattributes b/exampleSite/.gitattributes new file mode 100644 index 0000000..6393d4c --- /dev/null +++ b/exampleSite/.gitattributes @@ -0,0 +1,2 @@ +resources/** linguist-generated=true +resources/** -diff -merge diff --git a/layouts/partials/home/projects.html b/layouts/partials/home/projects.html index 62d0a83..e5a28a8 100644 --- a/layouts/partials/home/projects.html +++ b/layouts/partials/home/projects.html @@ -10,18 +10,17 @@ {{ $totalProjects := (len .Pages) }} {{ $numberOfProjectsToShow := .Site.Params.home.numberOfProjectsToShow | default $totalProjects }} {{ range $index, $element := .Pages.ByWeight | first $numberOfProjectsToShow }} + {{ $width := "302x" }} + {{ $columWidth := "is-one-third" }} {{ if .Site.Params.projects.useTwoColumns }} - {{ .Scratch.Set "width" "490x" }} - <div class="column is-half"> - {{ else }} - {{ .Scratch.Set "width" "302x" }} - <div class="column is-one-third"> - {{ end }} + {{ $columWidth = "is-half" }} + {{ $width = "490x" }} + {{ end}} + <div class="column {{ $columWidth }}"> <div class="card" data-target="#project-{{ $index }}"> <div class="card-image"> <figure class="image is-3by2"> <a {{ if .Params.external_link }} href="{{ .Params.external_link }}" {{ end }}> - {{ $width := ( .Scratch.Get "width" ) }} {{ with .Resources.ByType "image" }} {{ range first 1 (sort . "Params.weight") }} {{ $image := .Resize $width }} diff --git a/layouts/projects/list.html b/layouts/projects/list.html index a4f6e1a..37480ea 100644 --- a/layouts/projects/list.html +++ b/layouts/projects/list.html @@ -7,18 +7,17 @@ <div class="columns is-multiline"> {{ $numberOfPages := len .Pages}} {{ range .Pages.ByWeight }} + {{ $width := "302x" }} + {{ $columWidth := "is-one-third" }} {{ if .Site.Params.projects.useTwoColumns }} - {{ .Scratch.Set "width" "490x" }} - <div class="column is-half"> - {{ else }} - {{ .Scratch.Set "width" "302x" }} - <div class="column is-one-third"> - {{ end }} + {{ $columWidth = "is-half" }} + {{ $width = "490x" }} + {{ end}} + <div class="column {{ $columWidth }}"> <div class="card"> <div class="card-image"> <figure class="image is-3by2"> <a href="{{ if .Params.external_link }}{{ .Params.external_link }}{{ else }}{{ .Permalink }}{{ end }}"> - {{ $width := ( .Scratch.Get "width" ) }} {{ with .Resources.ByType "image" }} {{ range first 1 (sort . "Params.weight") }} {{ $image := .Resize $width }} diff --git a/static/.gitattributes b/static/.gitattributes new file mode 100644 index 0000000..fa63787 --- /dev/null +++ b/static/.gitattributes @@ -0,0 +1,2 @@ +fonts/** linguist-generated=true +fonts/** -diff -merge @@ -5,7 +5,7 @@ description = "Minimal, single page, smooth scrolling theme for Hugo." homepage = "https://github.com/vickylai/hugo-theme-introduction" tags = ["blog", "bulma", "clean", "dark", "disqus", "font awesome", "gallery", "minimal", "minimalist", "mobile", "multilingual", "one page", "personal", "responsive", "simple", "single page", "starter", "syntax highlighting", "projects", "white" ] features = ["responsive", "blog", "portfolio", "gallery"] -min_version = "0.46" +min_version = "0.48" [author] name = "Vicky Lai" |