SummaryContent & DetailContent not working in NotificationMessage

You can check my reply here: Multi Line in DialogService.Confirm() - #14 by korchev

Here is something that will work in a regular C# file:

NotificationService.Notify(new NotificationMessage
{
  Severity = NotificationSeverity.Warning,
  Duration = 40000,
  SummaryContent = ns => builder => builder.AddMarkupContent(0, "<strong>Summary</strong>"),
  DetailContent = ns => builder => builder.AddMarkupContent(0, "Paragraph 1 <br />Paragraph 2")
});