-
Notifications
You must be signed in to change notification settings - Fork 839
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
[EuiButton] Remove hover state | translateY #2184
Comments
For better or worse one of the design principles we have on EUI's front page is
I wrote that on day one because we knew very well that EUI itself needed to be extremely generic and almost boring as a UI that mostly surrounds the actual content (visualizations). At the same time there's a fine line between generic and "looks like everything else". That's generally why we use it. We use animations on hover not just here, but also on the cards for example. Or tooltips Modals open with animations, flyouts, popovers. We animate "borders" on focused form elements. Toasts pop in with animation, accordions slide open and closed. These are all on click, but there's definitely a pattern to how we manage them. A lot of this stuff also happens on focus. In small ways this helps with accessibility. The slight movement makes tabbing through buttons and form elements very clear. It's not primarily why we went in that direction, but it's something we know helps. That said. Animation is subjective. There are some folks that simply can't stand it and find it distracting. And that's OK. For those folks Kibana has an advanced setting that limits it a bit. The CSS file it loads is here. You're welcome to tweak it or adjust it. For some reason I notice it doesn't work on the buttons, but I think it just needs some more specificity (taking hover and focus into account). Whenever someone brings this up (you aren't the first, so don't worry) I remember this setting and load it up. Personally I don't like it, but again, a lot of this is subjective, and I'm glad it's around for folks that feel strongly about it. Anyways. Thanks for your comment. That's at least some history and reasoning. None of this is set in stone, and we've gained more and more designers over time. Likely they have opinions on this as well, and I'll bring it up in our next review. |
Wow! thanks for the detailed explanation @snide! To be clear I think animations, as done in EUI and in general, are FANTASTIC! The animations you pointed out including tooltip, modal, input, etc are all very different from the button hover state, mainly because none of those actually move the element being hovered. The closest of those might be the tooltip appearing with a translation but the big difference between that animation and the button animation is that the tooltip is not "actionable" (that I have seen) it's just meant to show more information and not for the user to click on it. Nor is the tooltip the element being hovered. The only issue I have with the button hover state is that the thing moves! Why does it move? 🤔 I would argue that this detracts from the overall UX and accessibility of the button. If we take the current hover state a "step" further, say I've looked through a few UI design sites like dribbble as well as material guidelines and found no examples of hover movement, only hover emphasis. Like the compose button on Gmail 👇. This enhancement shows the user what is focused and without moving the element, by making it appear to be elevating of the page. I feel like removing the animated But it's up to you guys, thanks a lot for genuinely considering my ideas! |
Yep. I'll bring it up with the crew. They might agree. FWIW I stole the idea from Stripe originally so there are others out there doing it as well. |
Hey just wanted to add to this discussion. I was at a 3PC (3rd party conference) yesterday and the user was using kibana and happened to get the mouse into an "infinite twitch state" because of the button focus y-transition. The video is not very clear but the cursor goes from |
Related: #2544 |
Yep! And the fix from EUI for that specific instance is in Kibana master already 😉 |
Related: #3975 |
👋 Hey there. This issue hasn't had any activity for 180 days. We'll automatically close it if that trend continues for another week. If you feel this issue is still valid and needs attention please let us know with a comment. |
❌ We're automatically closing this issue due to lack of activity. Please comment if you feel this was done in error. |
The first time I started to explore Kibana, long before joining elastic, the first thing I noticed was the button hover state and unfortunately, it was not because it was a pleasurable experience.
I wanted to open this discussion issue to see if there was a reason for the
translateY
on hover state.Personally, I feel this hover state is very jarring to the user which is compounded with several buttons on the UI. This movement pattern also seems to be inconsistent with other hover states throughout EUI, if buttons move shouldn't all icons and other interactable elements move on hover too?
Proposed solution
My proposed solution would be to not move the "hit slop" of the button but add a darker contrasting drop shadow on hover giving the illusion of movement without actually moving the button.
Screenshot
Thanks for the consideration 👍
The text was updated successfully, but these errors were encountered: