Feature Request: [DataGrid] Data-based CSS evaluation per-column #1263

Open
opened 2026-01-29 17:51:16 +00:00 by claunia · 0 comments
Owner

Originally created by @robertmclaws on GitHub (Jun 9, 2024).

All of my Grid-based objects implement IRevertibleChangeTracking, so they natively keep a list of the fields that have changed so they can revert their values.

Kendo UI Grid had a great feature for in-cell editing where the fields that had changed had a triangular red CSS corner border to show that the element had changed.

There are ways that I can potentially replicate some version of this functionality within a column's template without changing any code.

However, one could argue that the right way to do it would be to apply classes to the table cell.

The problem is that cell is rendered at the RadzenDataGrid level, not the RadzenDataGridColumn level.

In order to replicate the feature appropriately, the render process would need to call a method like column.CalculateItemCssClass(TItem), where the item for the row being rendered would be passed in.

That would allow the column to check its' property against the list of properties that have changed for that item and determine if an additional CSS class should be added to the cell or not.

I intend to send a pull request for this once my other request is accepted.

Originally created by @robertmclaws on GitHub (Jun 9, 2024). All of my Grid-based objects implement `IRevertibleChangeTracking`, so they natively keep a list of the fields that have changed so they can revert their values. Kendo UI Grid had a great feature for in-cell editing where the fields that had changed had a triangular red CSS corner border to show that the element had changed. There are ways that I can potentially replicate some version of this functionality within a column's template without changing any code. However, one could argue that the right way to do it would be to apply classes to the table cell. The problem is that cell is rendered at the `RadzenDataGrid` level, not the `RadzenDataGridColumn` level. In order to replicate the feature appropriately, the render process would need to call a method like `column.CalculateItemCssClass(TItem)`, where the item for the row being rendered would be passed in. That would allow the column to check its' property against the list of properties that have changed for that item and determine if an additional CSS class should be added to the cell or not. I intend to send a pull request for this once my other request is accepted.
Sign in to join this conversation.
1 Participants
Notifications
Due Date
No due date set.
Dependencies

No dependencies set.

Reference: starred/radzen-blazor#1263