【问题标题】:Remove gutter from card columns in Bootstrap 4从 Bootstrap 4 中的卡片列中删除装订线
【发布时间】:2016-06-07 00:49:45
【问题描述】:

如何去除 Bootstrap 4 的 .card-columns 容器中的列和行之间的间距?

【问题讨论】:

    标签: css twitter-bootstrap twitter-bootstrap-4 bootstrap-4


    【解决方案1】:

    .card-columns 容器利用了CSS columns 并定义了一个column-gap

    要移除列之间的间距,您需要移除列间隙:

    .no-gutter-card-deck.card-columns {
      column-gap: 0;
    }
    

    要移除行之间的间距,您需要移除卡片周围的边距:

    .no-gutter-card > .card {
      margin: 0;
    }
    

    演示:http://codeply.com/go/vLfsAlZFRn

    【讨论】:

      猜你喜欢
      • 1970-01-01
      • 2014-02-10
      • 2016-03-12
      • 2021-08-04
      • 1970-01-01
      • 1970-01-01
      • 2017-11-11
      • 1970-01-01
      • 2018-08-06
      相关资源
      最近更新 更多