Skip to content
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

跨多列的鼠标悬浮样式在固定的列上无效 #15684

Closed
1 task
405go opened this issue Mar 27, 2019 · 3 comments
Closed
1 task

跨多列的鼠标悬浮样式在固定的列上无效 #15684

405go opened this issue Mar 27, 2019 · 3 comments
Assignees

Comments

@405go
Copy link
Contributor

405go commented Mar 27, 2019

  • I have searched the issues of this repository and believe that this is not a duplicate.

Reproduction link

https://codepen.io/anon/pen/vPwrGp?editors=0010

Steps to reproduce

鼠标悬停的列表的最后一行会发现,被固定的最后一列背景色不会发生变化

What is expected?

被固定的最后一列背景色同该行一致

What is actually happening?

被固定的最后一列背景色同该行不一致

Environment Info
antd 3.15.2
React 16.2
System w7
Browser 谷歌
@405go
Copy link
Contributor Author

405go commented Mar 27, 2019

原因是被固定的那一列只是生成了一个空的tr标签,并没有生成td标签,导致样式不同步

@405go
Copy link
Contributor Author

405go commented Mar 27, 2019

rc-table TableCell.js 89行不要返回null而是返回<td>{}</td>可以解决该问题

@zombieJ
Copy link
Member

zombieJ commented Apr 3, 2019

这是因为最后一列的 render 你设置 colSpan 为 0 了,而左边的部分不是 fixed 的,导致它就不显示了。直接render 的时候不要 span 就行了:https://codesandbox.io/s/3z98z526

CodeSandbox
The online code editor tailored for web applications

@zombieJ zombieJ closed this as completed Apr 3, 2019
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants