-
Notifications
You must be signed in to change notification settings - Fork 276
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
Reducing the width of "Punch" button to leave room for the scrollbars #455
Conversation
@thamara If I notice some code that can be refactored in a cleaner more terse way, should I go ahead with it ? |
Codecov Report
@@ Coverage Diff @@
## main #455 +/- ##
==========================================
+ Coverage 63.95% 63.97% +0.01%
==========================================
Files 28 28
Lines 2536 2537 +1
Branches 389 389
==========================================
+ Hits 1622 1623 +1
Misses 806 806
Partials 108 108
Continue to review full report at Codecov.
|
css/styles.css
Outdated
width: 5px; | ||
height: 5px; |
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.
I have a feeling 5px is too small... Not sure if it's just me.
@araujoarthur0 what do you think?
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.
It looked small on the other PR...
Is there a reason we are avoiding having the scrollbar only on the table part ?
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.
In detail, if we want to have scrolling on the table, the right way to do it would be to have it on the tbody
because we'd want to keep the Table Headers fixed.
The only way to do that (while still using <table
and not divs) tag would be to have both <thead> and
<tbody as display: block
and have overflow set on them.
This works ( i've verified it ) but the "Punch button" overlaps the table. This is due to the fact that it's position is fixed
which breaks it from the page layout flow. There are ways to get around that but the best way would be to change the markup in a way as follows ->
--- Title---
--- header ---
[[[ table ]]]. ---> expands to fill the available space.
-- footer---
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.
@thamara How does this look ? Scrollbar is 8px wide here.
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.
Thanks for the great explanation.
Given that a lot of changes would be required and that the future of the fixed table is still under discussion, I guess we can go for the workaround right now.
But if you'd like to, you could open an issue for the flexible table. I suppose the same issue must be happening there, though it most likely is not a pure table element.
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.
Will do
Usually, I would say just raise a PR, but we got some big discussions regarding some components on the app (for example #401 ), and, to avoid having you doing some unnecessary work, I think it would be really good if you could just shout out refactoring changes you are seeing.
Oh! Thank you a lot! During October the project receives lots of people and almost all the issues have someone working on them. You can check if there is any other issues open, and comment if you want to check it out. Of course, you can also propose new changes. :D |
Looks awesome! |
\changelog-update |
…TTLApp#455) * Reducing the width of "Punch" button to leave room for the scrollbars * Increasing scrollbar width as per review comments
Related issue
Closes #441
Context / Background
The reason for the gap is that the Scrollbar is Actually appearing on the body and it automatically reserves 10px for the scrollbar. Ideally, the scrollbar should appear on the container holding the table.
Leaving some room on the left and the right of the button looks like a good solution until we get to redoing the layout.
What change is being introduced by this PR?
How will this be tested?
Will check if the button always reserves 20px from the left and from the right.