Skip to content

Commit

Permalink
Upload v1.5.0
Browse files Browse the repository at this point in the history
  • Loading branch information
marcelodolza committed Jun 5, 2017
1 parent a29b14f commit 55c1893
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 6 deletions.
11 changes: 6 additions & 5 deletions js/iziModal.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@
* http://izimodal.marcelodolce.com
* by Marcelo Dolce.
*/

(function (factory) {
if (typeof define === 'function' && define.amd) {
// AMD. Register as an anonymous module.
Expand Down Expand Up @@ -962,15 +961,17 @@

recalcWidth: function(){

var that = this;

this.$element.css('max-width', this.options.width);

if(isIE()){
var modalWidth = this.options.width;
var modalWidth = that.options.width;

if( this.options.width.indexOf("%") !== -1 ){
modalWidth = this.$element.outerWidth();
if(modalWidth.toString().split("%").length > 1){
modalWidth = that.$element.outerWidth();
}
this.$element.css({
that.$element.css({
left: '50%',
marginLeft: -(modalWidth/2)
});
Expand Down
Loading

0 comments on commit 55c1893

Please sign in to comment.