Przeglądaj źródła

HomePage uses Params.urlFunc + Based on HomePage relLink (#872)

### 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>
toinux 1 rok temu
rodzic
commit
745f785dd9
2 zmienionych plików z 5 dodań i 2 usunięć
  1. 1 0
      CONTRIBUTORS.md
  2. 4 2
      layouts/partials/header.html

+ 1 - 0
CONTRIBUTORS.md

@@ -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)

+ 4 - 2
layouts/partials/header.html

@@ -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">