diff --git a/src/renderer/src/pages/home/Markdown/CodeBlock.tsx b/src/renderer/src/pages/home/Markdown/CodeBlock.tsx index 321da3c265..209c44f577 100644 --- a/src/renderer/src/pages/home/Markdown/CodeBlock.tsx +++ b/src/renderer/src/pages/home/Markdown/CodeBlock.tsx @@ -36,6 +36,8 @@ const CodeBlock: React.FC = ({ children, className, node, blockId }) => { const handleSave = useCallback( async (newContent: string) => { if (id !== undefined) { + // The event form cannot obtain the completion status of the handler via a promise. + // TODO: Use useContext to get topicId, use useEditCodeBlock to edit code block. EventEmitter.emit(EVENT_NAMES.EDIT_CODE_BLOCK, { msgBlockId: blockId, codeBlockId: id,