0
0
mirror of https://github.com/twbs/bootstrap.git synced 2024-11-29 11:24:18 +01:00

try using tricker opacity thingy

This commit is contained in:
Jacob Thornton 2011-08-28 17:40:25 -07:00
parent d8d6e40097
commit 9059a72bf8
4 changed files with 16 additions and 10 deletions

11
bootstrap-1.1.1.css vendored
View File

@ -6,7 +6,7 @@
* http://www.apache.org/licenses/LICENSE-2.0 * http://www.apache.org/licenses/LICENSE-2.0
* *
* Designed and built with all the love in the world @twitter by @mdo and @fat. * Designed and built with all the love in the world @twitter by @mdo and @fat.
* Date: Sun Aug 28 16:34:52 PDT 2011 * Date: Sun Aug 28 17:40:04 PDT 2011
*/ */
/* Reset.less /* Reset.less
* Props to Eric Meyer (meyerweb.com) for his CSS reset file. We're using an adapted version here that cuts out some of the reset HTML elements we will never need here (i.e., dfn, samp, etc). * Props to Eric Meyer (meyerweb.com) for his CSS reset file. We're using an adapted version here that cuts out some of the reset HTML elements we will never need here (i.e., dfn, samp, etc).
@ -1679,8 +1679,10 @@ button.btn::-moz-focus-inner, input[type=submit].btn::-moz-focus-inner {
box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05); box-shadow: inset 0 1px 1px rgba(0, 0, 0, 0.05);
} }
.modal-backdrop { .modal-backdrop {
background-color: rgba(0, 0, 0, 0.5); /* background-color: rgba(0,0,0,.5);
filter: progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr='#aa000000',endColorstr='#aa000000'); filter: e(%("progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=%d,endColorstr=%d)", '#aa000000', '#aa000000'));*/
background-color: #000;
position: fixed; position: fixed;
top: 0; top: 0;
left: 0; left: 0;
@ -1688,6 +1690,9 @@ button.btn::-moz-focus-inner, input[type=submit].btn::-moz-focus-inner {
bottom: 0; bottom: 0;
z-index: 1000; z-index: 1000;
} }
.modal-backdrop.fade.in {
opacity: .5;
}
.modal { .modal {
position: fixed; position: fixed;
top: 50%; top: 50%;

View File

@ -226,7 +226,7 @@ button.btn::-moz-focus-inner,input[type=submit].btn::-moz-focus-inner{padding:0;
.pagination ul li.disabled a,.pagination ul li.disabled a:hover{background-color:transparent;color:#bfbfbf;} .pagination ul li.disabled a,.pagination ul li.disabled a:hover{background-color:transparent;color:#bfbfbf;}
.pagination ul li.next a{border:0;} .pagination ul li.next a{border:0;}
.well{background-color:#f5f5f5;margin-bottom:20px;padding:19px;min-height:20px;border:1px solid #eee;border:1px solid rgba(0, 0, 0, 0.05);-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0, 0, 0, 0.05);-moz-box-shadow:inset 0 1px 1px rgba(0, 0, 0, 0.05);box-shadow:inset 0 1px 1px rgba(0, 0, 0, 0.05);} .well{background-color:#f5f5f5;margin-bottom:20px;padding:19px;min-height:20px;border:1px solid #eee;border:1px solid rgba(0, 0, 0, 0.05);-webkit-border-radius:4px;-moz-border-radius:4px;border-radius:4px;-webkit-box-shadow:inset 0 1px 1px rgba(0, 0, 0, 0.05);-moz-box-shadow:inset 0 1px 1px rgba(0, 0, 0, 0.05);box-shadow:inset 0 1px 1px rgba(0, 0, 0, 0.05);}
.modal-backdrop{background-color:rgba(0, 0, 0, 0.5);filter:progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr='#aa000000',endColorstr='#aa000000');position:fixed;top:0;left:0;right:0;bottom:0;z-index:1000;} .modal-backdrop{background-color:#000;position:fixed;top:0;left:0;right:0;bottom:0;z-index:1000;}.modal-backdrop.fade.in{opacity:.5;}
.modal{position:fixed;top:50%;left:50%;z-index:2000;width:560px;margin:-280px 0 0 -250px;background-color:#ffffff;border:1px solid #999;border:1px solid rgba(0, 0, 0, 0.3);*border:1px solid #999;-webkit-border-radius:6px;-moz-border-radius:6px;border-radius:6px;-webkit-box-shadow:0 3px 7px rgba(0, 0, 0, 0.3);-moz-box-shadow:0 3px 7px rgba(0, 0, 0, 0.3);box-shadow:0 3px 7px rgba(0, 0, 0, 0.3);-webkit-background-clip:padding-box;-moz-background-clip:padding-box;background-clip:padding-box;}.modal .modal-header{border-bottom:1px solid #eee;padding:5px 20px;}.modal .modal-header .close{position:absolute;right:10px;top:10px;color:#999;line-height:10px;font-size:18px;} .modal{position:fixed;top:50%;left:50%;z-index:2000;width:560px;margin:-280px 0 0 -250px;background-color:#ffffff;border:1px solid #999;border:1px solid rgba(0, 0, 0, 0.3);*border:1px solid #999;-webkit-border-radius:6px;-moz-border-radius:6px;border-radius:6px;-webkit-box-shadow:0 3px 7px rgba(0, 0, 0, 0.3);-moz-box-shadow:0 3px 7px rgba(0, 0, 0, 0.3);box-shadow:0 3px 7px rgba(0, 0, 0, 0.3);-webkit-background-clip:padding-box;-moz-background-clip:padding-box;background-clip:padding-box;}.modal .modal-header{border-bottom:1px solid #eee;padding:5px 20px;}.modal .modal-header .close{position:absolute;right:10px;top:10px;color:#999;line-height:10px;font-size:18px;}
.modal .modal-body{padding:20px;} .modal .modal-body{padding:20px;}
.modal .modal-footer{background-color:#f5f5f5;padding:14px 20px 15px;border-top:1px solid #ddd;-webkit-border-radius:0 0 6px 6px;-moz-border-radius:0 0 6px 6px;border-radius:0 0 6px 6px;-webkit-box-shadow:inset 0 1px 0 #ffffff;-moz-box-shadow:inset 0 1px 0 #ffffff;box-shadow:inset 0 1px 0 #ffffff;zoom:1;margin-bottom:18px;margin-bottom:0;}.modal .modal-footer:before,.modal .modal-footer:after{display:table;content:"";} .modal .modal-footer{background-color:#f5f5f5;padding:14px 20px 15px;border-top:1px solid #ddd;-webkit-border-radius:0 0 6px 6px;-moz-border-radius:0 0 6px 6px;border-radius:0 0 6px 6px;-webkit-box-shadow:inset 0 1px 0 #ffffff;-moz-box-shadow:inset 0 1px 0 #ffffff;box-shadow:inset 0 1px 0 #ffffff;zoom:1;margin-bottom:18px;margin-bottom:0;}.modal .modal-footer:before,.modal .modal-footer:after{display:table;content:"";}

View File

@ -107,13 +107,10 @@
, animate = this.$element.hasClass('fade') ? 'fade' : '' , animate = this.$element.hasClass('fade') ? 'fade' : ''
if ( this.isOpen && this.settings.backdrop ) { if ( this.isOpen && this.settings.backdrop ) {
this.$backdrop = $('<div class="modal-backdrop ' + animate + '" />') this.$backdrop = $('<div class="modal-backdrop ' + animate + '" />')
.click(function () { that.close() })
.appendTo(document.body) .appendTo(document.body)
$('body').delegate('.modal-backdrop', 'click.modal.backdrop', function () {
that.close()
})
} else if ( !this.isOpen && this.$backdrop ) { } else if ( !this.isOpen && this.$backdrop ) {
this.$backdrop.removeClass('in') this.$backdrop.removeClass('in')
$('body').undelegate('click.modal.backdrop')
function removeElement() { function removeElement() {
that.$backdrop.remove() that.$backdrop.remove()

View File

@ -578,8 +578,12 @@ input[type=submit].btn {
// ------ // ------
.modal-backdrop { .modal-backdrop {
background-color: rgba(0,0,0,.5); /* background-color: rgba(0,0,0,.5);
filter: e(%("progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=%d,endColorstr=%d)", '#aa000000', '#aa000000')); filter: e(%("progid:DXImageTransform.Microsoft.gradient(GradientType=0,startColorstr=%d,endColorstr=%d)", '#aa000000', '#aa000000'));*/
background-color:#000;
&.fade.in {
opacity: .5;
}
position: fixed; position: fixed;
top: 0; top: 0;
left: 0; left: 0;