From the course: Bootstrap 4 Essential Training

Unlock the full course today

Join today to access over 22,600 courses taught by industry experts or purchase this course individually.

Using colors with Bootstrap

Using colors with Bootstrap - Bootstrap Tutorial

From the course: Bootstrap 4 Essential Training

Start my 1-month free trial

Using colors with Bootstrap

- [Instructor] Bootstrap has a number of colors that you can access through what are called contextual color names. Now, these are names like primary, secondary, success, danger, and info, and they're called contextual because they have a meaning to them. When you say primary and secondary, that means that primary probably has more importance than secondary and info and danger. All those things mean things, but in reality what they actually do is give you different colors. Now, if you're using the Sass version of Bootstrap, you can redefine what those colors are, but that's the main way that you control the color of things in Bootstrap, and there's two different sort of family of classes that you can use. The first are to control different kinds of text, so you can add the text label as a class and then put a hyphen and then add a color name, so you can add a class, for example, of text-success, and that would give you text that is green, and if you do text-danger, it would be red, et…

Contents