form-checkbox css of bootstrap 3等价于bootstrap 4

lztngnrs  于 12个月前  发布在  Bootstrap
关注(0)|答案(2)|浏览(151)

我在bootstrap 3中使用<input type="checkbox class="form-checkbox form-control-radio">。我试图升级到bootstrap 4,找不到这些类form-checkbox form-control-radio
这些类被删除了吗?或者我们在bootstrap 4中有任何等价的类吗?

zed5wv10

zed5wv101#

bootstrap v3不再由bootstrap团队维护,因此您可以使用它。class="form-checkbox form-control-radio"在bootstrap v4中,这些类被bootstrap团队删除,因此这些类不再工作,因此您无法使用它们。对于您的解决方案,您可以使用这些类..

<div class="input-group-text">
      <input type="checkbox" aria-label="Checkbox for following text input">
    </div>
  </div>```

to checked box. for more details you can follow bootstrap v4 official document.

https://getbootstrap.com/docs/4.0/components/input-group/#multiple-inputs
vptzau2j

vptzau2j2#

是,此类将从引导中删除
您可以使用下面的类进行bootstrap 4

<div class="form-check">
    <input type="checkbox" class="form-check-input" id="exampleCheck1">
    <label class="form-check-label" for="exampleCheck1">Check me out</label>
</div>

有关更多信息,请参阅 Bootstrap https://getbootstrap.com/docs/4.0/components/forms/的此链接

相关问题