You've already forked authentication-service
mirror of
https://github.com/matrix-org/matrix-authentication-service.git
synced 2025-11-20 12:02:22 +03:00
First-pass for Compound styles
This commit is contained in:
@@ -149,11 +149,15 @@ export const Link: React.FC<
|
||||
return (
|
||||
<a
|
||||
href={path}
|
||||
onClick={(e) => {
|
||||
e.preventDefault();
|
||||
startTransition(() => {
|
||||
setRoute(route);
|
||||
});
|
||||
onClick={(e: React.MouseEvent) => {
|
||||
// Local links should be handled by the internal routers
|
||||
// external links do not require a transition
|
||||
if (!path.startsWith("http")) {
|
||||
e.preventDefault();
|
||||
startTransition(() => {
|
||||
setRoute(route);
|
||||
});
|
||||
}
|
||||
}}
|
||||
{...props}
|
||||
>
|
||||
|
||||
Reference in New Issue
Block a user