diff --git a/docs/assets/css/bootstrap.css b/docs/assets/css/bootstrap.css index f39fe4771948087d2755c3c604aa1fdc5aa2c03c..0a20e33789e96e4ebc25be92c2333a0512220def 100644 --- a/docs/assets/css/bootstrap.css +++ b/docs/assets/css/bootstrap.css @@ -5596,28 +5596,38 @@ a.badge:hover { .carousel-control { position: absolute; - top: 40%; - left: 15px; - width: 40px; - height: 40px; - margin-top: -20px; - font-size: 60px; - font-weight: 100; - line-height: 30px; - color: #ffffff; - text-align: center; - background: #222222; - border: 3px solid #ffffff; - -webkit-border-radius: 23px; - -moz-border-radius: 23px; - border-radius: 23px; + top: 0; + bottom: 0; + left: 0; + width: 100px; opacity: 0.5; filter: alpha(opacity=50); } +.carousel-control.left { + background-color: rgba(0, 0, 0, 0.001); + background-color: transparent; + background-image: -moz-linear-gradient(left, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.001)); + background-image: -webkit-gradient(linear, 0 0, 100% 0, from(rgba(0, 0, 0, 0.75)), to(rgba(0, 0, 0, 0.001))); + background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.001)); + background-image: -o-linear-gradient(left, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.001)); + background-image: linear-gradient(to right, rgba(0, 0, 0, 0.75), rgba(0, 0, 0, 0.001)); + background-repeat: repeat-x; + filter: progid:dximagetransform.microsoft.gradient(startColorstr='#bf000000', endColorstr='#00000000', GradientType=1); +} + .carousel-control.right { - right: 15px; + right: 0; left: auto; + background-color: rgba(0, 0, 0, 0.75); + background-color: transparent; + background-image: -webkit-gradient(linear, 0 0, 100% 0, from(rgba(0, 0, 0, 0.001)), to(rgba(0, 0, 0, 0.75))); + background-image: -moz-linear-gradient(left, rgba(0, 0, 0, 0.001), rgba(0, 0, 0, 0.75)); + background-image: -o-linear-gradient(left, rgba(0, 0, 0, 0.001), rgba(0, 0, 0, 0.75)); + background-image: linear-gradient(to right, rgba(0, 0, 0, 0.001), rgba(0, 0, 0, 0.75)); + background-image: -webkit-linear-gradient(left, rgba(0, 0, 0, 0.001), rgba(0, 0, 0, 0.75)); + background-repeat: repeat-x; + filter: progid:dximagetransform.microsoft.gradient(startColorstr='#00000000', endColorstr='#bf000000', GradientType=1); } .carousel-control:hover { @@ -5627,23 +5637,37 @@ a.badge:hover { filter: alpha(opacity=90); } +.carousel-control .control { + position: absolute; + top: 50%; + z-index: 5; + display: block; + margin-top: -35px; + margin-left: 35px; + font-size: 80px; + font-weight: 100; + color: #fff; + text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); +} + .carousel-caption { position: absolute; right: 0; bottom: 0; left: 0; - padding: 15px; - background: #333333; - background: rgba(0, 0, 0, 0.75); + z-index: 10; + max-width: 60%; + padding: 40px; + text-shadow: 0 1px 2px rgba(0, 0, 0, 0.6); } -.carousel-caption h4, +.carousel-caption h3, .carousel-caption p { line-height: 20px; color: #ffffff; } -.carousel-caption h4 { +.carousel-caption h3 { margin: 0 0 5px; } diff --git a/docs/javascript.html b/docs/javascript.html index 0dcd2053dbfece4c6429ee3b34f23abc6fefb4ea..0a757c2dea321210d40953d6179116a6e8b15894 100644 --- a/docs/javascript.html +++ b/docs/javascript.html @@ -1416,27 +1416,31 @@ $('#myCollapsible').on('hidden', function () { <div class="item active"> <img src="assets/img/bootstrap-mdo-sfmoma-01.jpg" alt=""> <div class="carousel-caption"> - <h4>First Thumbnail label</h4> - <p>Cras justo odio, dapibus ac facilisis in, egestas eget quam. Donec id elit non mi porta gravida at eget metus. Nullam id dolor id nibh ultricies vehicula ut id elit.</p> + <h3>First slide label</h3> + <p>Nulla vitae elit libero, a pharetra augue. Maecenas faucibus mollis interdum. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div> </div> <div class="item"> <img src="assets/img/bootstrap-mdo-sfmoma-02.jpg" alt=""> <div class="carousel-caption"> - <h4>Second Thumbnail label</h4> - <p>Cras justo odio, dapibus ac facilisis in, egestas eget quam. Donec id elit non mi porta gravida at eget metus. Nullam id dolor id nibh ultricies vehicula ut id elit.</p> + <h3>Second slide label</h3> + <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean lacinia bibendum nulla sed consectetur. Nullam quis risus eget urna mollis ornare vel eu leo.</p> </div> </div> <div class="item"> <img src="assets/img/bootstrap-mdo-sfmoma-03.jpg" alt=""> <div class="carousel-caption"> - <h4>Third Thumbnail label</h4> - <p>Cras justo odio, dapibus ac facilisis in, egestas eget quam. Donec id elit non mi porta gravida at eget metus. Nullam id dolor id nibh ultricies vehicula ut id elit.</p> + <h3>Third slide label</h3> + <p>Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Integer posuere erat a ante venenatis dapibus posuere velit aliquet. Nullam id dolor id nibh ultricies vehicula ut id elit.</p> </div> </div> </div> - <a class="left carousel-control" href="#myCarousel" data-slide="prev">‹</a> - <a class="right carousel-control" href="#myCarousel" data-slide="next">›</a> + <a class="left carousel-control" href="#myCarousel" data-slide="prev"> + <span class="control">‹</span> + </a> + <a class="right carousel-control" href="#myCarousel" data-slide="next"> + <span class="control">›</span> + </a> </div> </div> <pre class="prettyprint linenums"> diff --git a/docs/templates/pages/javascript.mustache b/docs/templates/pages/javascript.mustache index b707ebe20e6cba1805daa63a8189a1f662e41748..ff16aba8b3466e3bb5bba27edd7264f446cd5c13 100644 --- a/docs/templates/pages/javascript.mustache +++ b/docs/templates/pages/javascript.mustache @@ -1348,27 +1348,31 @@ $('#myCollapsible').on('hidden', function () { <div class="item active"> <img src="assets/img/bootstrap-mdo-sfmoma-01.jpg" alt=""> <div class="carousel-caption"> - <h4>{{_i}}First Thumbnail label{{/i}}</h4> - <p>Cras justo odio, dapibus ac facilisis in, egestas eget quam. Donec id elit non mi porta gravida at eget metus. Nullam id dolor id nibh ultricies vehicula ut id elit.</p> + <h3>{{_i}}First slide label{{/i}}</h3> + <p>Nulla vitae elit libero, a pharetra augue. Maecenas faucibus mollis interdum. Cum sociis natoque penatibus et magnis dis parturient montes, nascetur ridiculus mus.</p> </div> </div> <div class="item"> <img src="assets/img/bootstrap-mdo-sfmoma-02.jpg" alt=""> <div class="carousel-caption"> - <h4>{{_i}}Second Thumbnail label{{/i}}</h4> - <p>Cras justo odio, dapibus ac facilisis in, egestas eget quam. Donec id elit non mi porta gravida at eget metus. Nullam id dolor id nibh ultricies vehicula ut id elit.</p> + <h3>{{_i}}Second slide label{{/i}}</h3> + <p>Lorem ipsum dolor sit amet, consectetur adipiscing elit. Aenean lacinia bibendum nulla sed consectetur. Nullam quis risus eget urna mollis ornare vel eu leo.</p> </div> </div> <div class="item"> <img src="assets/img/bootstrap-mdo-sfmoma-03.jpg" alt=""> <div class="carousel-caption"> - <h4>{{_i}}Third Thumbnail label{{/i}}</h4> - <p>Cras justo odio, dapibus ac facilisis in, egestas eget quam. Donec id elit non mi porta gravida at eget metus. Nullam id dolor id nibh ultricies vehicula ut id elit.</p> + <h3>{{_i}}Third slide label{{/i}}</h3> + <p>Praesent commodo cursus magna, vel scelerisque nisl consectetur et. Integer posuere erat a ante venenatis dapibus posuere velit aliquet. Nullam id dolor id nibh ultricies vehicula ut id elit.</p> </div> </div> </div> - <a class="left carousel-control" href="#myCarousel" data-slide="prev">‹</a> - <a class="right carousel-control" href="#myCarousel" data-slide="next">›</a> + <a class="left carousel-control" href="#myCarousel" data-slide="prev"> + <span class="control">‹</span> + </a> + <a class="right carousel-control" href="#myCarousel" data-slide="next"> + <span class="control">›</span> + </a> </div> </div>{{! /example }} <pre class="prettyprint linenums"> diff --git a/less/carousel.less b/less/carousel.less index 33f98ac4d23b0e84b6714bc904d824cddb466568..d92cb1bcca8ec78b6f4f27e5f4b39ad5e706da8c 100644 --- a/less/carousel.less +++ b/less/carousel.less @@ -10,9 +10,9 @@ } .carousel-inner { + position: relative; overflow: hidden; width: 100%; - position: relative; } .carousel { @@ -69,21 +69,17 @@ .carousel-control { position: absolute; - top: 40%; - left: 15px; - width: 40px; - height: 40px; - margin-top: -20px; - font-size: 60px; - font-weight: 100; - line-height: 30px; - color: @white; - text-align: center; - background: @grayDarker; - border: 3px solid @white; - .border-radius(23px); + top: 0; + left: 0; + bottom: 0; + width: 100px; .opacity(50); + &.left { + #gradient > .horizontal(rgba(0,0,0,.75), rgba(0,0,0,.001)); + background-color: transparent; + } + // we can't have this transition here // because webkit cancels the carousel // animation if you trip this while @@ -94,7 +90,9 @@ // Reposition the right one &.right { left: auto; - right: 15px; + right: 0; + #gradient > .horizontal(rgba(0,0,0,.001), rgba(0,0,0,.75)); + background-color: transparent; } // Hover state @@ -104,6 +102,18 @@ .opacity(90); } } +.carousel-control .control { + position: absolute; + top: 50%; + z-index: 5; + display: block; + margin-top: -35px; + margin-left: 35px; + font-size: 80px; + font-weight: 100; + color: #fff; + text-shadow: 0 1px 2px rgba(0,0,0,.6); +} // Caption for text below images @@ -114,16 +124,17 @@ left: 0; right: 0; bottom: 0; - padding: 15px; - background: @grayDark; - background: rgba(0,0,0,.75); + z-index: 10; + padding: 40px; + text-shadow: 0 1px 2px rgba(0,0,0,.6); + max-width: 60%; } -.carousel-caption h4, +.carousel-caption h3, .carousel-caption p { color: @white; line-height: @baseLineHeight; } -.carousel-caption h4 { +.carousel-caption h3 { margin: 0 0 5px; } .carousel-caption p {