-
-
Notifications
You must be signed in to change notification settings - Fork 619
feat: support custom cell ellipsis tooltip #474
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Conversation
Codecov Report
@@ Coverage Diff @@
## master #474 +/- ##
=======================================
Coverage 99.70% 99.70%
=======================================
Files 23 23
Lines 669 670 +1
Branches 190 191 +1
=======================================
+ Hits 667 668 +1
Misses 2 2
Continue to review full report at Codecov.
|
This pull request introduces 1 alert when merging 9682806 into 8f736e6 - view on LGTM.com new alerts:
|
改成这样的 API 吧。
|
可以的, 你的意思是 在 <Table ellipsis={{ showTitle: false }}/> 还是基于 columns 的 ellipsis 字段? const columns = [
{
title: 'name',
dataIndex: 'name',
width: 100,
ellipsis: true,
// ellipsis: { showTitle: false }
}
] |
似乎 基于 columns ellipsis 更合理一点, 你认为呢 |
下面这个。 |
@afc163 偏右大佬麻烦有空review下哈 |
需求场景
设置 columns 的 ellipsis 属性后, 会很贴心的在自动省略的单元格, hover后显示完整的数据, 因为添加了html的
title
属性但比较尴尬, 在我们的业务场景中, 用户觉得 初次 hover 后显示
title
有一定的延迟, 大概有 2 秒左右, 所以用Tooltip
替代title
, 但这样会有重复的提示, 如图 所以需要一个开关来关闭默认的title
属性使用
codesandbox