From 96e0cb5313fef8a6ab89cdea85faa8fc61180fa4 Mon Sep 17 00:00:00 2001 From: afc163 Date: Fri, 26 Oct 2018 20:31:06 +0800 Subject: [PATCH] site: fix hash --- site/theme/template/Content/MainContent.jsx | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/site/theme/template/Content/MainContent.jsx b/site/theme/template/Content/MainContent.jsx index 4c697c4804..405279e7a4 100644 --- a/site/theme/template/Content/MainContent.jsx +++ b/site/theme/template/Content/MainContent.jsx @@ -72,7 +72,7 @@ export default class MainContent extends React.Component { } this.timer = setTimeout(() => { if (window.location.hash) { - document.querySelector(window.location.hash).scrollIntoView(); + document.querySelector(decodeURIComponent(window.location.hash)).scrollIntoView(); } }, 50); }