【发布时间】:2014-04-08 21:56:31
【问题描述】:
我正在制作一个全高菜单,当您单击选项卡时,它会从屏幕右侧滑出。
您会注意到,当您单击 openerthingie(选项卡)时,它会消失,直到动画完成然后重新出现。
这是为什么呢?我怎样才能让它和它的容器一起滑动?
HTML:
<div id="rightwrapper" class="closed">
<div id="openertabthingie">=</div>
</div>
<div id="leftwrapper" class="closed">
</div>
CSS:
#rightwrapper { position: relative; width: 0; height: 100%; float: right; background: #222; }
#rightwrapper #openertabthingie { position: absolute; height: 60px; width: 74px; top: 145px; left: -74px; background: #111; cursor: pointer; z-index: 1000; }
#leftwrapper { height: 100%; overflow: auto; position: fixed; width: 100%; background: #ccc; }
所有的 jquery 都在这里摆弄: http://jsfiddle.net/9k578/
【问题讨论】:
-
感谢您添加小提琴。我想帮忙,但需要从概念上知道你想要完成什么。这应该是一个动画打开还是关闭的盒子?
-
我的错。基本上,当您单击选项卡时,会从右侧滑出(打开)一个小菜单。
标签: jquery