我有以下代码:
<div class="card">
<div class="card-block">
<form>
<div class="form-group col-sm-6">
<label for="visualTheme" class="control-label">Visual Theme</label>
<div>
<input class="form-control"
style="height:30px;width:250px" id="visualTheme" />
</div>
</div>
<div class="form-group col-sm-6">
<label for="startingScreen" class="control-label">Starting Screen</label>
<div>
<input class="form-control"
style="height:30px;width:250px" id="startingScreen" />
</div>
</div>
</form>
</div>
但是使用Alpha 6它看起来像这样:
这是我的 Fiddle
为什么即使有足够的空间将它们放在同一行上,它也会包装列?它与Alpha 4一样正确。
由于
答案 0 :(得分:2)
col-*
应始终放在row
..
<div class="card">
<div class="card-block">
<form class="row">
<div class="form-group col-sm-6">
<label for="visualTheme" class="control-label">Visual Theme</label>
<div>
<input class="form-control" style="height:30px;width:250px" id="visualTheme">
</div>
</div>
<div class="form-group col-sm-6">
<label for="startingScreen" class="control-label">Starting Screen</label>
<div>
<input class="form-control" style="height:30px;width:250px" id="startingScreen">
</div>
</div>
</form>
</div>
</div>