It took me an hour to finish this. There is this slight push to top when you hover the button. I don't know what caused that.
Alex Efimenko
@aleksandr-efimenkoAll comments
- @frkanyilmaz2Submitted over 1 year ago@aleksandr-efimenkoPosted over 1 year ago
Hello @frkanyilmaz2,
Great job!
The reason why the button moves slightly when hovering is due to the border property. When you add a border to an element, it increases the size of the element, which can cause it to shift position. To prevent this from happening, you can use the
outline: 1px solid #f2f2f2;
property instead ofborder
in your.buttons:hover
styles. Theoutline
property will add a border-like effect without changing the size of the element, so there won't be any shifting when you hover.Alternatively, you can add a transparent border to your .buttons styles. This will create space for the border to be added when you hover, without changing the size of the button. You can do this by adding
border: 1px solid transparent
to your .buttons styles.I hope this additional information is helpful to you in understanding the cause of the issue and providing alternative solutions to fix it.
Marked as helpful1