LDropl
LDropl

Reputation: 934

padding for Bootstrap column only for large grid

Is it possible to add padding for example for large grid only and for medium grid no padding ?

Large grid with padding:

    <div class="col-lg-4 pl-3">
    </div>

Medium grid without padding:

    <div class="col-md-3">
    </div>

how to combine them together and use padding for large grid only ?

Upvotes: 1

Views: 737

Answers (1)

Nayeem Rahman
Nayeem Rahman

Reputation: 49

For adding padding for any particular type of grid you use these classes-

Padding Left: pl-*-#

Here, in * use the grid sizes like lg, md, sm ... and in # use the values 1, 2, 3, ...

Like this way, you may use pb for padding-bottom, pr for padding-right, pt for padding-top, px for padding-horizontal and py for padding-vertical

You may find details here in Utility Spacing section https://hackerthemes.com/bootstrap-cheatsheet/

Upvotes: 1

Related Questions