我有这样的布局:

完整内容的positionabsolute

我只希望滚动此I should scroll框和此灰色内容,以保持其位置。

代码和游乐场位于=> codepen

html - 在绝对定位的父级中滚动子级div-LMLPHP

最佳答案

您需要修改CSS文件

.user-search-box .result-list{
  position: absolute;
  max-height:100%;
  min-width:100%;
  overflow:scroll;
}

关于html - 在绝对定位的父级中滚动子级div,我们在Stack Overflow上找到一个类似的问题:https://stackoverflow.com/questions/39396099/

10-14 14:37
查看更多