mirror of
https://github.com/wassname/Open-Assistant.git
synced 2026-08-11 11:13:12 +08:00
Admin user management (#1393)
part of #1022 Allow updating the show_on_leaderboard field. Add raw JSON of the user object. Add a new user message table. Also fixed style issue: hard to see reaction count when the user also reacted. Rename MessageTable to MessageConversation.
This commit is contained in:
@@ -0,0 +1,24 @@
|
||||
import { Stack } from "@chakra-ui/react";
|
||||
import { MessageTableEntry } from "src/components/Messages/MessageTableEntry";
|
||||
import { Message } from "src/types/Conversation";
|
||||
|
||||
interface MessageConversationProps {
|
||||
messages: Message[];
|
||||
enableLink?: boolean;
|
||||
highlightLastMessage?: boolean;
|
||||
}
|
||||
|
||||
export function MessageConversation({ messages, enableLink, highlightLastMessage }: MessageConversationProps) {
|
||||
return (
|
||||
<Stack spacing="4">
|
||||
{messages.map((message, idx) => (
|
||||
<MessageTableEntry
|
||||
enabled={enableLink}
|
||||
message={message}
|
||||
key={message.id + message.frontend_message_id}
|
||||
highlight={highlightLastMessage && idx === messages.length - 1}
|
||||
/>
|
||||
))}
|
||||
</Stack>
|
||||
);
|
||||
}
|
||||
Reference in New Issue
Block a user