import { getActiveConvoIdAtom, setActiveConvoIdAtom, } from "@/_helpers/JotaiWrapper"; import { useAtomValue, useSetAtom } from "jotai"; import Image from "next/image"; type Props = { imageUrl: string; conversationId: string; }; const CompactHistoryItem: React.FC = ({ imageUrl, conversationId }) => { const activeConvoId = useAtomValue(getActiveConvoIdAtom); const setActiveConvoId = useSetAtom(setActiveConvoIdAtom); const isSelected = activeConvoId === conversationId; return ( ); }; export default CompactHistoryItem;