diff options
author | Wu Cheng-Han | 2016-11-26 19:46:20 +0800 |
---|---|---|
committer | Wu Cheng-Han | 2016-11-26 19:46:20 +0800 |
commit | 64d1d2c04b4d3a43d17d193819eef83b3b4641a5 (patch) | |
tree | 3fd36414e23365a257bd052a7a23605805fb4746 /public | |
parent | 80ee507951914aef9df62d05d7d482cbb44c4729 (diff) |
Fix published note won't scroll to hash on load
Diffstat (limited to 'public')
-rw-r--r-- | public/js/pretty.js | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/public/js/pretty.js b/public/js/pretty.js index b5c5ba8a..f43df90c 100644 --- a/public/js/pretty.js +++ b/public/js/pretty.js @@ -18,6 +18,7 @@ var smoothHashScroll = extra.smoothHashScroll; var postProcess = extra.postProcess; var updateLastChange = extra.updateLastChange; var parseMeta = extra.parseMeta; +var scrollToHash = extra.scrollToHash; var preventXSS = require('./render').preventXSS; var markdown = $("#doc.markdown-body"); @@ -117,6 +118,7 @@ $(window).resize(function () { $(document).ready(function () { windowResize(); generateScrollspy(); + setTimeout(scrollToHash, 0); //tooltip $('[data-toggle="tooltip"]').tooltip(); }); |