Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Bootstrap modify breadcrumb with fontawesome icon separator with SASS

So I'm trying to change the default breadcrumb style with SASS. I've setup everything as mentioned in the official Bootstrap 4 beta 3 docs. I've changed the following in the custom.scss

$breadcrumb-divider: "\f105"; //fontawesome icon for fa-angle-right

Now this also needs font family to set to

font-family: 'fontAwesome'; //How do I plug this in

How do you setup the font for the .breadcrumb-item::before class in the right way?

like image 973
Soham Dasgupta Avatar asked Jan 08 '18 14:01

Soham Dasgupta


People also ask

How do I change breadcrumb separator in bootstrap?

They can be changed by modifying a local CSS custom property --bs-breadcrumb-divider , or through the $breadcrumb-divider Sass variable — and $breadcrumb-divider-flipped for its RTL counterpart, if needed.

How do I change the color of breadcrumbs in bootstrap?

Go to Customizing Bootstrap page. Move to Breadcrumbs section. Override the default value of @breadcrumb-active-color varaible with the value that you need i.e. #000 . Move to Download section and press "Compile and Download" Button.

How do I use breadcrumbs in bootstrap?

Since breadcrumbs provide a navigation, it's a good idea to add a meaningful label such as aria-label="breadcrumb" to describe the type of navigation provided in the <nav> element, as well as applying an aria-current="page" to the last item of the set to indicate that it represents the current page.


1 Answers

Try this:

.breadcrumb-item::before {
    font-family: 'FontAwesome';
    content: "\f105";
}
like image 184
Rodlen Avatar answered Sep 24 '22 17:09

Rodlen