gpt4 book ai didi

javascript - td中的对齐问题

转载 作者:太空宇宙 更新时间:2023-11-04 14:04:03 24 4
gpt4 key购买 nike

我使用下面的代码片段在 td 中对齐多个 div

<style type="text/css">
td {
border-collapse: collapse;
border-style: solid;
border-width: 1px 1px 1px 1px;
display: table-cell;
overflow: hidden;
/*padding: 0.7em;*/
height: 30px;
white-space: nowrap;
width: auto;
vertical-align: middle;
-moz-box-sizing: border-box!important;
box-sizing: border-box !important;
-webkit-box-sizing: border-box !important;
}
.e-gridtreeexpand {
width: 0;
height: 0;
border-bottom: 10px solid black;
border-left: 10px solid transparent;
}
.e-gridtreecollapse {
width: 0;
height: 0;
border-top: 5px solid transparent;
border-left: 10px solid black;
border-bottom: 5px solid transparent;
} </style>
<div style="height:30px;width:200px;">
<table>
<tr>
<td><div><div class="intend" style="height:1px; float:left; width:0px;"></div><div class="e-gridtreeexpand" style="float: left"></div><form style="width: 100%; height: 100%;" id="ejGridTreeGridEditForm"><input style="width: 100%; height: 100%;" name="taskId" id="ejGridTreeGridtaskId" value="1" class="e-field e-ejinputtext"></form></div></td>
</tr>
</table>
</div>

如何在 td 中水平对齐此 div

最佳答案

请查看JSFiddle url ,

<div style='float:right'><form style="height: 100%;"></form></div>

关于javascript - td中的对齐问题,我们在Stack Overflow上找到一个类似的问题: https://stackoverflow.com/questions/21264868/

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