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

feat: support scrollTo #1030

Merged
merged 4 commits into from
Oct 10, 2023
Merged

feat: support scrollTo #1030

merged 4 commits into from
Oct 10, 2023

Conversation

zombieJ
Copy link
Member

@zombieJ zombieJ commented Oct 10, 2023

No description provided.

@vercel
Copy link

vercel bot commented Oct 10, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

Name Status Preview Updated (UTC)
table ✅ Ready (Inspect) Visit Preview Oct 10, 2023 7:31am

@codecov
Copy link

codecov bot commented Oct 10, 2023

Codecov Report

Merging #1030 (d428d28) into master (7f5fda9) will increase coverage by 0.09%.
The diff coverage is 100.00%.

❗ Current head d428d28 differs from pull request most recent head 7856139. Consider uploading reports for the commit 7856139 to get more accurate results

@@            Coverage Diff             @@
##           master    #1030      +/-   ##
==========================================
+ Coverage   99.41%   99.50%   +0.09%     
==========================================
  Files          47       47              
  Lines        4448     4486      +38     
  Branches      561      570       +9     
==========================================
+ Hits         4422     4464      +42     
+ Misses         26       22       -4     
Files Coverage Δ
src/Table.tsx 99.77% <100.00%> (+<0.01%) ⬆️
src/VirtualTable/BodyGrid.tsx 98.44% <100.00%> (+1.63%) ⬆️
src/index.ts 100.00% <100.00%> (ø)

📣 We’re building smart automated test selection to slash your CI/CD build times. Learn more


// Scroll key
ref.current.scrollTo({
key: 'bamboo',
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个支持 ['a', 'b']

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个是 dataIndex 吧?key 就是标准的 React.Key

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

用的是 rowKey 的值是吗

dataIndex: 'key',
},
]}
reference={ref}
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

这个不用 ref,是因为 ref 已经被占用了吗

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

嗯,都是历史债:ant-design/ant-design#45242

@zombieJ zombieJ merged commit 2fbe8b4 into master Oct 10, 2023
8 checks passed
@zombieJ zombieJ deleted the ref branch October 10, 2023 07:39
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

Successfully merging this pull request may close these issues.

2 participants