How can I make the progress bars thinner with Bootstrap 3.0? I'm thinking how the YouTube like/dislike meter looks (the blue bar). I've tried searching for any CSS tricks but could not find anything.
Height of Progress Bar: Use CSS property to change the height of progress bar. The default height of progress is 16px. The height of progress and progress-bar container must be the same.
A normal <div> element can be used for a progress bar. The CSS width property can be used to set the height and width of a progress bar.
For creating a default static progress bar, we need the following elements. aria-valuenow- This is known as curent progress bar value. aria-valuemin- This is known as initial value of the progress bar value. aria-valuemax- This is known as maximum value of the progress bar value.
As easy as doing this:
.progress {height: 10px;}
See: Reduce the height of progress bar
Extra, if you want to show the text inside the progress bar:
.progress {height: 20px;} // we increased it so the text is visible or change font size .progress .sr-only { position: relative; }
See: Show text inside progress bar
Shina is right, I just would like to add, it may be in some cases necessary to add the !important command to make the change apply over the already set parameter of the "progress" class, like this:
.progress {height: 10px !important;}
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With