How to Customize Bootstrap Column Widths?

前端 未结 6 807
我在风中等你
我在风中等你 2020-12-05 02:23

I have this, but I feel 4 is too big for my sidebar width and 3 is too small (it has to add up to 12).

  
6条回答
  •  春和景丽
    2020-12-05 02:47

    You could certainly create your own classes:

    .col-md-3point5 {width: 28.75%}
    .col-md-8point5 {width: 81.25%;}
    

    I'd do this before I'd mess with the default columns. You may want to use those inside these.

    You'd probably also want to put those inside a media query statement so that they only apply for larger-than-mobile screen sizes.

提交回复
热议问题