mirror of
https://github.com/wassname/Open-Assistant.git
synced 2026-08-15 12:05:19 +08:00
fix: review comments and frontend build issue in label_initial_prompt.tsx due to previous message_id changes
This commit is contained in:
@@ -12,8 +12,8 @@ export interface Message {
|
||||
|
||||
export const Messages = ({ messages, post_id }: { messages: Message[]; post_id: string }) => {
|
||||
const items = messages.map((messageProps: Message, i: number) => {
|
||||
const { text } = messageProps;
|
||||
const { message_id } = messageProps;
|
||||
const { text } = messageProps;
|
||||
return (
|
||||
<FlaggableElement text={text} post_id={post_id} message_id={message_id} key={i + text}>
|
||||
<MessageView {...messageProps} />
|
||||
@@ -24,7 +24,7 @@ export const Messages = ({ messages, post_id }: { messages: Message[]; post_id:
|
||||
return <Grid gap={2}>{items}</Grid>;
|
||||
};
|
||||
|
||||
export const MessageView = ({ is_assistant, text }: Message) => {
|
||||
export const MessageView = ({ is_assistant, text, message_id }: Message) => {
|
||||
const { colorMode } = useColorMode();
|
||||
|
||||
const bgColor = useMemo(() => {
|
||||
|
||||
Reference in New Issue
Block a user