【发布时间】:2013-12-19 22:44:30
【问题描述】:
我将 Bootstrap 按钮组用作一系列复选框。
<div class="btn-group" data-toggle="buttons">
<label class="btn btn-primary">
<input type="checkbox"> Option 1
</label>
<label class="btn btn-primary">
<input type="checkbox"> Option 2
</label>
<label class="btn btn-primary">
<input type="checkbox"> Option 3
</label>
</div>
有关工作示例,请参阅http://getbootstrap.com/javascript/#buttons Checkbox 部分。
当您将鼠标悬停在未选中按钮上时,它会变为与选中按钮相同的颜色。如果您然后单击按钮,它不会改变颜色,因为它已经与选中按钮的颜色相同。因此,您必须将鼠标从按钮上移开,以验证您实际上是否正确单击了它。显然,当从选中状态移动到未选中状态时,也会出现类似的问题。我认为这对我的用户来说有点令人困惑。有什么方法可以让 Bootstrap 按钮在悬停时不改变颜色?
【问题讨论】:
标签: twitter-bootstrap twitter-bootstrap-3