Articles in this section
Category / Section

How to Apply Styles to Drill-through Grid in Blazor Pivot Table?

2 mins read

Introduction

In certain scenarios, you may want to personalize the appearance of your drill-through grid column headers to enhance readability and improve the presentation of data. This article explains how to apply custom styles to the drill-through grid column headers in the Blazor Pivot Table component.

Customizing drill-through grid column headers style

To customize the styles of the drill-through grid column headers, target the built-in CSS classes associated with these header cells. Here’s an example of how to change the font color and font family of the drill-through grid column headers.

[Index.razor]

<style>
    .e-drillthrough-grid.e-grid .e-gridheader {
        color: red !important;
        font-family: cursive;
    }
</style>

In the above code snippet, targeting the CSS class .e-gridheader within the .e-drillthrough-grid container. Inside the curly braces, set the color property to red and modify the font-family to cursive. By applying these styles, you can easily enhance the appearance of the drill-through grid column headers.

Note: By adding “!important” to the style rule, you ensure that this custom style takes precedence over any existing styles.

The following screenshot illustrates the results of the above code snippet.

Screenshot

KB-14617.png

For a practical demonstration, refer to the Blazor Playground Sample.

Conclusion

We hope you enjoyed learning how to apply custom styles to the drill-through grid column headers in the Blazor Pivot Table.

You can also refer to our Blazor Pivot Table feature tour page to learn about its other groundbreaking features, documentation, and how to quickly get started with configuration specifications. You can also explore our Blazor Pivot Table example to understand how to create and manipulate data.

For current customers, our Blazor components are available on the License and Downloads page. If you are new to Syncfusion, you can try our 30-day free trial to evaluate our Blazor Pivot Table and other Blazor components.

If you have any questions or require clarifications, please let us know in the comments section below. You can also contact us through our support forums, support portal, or feedback portal. We are always happy to assist you!

Did you find this information helpful?
Yes
No
Help us improve this page
Please provide feedback or comments
Comments (0)
Please  to leave a comment
Access denied
Access denied