0

Transitions and hovering

So I have this code. I was experimenting with transitions and hovering. It slowly transitions for the width, but the height won't work. Anyone know why? https://code.sololearn.com/WpMWwtgSJ8dS/?ref=app

24th May 2018, 6:15 AM
Daniel Cooper
Daniel Cooper - avatar
4 ответов
+ 10
Specify the transition for both height and width. #button { border:1px solid black; border-radius:15px; width:3cm; height:1cm; transition:width 2s, height 2s; } #button:hover { width:4cm; height:4cm; }
24th May 2018, 6:22 AM
Hatsy Rei
Hatsy Rei - avatar
0
It was possibly just glitching. After leaving without saving and completely re writing the code the exact same way, it worked fine for me.
24th May 2018, 2:24 PM
Daniel Cooper
Daniel Cooper - avatar
0
nevermind. It stopped working again.
24th May 2018, 5:19 PM
Daniel Cooper
Daniel Cooper - avatar