mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2026-08-24 20:52:11 +00:00
Fix single line breaks rendering as spaces in chat messages
This commit is contained in:
parent
fc53278c60
commit
46ad011e7b
@ -103,7 +103,7 @@
|
|||||||
var segmentContent = segment.GetContent(renderPlan.Source);
|
var segmentContent = segment.GetContent(renderPlan.Source);
|
||||||
if (segment.Type is MarkdownRenderSegmentType.MARKDOWN)
|
if (segment.Type is MarkdownRenderSegmentType.MARKDOWN)
|
||||||
{
|
{
|
||||||
<MudMarkdown @key="@segment.RenderKey" Value="@segmentContent" Props="Markdown.DefaultConfig" Styling="@this.MarkdownStyling" MarkdownPipeline="Markdown.SAFE_MARKDOWN_PIPELINE" />
|
<MudMarkdown @key="@segment.RenderKey" Value="@segmentContent" Props="Markdown.DefaultConfig" Styling="@this.MarkdownStyling" MarkdownPipeline="Markdown.CHAT_MARKDOWN_PIPELINE" />
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|||||||
@ -10,6 +10,12 @@ public static class Markdown
|
|||||||
.DisableHtml()
|
.DisableHtml()
|
||||||
.Build();
|
.Build();
|
||||||
|
|
||||||
|
public static readonly MarkdownPipeline CHAT_MARKDOWN_PIPELINE = new MarkdownPipelineBuilder()
|
||||||
|
.UseAdvancedExtensions()
|
||||||
|
.UseSoftlineBreakAsHardlineBreak()
|
||||||
|
.DisableHtml()
|
||||||
|
.Build();
|
||||||
|
|
||||||
public static MudMarkdownProps DefaultConfig => new()
|
public static MudMarkdownProps DefaultConfig => new()
|
||||||
{
|
{
|
||||||
Heading =
|
Heading =
|
||||||
|
|||||||
Loading…
Reference in New Issue
Block a user