File tree Expand file tree Collapse file tree 2 files changed +17
-3
lines changed Expand file tree Collapse file tree 2 files changed +17
-3
lines changed Original file line number Diff line number Diff line change @@ -45,8 +45,9 @@ export const prepareSystemPrompt = {
45
45
46
46
let prompt = `You are a helpful assistant that explains Accord Project ${ typeName } code clearly and concisely.
47
47
Focus on what the code does, its purpose, and any important details about its structure or syntax.
48
- Provide easy to understand explanations for developers.\n\n` ;
49
-
48
+ Provide easy to understand explanations for developers. You can break down the code in detail line-by-line
49
+ but don't include the complete code block in your response as it is, user already knows their selection.\n\n` ;
50
+
50
51
return includeEditorContents ( prompt , aiConfig , editorsContent ) ;
51
52
} ,
52
53
Original file line number Diff line number Diff line change @@ -169,7 +169,20 @@ const CodeSelectionMenu: React.FC<CodeSelectionMenuProps> = ({
169
169
< div className = "text-sm text-gray-700 prose lg:prose-md" >
170
170
< ReactMarkdown
171
171
components = { {
172
- code : ( { children, className } ) => < code className = { `bg-gray-200 p-1 rounded-md before:content-[''] after:content-[''] ${ className } ` } > { children } </ code > ,
172
+ pre : ( { children } ) => {
173
+ return (
174
+ < pre className = "[&_code]:bg-transparent" >
175
+ { children }
176
+ </ pre >
177
+ ) ;
178
+ } ,
179
+ code : ( { children, className } ) => {
180
+ return (
181
+ < code className = { `bg-gray-200 p-1 rounded-md before:content-[''] after:content-[''] ${ className } ` } >
182
+ { children }
183
+ </ code >
184
+ ) ;
185
+ }
173
186
} } >
174
187
{ explanation }
175
188
</ ReactMarkdown >
You can’t perform that action at this time.
0 commit comments