Borders
The Border Utilities extend Bootstrap by adding precise control over border width, style, and radius using Sass-powered utilities — fully RTL and LTR aware.
All classes use the al- prefix and follow utility-first conventions.
Overview
| Utility Type | Class Format | Description |
|---|---|---|
| Border Width | .al-border-{value} | Border width (px) |
| Border Style | .al-border-{style} | Border style: dotted, double |
| Border Radius | .al-rounded-{value} | Border radius (px) |
| Radius Top/Bottom | .al-rounded-top-{value} / .al-rounded-bottom-{value} | Top or bottom corners |
| Radius Start/End | .al-rounded-start-{value} / .al-rounded-end-{value} | Logical corners (RTL safe) |
| Sub-corner Start/End | .al-rounded-start-top-{value} ... | Individual logical corners |
| Outline Size | .al-outline-{value} | Outline width in px |
| Outline Offset | .al-outline-offset-{value} | Outline offset in px |
| Outline Color | .al-outline-{color} | Solid color outline |
| Outline Opacity | .al-outline-{color}-{opacity} | RGBA color outline |
| Outline Style | .al-outline-{style} | Outline style type |
Sass Reference
$border-size: ( 1:1, 2:2, 3:3, 4:4, 5:5, 6:6, 7:7, 8:8, 9:9, 10:10);
$radius-size: ( 0:0, 2:2, 3:3, 4:4, 5:5, 6:6, 8:8, 10:10, 12:12, 15:15, 16:16, 20:20, 24:24, 32:32, 48:48, 64:64);
$outline-size: ( 1:1, 2:2, 3:3, 4:4, 5:5, 6:6, 7:7, 8:8, 9:9, 10:10);
$outline-opacity: ( 5: 0.05, 10: 0.10, 25: 0.25, 50: 0.50, 75: 0.75);
Class Usage Reference
| Class | Output |
|---|---|
| .al-border-3 | --bs-border-width: 3px |
| .al-border-dotted | --bs-border-style: dotted |
| .al-border-double | --bs-border-style: double |
| .al-rounded-12 | border-radius: 12px |
| .al-rounded-top-32 | Top radius 32px |
| .al-rounded-bottom-16 | Bottom radius 16px |
| .al-rounded-start-20 | Start radius 20px |
| .al-rounded-end-20 | End radius 20px |
| .al-rounded-start-top-20 | Start top radius 20px |
| .al-rounded-end-top-20 | End top radius 20px |
| .al-rounded-start-bottom-20 | Start bottom radius 20px |
| .al-rounded-end-bottom-20 | End radius bottom 20px |
| .al-outline | outline: 1px solid |
| .al-outline-5 | outline-width: 5px |
| .al-outline-offset-3 | outline-offset: 3px |
| .al-outline-primary | outline-color: var(--bs-primary) |
| .al-outline-danger-50 | rgba(var(--bs-danger-rgb), 0.5) |
| .al-outline-dashed | outline-style: dashed |
Border Examples
Border Width
Border Style
Border Radius Examples
Border Radius - Top / Bottom / Start / End
Border Radius - Start Top / Start Bottom / End Top / End Bottom
Outline Examples
Basic Outline
Outline Width
Outline Offset
Outline Color
Outline Color with Opacity
Outline Style
Developer Notes
-
Border width fully controlled via $border-size Sass map
-
Border radius fully controlled via $radius-size Sass map
-
Fully LTR/RTL aware via logical start and end utilities
-
Border style uses native Bootstrap CSS variable --bs-border-style
-
Border width uses native Bootstrap CSS variable --bs-border-width
-
Outline size controlled from $outline-size map
-
Opacity fully supported via $outline-opacity map
-
Fully integrates with Bootstrap color variables
-
Style utilities cover: solid, dotted, dashed, double
-
Border-width overrides use CSS variable --bs-border-width
-
Border-style overrides use CSS variable --bs-border-style
-
Can be combined seamlessly with all existing Bootstrap classes