From 3c6cb7f29631dfcdd954e7cbd5d2370efe7eb827 Mon Sep 17 00:00:00 2001 From: olOwOlo <26087907+olOwOlo@users.noreply.github.com> Date: Sun, 27 Aug 2017 22:38:42 +0800 Subject: 🎉 first commit MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- layouts/partials/comments.html | 35 ++++++++++++++++++ layouts/partials/footer.html | 37 +++++++++++++++++++ layouts/partials/head.html | 71 ++++++++++++++++++++++++++++++++++++ layouts/partials/header.html | 13 +++++++ layouts/partials/post/copyright.html | 33 +++++++++++++++++ layouts/partials/post/reward.html | 19 ++++++++++ layouts/partials/post/toc.html | 8 ++++ layouts/partials/scripts.html | 55 ++++++++++++++++++++++++++++ layouts/partials/slideout.html | 19 ++++++++++ 9 files changed, 290 insertions(+) create mode 100644 layouts/partials/comments.html create mode 100644 layouts/partials/footer.html create mode 100644 layouts/partials/head.html create mode 100644 layouts/partials/header.html create mode 100644 layouts/partials/post/copyright.html create mode 100644 layouts/partials/post/reward.html create mode 100644 layouts/partials/post/toc.html create mode 100644 layouts/partials/scripts.html create mode 100644 layouts/partials/slideout.html (limited to 'layouts/partials') diff --git a/layouts/partials/comments.html b/layouts/partials/comments.html new file mode 100644 index 0000000..fea1a33 --- /dev/null +++ b/layouts/partials/comments.html @@ -0,0 +1,35 @@ +{{ if and .IsPage (ne .Params.comment false) }} + + {{- if .Site.DisqusShortname -}} +
+ + + comments powered by Disqus + {{- end }} + + + {{- if and .Site.Params.changyanAppid .Site.Params.changyanAppkey -}} +
+ + {{- end }} +{{- end }} \ No newline at end of file diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html new file mode 100644 index 0000000..246f26a --- /dev/null +++ b/layouts/partials/footer.html @@ -0,0 +1,37 @@ + + + \ No newline at end of file diff --git a/layouts/partials/head.html b/layouts/partials/head.html new file mode 100644 index 0000000..0310b16 --- /dev/null +++ b/layouts/partials/head.html @@ -0,0 +1,71 @@ + + + + + + + + + + + + + + +{{- if .Description -}} + +{{ else if .IsPage }} + +{{ else if .Site.Params.description }} + +{{- end -}} + +{{- if .Keywords -}} + {{ $length := len .Keywords | add -1 -}} + +{{ else if .Site.Params.keywords }} + {{ $length := len .Site.Params.keywords | add -1 -}} + +{{- end }} + + +{{ with .Site.Params.baidu_verification }}{{ end }} +{{ with .Site.Params.google_verification }}{{ end }} + + + + + + +{{ if .RSSLink -}} + + +{{ end -}} + + + + + + + + + + + +{{ if .Site.Params.bootcdn -}} + {{ if .Site.Params.fancybox }}{{ end }} +{{ else -}} + {{ if .Site.Params.fancybox }}{{ end }} +{{- end }} + +{{/* NOTE: These Hugo Internal Templates can be found starting at https://github.com/spf13/hugo/blob/master/tpl/tplimpl/template_embedded.go#L158 */}} +{{- template "_internal/opengraph.html" . -}} +{{- template "_internal/google_news.html" . -}} +{{- template "_internal/schema.html" . -}} +{{- template "_internal/twitter_cards.html" . -}} + + +{{ `` | safeHTML }} diff --git a/layouts/partials/header.html b/layouts/partials/header.html new file mode 100644 index 0000000..a8a555a --- /dev/null +++ b/layouts/partials/header.html @@ -0,0 +1,13 @@ +
+ +
+ + \ No newline at end of file diff --git a/layouts/partials/post/copyright.html b/layouts/partials/post/copyright.html new file mode 100644 index 0000000..6908b10 --- /dev/null +++ b/layouts/partials/post/copyright.html @@ -0,0 +1,33 @@ +{{ if and .Site.Copyright (ne .Params.copyright false) }} +{{ $lang := .Site.Data.even.default -}} +
+ + + + {{ if $.Site.Params.linkToMarkDown -}} + {{ with $.OutputFormats.Get "markdown" -}} + + {{- end }} + {{- end }} + +
+{{- end }} \ No newline at end of file diff --git a/layouts/partials/post/reward.html b/layouts/partials/post/reward.html new file mode 100644 index 0000000..5a26cd7 --- /dev/null +++ b/layouts/partials/post/reward.html @@ -0,0 +1,19 @@ +{{ if and .Site.Params.reward.enable (ne .Params.reward false) }} +
+ + +
+ {{ $qrCode := .Site.Params.reward }} + {{ with $qrCode.wechat }} + + {{- end }} + {{ with $qrCode.alipay }} + + {{- end }} +
+
+{{- end }} \ No newline at end of file diff --git a/layouts/partials/post/toc.html b/layouts/partials/post/toc.html new file mode 100644 index 0000000..7921065 --- /dev/null +++ b/layouts/partials/post/toc.html @@ -0,0 +1,8 @@ +{{ if and .Site.Params.toc (ne .Params.toc false) }} +
+

{{ .Site.Data.even.default.posts.toc }}

+
+ {{.TableOfContents}} +
+
+{{- end }} \ No newline at end of file diff --git a/layouts/partials/scripts.html b/layouts/partials/scripts.html new file mode 100644 index 0000000..d1eefa8 --- /dev/null +++ b/layouts/partials/scripts.html @@ -0,0 +1,55 @@ + + +{{ if .Site.Params.bootcdn -}} + + + + {{ if .Site.Params.fancybox }}{{ end }} + +{{ else -}} + + + {{ if .Site.Params.fancybox }}{{ end }} + +{{- end }} + +{{ if and (and .Site.Params.mathjax (ne .Params.mathjax false)) (or .IsPage .IsHome) -}} + +{{- end }} + + +{{- if .Site.GoogleAnalytics -}} + {{ template "_internal/google_analytics_async.html" . }} +{{- end -}} + +{{- with .Site.Params.baidu_analytics -}} + +{{- end }} + + +{{- if .Site.Params.baidu_push -}} + +{{- end }} \ No newline at end of file diff --git a/layouts/partials/slideout.html b/layouts/partials/slideout.html new file mode 100644 index 0000000..4ec6344 --- /dev/null +++ b/layouts/partials/slideout.html @@ -0,0 +1,19 @@ +
+ +
+ + + +
+
+ \ No newline at end of file -- cgit v1.2.3