fixed version selection default value and added proper avatar names to the dropdown preview
This commit is contained in:
@ -66,6 +66,7 @@ export const TrophyCustomization: FC<AvatarSelectionProps> = ({
|
||||
const data = await getCurrentTrophies();
|
||||
if (data.length > 0) {
|
||||
setTrophyId(data[0].trophyId!);
|
||||
form.setValue("trophies", data[0].trophyId as number);
|
||||
}
|
||||
} catch (error) {
|
||||
console.error("Error fetching avatar parts:", error);
|
||||
@ -118,7 +119,7 @@ export const TrophyCustomization: FC<AvatarSelectionProps> = ({
|
||||
variant="outline"
|
||||
role="combobox"
|
||||
className={cn(
|
||||
"w-[300px] justify-between",
|
||||
"w-[400px] justify-between",
|
||||
!field.value && "text-muted-foreground",
|
||||
)}
|
||||
>
|
||||
@ -131,7 +132,7 @@ export const TrophyCustomization: FC<AvatarSelectionProps> = ({
|
||||
</Button>
|
||||
</FormControl>
|
||||
</PopoverTrigger>
|
||||
<PopoverContent className="w-[300px] p-0">
|
||||
<PopoverContent className="w-[400px] p-0">
|
||||
<Command>
|
||||
<CommandList>
|
||||
<CommandEmpty>No avatar part found.</CommandEmpty>
|
||||
|
Reference in New Issue
Block a user