merlyn/frontend/src/components/EmbeddingSelection/EmbedderItem/index.jsx
Sean Hatfield c8c618137f
[CHORE] Clean up text and bg hex colors (#1685)
clean up text and bg hex colors

Co-authored-by: Timothy Carambat <rambat1010@gmail.com>
2024-06-17 14:55:56 -07:00

38 lines
885 B
JavaScript

export default function EmbedderItem({
name,
value,
image,
description,
checked,
onClick,
}) {
return (
<div
onClick={() => onClick(value)}
className={`w-full p-2 rounded-md hover:cursor-pointer hover:bg-white/10 ${
checked ? "bg-white/10" : ""
}`}
>
<input
type="checkbox"
value={value}
className="peer hidden"
checked={checked}
readOnly={true}
formNoValidate={true}
/>
<div className="flex gap-x-4 items-center">
<img
src={image}
alt={`${name} logo`}
className="w-10 h-10 rounded-md"
/>
<div className="flex flex-col">
<div className="text-sm font-semibold text-white">{name}</div>
<div className="mt-1 text-xs text-description">{description}</div>
</div>
</div>
</div>
);
}