Exemple #1
0
 /// <summary>
 /// Преобразования объекта типв <see cref="StyleType"/> в html
 /// </summary>
 /// <param name="item"></param>
 /// <returns></returns>
 public static string ToHtml(this StyleType item)
 {
     return(item switch {
         SimpleText text => text.ToHtml(),
         InternalLinkItem link => link.ToHtml(),
         InlineImageItem image => image.ToHtml(),
         _ => item.ToString()
     });