Skip to content

Commit fe0cd8f

Browse files
committed
refactor: minor InlineLInk optimizations
1 parent 054e20c commit fe0cd8f

File tree

1 file changed

+2
-3
lines changed

1 file changed

+2
-3
lines changed

packages/curve-ui-kit/src/shared/ui/InlineLink.tsx

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -10,13 +10,12 @@ export const InlineLink = ({ href, children }: { href: string; children: React.R
1010
const isExternal = href.startsWith('http')
1111
return (
1212
<Link
13-
component={isExternal ? Link : TanstackLink}
1413
sx={{ color: 'currentColor', '&:hover': { textDecoration: 'none' } }}
1514
href={href}
16-
{...(isExternal && { target: '_blank', rel: 'noreferrer noopener' })}
15+
{...(isExternal && { target: '_blank', rel: 'noreferrer noopener', component: TanstackLink })}
1716
>
1817
{children}
19-
{isExternal && <ArrowTopRightIcon fontSize={'small'} sx={{ verticalAlign: 'bottom' }} />}
18+
{isExternal && <ArrowTopRightIcon fontSize="small" sx={{ verticalAlign: 'bottom' }} />}
2019
</Link>
2120
)
2221
}

0 commit comments

Comments
 (0)