We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
There was an error while loading. Please reload this page.
1 parent 072d50b commit 1d8e2f5Copy full SHA for 1d8e2f5
apps/events/src/components/todos.tsx
@@ -46,7 +46,23 @@ export const Todos = () => {
46
<h2>{todo.name}</h2>
47
{todo.assignees.length > 0 && (
48
<span className="text-xs text-gray-500">
49
- Assigned to: {todo.assignees.map((assignee) => assignee.name).join(', ')}
+ Assigned to:{' '}
50
+ {todo.assignees.map((assignee) => (
51
+ <span key={assignee.id} className="border rounded-sm mr-1 p-1">
52
+ {assignee.name}
53
+ <button
54
+ type="button"
55
+ onClick={() =>
56
+ updateEntity(todo.id, {
57
+ assignees: todo.assignees.map((assignee) => assignee.id).filter((id) => id !== assignee.id),
58
+ })
59
+ }
60
+ className="cursor-pointer ml-1 text-red-400"
61
+ >
62
+ x
63
+ </button>
64
+ </span>
65
+ ))}
66
</span>
67
)}
68
<input
0 commit comments