DxSchedulerResourceMappings.TextCssClass Property

Maps a ResourcesSource's data field to the resource's TextCssClass property.

Namespace: DevExpress.Blazor

Assembly: DevExpress.Blazor.v20.2.dll

Declaration

public DxSchedulerMapping TextCssClass { get; set; }

Property Value

Type Description
DxSchedulerMapping

Maps a data field to the resource property.

Remarks

@code {
    public class ResourceObject {
        public int Id { get; set; }
        public string Caption { get; set; }
        public System.Drawing.Color Color { get; set; }
        public string TextCssClass { get; set; }
        public string BackgroundCssClass { get; set; }
    }

    DxSchedulerDataStorage DataStorage = new DxSchedulerDataStorage() {
        ResourcesSource = new List<ResourceObject>() {
            new ResourceObject() { 
                Id = "1", 
                Caption = "Resource One", 
                Color = System.Drawing.Color.Red, 
                TextCssClass = "apt-text-red", 
                BackgroundCssClass = "apt-bg-lightpink",
            },
            new ResourceObject() { 
                Id = "2", 
                Caption = "Resource Two", 
                Color = System.Drawing.Color.Green
                TextCssClass = "apt-text-green", 
                BackgroundCssClass = "apt-text-lightgreen"
            },
        },
        ResourceMappings = new DxSchedulerResourceMappings() {
            Id = "Id",
            Caption = "Caption",
            Color = "Color",
            TextCssClass = "TextCssClass", 
            BackgroundCssClass = "BackgroundCssClass"
        }
    };
}
See Also