Skip to content

Commit

Permalink
Change version, update build.
Browse files Browse the repository at this point in the history
  • Loading branch information
vodkabears committed Feb 23, 2014
1 parent 2c0c30e commit 839bb29
Show file tree
Hide file tree
Showing 7 changed files with 53 additions and 51 deletions.
4 changes: 2 additions & 2 deletions bower.json
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
{
"name": "remodal",
"version": "0.1.0",
"version": "0.1.1",
"homepage": "http://vodkabears.github.io/remodal/",
"authors": [
"Zeno Rocha <hi@zenorocha.com>"
"Ilya Makarov <dfrost.00@gmail.com>"
],
"description": "Flat, responsive, lightweight, easy customizable modal window plugin with declarative state notation and hash tracking.",
"main": [ "dist/jquery.remodal.js", "dist/jquery.remodal.min.js", "dist/jquery.remodal.css"],
Expand Down
13 changes: 7 additions & 6 deletions dist/jquery.remodal.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
/*! Remodal - v0.1.0 - 2014-02-15
/*! Remodal - v0.1.1 - 2014-02-23
* https://github.com/VodkaBears/remodal
* Copyright (c) 2014 VodkaBears; */

/* Fonts */
@import url(http://fonts.googleapis.com/css?family=Exo+2:700,400&subset=latin,cyrillic);

Expand All @@ -20,11 +21,11 @@ html.remodal_lock, body.remodal_lock {
}

body.remodal_active .remodal-bg {
-webkit-filter: blur(5px);
-moz-filter: blur(5px);
-o-filter: blur(5px);
-ms-filter: blur(5px);
filter: blur(5px);
-webkit-filter: blur(3px);
-moz-filter: blur(3px);
-o-filter: blur(3px);
-ms-filter: blur(3px);
filter: blur(3px);
}

/* Background for effects(end) */
Expand Down
76 changes: 38 additions & 38 deletions dist/jquery.remodal.js
Original file line number Diff line number Diff line change
@@ -1,8 +1,7 @@
/*! Remodal - v0.1.0 - 2014-02-15
/*! Remodal - v0.1.1 - 2014-02-23
* https://github.com/VodkaBears/remodal
* Copyright (c) 2014 VodkaBears; */
;
(function ($) {
;(function ($) {
"use strict";

/**
Expand All @@ -29,17 +28,17 @@
* @return {Number}
*/
var getTransitionDuration = function ($elem) {
var duration = $elem.css('transitionDuration') ||
$elem.css('webkitTransitionDuration') ||
$elem.css('mozTransitionDuration') ||
$elem.css('oTransitionDuration') ||
$elem.css('msTransitionDuration') ||
var duration = $elem.css('transition-duration') ||
$elem.css('-webkit-transition-duration') ||
$elem.css('-moz-transition-duration') ||
$elem.css('-o-transition-duration') ||
$elem.css('-ms-transition-duration') ||
0;
var delay = $elem.css('transitionDelay') ||
$elem.css('webkitTransitionDelay') ||
$elem.css('mozTransitionDelay') ||
$elem.css('oTransitionDelay') ||
$elem.css('msTransitionDelay') ||
var delay = $elem.css('transition-delay') ||
$elem.css('-webkit-transition-delay') ||
$elem.css('-moz-transition-delay') ||
$elem.css('-o-transition-delay') ||
$elem.css('-ms-transition-delay') ||
0;

return (parseFloat(duration) + parseFloat(delay)) * 1000;
Expand Down Expand Up @@ -68,6 +67,22 @@
return widthNoScroll - widthWithScroll;
};

/**
* Lock screen
*/
var lockScreen = function () {
$("html, body").addClass(pluginName + "_lock");
$(document.body).css("padding-right", "+=" + getScrollbarWidth());
};

/**
* Unlock screen
*/
var unlockScreen = function () {
$("html, body").removeClass(pluginName + "_lock");
$(document.body).css("padding-right", "-=" + getScrollbarWidth());
};

/**
* Remodal constructor
*/
Expand Down Expand Up @@ -144,22 +159,6 @@
}.bind(this));
};

/**
* Lock screen
*/
Remodal.prototype.lockScreen = function () {
$("html, body").addClass(pluginName + "_lock");
this.body.css("padding-right", "+=" + getScrollbarWidth());
};

/**
* Unlock screen
*/
Remodal.prototype.unlockScreen = function () {
$("html, body").removeClass(pluginName + "_lock");
this.body.css("padding-right", "-=" + getScrollbarWidth());
};

/**
* Open modal window
*/
Expand All @@ -183,7 +182,7 @@
}
current = this;

this.lockScreen();
lockScreen();
this.overlay.show();
setTimeout(function () {
this.body.addClass(pluginName + "_active");
Expand Down Expand Up @@ -214,10 +213,11 @@
}

this.body.removeClass(pluginName + "_active");
console.log(this.td);

setTimeout(function () {
this.overlay.hide();
this.unlockScreen();
unlockScreen();

this.busy = false;
this.modal.trigger("closed");
Expand All @@ -228,9 +228,9 @@
$["fn"][pluginName] = function (opts) {
return this["each"](function (i, e) {
var $e = $(e);
if (!$e.data(pluginName) || !$e.data(pluginName).open) {
if (!$e.data(pluginName)) {
var instance = new Remodal($e, opts);
$e.data(pluginName, instance);
$e.data(pluginName, instance.index);
}
});
};
Expand All @@ -246,7 +246,7 @@
id = elem.getAttribute("data-" + pluginName + "-target"),
$target = $("[data-" + pluginName + "-id=" + id + "]");

$target.data(pluginName).open();
instances[$target.data(pluginName)].open();
});

/**
Expand Down Expand Up @@ -287,14 +287,14 @@
var $elem = $("[data-" + pluginName + "-id=" + id + "]");

if ($elem.length) {
var data = $elem.data(pluginName);
if (data && data.settings.hashTracking) {
data.open();
var instance = instances[$elem.data(pluginName)];
if (instance && instance.settings.hashTracking) {
instance.open();
}
}

}
};
$(window).bind("hashchange." + pluginName, hashHandler);
hashHandler(null, false);
})(window["jQuery"]);
})(window["jQuery"] || window["Zepto"]);
4 changes: 2 additions & 2 deletions dist/jquery.remodal.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion remodal.jquery.json
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@
"lightbox",
"ui"
],
"version": "0.1.0",
"version": "0.1.1",
"author": {
"name": "Ilya Makarov",
"email": "[email protected]",
Expand Down
3 changes: 2 additions & 1 deletion src/jquery.remodal.css
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
/*! Remodal - v0.1.0 - 2014-02-15
/*! Remodal - v0.1.1 - 2014-02-23
* https://github.com/VodkaBears/remodal
* Copyright (c) 2014 VodkaBears; */

/* Fonts */
@import url(http://fonts.googleapis.com/css?family=Exo+2:700,400&subset=latin,cyrillic);

Expand Down
2 changes: 1 addition & 1 deletion src/jquery.remodal.js
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
/*! Remodal - v0.1.0 - 2014-02-15
/*! Remodal - v0.1.1 - 2014-02-23
* https://github.com/VodkaBears/remodal
* Copyright (c) 2014 VodkaBears; */
;(function ($) {
Expand Down

0 comments on commit 839bb29

Please sign in to comment.