fix: 修复相对路径 @see 链接跳转
This commit is contained in:
@@ -46,7 +46,7 @@ export const ApiDocViewer = () => {
|
||||
}, [])
|
||||
|
||||
const handleReferenceClick = useCallback((ref: string) => {
|
||||
const normalizedRef = ref.replace('.md', '')
|
||||
const normalizedRef = ref.replace('.md', '').replace(/^\.\.\//, '')
|
||||
const allFiles = Object.keys(DOCS_FILES)
|
||||
const match = allFiles.find(f => f.replace('.md', '') === normalizedRef)
|
||||
if (match) {
|
||||
|
||||
Reference in New Issue
Block a user