KendoReact Data Grid Styling Overview

The KendoReact Data Grid enables you to style its columns, rows, and cells.

ninja-iconThe Styling is part of KendoReact, a professional grade UI library with 110+ components for building modern and feature-rich applications. To try it out sign up for a free 30-day trial.Start Free Trial

Styling the KendoReact Data Grid Columns

To style the columns of the Grid, either:

Setting Custom Cells

Setting a custom cell for the Grid columns allows you to change the appearance of that cell based on the provided value. By using the custom-cell approach, you can include icons, buttons, links, or any other HTML elements in the cell.

Change Theme
Theme
Loading ...

Setting Custom Header Cells

Setting a custom headerCell for the column header of the Grid allows you to change the appearance and to include icons, buttons, links, or any other HTML elements in that header.

Change Theme
Theme
Loading ...

Setting Class Names

The className property applies additional class to the td element and can be used for styling the background, text color, text alignment, and other styling options of the Grid.

jsx
    <GridColumn field="ProductName" title="Product Name" className="product-name">
css
product-name {
    color: 'white';
    background-color: '#888888';
}

Styling the KendoReact Data Grid Rows

To style the rows of the Grid, utilize the rowRender function. rowRender allows you to modify the appearance of the rows based on the provided values.

Change Theme
Theme
Loading ...

Styling the KendoReact Data Grid Individual Elements

You can individually style the elements of the Grid by using CSS.

The Grid provides multiple elements that can be individually styled. Before you apply the styling options to the desired elements, inspect the element and use selectors of higher priority.

Styling the KendoReact Data Grid Filter Icons

The following example demonstrates how to style the appearance of the filter icon in the Grid.

css
    .k-filtercell-operator > .k-dropdownlist .k-i-filter {
        color:"white"
    }

Styling the KendoReact Data Grid Sort Icons

The following example demonstrates how to style the appearance of the sort ascending-order icon in the Grid.

css
    .k-header .k-sort-icon > .k-i-sort-asc-small {
        color:"red"
    }

Styling the KendoReact Data Grid Page Numbers

The following example demonstrates how to style the appearance of the page numbers in the Grid.

css
    .k-pager-numbers .k-button {
        color: "black";
    }

Applying Conditional Styling

You can use the custom-cell approach of the Grid to change the appearance of the cells on condition and based on the provided value.

Change Theme
Theme
Loading ...

KendoReact Data Grid Styling APIs