Border
Notation
Border utility classes can be defined using the format -b{sides}[-{breakpoint}]--{size}
.
{sides}
t
- use to applyborder-top
b
- use to applyborder-bottom
l
- use to applyborder-left
r
- use to applyborder-right
x
- use to applyborder-left
andborder-right
y
- use to applyborder-top
andborder-bottom
- blank - leave blank to apply
border
to all 4 sides.
{breakpoint}
Optionally, include -{breakpoint} to apply the utility behaviour to some breakpoints. As a mobile-first library, any applying to smaller breakpoints will also modify larger ones unless another class overrides this behaviour.
- blank - leave blank to apply
border
to all breakpoints. sm
- use to applyborder
to sm and larger breakpoints.md
- use to applyborder
to md and larger breakpoints.lg
- use to applyborder
to lg and larger breakpoints.xl
- use to applyborder
to xl breakpoints.
{size}
0
- use to eliminate existingborder
and set to0
1
- use to setborder
to1px
2
- use to setborder
to2px
3
- use to setborder
to3px
4
- use to setborder
to4px
Examples
Border Colors
Use contextual color classes to change a border's color.