Home › Forums › CSS › App like side-slide menu, fixed/absolute positioning problems inside parent div › Reply To: App like side-slide menu, fixed/absolute positioning problems inside parent div
January 13, 2014 at 5:22 am
#160238
Member
OK…if the right menu isn’t to scroll it will have to be position:fixed
.
So you will have to adjust the right value.
I’ve used
#rightmenu {
right: calc(50% - 521px); /* 50% less [300 (half of content width) + 221px (menu width)]
}
My JS skill are terrible but all you would have to do is adjust the “negative” value to get it into position.
http://codepen.io/Paulie-D/pen/nEiog
However, please note that because the position is now fixed, your overflow hidden will not affect it and you will have to find an alternative visibility solution.
Of course, others may have more elegant solutions.