Table: not display tooltip when cell is empty (#13152)

* Update table-body.js

* Update table-body.js
pull/13207/head
rongxingsun 2018-10-29 15:25:41 +08:00 committed by hetech
parent 2c32ff99b1
commit 87baaad394
1 changed files with 1 additions and 1 deletions

View File

@ -314,7 +314,7 @@ export default {
// 判断是否text-overflow, 如果是就显示tooltip
const cellChild = event.target.querySelector('.cell');
if (!hasClass(cellChild, 'el-tooltip')) {
if (!(hasClass(cellChild, 'el-tooltip') && cellChild.childNodes.length)) {
return;
}
// use range width instead of scrollWidth to determine whether the text is overflowing