diff --git a/packages/api/src/types/CommentType.ts b/packages/api/src/types/CommentType.ts index df97de20..ae006265 100644 --- a/packages/api/src/types/CommentType.ts +++ b/packages/api/src/types/CommentType.ts @@ -11,7 +11,14 @@ export type GetCommentsRequest = { optionId: string; }; -export type GetCommentsResponse = (Comment & { user?: { id: string; username: string } })[]; +export type GetCommentsResponse = (Comment & { + user?: { + id: string; + username: string; + firstName: string; + lastName: string; + }; +})[]; export type PostCommentRequest = { value: string; diff --git a/packages/berlin/src/components/tables/comment-table/CommentsTable.tsx b/packages/berlin/src/components/tables/comment-table/CommentsTable.tsx index 725460d9..6580aac1 100644 --- a/packages/berlin/src/components/tables/comment-table/CommentsTable.tsx +++ b/packages/berlin/src/components/tables/comment-table/CommentsTable.tsx @@ -103,7 +103,9 @@ function CommentsTable({ comment }: CommentsTableProps) { {comment.value} - @{comment.user?.username} + + {comment.user?.firstName} {comment.user?.lastName} + {formattedDate} Distinct groups: {option.distinctGroups} - Group names: {option.listOfGroupNames.join(', ')} + Voter affiliations: {option.listOfGroupNames.join(', ')}