Skip to content

Commit

Permalink
added navigation dropdown markup and modified readme file
Browse files Browse the repository at this point in the history
  • Loading branch information
somrat committed Aug 24, 2019
1 parent b1130ab commit c0511f4
Show file tree
Hide file tree
Showing 2 changed files with 25 additions and 8 deletions.
4 changes: 3 additions & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -81,4 +81,6 @@ We are available for Hiring of your next HUGO project. Drop Us a mail [themefish
|:---:|:---:|:---:|
| **Biztrox** | **Bexer** | **Small Apps** |
| [![Dtox](https://user-images.githubusercontent.com/37659754/54068836-07284100-427b-11e9-8ff2-48eec3220a26.png)](https://themefisher.com/products/dtox-hugo-theme/) | [![Agico](https://user-images.githubusercontent.com/37659754/57753899-16aa8700-770f-11e9-9a3d-d3fc45313fbd.png)](https://themefisher.com/products/agico-hugo-theme/) | [![Airspace](https://user-images.githubusercontent.com/37659754/57754161-9d5f6400-770f-11e9-8a76-778fbb9910c4.png)](https://themefisher.com/products/airspace-hugo/) |
| **Dtox** | **Agico** | **Airspace** |
| **Dtox** | **Agico** | **Airspace** |
| [![Agen](https://user-images.githubusercontent.com/37659754/63633832-3a675c80-c670-11e9-8380-a7b5f8f82b76.png)](https://themefisher.com/products/agen-hugo-agency-template/) | [![Mega-Bundle-HUGO](https://user-images.githubusercontent.com/37659754/63633830-30ddf480-c670-11e9-8a8b-04a142f8ffc1.png)](https://themefisher.com/products/hugo-mega-bundle/) |
| **Agen** | **Hugo Mega Bundle** |
29 changes: 22 additions & 7 deletions layouts/partials/header.html
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{{ "<!-- Fixed Navigation -->" | safeHTML }}
<!-- <section class="top-bar animated-header"> emprunt depuis timer theme -->
{{ if .Site.Params.menufixed }}
<section class="header navigation top-bar animated-header">
<section class="header navigation top-bar animated-header">
{{ else }}
<section class="header navigation">
<section class="header navigation">
{{ end }}
<div class="container">
<div class="row">
Expand All @@ -12,31 +12,46 @@
<a class="navbar-brand" href="{{ .Site.BaseURL }}">
<img src="{{ with .Site.Params.logo }}{{ . | absURL }}{{ end }}" alt="logo">
</a>
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navigation" aria-controls="navigation"
aria-expanded="false" aria-label="Toggle navigation">
<button class="navbar-toggler" type="button" data-toggle="collapse" data-target="#navigation"
aria-controls="navigation" aria-expanded="false" aria-label="Toggle navigation">
<span class="tf-ion-android-menu"></span>
</button>
<!-- Icones & drapeaux de choix des langues -->
<div id="drapeaux">
<!-- Pour passer la langue actuelle (variable globale) dans la range => explicitement -->
{{ range .Site.Params.listeLangues }}
{{ partial "flags.html" (dict "site" $.Site "liste" .) }}
{{ partial "flags.html" (dict "site" $.Site "liste" .) }}
{{ end }}
</div>
<div class="collapse navbar-collapse" id="navigation">
<ul class="navbar-nav ml-auto">
<li class="nav-item">
<a class="nav-link" href="{{ .Site.BaseURL }}">{{ with .Site.Params.home }}{{ . }}{{ end }}</a>
<a class="nav-link"
href="{{ .Site.BaseURL }}">{{ with .Site.Params.home }}{{ . }}{{ end }}</a>
</li>
{{ range .Site.Menus.nav }}
{{ if .HasChildren }}
<li class="nav-item dropdown">
<a class="nav-link dropdown-toggle" href="#" role="button" data-toggle="dropdown"
aria-haspopup="true" aria-expanded="false">
{{ .Name }}
</a>
<div class="dropdown-menu">
{{ range .Children }}
<a class="dropdown-item" href="{{ .URL | absURL }}">{{ .Name }}</a>
{{ end }}
</div>
</li>
{{ else }}
<li class="nav-item">
<a class="nav-link" href="{{ .URL | absLangURL }}">{{ i18n .Name }}</a>
</li>
{{ end }}
{{ end }}
</ul>
</div>
</nav>
</div>
</div>
</div>
</section>
</section>

0 comments on commit c0511f4

Please sign in to comment.