-
Notifications
You must be signed in to change notification settings - Fork 842
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 EuiPopover arrow position in Android and Linux #3188
Fix EuiPopover arrow position in Android and Linux #3188
Conversation
Since this is a community submitted pull request, a Jenkins build has not been kicked off automatically. Can an Elastic organization member please verify the contents of this patch and then kick off a build manually? |
jenkins test this |
Preview documentation changes for this PR: https://eui.elastic.co/pr_3188/ |
Hi @dimitropoulos, Thanks for creating this PR. I tried to replicate this issue without success. I opened the page https://elastic.github.io/eui/#/tabular-content/tables and toggled the rows per page popovers. I tried in different browsers and I couldn't see the dark line. Chrome with Zoom: Chrome without Zoom: Can you provide instructions on how to replicate the issue? |
I've also never seen this issue. Giving us your browser and OS might help. This can also be something that comes from subpixel rendering, which non-retina screens can have issues with. A better summary of your test env will help us out. |
👍 Yep, I can replicate this on Chrome on Android |
bonus: if you go to the PR link on android, it's fixed! :) |
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 @dimitropoulos! I could replicate the issue in Android and the fix looks good to me!
TLDR;
Before
After
This is a one-pixel offset change.
Summary
So I noticed that some of the chevrons (i.e. arrows) on the popovers on the BasicTables component had a dark line between the arrow and the box:
without dark line:
with dark line:
I noticed that this happens repeatably for the same components on the same page (at the same zoom level), as well as that which popovers on the page do it changes if I adjust my browser zoom. This suggests it's just a subpixel thingy, as I like to call them.
To help illustrate: we can move the arrow down to exaggerate the effect:
Or we can move it up too far:
It seemed like, in this case, all that was needed was one more pixel. And it's in better shape now.
I checked all of the positions in 3 different zoom levels and (on my machine, running chrome) they all seemed to work now. Just to be sure there wasn't anything I missed with the background of the popover and the background of the page both being white I made sure to color the background for the tests. I know the border is grey, but I can imagine why the bottom one might stand out more because of the bottom shadow, and also I found out that if you star at enough of these you start to imagine the line being there when it isn't thanks to the hermann grid illusion, haha.
Checklist