fix: pdf issue w/ markdown

This commit is contained in:
Timothy J. Baek 2024-10-28 05:47:53 -07:00
parent 25a2c6ee52
commit bcf88585de

View File

@ -54,18 +54,18 @@ class PDFGenerator:
html_content = markdown(content, extensions=["pymdownx.extra"])
html_message = f"""
<div class="message">
<small> {date_str} </small>
<div>
<h2>
<strong>{role.title()}</strong>
<small class="text-muted">{model}</small>
</h2>
</div>
<div class="markdown-section">
{html_content}
</div>
</div>
<div> {date_str} </div>
<div class="message">
<div>
<h2>
<strong>{role.title()}</strong>
<span style="font-size: 12px; color: #888;">{model}</span>
</h2>
</div>
<pre class="markdown-section">
{content}
</pre>
</div>
"""
return html_message