fix(components): [table] the overflowTooltip cannot be refreshed (#19440)

fix(components): [table] the tooltip cannot be refreshed
This commit is contained in:
xingyixiang 2024-12-29 10:15:02 +08:00 committed by GitHub
parent 13506ffb81
commit 7d76dea667
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -2,7 +2,12 @@
import { h, inject, ref } from 'vue'
import { debounce } from 'lodash-unified'
import { addClass, hasClass, removeClass } from '@element-plus/utils'
import { createTablePopper, getCell, getColumnByCell } from '../util'
import {
createTablePopper,
getCell,
getColumnByCell,
removePopper,
} from '../util'
import { TABLE_INJECTION_KEY } from '../tokens'
import type { TableColumnCtx } from '../table-column/defaults'
import type { TableBodyProps } from './defaults'
@ -156,6 +161,8 @@ function useEvents<T>(props: Partial<TableBodyProps<T>>) {
cell,
table
)
} else if (removePopper?.trigger === cell) {
removePopper?.()
}
}
const handleCellMouseLeave = (event) => {