例如:<div class="container m-5">可以完美地工作,但<div class="container m-9">不能。任何超过5的数字似乎都不再有效。为什么会这样呢?
发布于 2021-03-10 13:38:50
你绝对是对的。bootstrap 4+中只有m-1, m-2, m-3, m-4, m-5类。如果你想提供更多的空间,那么在它的子div中给出另一个m-5类,比如<div class="container m-5"><div class="subcontainer m-5">,参考这个Doc。
发布于 2021-03-10 13:41:02
对于不超过5. Check here for documentation的间隔实用程序,Bootstrap 4仅包含五个级别的缩放。
.m-1{ margin: .25rem!important}
.m-2{ margin: .5rem!important}
.m-3{ margin: 1rem!important}
.m-4{ margin: 1.5rem!important}
.m-5{ margin: 3rem!important}https://stackoverflow.com/questions/66558869
复制相似问题