Clickable Boxes in Bootstrap 4
Alright. You might have been asking for the last like 30 videos, are we there yet? We are there finally got one more little thing to do. We are going to style these blue primary buttons down the bottom. We're going to make them this nice green colour. Let's jump in and work out how to do it now in bootstrap and venus code. Alright, so at the moment my card here, the only thing you can click is the button and that's totally fine. But I want to make the entire card clickable. Okay. And Bootstrap has a special class for that. Okay, so under utilities, there's one called stretched link, basically all we need to do is add this okay, to this little nice little class to the a tag. It will make the parent okay? Or clickable. Apparently let's give it a go. So let's grab that. Let's go into our visual studio code. Let's find the a tag. Okay, there it is there inside my card and we'll add it to this. Let's change the link to go somewhere. Okay, so just I don't know, I'm not going anywhere. It fee...
ls like it feels like a shoot. Anyway, let's go to any old website. Okay? And let's save it and let's give it a go. All right. First up, we've got the mickey mouse hand. This one doesn't see the mickey mouse and only appears over there. Okay, if you don't have the mickey mouse hand, different operating systems have different curses. Okay, but there we go. And if I click on it. Hey, presto. Hey, it's me. Okay, so really easy. I love that. Seems like it's such a nice easy thing to do. Alright, let's do it for the other links and let's probably style the button and then that's gonna be us. We'll be adding it to this link here. We're gonna do primary, going to do both these, let's make sure they work first. Let's go back one. Okay, that one works. This one doesn't why not refresh? Refresh on that one worked. Okay. So sometimes you do need to hit refresh. Okay, We've learned that through the course. Right? All right. It's all clickable. Let's change this button because this button at the moment has a hover which we don't like and the color is wrong. So we're going to actually, we kind of created our own kind of styles for primary outline. We're going to do the same thing for this one here. Just button primary. Don't want the outlying version. So let's make a class over here together. Our finale finale class, we'll call it. Okay? And we're gonna make the background to the B G. Actually we'll make the background background color, background color and we're going to use color views before somewhere. K O B B C nine K is going to give us the green, check it. Perfect. Okay, we need to change the hover. Okay, because it's still going blue. So we'll make a pseudo class actually will make a compound and pseudo class let's go out in a blaze of CSS glory. So comma, I want to do this one again, but I want this one to be there colon hover, so remember comma separates, so we're doing two separate things and the separate things happen to be the regular primary process, the pseudo version of it where we hover above. Let's check it out and now hover is the same color as I'm just waiting for it to change. I didn't pick a different color, I just wanted to be the same. It's also work on the border color here. So order color. We're going to make it the same color as. Can you set it to none. Let's have a look, nope. You gotta set it to a color. We could probably turn the size down on it, but we're actually just going to set it to the same color as everything else. There we go, look at us and that is going to be it for our coding together. Hang around for the next video where we'll discuss your next steps and of course I'll take your payment details for the yogurt that you want to order. See in a sec