|
|
@@ -141,13 +141,9 @@ class ManualColumnResize extends BasePlugin {
|
|
|
}
|
|
|
|
|
|
this.currentTH = TH;
|
|
|
-
|
|
|
- // const col = this.hot.view.wt.wtTable.getCoords(TH).col; // getCoords returns CellCoords
|
|
|
- let col = 0;
|
|
|
- TH.parentNode.children.forEach((element, index) => {
|
|
|
- if (element === TH) col = index;
|
|
|
- });
|
|
|
- if (col > 0) col += -1;
|
|
|
+ // getCoords returns CellCoords
|
|
|
+ // const col = this.hot.view.wt.wtTable.getCoords(TH).col;
|
|
|
+ const col = this.hot.getColHeader().indexOf(TH.innerText);
|
|
|
|
|
|
const headerHeight = outerHeight(this.currentTH);
|
|
|
|