Skip to content

Commit

Permalink
Merge pull request #900 from near/develop
Browse files Browse the repository at this point in the history
fix link regression
  • Loading branch information
charleslavon authored Jan 3, 2024
2 parents 3aeef22 + 1d5b5af commit 95988f7
Showing 1 changed file with 1 addition and 0 deletions.
1 change: 1 addition & 0 deletions src/components/vm/VmInitializer.tsx
Original file line number Diff line number Diff line change
Expand Up @@ -106,6 +106,7 @@ export default function VmInitializer() {
Link: ({ to, href, ...rest }: { to: string | object | undefined; href: string | object }) => {
const cleanProps = mapValues({ to, href, ...rest }, (val: any, key: string) => {
if (!['to', 'href'].includes(key)) return val;
if (key === 'href' && !val) val = to;
return typeof val === 'string' && isValidAttribute('a', 'href', val) ? val : 'about:blank';
});

Expand Down

2 comments on commit 95988f7

@vercel
Copy link

@vercel vercel bot commented on 95988f7 Jan 3, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@vercel
Copy link

@vercel vercel bot commented on 95988f7 Jan 3, 2024

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please sign in to comment.