summaryrefslogtreecommitdiff
path: root/layouts/partials/header.html
diff options
context:
space:
mode:
authorVidhu Kant Sharma <vidhukant@vidhukant.com>2023-08-27 01:36:12 +0530
committerVidhu Kant Sharma <vidhukant@vidhukant.com>2023-08-27 01:36:12 +0530
commit77d4a98a666ef6c2c18c10f2f2d62210f9eeb752 (patch)
tree11c75334b682009ff015a0fcd2e8eddc7eb4d315 /layouts/partials/header.html
first commit
Diffstat (limited to 'layouts/partials/header.html')
-rw-r--r--layouts/partials/header.html10
1 files changed, 10 insertions, 0 deletions
diff --git a/layouts/partials/header.html b/layouts/partials/header.html
new file mode 100644
index 0000000..ba1869b
--- /dev/null
+++ b/layouts/partials/header.html
@@ -0,0 +1,10 @@
+<div id="site-header">
+ <nav id="global-nav">
+ {{ range .Site.Params.navLinks }}
+ {{ $path := index . 1 }}
+ <a href="{{ $path }}" {{ if $.Params.navPath }}{{ $p := printf "/%s" $.Params.navPath | printf "%s" }}{{ if eq $path $p }}id="nav-link-active"{{ end }}{{ else }}{{ $p := printf "/%s" $.Section | printf "%s" }}{{ if eq $path $p }}id="nav-link-active"{{ end }}{{ end }}>
+ {{ index . 0 }}
+ </a>
+ {{ end }}
+ </nav>
+</div>