-
-
Notifications
You must be signed in to change notification settings - Fork 619
fix:表格只有一列时,该列固定,并且给scroll.x设置值,表格出现横向滚动条,并且出现右侧出现空白 #36330 #847
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
The latest updates on your projects. Learn more about Vercel for Git ↗︎
|
Codecov Report
@@ Coverage Diff @@
## master #847 +/- ##
=======================================
Coverage 99.39% 99.39%
=======================================
Files 36 36
Lines 984 987 +3
Branches 295 296 +1
=======================================
+ Hits 978 981 +3
Misses 6 6
📣 Codecov can now indicate which changes are the most critical in Pull Requests. Learn more |
|
||
const perfRecord = React.useContext(PerfContext); | ||
const supportSticky = React.useContext(StickyContext); | ||
const { allColumnsFixedLeft } = React.useContext(BodyContext); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
逻辑上改成 allColumnsFixed 如何,这样还能支持都是右固定的情况。
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
allColumnsFixedLeft 在结果上是不是等于 firstFixLeft && lastFixLeft
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
src/Cell/index.tsx
Outdated
[`${cellPrefixCls}-fix-left`]: isFixLeft && supportSticky, | ||
[`${cellPrefixCls}-fix-left-first`]: firstFixLeft && supportSticky, | ||
[`${cellPrefixCls}-fix-left-last`]: lastFixLeft && supportSticky, | ||
[`${cellPrefixCls}-all-fix-left`]: lastFixLeft && allColumnsFixedLeft && supportSticky, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
${cellPrefixCls}-fix-left-all
这样统一一点。
7.25.2 已发。还需要去 antd 仓库提交一个新的 PR 补 css。 |
@zombieJ 确实,不过对 antd 现有版本应该没影响。我回滚掉,还是直接更新 snapshot? |
我更新一下 snapshot 即可~~ |
大佬 这个pr需要我去提吗 |
@dashaowang 需要 |
我看应该是更新rc-table版本就可以吧 |
还有样式要补。 |
修复内容:修复表格在所有列全是左固定时,会出现横向滚动条。详情见36330
修改内容:bodyContext增加属性allColumnsFixedLeft用于在渲染表格时判断是否取消该单元格的shadow