fix: Simplify HTML rendering in chunk output by removing unnecessary line breaks

This commit is contained in:
JB
2025-10-10 12:50:48 -07:00
parent 4f46eb74f4
commit 283651e7dd
+3 -4
View File
@@ -656,11 +656,10 @@ def _render_chunk_html(chunk: ChunkOverlay) -> str:
escaped_text = html.escape(raw_text)
if not escaped_text:
escaped_text = " "
body = escaped_text.replace("\n", "\n ")
return (
f" <div class=\"chunk\" id=\"{escaped_id}\"{speaker_attr}{voice_attr}{level_attr}>\n"
f" {body}\n"
" </div>"
f" <div class=\"chunk\" id=\"{escaped_id}\"{speaker_attr}{voice_attr}{level_attr}>"
f"{escaped_text}"
"</div>"
)