コード例 #1
0
        protected override void BuildAttributeSet(AttributeSetBuilder builder)
        {
            builder.AddClassAttribute(x => x
                                      .Add(ClassName)
                                      .Add(ClassNames.Active, IsActive));

            builder.AddStyleAttribute(x => x
                                      .AddProperty("height", Size.ToString())
                                      .AddProperty("width", Size.ToString()));
        }
コード例 #2
0
        protected override void BuildAttributeSet(AttributeSetBuilder builder)
        {
            builder.AddAttribute("role", "img");
            builder.AddAriaAttribute("hidden", "true");
            builder.AddClassAttribute(ClassName);

            builder.AddStyleAttribute(x => x
                                      .AddProperty("height", Size.ToString())
                                      .AddProperty("min-height", Size.ToString())
                                      .AddProperty("width", Size.ToString())
                                      .AddProperty("min-width", Size.ToString())
                                      .AddProperty("fill", Fill.IsEmpty ? _fillColor.ToRgbStr() : Fill.ToRgbaStr(), _isSourceResource)
                                      .AddProperty("color", Fill.IsEmpty ? _fillColor.ToRgbStr() : Fill.ToRgbaStr(), _isSourceResource));
        }
コード例 #3
0
 protected override void BuildAttributeSet(AttributeSetBuilder builder)
 {
     builder.AddClassAttribute(ClassName, ClassNames.FlexColumn);
     builder.AddStyleAttribute(x => x
                               .AddProperty("width", Width.ToString()));
 }