-
-
Notifications
You must be signed in to change notification settings - Fork 729
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 gaps in cart & checkout tables on Firefox #13010
base: master
Are you sure you want to change the base?
Conversation
Tables from the cart and checkout pages would show some gaps where the table content doesn't extend to take all the available space. Not forcing the `display` CSS property of table elements to `block` appears to fix without adverse side effects.
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.
Great, thankyou for your detailed explanation, and pointing out that #9976 is not working.
We'll test this out and consider re-opening the issue.
Hello @dacook this is my first PR, can you please clarify if there is any action item for me before merging this? Or are we just waiting for more tests/verifications? Thanks! |
Hi @ndossougbete, sorry for the delay, but yes we need an expert to manually test and verify this change before merging. Our testing team has limited capacity and there is a large backlog at the moment, so this will take longer than usual. Thanks again for your contribution, it will get there eventually! |
Hi @ndossougbete, I have tested before and after staging your PR on our testing server. There are four pages I found having a similar version of the table available, so I decided to compare their behaviour. Firefox
Image 1Image 2ConclusionThis is a tricky one. Feedback@openfoodfoundation/train-drivers-product-owners What do you think? Is the benefit of the fixed gap greater than the cost of the broken page layout? I personally don't think so. Let us know and we will take it from there. Testing noteBefore merging this should be tested on Chrome and Safari as well. Thanks again @ndossougbete! Let's see how we move on! |
What? Why?
Tables from the cart and checkout pages would show some gaps where the table content doesn't extend to take all the available space. Not forcing the
display
CSS property oftable
elements toblock
appears to fix the issue without adverse side effects.The
display: block
properties were originally added in PR #10103 to address issue #9976 on mobile, but it does not seem to be working anymore, with or without this patch. For example, in the screenshot below, the white gap at the right of the footer hints at how much extra width is added on the page:PR #10103 was aiming to make the table itself scroll horizontally while keeping the overall body width matching the viewport. It doesn't work today, and upon testing, seems unfeasible on Firefox (see the issue mentioned on https://stackoverflow.com/a/48736763, compare behaviour on Chrome & Firefox). If it was working, it would be sometimes confusing as there would be no or very little indication that the table has the ability to scroll. I would suggest to entirely change the table's layout on Mobile instead. For example, put price, quantity and the remove button below the item title and description, so that everything can fit without needing to scroll.
What should we test?
Repro steps:
There is also an affected table on the cart page, but I couldn't repro the issue there.
Release notes
Changelog Category (reviewers may add a label for the release notes):
The title of the pull request will be included in the release notes.