Basecoat has margin and padding utility classes that you can add to any element. The spacing values are defined in a Sass map in the _variables.scss file, and classes are generated by a function in _utilities.scss. Additionally, Basecoat includes responsive utility classes, in case you want padding or margin only to kick in at certain breakpoints.
Borders & Rounded Corners
The below utility classes can be added to elements to give them a border or rounded corners.
Text
Text Color
You can put the class .text-white on any element to make its text white. Make sure to only apply this class on backgrounds that meet accessibility guidelines.
If you need your text to be small, use .text-small
I'm little tiny text, smaller than other paragraphs.
Text Alignment
By default, text is aligned on the left. If you need it to be centered or on the right, you can use a utility class. These alignment classes are responsive, for mobile-first styles.
I'm in the center.
I'm on the left on small screens, but centered on large screens.
Backgrounds
For applying a color to an element’s background that is different from the body background color.
Use .bg-black to give something a black background.
Use .bg-white to give something a white background.
Use .bg-gray-light to give something a gray background.
Use .bg-theme-color to give something you project's theme color as a background.
Use .bg-shade-gradient to give something a shadowed bg. This can be used in combination with any other background utility class.
Positioning
You can use the following utility classes to set positioning on elements.
I'm always a block element.I'm hidden on small screens, then medium-sized screens, I am inline, and on medium screens and above I become a block element.You can only see me on a small screen.
Additional positioning and alignment utilities
Display
Basecoat has utility classes for displaying elements. The mobile-first responsive classes are generated by a Sass function, which creates a class for each of the breakpoints in the breakpoint map.
Media Object
Media Objects as described here can be created using utility classes.
On smaller screens my image stacks, but on larger screens it floats to the left. This text is long to show that it doesn't wrap. Lorem ipsum dolor sit amet, consectetur adipiscing elit, sed do eiusmod tempor incididunt ut labore et dolore magna aliqua. Ut enim ad minim veniam, quis nostrud exercitation ullamco laboris nisi ut aliquip ex ea commodo consequat.