Skip to content

Commit

Permalink
HomePage uses Params.urlFunc + Based on HomePage relLink (#872)
Browse files Browse the repository at this point in the history
### Prerequisites

Put an `x` into the box(es) that apply:

- [x] This pull request fixes a bug.
- [ ] This pull request adds a feature.
- [ ] This pull request introduces breaking change.

### Description

Use urlFunc on homepage link + refer to .Site.Home instead of
.Site.BaseURL

+ explicitly use .Site as . for clarity

### Issues Resolved

fix #871 

### Checklist

Put an `x` into the box(es) that apply:

#### General

- [x] Describe what changes are being made
- [x] Explain why and how the changes were necessary and implemented
respectively
- [x] Reference issue with `#<ISSUE_NO>` if applicable

#### Resources

- [ ] If you have changed any SCSS code, run `make release` to
regenerate all CSS files

#### Contributors

- [x] Add yourself to `CONTRIBUTORS.md` if you aren't on it already
- [x] Linted the file as an optional task

---------

Co-authored-by: Luiz F. A. de Prá <luizdepra@users.noreply.github.com>
  • Loading branch information
itzwam and luizdepra committed Feb 28, 2024
1 parent e5ffcde commit 745f785
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 2 deletions.
1 change: 1 addition & 0 deletions CONTRIBUTORS.md
Original file line number Diff line number Diff line change
Expand Up @@ -140,3 +140,4 @@
- [Muqeet Malik](https://github.com/mmalik23)
- [Sammy44nts](https://github.com/sammy44nts)
- [Leo Heimann Ruiz](https://leo.heitmannruiz.org/)
- [Antoine "Toinux" Wam](https://github.com/itzwam)
6 changes: 4 additions & 2 deletions layouts/partials/header.html
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
<nav class="navigation">
<section class="container">
<a class="navigation-title" href="{{ .Site.BaseURL | relLangURL }}">
{{ .Site.Title }}
{{ with .Site }}
<a class="navigation-title" href="{{ absLangURL "" }}">
{{ .Title }}
</a>
{{ end }}
{{ if or .Site.Menus.main .Site.IsMultiLingual }}
<input type="checkbox" id="menu-toggle" />
<label class="menu-button float-right" for="menu-toggle">
Expand Down

0 comments on commit 745f785

Please sign in to comment.