Browse Source

#6520 - remove blurring on dimmer hide. Remove console logs.

gulp4
Jack 6 years ago
parent
commit
8a1ad49be1
2 changed files with 15 additions and 5 deletions
  1. 3
      RELEASE-NOTES.md
  2. 17
      src/definitions/modules/modal.js

3
RELEASE-NOTES.md

@ -13,11 +13,12 @@
For example when `attachable: false` is used with a modal, or if IE11/Edge is used (Absolutely positioned elements inside flex containers in IE behave differently)
**Critical Bugs**
- **Modal** - Fixed issue where `scrolling modal` would not allow for scrolling with touch devices (including mobile). #6449
- **Modal** - Fixed issue where `scrolling modal` would not allow for scrolling with touch devices. #6449
**Bugs**
- **Dropdown** - Fixed issue where `onChange` when used with `action: hide` would be missing the third param `$item` #6555
- **Dimmer** - Dimmer now sets `variation` at runtime, to support run-time swapping between `top aligned` and `middle aligned` using `.dimmer('setting', 'variation', 'top aligned')`
- **Modal** - Modal now will remove `blurring` after undimming, to prevent issues with position: fixed #6520
- **Menu/Dropdown** - Fixes dropdown item margin not obeyed inside `labeled icon menu` #6557
- **Modal** - Fixes `@mobileTopAlignedMargin` theming variable was not implemented
- **List** - Fixed issue where `content` would not take up 100% width when used alongside `img` or `icon`

17
src/definitions/modules/modal.js

@ -319,6 +319,8 @@ $.fn.modal = function(parameters) {
;
module.refreshModals();
module.set.dimmerSettings();
module.set.dimmerStyles();
module.showModal(callback);
},
@ -327,7 +329,6 @@ $.fn.modal = function(parameters) {
? callback
: function(){}
;
module.unbind.scrollLock();
module.refreshModals();
module.hideModal(callback);
},
@ -425,6 +426,7 @@ $.fn.modal = function(parameters) {
},
onComplete : function() {
settings.onHidden.call(element);
module.remove.dimmerStyles();
module.restore.focus();
callback();
}
@ -449,6 +451,7 @@ $.fn.modal = function(parameters) {
hideDimmer: function() {
if( $dimmable.dimmer('is animating') || ($dimmable.dimmer('is active')) ) {
module.unbind.scrollLock();
$dimmable.dimmer('hide', function() {
module.remove.clickaway();
module.remove.screenHeight();
@ -544,6 +547,10 @@ $.fn.modal = function(parameters) {
.off('click' + elementEventNamespace)
;
},
dimmerStyles: function() {
$dimmer.removeClass(className.inverted);
$dimmable.removeClass(className.blurring);
},
bodyStyle: function() {
if($body.attr('style') === '') {
module.verbose('Removing style attribute');
@ -685,6 +692,11 @@ $.fn.modal = function(parameters) {
? dimmerSettings.variation + ' inverted'
: 'inverted'
;
}
$context.dimmer('setting', dimmerSettings);
},
dimmerStyles: function() {
if(settings.inverted) {
$dimmer.addClass(className.inverted);
}
else {
@ -696,14 +708,12 @@ $.fn.modal = function(parameters) {
else {
$dimmable.removeClass(className.blurring);
}
$context.dimmer('setting', dimmerSettings);
},
modalOffset: function() {
var
width = module.cache.width,
height = module.cache.height
;
console.log(module.can.fit());
$module
.css({
marginTop: (settings.centered && module.can.fit())
@ -737,7 +747,6 @@ $.fn.modal = function(parameters) {
$module.addClass(className.legacy);
},
type: function() {
console.log('setting');
if(module.can.fit()) {
module.verbose('Modal fits on screen');
if(!module.others.active() && !module.others.animating()) {

Loading…
Cancel
Save