Breaking Change T933410
Visible to All Users

DataGrid/TreeList - The markup of an editable cell has changed

What Changed

In v20.2 and newer, DataGrid/TreeList does not render a DIV element with the dx-highlight-outline CSS rule in an editable data cell, and data cell content is placed directly in the TD element.

Reasons for Change

Prior to v20.2, DataGrid/TreeList rendered a DIV element with the dx-highlight-outline CSS rule in an editable cell. This DIV was used for highlighting a modified or invalid cell (a green or red border was shown). However, rendering this element caused the following issue: DataGrid - The "Failed to execute 'removeChild' on 'Node'" error appears when modifying a component's state in a cell template.

Currently, CSS allows highlighting table cells without using this redundant element. That is why, we decided to remove it to fix the issue.

Impact on Existing Apps

Though this change simplifies the markup of a data cell and the CSS class is not documented, it may affect your project if you overrode DevExtreme CSS rules that contained the dx-highlight-outline class.

The following code snippet shows how to change the border of a modified or invalid cell in versions prior to v20.2:

CSS
.dx-datagrid-rowsview .dx-data-row .dx-cell-modified .dx-highlight-outline::after, .dx-treelist-rowsview .dx-data-row .dx-cell-modified .dx-highlight-outline::after { border-color: yellow!important; } .dx-datagrid-rowsview .dx-data-row .dx-datagrid-invalid .dx-highlight-outline::after .dx-treelist-rowsview .dx-data-row .dx-treelist-invalid .dx-highlight-outline::after { border-color: blue!important; }

The code below shows how you can do this in v20.2:

CSS
.dx-datagrid-rowsview .dx-data-row td.dx-cell-modified:not(.dx-datagrid-invalid)::after .dx-treelist-rowsview .dx-data-row td.dx-cell-modified:not(.dx-treelist-invalid)::after { border-color: yellow!important; } .dx-datagrid-rowsview .dx-data-row td.dx-datagrid-invalid::after .dx-treelist-rowsview .dx-data-row td.dx-treelist-invalid::after { border-color: blue!important; }

Disclaimer: The information provided on DevExpress.com and affiliated web properties (including the DevExpress Support Center) is provided "as is" without warranty of any kind. Developer Express Inc disclaims all warranties, either express or implied, including the warranties of merchantability and fitness for a particular purpose. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.

Confidential Information: Developer Express Inc does not wish to receive, will not act to procure, nor will it solicit, confidential or proprietary materials and information from you through the DevExpress Support Center or its web properties. Any and all materials or information divulged during chats, email communications, online discussions, Support Center tickets, or made available to Developer Express Inc in any manner will be deemed NOT to be confidential by Developer Express Inc. Please refer to the DevExpress.com Website Terms of Use for more information in this regard.