public INotificationContentBuilder AddLink(string href, string text) { var template = LoadFromFile(LinkTemplateName); var injected = InjectContentIntoTemplate(template, ("Link-Href", href), ("Link-Content", text)); _contentSections.Add(injected); return(this); }
public INotificationContentBuilder AddText(string text) { var template = LoadFromFile(TextTemplateName); var injected = InjectContentIntoTemplate(template, ("Text-Content", text)); _contentSections.Add(injected); return(this); }
public string Build() { var template = LoadFromFile(BaseTemplateName); var joinedSections = string.Join('\n', _contentSections); var injectedHtml = InjectContentIntoTemplate( template, ("Layout-Title", _title), ("Layout-Content", joinedSections)); return(InlineCss(injectedHtml)); }