From 7f56f57778b138c793dc8c56d62a820e7caf1b57 Mon Sep 17 00:00:00 2001 From: Alex Date: Sat, 6 May 2023 15:22:23 +0100 Subject: [PATCH] better markdown styling --- frontend/src/conversation/ConversationBubble.tsx | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) diff --git a/frontend/src/conversation/ConversationBubble.tsx b/frontend/src/conversation/ConversationBubble.tsx index d1b78fec..ae3db621 100644 --- a/frontend/src/conversation/ConversationBubble.tsx +++ b/frontend/src/conversation/ConversationBubble.tsx @@ -22,6 +22,16 @@ const ConversationBubble = forwardRef< ref, ) { const [showFeedback, setShowFeedback] = useState(false); + const List = ({ + ordered, + children, + }: { + ordered?: boolean; + children: React.ReactNode; + }) => { + const Tag = ordered ? 'ol' : 'ul'; + return {children}; + }; let bubble; if (type === 'QUESTION') { @@ -75,6 +85,12 @@ const ConversationBubble = forwardRef< ); }, + ul({ node, children }) { + return {children}; + }, + ol({ node, children }) { + return {children}; + }, }} > {message}