use*_*827 61 row hover css-tables twitter-bootstrap twitter-bootstrap-3
如何Bootstrap 3在悬停时更改表格行的背景.我现在使用的表类是table table-striped.我试图<tr>在表格中的标签上添加一个额外的类,并使css像这样.table-row:hover{background:black;}.现在只有非条纹行正在工作.是不是在引导程序中有一个类可以让我轻松实现它?或者我应该用它JQuery来解决这个问题?我真的无法自己解决这个问题.
jra*_*ede 138
您需要将该table-hover类添加到<table/>元素中.像这样:
<table class="table table-striped table-hover">
<tbody>
<tr>
<td>Col 1</td>
<td>Col 2 </td>
</tr>
</tbody>
</table>
Run Code Online (Sandbox Code Playgroud)
资料来源:文件