Explorar o código

Table: fix table column show-overflow-tooltip bug

Table: fix table column show-overflow-tooltip bug, low version Firefox without innerText, add textContent
Ryan.xu %!s(int64=7) %!d(string=hai) anos
pai
achega
292ad8efec
Modificáronse 1 ficheiros con 1 adicións e 1 borrados
  1. 1 1
      packages/table/src/table-body.js

+ 1 - 1
packages/table/src/table-body.js

@@ -343,7 +343,7 @@ export default {
       if (hasClass(cellChild, 'el-tooltip') && cellChild.scrollWidth > cellChild.offsetWidth && this.$refs.tooltip) {
         const tooltip = this.$refs.tooltip;
 
-        this.tooltipContent = cell.innerText;
+        this.tooltipContent = cell.textContent || cell.innerText;
         tooltip.referenceElm = cell;
         tooltip.$refs.popper && (tooltip.$refs.popper.style.display = 'none');
         tooltip.doDestroy();