Skip to content

message_box

fastagency.ui.mesop.message.message_box #

message_box(
    message: ConversationMessage,
    read_only: bool,
    *,
    styles: MesopHomePageStyles
) -> None
Source code in fastagency/ui/mesop/message.py
def message_box(
    message: ConversationMessage, read_only: bool, *, styles: MesopHomePageStyles
) -> None:
    io_message_dict = json.loads(message.io_message_json)
    level = message.level
    conversation_id = message.conversation_id
    io_message = IOMessage.create(**io_message_dict)
    visitor = MesopGUIMessageVisitor(level, conversation_id, message, styles, read_only)
    visitor.process_message(io_message)