mirror of
https://github.com/MindWorkAI/AI-Studio.git
synced 2025-02-10 18:09:07 +00:00
Override header styles for Markdown
This commit is contained in:
parent
2abc9a1436
commit
a6e9ef7757
@ -36,6 +36,7 @@
|
||||
else
|
||||
{
|
||||
<MudMarkdown Value="@textContent.Text"/>
|
||||
<MudMarkdown Value="@textContent.Text" OverrideHeaderTypo="@Markdown.OverrideHeaderTypo"/>
|
||||
}
|
||||
}
|
||||
|
||||
|
16
app/MindWork AI Studio/Tools/Markdown.cs
Normal file
16
app/MindWork AI Studio/Tools/Markdown.cs
Normal file
@ -0,0 +1,16 @@
|
||||
namespace AIStudio.Tools;
|
||||
|
||||
public static class Markdown
|
||||
{
|
||||
public static Typo OverrideHeaderTypo(Typo arg) => arg switch
|
||||
{
|
||||
Typo.h1 => Typo.h4,
|
||||
Typo.h2 => Typo.h5,
|
||||
Typo.h3 => Typo.h6,
|
||||
Typo.h4 => Typo.h6,
|
||||
Typo.h5 => Typo.h6,
|
||||
Typo.h6 => Typo.h6,
|
||||
|
||||
_ => arg
|
||||
};
|
||||
}
|
Loading…
Reference in New Issue
Block a user