Browse Source

Merge branch 'master' into 2.0.0-wip

pull/214/head
connors 11 years ago
parent
commit
d1203bf6ea
  1. 11
      dist/ratchet.js
  2. 9
      lib/js/popovers.js

11
dist/ratchet.js vendored

@ -50,7 +50,7 @@
};
var onPopoverHidden = function () {
document.body.removeChild(backdrop);
popover.parentNode.removeChild(backdrop);
popover.style.display = 'none';
popover.removeEventListener('webkitTransitionEnd', onPopoverHidden);
}
@ -80,7 +80,7 @@
return popover;
}
window.addEventListener('touchend', function (e) {
var showHidePopover = function (e) {
var popover = getPopover(e);
if (!popover) return;
@ -90,9 +90,10 @@
popover.classList.add('visible');
popover.parentNode.appendChild(backdrop);
});
};
window.addEventListener('click', function (e) { if (getPopover(e)) e.preventDefault(); });
window.addEventListener('touchend', showHidePopover);
window.addEventListener('click', showHidePopover);
}();
@ -769,4 +770,4 @@
toggle = false;
});
}();
}();

9
lib/js/popovers.js

@ -16,7 +16,7 @@
};
var onPopoverHidden = function () {
document.body.removeChild(backdrop);
popover.parentNode.removeChild(backdrop);
popover.style.display = 'none';
popover.removeEventListener('webkitTransitionEnd', onPopoverHidden);
}
@ -46,7 +46,7 @@
return popover;
}
window.addEventListener('touchend', function (e) {
var showHidePopover = function (e) {
var popover = getPopover(e);
if (!popover) return;
@ -56,8 +56,9 @@
popover.classList.add('visible');
popover.parentNode.appendChild(backdrop);
});
};
window.addEventListener('click', function (e) { if (getPopover(e)) e.preventDefault(); });
window.addEventListener('touchend', showHidePopover);
window.addEventListener('click', showHidePopover);
}();

Loading…
Cancel
Save