add target to ui button link

This commit is contained in:
Matthias Nannt
2023-01-30 13:34:14 +01:00
parent 1392bc9ad2
commit b8fd9ee624

View File

@@ -138,7 +138,7 @@ export const Button = forwardRef<HTMLAnchorElement | HTMLButtonElement, ButtonPr
</>
);
return props.href ? (
<Link passHref href={props.href} shallow={shallow && shallow}>
<Link passHref href={props.href} shallow={shallow && shallow} target={props.target || "_self"}>
{element}
</Link>
) : (