Fixed #2019 - TreeTable | More than 2 Frozen Columns not Compatible with Table Scroll

pull/2057/head
Tuğçe Küçükoğlu 2022-01-27 14:47:10 +03:00 committed by Tuğçe Küçükoğlu
parent 39fd8a0b95
commit e4789c9a73
3 changed files with 6 additions and 6 deletions

View File

@ -91,7 +91,7 @@ export default {
let right = 0; let right = 0;
let next = this.$el.nextElementSibling; let next = this.$el.nextElementSibling;
if (next) { if (next) {
right = DomHandler.getOuterWidth(next) + parseFloat(next.style.right); right = DomHandler.getOuterWidth(next) + parseFloat(next.style.right || 0);
} }
this.styleObject.right = right + 'px'; this.styleObject.right = right + 'px';
} }
@ -99,7 +99,7 @@ export default {
let left = 0; let left = 0;
let prev = this.$el.previousElementSibling; let prev = this.$el.previousElementSibling;
if (prev) { if (prev) {
left = DomHandler.getOuterWidth(prev) + parseFloat(prev.style.left); left = DomHandler.getOuterWidth(prev) + parseFloat(prev.style.left || 0);
} }
this.styleObject.left = left + 'px'; this.styleObject.left = left + 'px';
} }

View File

@ -42,7 +42,7 @@ export default {
let right = 0; let right = 0;
let next = this.$el.nextElementSibling; let next = this.$el.nextElementSibling;
if (next) { if (next) {
right = DomHandler.getOuterWidth(next) + parseFloat(next.style.right); right = DomHandler.getOuterWidth(next) + parseFloat(next.style.right || 0);
} }
this.styleObject.right = right + 'px'; this.styleObject.right = right + 'px';
} }
@ -50,7 +50,7 @@ export default {
let left = 0; let left = 0;
let prev = this.$el.previousElementSibling; let prev = this.$el.previousElementSibling;
if (prev) { if (prev) {
left = DomHandler.getOuterWidth(prev) + parseFloat(prev.style.left); left = DomHandler.getOuterWidth(prev) + parseFloat(prev.style.left || 0);
} }
this.styleObject.left = left + 'px'; this.styleObject.left = left + 'px';
} }

View File

@ -67,7 +67,7 @@ export default {
let right = 0; let right = 0;
let next = this.$el.nextElementSibling; let next = this.$el.nextElementSibling;
if (next) { if (next) {
right = DomHandler.getOuterWidth(next) + parseFloat(next.style.right); right = DomHandler.getOuterWidth(next) + parseFloat(next.style.right || 0);
} }
this.styleObject.right = right + 'px'; this.styleObject.right = right + 'px';
} }
@ -75,7 +75,7 @@ export default {
let left = 0; let left = 0;
let prev = this.$el.previousElementSibling; let prev = this.$el.previousElementSibling;
if (prev) { if (prev) {
left = DomHandler.getOuterWidth(prev) + parseFloat(prev.style.left); left = DomHandler.getOuterWidth(prev) + parseFloat(prev.style.left || 0);
} }
this.styleObject.left = left + 'px'; this.styleObject.left = left + 'px';
} }