0

Can someone tell me how to make drop-down menu do not move? When I press on it it jumps left right..

Help https://code.sololearn.com/WD6MsDPD7bub/?ref=app

9th Apr 2020, 7:58 PM
kaspars kaspars
kaspars kaspars - avatar
3 ответов
+ 2
The easiest fix would be to change right to left in the CSS in line 38.
9th Apr 2020, 8:27 PM
Aaron Eberhardt
Aaron Eberhardt - avatar
+ 2
Because the whole element <div id="menu-box"> grows once the elements of the drop-down are visible. Since it grows to the right it pushes the menu button with it because the menu button follows the left edge of the box. If you want to visualise this add something like border: 1px solid red; to the CSS of the #menu-box and see what happens.
9th Apr 2020, 8:55 PM
Aaron Eberhardt
Aaron Eberhardt - avatar
0
Why it was moving when it was o.n right?
9th Apr 2020, 8:42 PM
kaspars kaspars
kaspars kaspars - avatar