css - How to absolute position with border width counted in -
i have trouble absolute position.
<div class="frame" style="position:relative; width:100px;height:100%; box-sizing:border-box; border:10px solid black;"> <div class="problem" style="width:20px; height:100%; position:absolute; right:-20px;"></div> </div> the problem ".problem" using right boundary of ".frame" without considering border width, inside frame 20px; wonder how can let ".problem" use boundary of border right?
you've typo posiiton:absolute should position:absolute
i've added solution question :is possible position element relative border-box of parent?
just in case, helps!
Comments
Post a Comment