kendo-uikendo-panelbar

how to get bold text in the kendo UI in panel bar text?


@(Html.Kendo().PanelBar()
.Name("panelbar")
.ExpandMode(PanelBarExpandMode.Single)
.Items(PanelBar =>
{
    PanelBar.Add().Text("abcd")
           .Expanded(true)
           .Content("abcd-have to show in bold text ");

}))

The "abcd" text has to display the as in bold !???how to get it, but text not in .content box!.


Solution

  • Use the LinkHtmlAttributes() method with whatever style/class you want:

    @(Html.Kendo().PanelBar()
        .Name("panelbar")
        .ExpandMode(PanelBarExpandMode.Single)
        .Items(PanelBar =>
        {
             PanelBar.Add().Text("abcd")
                .LinkHtmlAttributes(new { style = "font-weight: bold;" })
                .Expanded(true)
                .Content("abcd-have to show in bold text ");
    }))