various improvements, edit tournament, etc
This commit is contained in:
@@ -15,15 +15,15 @@ const Profile = ({ player }: ProfileProps) => {
|
||||
label: "Overview",
|
||||
content: <Text p="md">Stats/Badges will go here</Text>
|
||||
},
|
||||
{
|
||||
label: "Matches",
|
||||
content: <Text p="md">Matches feed will go here</Text>
|
||||
},
|
||||
{
|
||||
label: "Teams",
|
||||
content: <>
|
||||
<TeamList teams={player.teams || []} />
|
||||
</>
|
||||
},
|
||||
{
|
||||
label: "Tournaments",
|
||||
content: <Text p="md">Panel 3 content</Text>
|
||||
}
|
||||
];
|
||||
|
||||
|
||||
@@ -1,10 +1,11 @@
|
||||
import { updatePlayer } from "@/features/players/server";
|
||||
import { useMutation } from "@tanstack/react-query";
|
||||
import { Button, Stack, TextInput } from "@mantine/core"
|
||||
import { Stack, TextInput } from "@mantine/core"
|
||||
import { useForm } from "@mantine/form";
|
||||
import toast from "@/lib/sonner";
|
||||
import { useRouter } from "@tanstack/react-router";
|
||||
import { Player } from "../../types";
|
||||
import Button from "@/components/button";
|
||||
|
||||
interface NameUpdateFormProps {
|
||||
player: Player;
|
||||
@@ -50,8 +51,8 @@ const NameUpdateForm = ({ player, toggle }: NameUpdateFormProps) => {
|
||||
<Stack gap='xs'>
|
||||
<TextInput label='First Name' {...form.getInputProps('first_name')} />
|
||||
<TextInput label='Last Name' {...form.getInputProps('last_name')} />
|
||||
<Button fullWidth loading={isPending} type='submit'>Save</Button>
|
||||
<Button fullWidth variant='subtle' color='red' onClick={toggle}>Cancel</Button>
|
||||
<Button loading={isPending} type='submit'>Save</Button>
|
||||
<Button variant='subtle' color='red' onClick={toggle}>Cancel</Button>
|
||||
</Stack>
|
||||
</form>
|
||||
)
|
||||
|
||||
Reference in New Issue
Block a user