我需要获取响应式表格,因此在小型设备上,我将overflow-x:auto
添加到其父级,table-layout:fixed
添加到表中。
代码在这里
HTML
<div class="class1">
<table class="class2">...</table>
</div>
CSS
.class1{overflow-x:auto}
.class2{width:640px,table-layout:fixed}
但是在iPhone上点击行时,tr
- s表现得非常奇怪,高度开始增加。
有没有人遇到同样的问题或知道解决方案?
答案 0 :(得分:0)
根据我的经验,问题不在table-layout:fixed
或overflow: auto
。它们都在设备上运行良好。您可以尝试将overflow-y:hidden
添加到.class1