Commit 1706f494 authored by Mark Otto's avatar Mark Otto Committed by Mark Otto
Browse files

flexbox powered indicators

This revamps the indicators to use flexbox instead of inline-block for added flexbility (hah). Indicators now automatically scale based on the number of elements present, and max out at the `$carousel-indicator-width` instead of always being that wide.
parent d426c3c5
Showing with 7 additions and 2 deletions
+7 -2
......@@ -121,6 +121,8 @@
bottom: 10px;
left: 0;
z-index: 15;
display: flex;
justify-content: center;
padding-left: 0; // override <ul> default
// Use the .carousel-control's width as margin so we don't overlay those
margin-right: $carousel-control-width;
......@@ -130,9 +132,11 @@
li {
position: relative;
display: inline-block;
width: $carousel-indicator-width;
flex: 1 0 auto;
max-width: $carousel-indicator-width;
height: $carousel-indicator-height;
margin-right: $carousel-indicator-spacer;
margin-left: $carousel-indicator-spacer;
text-indent: -999px;
cursor: pointer;
background-color: rgba($carousel-indicator-active-bg, .5);
......
......@@ -912,6 +912,7 @@ $carousel-control-opacity: .5 !default;
$carousel-indicator-width: 30px !default;
$carousel-indicator-height: 3px !default;
$carousel-indicator-spacer: 3px !default;
$carousel-indicator-active-bg: #fff !default;
$carousel-caption-width: 70% !default;
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment