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
feat: Flipping table to automatically scroll to the top #18726
Conversation
Deploy preview for ant-design ready! Built with commit 2745c06 |
It should also need to do this when sorting. |
I think it should be turned on by default,feature. |
Don't need to consider compatibility? |
Is MINOR version suitable? @afc163 |
Default true is accepted, it is a new feature which could be put in minor version. |
Codecov Report
@@ Coverage Diff @@
## feature #18726 +/- ##
===========================================
- Coverage 96.78% 96.74% -0.04%
===========================================
Files 281 281
Lines 7548 7553 +5
Branches 2102 2106 +4
===========================================
+ Hits 7305 7307 +2
- Misses 241 244 +3
Partials 2 2
Continue to review full report at Codecov.
|
Codecov Report
@@ Coverage Diff @@
## feature #18726 +/- ##
===========================================
+ Coverage 96.96% 96.96% +<.01%
===========================================
Files 281 281
Lines 7601 7609 +8
Branches 2136 2137 +1
===========================================
+ Hits 7370 7378 +8
Misses 229 229
Partials 2 2
Continue to review full report at Codecov.
|
https://github.com/ant-design/ant-design/blob/master/components/table/Table.tsx#L508 We should do the same thing here, I think. |
Maybe apply it in |
59d5ca4
to
bc4f358
Compare
bc4f358
to
20b0fdd
Compare
覆盖率不满足需求,或许需要加用例。 |
感觉最近GitHub变卡了,打开都要半天 |
我之前没用过 |
滚动位置要靠 mock,这种很难精确测试。没关系,测试能跑到相关代码就可以了。 |
好的,我晚上下班后试一下 |
👌 apply it in handleFilter and toggleSortOrder 👌 ref instead of findDOMNode ✅ update test for scroll to first row close ant-design#18623
d629ba6
to
5395a28
Compare
🤔 This is a ...
🔗 Related issue link
close #18623
💡 Background and solution
call
scrollTo
whenhandlePageChange
📝 Changelog
☑️ Self Check before Merge
View rendered components/table/demo/fixed-header.md
View rendered components/table/index.en-US.md
View rendered components/table/index.zh-CN.md