From 16feeacbf6f4b6ad3fd61bc67849c31bcc0f4b9b Mon Sep 17 00:00:00 2001 From: Vincent Fiduccia Date: Fri, 27 Apr 2018 01:41:40 -0700 Subject: [PATCH] Nav --- .../running-rancheros/cloud/gce/_index.md | 2 +- layouts/_default/list.html | 10 -- layouts/partials/docs-nav.html | 5 +- layouts/partials/docs-side-nav.html | 10 +- src/js/app.js | 99 ++++++++++--------- 5 files changed, 58 insertions(+), 68 deletions(-) diff --git a/content/os/installation/running-rancheros/cloud/gce/_index.md b/content/os/installation/running-rancheros/cloud/gce/_index.md index 2ba8ed6911d..d2e1f68a257 100644 --- a/content/os/installation/running-rancheros/cloud/gce/_index.md +++ b/content/os/installation/running-rancheros/cloud/gce/_index.md @@ -1,5 +1,5 @@ --- -title: Google Cloud Engine (GCE) +title: Google Compute Engine (GCE) weight: 106 --- diff --git a/layouts/_default/list.html b/layouts/_default/list.html index 12b1bb123c5..90eebfdae89 100644 --- a/layouts/_default/list.html +++ b/layouts/_default/list.html @@ -3,16 +3,6 @@ {{ end }} {{ define "hero" }} -
- {{ with .Params.Title }} -

{{ . }}

- {{end}} - - {{ with .Params.Author }} - - {{end}} -
- {{ end }} {{ define "main" }} diff --git a/layouts/partials/docs-nav.html b/layouts/partials/docs-nav.html index 27bb1e6f209..b0d26e900b5 100644 --- a/layouts/partials/docs-nav.html +++ b/layouts/partials/docs-nav.html @@ -33,11 +33,12 @@ {{ $topLevel := .Scratch.Get "topLevel"}} {{ if $topLevel }} {{ range $topLevel.Sections }} - {{ if .IsAncestor $.CurrentSection }} + {{ $isCurrent := .IsAncestor $.CurrentSection }} + {{ if $isCurrent }} {{ $.Scratch.Set "secondLevel" . }} {{ end }} -
  • {{ .Title }}
  • +
  • {{ .Title }}
  • {{ end }} {{ end }} diff --git a/layouts/partials/docs-side-nav.html b/layouts/partials/docs-side-nav.html index 83886fdeb1c..b87ef0c1100 100644 --- a/layouts/partials/docs-side-nav.html +++ b/layouts/partials/docs-side-nav.html @@ -1,4 +1,4 @@ -
    +