Further JS fixes

This commit is contained in:
Joseph Schorr 2014-05-09 17:23:35 -04:00
parent 278c28f350
commit e2992d08bb
2 changed files with 6 additions and 1 deletions

View file

@ -4,11 +4,16 @@ $.fn.clipboardCopy = function() {
clip.on('complete', function() {
// Resets the animation.
var elem = $('#clipboardCopied')[0];
if (!elem) {
return;
}
elem.style.display = 'none';
elem.classList.remove('animated');
// Show the notification.
setTimeout(function() {
if (!elem) { return; }
elem.style.display = 'inline-block';
elem.classList.add('animated');
}, 10);