Skip to content

Commit

Permalink
fix sort by weight order
Browse files Browse the repository at this point in the history
  • Loading branch information
xoxys committed Feb 5, 2020
1 parent 4236e57 commit 803dc97
Show file tree
Hide file tree
Showing 4 changed files with 4 additions and 3 deletions.
1 change: 1 addition & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
@@ -1,2 +1,3 @@
- BUGFIX
- fix typos
- fix sort by weight order
2 changes: 1 addition & 1 deletion layouts/partials/menu-bundle.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
{{ $site := .site }}

<ul class="gdoc-nav__list">
{{ range sort (default (seq 0) .sect) "weight" "desc" }}
{{ range sort (default (seq 0) .sect) "weight" }}
{{ $current.Scratch.Set "current" $current }}
{{ $current.Scratch.Set "site" $site }}

Expand Down
2 changes: 1 addition & 1 deletion layouts/partials/menu-filetree.html
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
{{ $current := .current }}

<ul class="gdoc-nav__list">
{{ range .sect.GroupBy "Weight" "desc" }}
{{ range .sect.GroupBy "Weight" }}
{{ range .ByTitle }}
{{ if not .Params.geekdocHidden }}
<li>
Expand Down
2 changes: 1 addition & 1 deletion layouts/partials/page-footer.html
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
{{ $current := .current }}
{{ $site := .site }}

{{ range sort (default (seq 0) .sect) "weight" "desc" }}
{{ range sort (default (seq 0) .sect) "weight" }}
{{ $current.Scratch.Set "current" $current }}
{{ $current.Scratch.Set "site" $site }}

Expand Down

0 comments on commit 803dc97

Please sign in to comment.