Skip to content

Commit e09f638

Browse files
authored
Merge pull request #484 from rvlzzr/fix-active
fix active detection for url's containing international characters
2 parents 83c54fd + 706d569 commit e09f638

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

src/components.tsx

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@ export function A(props: AnchorProps) {
5151
const to_ = to();
5252
if (to_ === undefined) return [false, false];
5353
const path = normalizePath(to_.split(/[?#]/, 1)[0]).toLowerCase();
54-
const loc = normalizePath(location.pathname).toLowerCase();
54+
const loc = decodeURI(normalizePath(location.pathname).toLowerCase());
5555
return [props.end ? path === loc : loc.startsWith(path + "/") || loc === path, path === loc];
5656
});
5757

0 commit comments

Comments
 (0)