我一直在寻找Bootstrap 4 - beta,但是当使用.is-invalid
与.input-group
它似乎并没有显示出来。Bootstrap 4无效反馈输入组不显示
<link href="https://maxcdn.bootstrapcdn.com/bootstrap/4.0.0-beta/css/bootstrap.min.css" rel="stylesheet" />
<div class="form-group">
<label for="label">Label</label>
<div class="input-group">
<div class="input-group-addon">
label
</div>
<input type="text" value="" name="label" class="form-control is-invalid">
</div>
<div class="invalid-feedback is-invalid">
<strong>Invalid Label</strong>
</div>
</div>
你怎么打算显示无效的信息,而使用.input-group
?
将以下CSS作为解决方法工作,但看起来很奇怪。
.form-group.is-invalid {
.invalid-feedback {
display: block;
}
}
有道理,似乎在表单验证侧面相当大的思念。希望下一个测试版将解决这个问题。 – Ian