Skip to content

Commit 1f7cff1

Browse files
Fix localized contents (#2546)
1 parent 6dde015 commit 1f7cff1

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

_includes/sidebar-toc-multipage-overview.html

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -18,11 +18,10 @@ <h5 class="contents">Contents</h5>
1818

1919
{% if pg.num and (page.partof == pg.partof) %}
2020
{% if page.language %} <!-- if page is a translation, get the translated title -->
21-
{% assign prefix = page.language | prepend: '/' %}
22-
{% assign localizedId = pg.id | prepend: prefix %}
21+
{% assign localizedId = pg.id %}
2322
{% for lpg in site.[page.language] %}
2423
{% if lpg.id == localizedId %}
25-
<li><a {% if page.title == lpg.title %}class="active"{% endif %} href="/{{ site.baseurl }}{{ page.language }}{{ pg.url }}">{{ lpg.title }}</a>
24+
<li><a {% if page.title == lpg.title %}class="active"{% endif %} href="{{ site.baseurl }}{{ pg.url }}">{{ lpg.title }}</a>
2625
{{ toc }}</li>
2726
{% endif %}
2827
{% endfor %}

0 commit comments

Comments
 (0)