Skip to content

Commit

Permalink
Use bootstrap right alignment
Browse files Browse the repository at this point in the history
  • Loading branch information
celestehorgan committed Jul 8, 2020
1 parent 0f30bc0 commit 086e8a6
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 15 deletions.
12 changes: 0 additions & 12 deletions assets/scss/_custom.scss
Original file line number Diff line number Diff line change
Expand Up @@ -101,18 +101,6 @@ section {
left: 0;
background: #fff;
}

.dropdown-menu {
left: -80px;
}

&.dropdown:hover {
color: $medium-grey;

.dropdown-menu {
display: block;
}
}
}
}

Expand Down
10 changes: 10 additions & 0 deletions layouts/partials/navbar-lang-selector.html
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
{{/* Link directly to documentation etc., if possible. */}}
{{ $langPage := cond (gt (len .Translations) 0) . .Site.Home }}
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
{{ $langPage.Language.LanguageName }}
</a>
<div class="dropdown-menu dropdown-menu-right" aria-labelledby="navbarDropdownMenuLink">
{{ range $langPage.Translations }}
<a class="dropdown-item" href="{{ .RelPermalink }}">{{ .Language.LanguageName }}</a>
{{ end }}
</div>
6 changes: 3 additions & 3 deletions layouts/partials/navbar-version-selector.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,8 @@
<a class="nav-link dropdown-toggle" href="#" id="navbarDropdown" role="button" data-toggle="dropdown" aria-haspopup="true" aria-expanded="false">
{{ T "version_menu" }}
{{ .Site.Params.version_menu }}
</a>
<div class="dropdown-menu" aria-labelledby="navbarDropdownMenuLink">
<div class="dropdown-menu dropdown-menu-right" aria-labelledby="navbarDropdownMenuLink">
{{ range .Site.Params.versions }}
<a class="dropdown-item" href="{{ .url }}">{{ .version }}</a>
{{ end }}
</div>
</div>

0 comments on commit 086e8a6

Please sign in to comment.