diff --git a/islands/AiChatBox.tsx b/islands/AiChatBox.tsx index 24bb157..a17b66a 100644 --- a/islands/AiChatBox.tsx +++ b/islands/AiChatBox.tsx @@ -1,5 +1,5 @@ import { JsonParseStream } from '$std/json/mod.ts' -import { CSS, render as renderMd } from '@deno/gfm' +import { Markdown } from ':components/Markdown.tsx' import { Signal, signal, useSignal } from '@preact/signals' import { JSX } from 'preact' import { useEffect, useRef } from 'preact/hooks' @@ -15,16 +15,6 @@ const currentReader = signal | null>( ) let currentResponse: string[] = [] -function MdCell({ children }: { children: Signal }) { - return ( -
-
- ) -} - type BotMessage = { role: string content: string @@ -95,7 +85,6 @@ export default function AiChatBox() { return ( <> - -
{history}
+
+ {history} +
) { const botEntry = ( - {botMessage} + {botMessage} )