gpt4 book ai didi

css - 当子元素在父元素上方时,safari 不滚动

转载 作者:太空宇宙 更新时间:2023-11-04 05:35:27 25 4
gpt4 key购买 nike

我有标签部分。单击选项卡时,其子内容出现在带有 CSS 的部分

position: absolute;
z-index: 9999;
top: 0;
left: 0;
height: 250px;
overflow: scroll;

但子元素似乎不可滚动。

最佳答案

请提及 Overflow-x 或 y 轴,不要使用 overflow:scroll;使用溢出:隐藏;

.abc {
height:100px;
overflow-x:hidden;}
<div class="abc">Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.</div>

关于css - 当子元素在父元素上方时,safari 不滚动,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/59731418/

25 4 0
Copyright 2021 - 2024 cfsdn All Rights Reserved 蜀ICP备2022000587号
广告合作:1813099741@qq.com 6ren.com