We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
To get leanModal working as a zepto plugin, a few small changes are needed:
// Zepto doesn't have $.fn.extend() //$.fn.extend({ $.fn.leanModal = function(options) {
and
// Zepto doesn't have .outerWidth(), and modal_height not used! //var modal_height = $(modal_id).outerHeight(); //var modal_width = $(modal_id).outerWidth(); var el = $(modal_id); el.css({'display': 'block', 'opacity': 0}); var modal_width = (typeof el.outerWidth != 'function') ? el.width() : el.outerWidth();
.width() returns 0 if the modal is display:none, so 'display' it first, but transparent.
})(window.jQuery || window.Zepto);
You will need the core zepto.js library, as well as the zepto.fx.js and zepto.fx_methods.js plugins, for the fadeIn/Out animation to work.
The text was updated successfully, but these errors were encountered:
No branches or pull requests
To get leanModal working as a zepto plugin, a few small changes are needed:
and
.width() returns 0 if the modal is display:none, so 'display' it first, but transparent.
You will need the core zepto.js library, as well as the zepto.fx.js and zepto.fx_methods.js plugins, for the fadeIn/Out animation to work.
The text was updated successfully, but these errors were encountered: