【发布时间】:2020-08-17 03:47:09
【问题描述】:
<tr *ngFor="let item of collection.data | paginate: config">
<th scope="row">
<div class="custom-control custom-checkbox">
<input type="checkbox" class="custom-control-input" [attr.id]="item.id">
<label class="custom-control-label" [attr.for]="item.id"></label>
</div>
</th>
<td>{{item.name}}
----code here----
</span>
</td>
我已经编写了上面的 HTML 代码,并且将鼠标悬停在名称上我应该能够查看详细信息。
【问题讨论】:
-
是什么阻止了您实现这一目标?有问题吗?
-
是的,实际上正在发生的事情是我将代码放入 span 并且表格正在扩展,而且我的位置也是相对的。我不知道为什么会这样
-
表格正在扩展,因为您没有将隐藏元素从文档流中取出。如果它出现,则单元格会增长,然后表格会扩展。您需要将其位置设置为绝对位置才能将其从文档流中移除。