import { FiFileText, FiImage, FiFile } from "react-icons/fi";
function SharedFile({ isDark, fileName, time, type }) {
// Get icon based on file type
const getIcon = () => {
if (type === "image") {
return ;
}
if (type === "pdf") {
return ;
}
return ;
};
// Get icon color based on type
const getIconColor = () => {
if (type === "pdf") {
return "#ef4444";
}
if (type === "image") {
return "#10b981";
}
return "var(--primary)";
};
return (
(e.currentTarget.style.background = "var(--hover-primary)")
}
onMouseLeave={(e) => (e.currentTarget.style.background = "transparent")}
>
{getIcon()}
{fileName}
Gửi lúc {time}
);
}
export default SharedFile;