SitePen / dgrid

A lightweight, mobile-ready, data-driven, modular grid widget designed for use with dstore
http://dgrid.io/
Other
628 stars 296 forks source link

dgrid/Grid updateSortArrow failing on IE caused by parentNode is null #1413

Closed rmadiwalid closed 4 years ago

rmadiwalid commented 6 years ago

in dgrid/Grid class, when sorting on the dgrid on IE browser it's failing because of parentNode is null. I can see that there was a change when migrated to dgrid 1.2.1.

if (this._lastSortedArrow) {
// Remove the sort classes from the parent node
domClass.remove(this._lastSortedArrow.parentNode, 'dgrid-sort-up dgrid-sort-down');
// Destroy the lastSortedArrow node
domConstruct.destroy(this._lastSortedArrow);
delete this._lastSortedArrow;
}

so I think we need a test on this line( in Grid.js class updateSortArrow method) to test that parentNode not null

domClass.remove(this._lastSortedArrow.parentNode
msssk commented 4 years ago

Closing this as it was fixed in #1430