Ana içeriğe atla

Kayıtlar

Ocak, 2024 tarihine ait yayınlar gösteriliyor

SetStyleTagHelper

[HtmlTargetElement("div", Attributes = StylePrefix + "*")] public class SetStyleTagHelper : TagHelper {     private const string StylePrefix = "style-";     [HtmlAttributeName("style")]     public string CssStyle { get; set; }     private IDictionary<string, string> _styleValues;     [HtmlAttributeName("", DictionaryAttributePrefix = StylePrefix)]     public IDictionary<string, string> StyleValues     {         get         {             return _styleValues ?? (_styleValues =                 new Dictionary<string, string>(StringComparer.OrdinalIgnoreCase));         }         set { _styleValues = value; }     }     public override void Process(TagHelperContext context, TagHelperOutput output)     {        ...

ConditionClassTagHelper

 using System.Collections.Generic; using System; using System.Linq; using Microsoft.AspNetCore.Razor.TagHelpers; namespace Web {     [HtmlTargetElement("div", Attributes = ClassPrefix + "*")]     public class ConditionClassTagHelper : TagHelper     {         private const string ClassPrefix = "class-if-";         [HtmlAttributeName("class")]         public string CssClass { get; set; }         private IDictionary<string, bool> _classValues;         [HtmlAttributeName("", DictionaryAttributePrefix = ClassPrefix)]         public IDictionary<string, bool> ClassValues         {             get             {                 return _classValues ?? (_classValues =              ...