diff --git a/lib/markdownRenderer.tsx b/lib/markdownRenderer.tsx index 0d981fb..0504553 100644 --- a/lib/markdownRenderer.tsx +++ b/lib/markdownRenderer.tsx @@ -55,19 +55,19 @@ function processLine(line: string, index: number, state: RenderState, elements: function renderHeading(line: string, index: number, elements: JSX.Element[]): boolean { if (line.startsWith('# ')) { - elements.push(

{line.substring(2)}

) + elements.push(

{line.substring(2)}

) return true } if (line.startsWith('## ')) { - elements.push(

{line.substring(3)}

) + elements.push(

{line.substring(3)}

) return true } if (line.startsWith('### ')) { - elements.push(

{line.substring(4)}

) + elements.push(

{line.substring(4)}

) return true } if (line.startsWith('#### ')) { - elements.push(

{line.substring(5)}

) + elements.push(

{line.substring(5)}

) return true } return false @@ -99,7 +99,7 @@ function renderBoldAndCodeLine(line: string, index: number, elements: JSX.Elemen function renderParagraphOrBreak(line: string, index: number, elements: JSX.Element[]): void { if (line.trim() !== '') { - elements.push(

{line}

) + elements.push(

{line}

) return } if (elements.length > 0) { @@ -118,7 +118,7 @@ function handleCodeBlock( ): void { if (state.inCodeBlock) { elements.push( -
+      
         {state.codeBlockContent.join('\n')}
       
) @@ -137,7 +137,7 @@ function closeListIfNeeded( ): void { if (state.currentList.length > 0 && !line.startsWith('- ') && !line.startsWith('* ') && line.trim() !== '') { elements.push( -