This is a preview, you can find the current version here.
Last updated: 12/16/2025

Borders

Stacks provides atomic classes for borders.

Classes

ClassOutputApply border toResponsive?
.baborder: solid 1px #000all sides
.btborder-top: solid 1px #000top
.bbborder-bottom: solid 1px #000bottom
.blborder-left: solid 1px #000left
.brborder-right: solid 1px #000right
.byborder-top: solid 1px #000; border-bottom: solid 1px #000;top and bottom
.bxborder-left: solid 1px #000; border-right: solid 1px #000;left and right

Examples

<div class="ba"></div>
<div class="bt"></div>
<div class="br"></div>
<div class="bb"></div>
<div class="bl"></div>
<div class="bx"></div>
<div class="by"></div>
all sides
top
bottom
left
right
top and bottom
left and right

Width

Width classes

ClassOutputBorder width, side(s)Responsive?
.baw0border-width: 0zero, all sides
.btw0border-top-width: 0zero, top
.bbw0border-bottom-width: 0zero, bottom
.blw0border-left-width: 0zero, left
.brw0border-right-width: 0zero, right
.byw0border-top-width: 0; border-bottom-width: 0;zero, top and bottom
.bxw0border-left-width: 0; border-right-width: 0;zero, left and right
.baw1border-width: 1px1px, all
.btw1border-top-width: 1px1px, top
.bbw1border-bottom-width: 1px1px, bottom
.blw1border-left-width: 1px1px, left
.brw1border-right-width: 1px1px, right
.byw1border-top-width: 1px; border-bottom-width: 1px;1px, top and bottom
.bxw1border-left-width: 1px; border-right-width: 1px;1px, left and right
.baw2border-width: 2px2px, all
.btw2border-top-width: 2px2px, top
.bbw2border-bottom-width: 2px2px, bottom
.blw2border-left-width: 2px2px, left
.brw2border-right-width: 2px2px, right
.byw2border-top-width: 2px; border-bottom-width: 2px;2px, top and bottom
.bxw2border-left-width: 2px; border-right-width: 2px;2px, left and right
.baw3border-width: 4px4px, all
.btw3border-top-width: 4px4px, top
.bbw3border-bottom-width: 4px4px, bottom
.blw3border-left-width: 4px4px, left
.brw3border-right-width: 4px4px, right
.byw3border-top-width: 4px; border-bottom-width: 4px;4px, top and bottom
.bxw3border-left-width: 4px; border-right-width: 4px;4px, left and right

Width examples

<div class="ba"></div>
<div class="ba brw0"></div>
<div class="ba bbw0"></div>
<div class="ba baw2"></div>
<div class="ba baw3"></div>
.ba
.ba.brw0
.ba.bbw0
.ba.baw2
.ba.baw3

Style

Style classes

ClassOutputDefinition
.bas-solidborder-style: solidApplies a solid border style to all sides
.bts-solidborder-top-style: solidApplies a solid border style to the top side
.brs-solidborder-right-style: solidApplies a solid border style to the right side
.bbs-solidborder-bottom-style: solidApplies a solid border style to the bottom side
.bls-solidborder-left-style: solidApplies a solid border style to the left side
.bas-dashedborder-style: dashedApplies a dashed border style to all sides
.bts-dashedborder-top-style: dashedApplies a dashed border style to the top side
.brs-dashedborder-right-style: dashedApplies a dashed border style to the right side
.bbs-dashedborder-bottom-style: dashedApplies a dashed border style to the bottom side
.bls-dashedborder-left-style: dashedApplies a dashed border style to the left side

Style examples

<div class="ba bas-solid"></div>
<div class="ba bas-dashed"></div>
<div class="ba brs-dashed"></div>
Solid border style
Dashed border style
Dashed border right style

Color

Color classes

Each color stop is available as a border class. See the colors documentation for all available classes.

Edit on GitHub