[frontend/mfm] Add fallback fg and bg fn values
This commit is contained in:
parent
4d3886880e
commit
5713ab4123
1 changed files with 4 additions and 0 deletions
|
@ -472,6 +472,8 @@ public static partial class MfmRenderer
|
|||
|
||||
if (args.TryGetValue("color", out var color) && ValidColor(color))
|
||||
el.SetAttribute("style", $"display: inline-block; color: #{color};");
|
||||
else
|
||||
el.SetAttribute("style", $"display: inline-block; color: #f00;");
|
||||
|
||||
return el;
|
||||
}
|
||||
|
@ -482,6 +484,8 @@ public static partial class MfmRenderer
|
|||
|
||||
if (args.TryGetValue("color", out var color) && ValidColor(color))
|
||||
el.SetAttribute("style", $"display: inline-block; background-color: #{color};");
|
||||
else
|
||||
el.SetAttribute("style", $"display: inline-block; background-color: #f00;");
|
||||
|
||||
return el;
|
||||
}
|
||||
|
|
Loading…
Add table
Reference in a new issue