mirror of
https://github.com/Sendouc/sendou.ink.git
synced 2026-09-30 15:17:43 -05:00
mylink prefetch false by default
This commit is contained in:
@@ -14,7 +14,7 @@ const MyLink: React.FC<Props> = ({
|
||||
children,
|
||||
href,
|
||||
isExternal,
|
||||
prefetch = true,
|
||||
prefetch = false,
|
||||
isColored = true,
|
||||
}) => {
|
||||
const { themeColorShade } = useMyTheme();
|
||||
|
||||
@@ -112,7 +112,6 @@ function LeagueMates({
|
||||
? `/u/${mate.player.user.discordId}`
|
||||
: `/player/${mate.player.switchAccountId}`
|
||||
}
|
||||
prefetch={false}
|
||||
>
|
||||
{mate.player.name ?? "???"}
|
||||
</MyLink>
|
||||
|
||||
@@ -117,7 +117,7 @@ function LeagueMate({
|
||||
if (!mate.user && !mate.name) return <>{"???"}</>;
|
||||
if (mate.user)
|
||||
return (
|
||||
<MyLink href={`/u/${mate.user.discordId}`} prefetch={false}>
|
||||
<MyLink href={`/u/${mate.user.discordId}`}>
|
||||
<Flex alignItems="center">
|
||||
<UserAvatar user={mate.user} size="sm" mr={2} />
|
||||
{mate.user.username}
|
||||
@@ -125,11 +125,7 @@ function LeagueMate({
|
||||
</MyLink>
|
||||
);
|
||||
|
||||
return (
|
||||
<MyLink href={`/player/${mate.switchAccountId}`} prefetch={false}>
|
||||
{mate.name}
|
||||
</MyLink>
|
||||
);
|
||||
return <MyLink href={`/player/${mate.switchAccountId}`}>{mate.name}</MyLink>;
|
||||
}
|
||||
|
||||
export default TwinTable;
|
||||
|
||||
@@ -64,10 +64,7 @@ const Top500Table: React.FC<Props> = ({ placements }) => {
|
||||
)}
|
||||
</TableCell>
|
||||
<TableCell>
|
||||
<MyLink
|
||||
href={`/player/${placement.player.switchAccountId}`}
|
||||
prefetch={false}
|
||||
>
|
||||
<MyLink href={`/player/${placement.player.switchAccountId}`}>
|
||||
{placement.playerName}
|
||||
</MyLink>
|
||||
</TableCell>
|
||||
|
||||
@@ -181,7 +181,10 @@ const AvatarWithInfo: React.FC<AvatarWithInfoProps> = ({
|
||||
)}
|
||||
<Box width="100%" textAlign="center" mt={4}>
|
||||
{!!user.player?.switchAccountId && (
|
||||
<MyLink href={`/player/${user.player?.switchAccountId}`}>
|
||||
<MyLink
|
||||
href={`/player/${user.player?.switchAccountId}`}
|
||||
prefetch={true}
|
||||
>
|
||||
<Button leftIcon={<RiTrophyLine />} variant="outline">
|
||||
<Trans>View results</Trans>
|
||||
</Button>
|
||||
|
||||
@@ -115,7 +115,11 @@ function UserInfo({ user }: { user: Unpacked<GetAllUsersData> }) {
|
||||
</Link>
|
||||
<Box ml={4}>
|
||||
<Box fontWeight="bold">
|
||||
<MyLink href={`/u/${user.discordId}`} isColored={false}>
|
||||
<MyLink
|
||||
href={`/u/${user.discordId}`}
|
||||
isColored={false}
|
||||
prefetch={true}
|
||||
>
|
||||
{user.username}#{user.discriminator}
|
||||
</MyLink>
|
||||
{user.profile?.country ? (
|
||||
|
||||
Reference in New Issue
Block a user