dishplanner/frontend-old/app/components/features/dishes/DishCard.tsx

22 lines
571 B
TypeScript
Raw Normal View History

2025-10-13 14:57:11 +02:00
import {UserType} from "@/types/UserType";
import {DishType} from "@/types/DishType";
interface Props {
user: UserType,
dish: DishType,
}
2025-11-09 13:09:22 +01:00
const DishCard = ({ user, dish }: Props) => {
2025-10-13 14:57:11 +02:00
return (
<div className="w-full flex py-2 text-xl font-bold text-primary">
<div className="user-badge flex-none w-16 text-center pr-5">
{ user.name.slice(0, 1) }
</div>
<div className="dish-name flex-1">
{ dish ? dish.name : '-' }
</div>
</div>
)
}
export default DishCard