Skip to content

Commit

Permalink
Update conditions for breadcrumb placement in njk file
Browse files Browse the repository at this point in the history
The breadcrumb placement conditions in the 'breadcrumbs.njk' file have been updated. The changes include an addition of a new condition to exclude the 'home.njk' layout from showing the breadcrumbs. This modification aims to improve the accuracy and usability of breadcrumbs and enhance the user navigation experience.
  • Loading branch information
reatlat committed Feb 17, 2024
1 parent 78f5519 commit 6498984
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/_includes/partials/breadcrumbs.njk
Expand Up @@ -20,7 +20,7 @@
{% elif layout == 'post.njk' %}
<a class="text-white hover:text-amber-300"
href="/blog/{{ title | slugify }}/">{{ title | titleSinPeriod }}<span class="text-white">&nbsp;/</span></a>
{% elif permalink != '/blog/' %}
{% elif permalink != '/blog/' and layout != 'home.njk' %}
<a class="text-white hover:text-amber-300"
href="/{{ (page.filePathStem or '') | replace('/', '') }}/">{{ (title or '') | titleSinPeriod }}<span class="text-white">&nbsp;/</span></a>
{% endif %}
Expand Down

0 comments on commit 6498984

Please sign in to comment.