浏览代码

fix iframe mode with hash-links

REJack 3 年之前
父节点
当前提交
26c84e39a3
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      build/js/IFrame.js

+ 1 - 1
build/js/IFrame.js

@@ -142,7 +142,7 @@ class IFrame {
       return
     }
 
-    const uniqueName = link.replace('./', '').replace(/["&'./:=?[\]]/gi, '-').replace(/(--)/gi, '')
+    const uniqueName = link.replace('./', '').replace(/["#&'./:=?[\]]/gi, '-').replace(/(--)/gi, '')
     const navId = `tab-${uniqueName}`
 
     if (!this._config.allowDuplicates && $(`#${navId}`).length > 0) {