css布局,左边的滚动时右边不随着滚动

<body>

   <div class="parent">

    <div class="leftChild"></div>

    <div class="rightChild"></div>

  </div>

</body>

body {width: 100%, height: 100%}

.parent {overflow: hidden; position:fixed; top:0; bottom:0; left:0; right:0}

.leftChild {float:left; overflow:auto; width:40%;height: 100%}

.leftChild {float:left; overflow:auto; width:60%; height: 100%}

后续还有更好的解决方案,会继续更新

 

posted @ 2018-06-15 13:49  小敏sweet  阅读(1789)  评论(0编辑  收藏  举报