Files
gridpilot.gg/apps/website/components/social/FriendItem.tsx
2026-01-18 22:55:55 +01:00

38 lines
851 B
TypeScript

'use client';
import { Image } from '@/ui/Image';
import { SidebarItem } from '@/ui/SidebarItem';
import { Text } from '@/ui/Text';
import React from 'react';
interface FriendItemProps {
name: string;
avatarUrl: string;
country: string;
}
export function FriendItem({ name, avatarUrl, country }: FriendItemProps) {
return (
<SidebarItem
icon={
<div style={{ width: '100%', height: '100%', borderRadius: '9999px', overflow: 'hidden' }}>
<Image
src={avatarUrl}
alt={name}
width={36}
height={36}
objectFit="cover"
/>
</div>
}
>
<Text size="sm" variant="high" weight="medium" truncate block>
{name}
</Text>
<Text size="xs" variant="low" block>
{country}
</Text>
</SidebarItem>
);
}