From 22f1890a9beab11d8cfdceba3a4d66f8bbbb468c Mon Sep 17 00:00:00 2001 From: Ian Lewis Date: Fri, 29 Mar 2019 22:40:11 -0400 Subject: Initial commit --- layouts/_default/content.html | 13 ++++++++++++ layouts/docs/list.html | 30 ++++++++++++++++++++++++++ layouts/partials/footer.html | 39 ++++++++++++++++++++++++++++++++++ layouts/partials/head.html | 27 +++++++++++++++++++++++ layouts/partials/navbar.html | 27 +++++++++++++++++++++++ layouts/partials/page-meta-links.html | 11 ++++++++++ layouts/shortcodes/blocks/lead.html | 11 ++++++++++ layouts/shortcodes/blocks/section.html | 12 +++++++++++ 8 files changed, 170 insertions(+) create mode 100644 layouts/_default/content.html create mode 100644 layouts/docs/list.html create mode 100644 layouts/partials/footer.html create mode 100644 layouts/partials/head.html create mode 100644 layouts/partials/navbar.html create mode 100644 layouts/partials/page-meta-links.html create mode 100644 layouts/shortcodes/blocks/lead.html create mode 100644 layouts/shortcodes/blocks/section.html (limited to 'layouts') diff --git a/layouts/_default/content.html b/layouts/_default/content.html new file mode 100644 index 000000000..7db3f3405 --- /dev/null +++ b/layouts/_default/content.html @@ -0,0 +1,13 @@ +
+

{{ .Title }}

+ {{ with .Params.description }}
{{ . | markdownify }}
{{ end }} + {{ .Content }} + {{ if (and (not .Params.hide_feedback) (.Site.Params.ui.feedback.enable) (.Site.GoogleAnalytics)) }} + {{ partial "feedback.html" .Site.Params.ui.feedback }} +
+ {{ end }} + {{ if (.Site.DisqusShortname) }} +
+ {{ partial "disqus-comment.html" . }} + {{ end }} +
diff --git a/layouts/docs/list.html b/layouts/docs/list.html new file mode 100644 index 000000000..4afc32653 --- /dev/null +++ b/layouts/docs/list.html @@ -0,0 +1,30 @@ +{{ define "title"}} {{ .Title}} {{end}} +{{ define "main" }} + +{{ if .Content }} +{{ .Render "content" }} +{{ else }} +
+

{{ .Title }}

+ {{ with .Params.description }}
{{ . | markdownify }}
{{ end }} +
+ +
+ +{{ range .Sections.ByWeight }} +
  • + {{.Title}} +
  • +{{ end }} + +{{ range .Paginator.Pages.ByWeight }} +
  • + {{.Title}} +
  • +{{ end }} + +
    + +{{ end }} + +{{ end }} diff --git a/layouts/partials/footer.html b/layouts/partials/footer.html new file mode 100644 index 000000000..b7bbbbdcf --- /dev/null +++ b/layouts/partials/footer.html @@ -0,0 +1,39 @@ +{{ $links := .Site.Params.links }} + +{{ define "footer-links-block" }} + +{{ end }} diff --git a/layouts/partials/head.html b/layouts/partials/head.html new file mode 100644 index 000000000..8edfd47a5 --- /dev/null +++ b/layouts/partials/head.html @@ -0,0 +1,27 @@ + + +{{ .Hugo.Generator }} +{{ if eq (getenv "HUGO_ENV") "production" }} + +{{ else }} + +{{ end }} +{{ range .AlternativeOutputFormats -}} + +{{ end -}} +{{ partialCached "favicons.html" . }} +{{ if .IsHome }}{{ .Site.Title }}{{ else }}{{ with .Title }}{{ . }} | {{ end }}{{ .Site.Title }}{{ end }} + +{{- template "_internal/opengraph.html" . -}} +{{- template "_internal/google_news.html" . -}} +{{- template "_internal/schema.html" . -}} +{{- template "_internal/twitter_cards.html" . -}} +{{ if eq (getenv "HUGO_ENV") "production" }} +{{ template "_internal/google_analytics_async.html" . }} +{{ end }} +{{ partialCached "head-css.html" . "asdf" }} + +{{ partial "hooks/head-end.html" . }} diff --git a/layouts/partials/navbar.html b/layouts/partials/navbar.html new file mode 100644 index 000000000..393684b8c --- /dev/null +++ b/layouts/partials/navbar.html @@ -0,0 +1,27 @@ + +{{ $cover := .HasShortcode "blocks/cover" }} + diff --git a/layouts/partials/page-meta-links.html b/layouts/partials/page-meta-links.html new file mode 100644 index 000000000..5889313a9 --- /dev/null +++ b/layouts/partials/page-meta-links.html @@ -0,0 +1,11 @@ +{{ if .Path }} +{{ $gh_repo := ($.Param "github_repo") }} +{{ if $gh_repo }} +
    +{{ $editURL := printf "%s/edit/master/content/%s/%s" $gh_repo ($.Site.Language.Lang) .Path }} +{{ $issuesURL := printf "%s/issues/new?title=%s" $gh_repo (htmlEscape $.Title )}} + {{ T "post_edit_this" }} + {{ T "post_create_issue" }} +
    +{{ end }} +{{ end }} diff --git a/layouts/shortcodes/blocks/lead.html b/layouts/shortcodes/blocks/lead.html new file mode 100644 index 000000000..7825eac70 --- /dev/null +++ b/layouts/shortcodes/blocks/lead.html @@ -0,0 +1,11 @@ +{{ $col_id := .Get "color" | default .Ordinal }} +{{ $height := .Get "height" | default "auto" }} +{{/* Height can be one of: auto, min, med, max, full. */}} + +
    +
    + + {{ .Inner }} + +
    +
    diff --git a/layouts/shortcodes/blocks/section.html b/layouts/shortcodes/blocks/section.html new file mode 100644 index 000000000..de7e6c8f1 --- /dev/null +++ b/layouts/shortcodes/blocks/section.html @@ -0,0 +1,12 @@ +{{ $col_id := .Get "color" | default .Ordinal }} +{{ $height := .Get "height" | default "auto" }} + +
    +
    +
    +
    + {{ .Inner }} +
    +
    +
    +
    -- cgit v1.2.3