The Importance of UX Design in App Development
When building an app for other users in particular, it's worth learning a little bit of UX design. That stands for user experience. And if you're on any of the massive companies, your Facebooks and your YouTube, they will have invested heavily in UX design. And there will be so much of the way that they design their site is to make it intuitive and common sense what items do. And one of the ways that we can do that in Bubble and can feel like a little bit mature, but it's an important bit of ensuring that our users don't get frustrated with what we make is a hover effect. How do we do a hover effect? Let me show you.
Creating a Hover Effect in Bubble
So at the moment I have this button styled by a style named Primary Button. And we have a video on our YouTube channel talking about why this is something that can be overlooked. That style allows you to basically build the look of an element once and then apply it to multiple elements. So we could have multiple buttons. And then if I go in and edit the style, let's take the font weight down, it applies it to every instance of the same type of element that has that style applied.
Overriding Styles for Individual Elements
Sometimes it's helpful to override that. So we'll do that by removing style. That makes this element then unique. It's not going to have an impact on other buttons. And over in conditional, you can see it's inherited it from that style I've just removed. I have a conditional statement of this button is Hovered and then the background color. And it's quite common just to go with a color that is slightly darker. And we can preview that by hitting the on so then the UI editor behaves as if this statement is passing as true.
Responsive Design Considerations for Hover Effects
Why is that relevant to responsive design? Well, because when we have a user who's on a tablet or a phone, they don't have hover. So as well as bearing in mind that if there's an important part of our app that relies on this element is hovered to display key information or whatever, really, you can't rely on that on a device that doesn't use a mouse because there is no hover when you're scrolling on an iPhone, for example.
Designing for Touch Interfaces
Something else to bear in mind is when we start to get down to say really small screens is someone isn't pointing with a mouse pointer or even likely using a stylus. They're using a finger to navigate your site. So don't create your buttons too small or too close to each other where they can't clearly tap on the elements that they want to interact with.