|
|
|
@ -1,7 +1,6 @@ |
|
|
|
using Microsoft.AspNetCore.Mvc.Rendering; |
|
|
|
using Microsoft.AspNetCore.Razor.TagHelpers; |
|
|
|
using System.Collections.Generic; |
|
|
|
using System.Text.Encodings.Web; |
|
|
|
using System.Threading.Tasks; |
|
|
|
using Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Extensions; |
|
|
|
|
|
|
|
@ -9,13 +8,6 @@ namespace Volo.Abp.AspNetCore.Mvc.UI.Bootstrap.TagHelpers.Tab; |
|
|
|
|
|
|
|
public class AbpTabLinkTagHelperService : AbpTagHelperService<AbpTabLinkTagHelper> |
|
|
|
{ |
|
|
|
protected HtmlEncoder Encoder { get; } |
|
|
|
|
|
|
|
public AbpTabLinkTagHelperService(HtmlEncoder encoder) |
|
|
|
{ |
|
|
|
Encoder = encoder; |
|
|
|
} |
|
|
|
|
|
|
|
public override Task ProcessAsync(TagHelperContext context, TagHelperOutput output) |
|
|
|
{ |
|
|
|
SetPlaceholderForNameIfNotProvided(); |
|
|
|
@ -43,7 +35,7 @@ public class AbpTabLinkTagHelperService : AbpTagHelperService<AbpTabLinkTagHelpe |
|
|
|
anchor.AddCssClass("dropdown-item"); |
|
|
|
anchor.Attributes.Add("id", id); |
|
|
|
anchor.Attributes.Add("href", href); |
|
|
|
anchor.InnerHtml.AppendHtml(Encoder.Encode(title)); |
|
|
|
anchor.InnerHtml.Append(title); |
|
|
|
|
|
|
|
return anchor.ToHtmlString(); |
|
|
|
} |
|
|
|
@ -53,7 +45,7 @@ public class AbpTabLinkTagHelperService : AbpTagHelperService<AbpTabLinkTagHelpe |
|
|
|
anchor.AddCssClass("nav-link " + AbpTabItemActivePlaceholder); |
|
|
|
anchor.Attributes.Add("id", id); |
|
|
|
anchor.Attributes.Add("href", href); |
|
|
|
anchor.InnerHtml.AppendHtml(Encoder.Encode(title)); |
|
|
|
anchor.InnerHtml.Append(title); |
|
|
|
|
|
|
|
var listItem = new TagBuilder("li"); |
|
|
|
listItem.AddCssClass("nav-item"); |
|
|
|
|