0
0
mirror of https://github.com/twbs/bootstrap.git synced 2025-01-17 09:52:29 +01:00

append trailing slash to slug so that page name matching is more accurate

This commit is contained in:
Mark Otto 2016-10-24 16:05:32 -07:00
parent 2c80f4d7cd
commit e17a767a4c

View File

@ -1,7 +1,7 @@
<nav class="bd-links" id="docsNavbarContent">
{% for group in site.data.nav %}
{% assign link = group.pages | first %}
{% assign slug = group.title | downcase | replace: ' ', '-' || page.title | downcase | replace: ' ', '-' %}
{% assign slug = group.title | downcase | replace: ' ', '-' || page.title | downcase | replace: ' ', '-' | append: '/' %}
{% assign active = nil %}
{% if page.url contains slug %}