Skip to content

Commit

Permalink
#2576 Modal will remove body style after hiding
Browse files Browse the repository at this point in the history
  • Loading branch information
jlukic committed Jul 10, 2015
1 parent bb5222d commit 6fbabf4
Showing 1 changed file with 12 additions and 10 deletions.
22 changes: 12 additions & 10 deletions src/definitions/modules/modal.js
Original file line number Diff line number Diff line change
Expand Up @@ -408,10 +408,8 @@ $.fn.modal = function(parameters) {
hideDimmer: function() {
if( $dimmable.dimmer('is animating') || ($dimmable.dimmer('is active')) ) {
$dimmable.dimmer('hide', function() {
if(settings.transition && $.fn.transition !== undefined && $module.transition('is supported')) {
module.remove.clickaway();
module.remove.screenHeight();
}
module.remove.clickaway();
module.remove.screenHeight();
});
}
else {
Expand Down Expand Up @@ -497,14 +495,18 @@ $.fn.modal = function(parameters) {
;
}
},
screenHeight: function() {
if(module.cache.height > module.cache.pageHeight) {
module.debug('Removing page height');
$body
.css('height', '')
;
bodyStyle: function() {
if($body.attr('style') === '') {
module.verbose('Removing style attribute');
$body.removeAttr('style');
}
},
screenHeight: function() {
module.debug('Removing page height');
$body
.css('height', '')
;
},
keyboardShortcuts: function() {
module.verbose('Removing keyboard shortcuts');
$document
Expand Down

0 comments on commit 6fbabf4

Please sign in to comment.