Skip to content

Commit 54cf6ce

Browse files
authored
fix(router): don't intercept download links (#1452)
1 parent 067e1a9 commit 54cf6ce

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/client/app/router.ts

+1-1
Original file line numberDiff line numberDiff line change
@@ -142,7 +142,7 @@ export function createRouter(
142142
if (button) return
143143

144144
const link = (e.target as Element).closest('a')
145-
if (link && !link.closest('.vp-raw')) {
145+
if (link && !link.closest('.vp-raw') && !link.download) {
146146
const { href, origin, pathname, hash, search, target } = link
147147
const currentUrl = window.location
148148
const extMatch = pathname.match(/\.\w+$/)

0 commit comments

Comments
 (0)