Skip to content

Instantly share code, notes, and snippets.

Created November 15, 2016 20:06
Show Gist options
  • Save anonymous/12dfb51d29d08383e149b5057a52fcc6 to your computer and use it in GitHub Desktop.
Save anonymous/12dfb51d29d08383e149b5057a52fcc6 to your computer and use it in GitHub Desktop.
function chatbubble() {
var str = "OMG I just did a thing! and now holy shit is this even longer thing!";
var x = str.length;
x = x * 50;
$('#cbinntertext').html(str);
$('#cb').show();
$('#cb').addClass('animated bounceIn').one(animationEnd, function() {
setTimeout(function() {
$('#cb').removeClass('bounceIn');
$('#cb').addClass('bounceOut').one(animationEnd, function() {
$('#cb').hide();
$('#cb').removeClass('animated bounceOut');
});
}, 1000);
});
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment