import * as React from "react"; import { List, ListItem, ListItemAvatar, ListItemText, Avatar, Typography, Box, Button, } from "@mui/material"; export interface LatestItem { id: string | number; icon: React.ReactNode; iconBgColor?: string; title: string; subtitle: string; amount: string; timeAgo: string; } export interface LatestItemsListProps { title?: string; items: LatestItem[]; onViewAll?: () => void; accentColor: any; } export default function LatestItems({ title = "Recent Transactions", items, onViewAll, accentColor, }: LatestItemsListProps) { return ( {/* Header */} {title} {onViewAll && ( )} {/* List */} {items.map((item, index) => ( {item.icon} {item.title} } secondary={ {item.subtitle} } /> {item.amount} {item.timeAgo} ))} ); }