Skip to content

Commit 9f259df

Browse files
committed
Fix wiki toc link borken for non-English languages
1 parent 02bbdd4 commit 9f259df

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

web_src/js/markup/anchors.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -38,7 +38,7 @@ export function initMarkupAnchors() {
3838
const href = a.getAttribute('href');
3939
if (!href.startsWith('#user-content-')) continue;
4040
const originalId = href.replace(/^#user-content-/, '');
41-
a.setAttribute('href', `#${encodeURIComponent(originalId)}`);
41+
a.setAttribute('href', `#${originalId}`);
4242
if (a.closest('.markup').querySelectorAll(`a[name="${originalId}"]`).length !== 1) {
4343
a.addEventListener('click', (e) => {
4444
scrollToAnchor(e.currentTarget.getAttribute('href'), false);

0 commit comments

Comments
 (0)