moved key prop

This commit is contained in:
jojopirker
2023-01-06 16:50:25 +01:00
parent ad7ccb21d8
commit a1b0bb5561
@@ -60,13 +60,8 @@ export function MessageWithChildren(props: MessageWithChildrenProps) {
renderRecursive ? (
<HStack spacing={8} alignItems="start" justifyContent="center">
{children.map((item, idx) => (
<Box flex="1">
<MessageWithChildren
id={item.id}
depth={depth ? depth + 1 : 1}
maxDepth={maxDepth}
key={`recursiveMessageWChildren_${idx}`}
/>
<Box flex="1" key={`recursiveMessageWChildren_${idx}`}>
<MessageWithChildren id={item.id} depth={depth ? depth + 1 : 1} maxDepth={maxDepth} />
</Box>
))}
</HStack>