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

fix: overflowY = 'auto' when set scroll.y #973

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

trongtai37
Copy link

Currently, if we set the value of scroll.y but the height of all items in the table does not exceed scroll.y, There is still an empty scroll bar
before_scrollY
I think it would be better if we set the overflowY is auto, the result after the change.
after_scrollY

@vercel
Copy link

vercel bot commented Mar 20, 2023

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

Name Status Preview Comments Updated (UTC)
table ✅ Ready (Inspect) Visit Preview 💬 Add feedback Aug 7, 2023 2:36pm

@codecov
Copy link

codecov bot commented Apr 17, 2023

Codecov Report

Merging #973 (87a476c) into master (5fb8f12) will decrease coverage by 0.03%.
The diff coverage is n/a.

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

@@            Coverage Diff             @@
##           master     #973      +/-   ##
==========================================
- Coverage   99.52%   99.49%   -0.03%     
==========================================
  Files          40       36       -4     
  Lines        3563      989    -2574     
  Branches      476      320     -156     
==========================================
- Hits         3546      984    -2562     
+ Misses         17        5      -12     
Files Changed Coverage Δ
src/Table.tsx 99.06% <ø> (-0.70%) ⬇️

... and 40 files with indirect coverage changes

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

@@ -315,7 +315,7 @@ function Table<RecordType extends DefaultRecordType>(tableProps: TableProps<Reco

if (fixHeader) {
scrollYStyle = {
overflowY: 'scroll',
overflowY: 'auto',
Copy link
Member

Choose a reason for hiding this comment

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

auto will break the width calculation which makes border out of table:
截屏2023-08-15 10 02 02

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.

None yet

2 participants