Created
July 5, 2014 23:04
-
-
Save kpeatt/5b18ff9427aa4ab94bde to your computer and use it in GitHub Desktop.
velocity blurbs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
<!DOCTYPE html> | |
<html xmlns="http://www.w3.org/1999/xhtml" lang="en" data-placeholder-focus="false"> | |
<head> | |
<meta http-equiv="Content-Language" content="en" charset="utf-8"/> | |
<title>Canadian MLS® Listings, Condos & Homes for Sale — Zolo.ca</title> | |
<meta name="viewport" content="width=device-width, initial-scale=1.0, user-scalable=no"/> | |
<meta name="HandheldFriendly" content="True"/> | |
<meta name="MobileOptimized" content="320"/> | |
<meta name="robots" content="NOODP, NOYDIR"> | |
<meta name="apple-mobile-web-app-title" content="Zolo Realty"> | |
<meta name="apple-mobile-web-app-capable" content="yes"> | |
<!-- Styles --> | |
<link href='http://fonts.googleapis.com/css?family=Open+Sans:400italic,400,700' rel='stylesheet' type='text/css'/> | |
<link href="css/loading.css" rel="stylesheet" type='text/css'/> | |
<!-- HTML5 shim, for IE6-8 support of HTML5 elements --> | |
<!--[if IE]> | |
<script type="text/javascript" src="http://html5shim.googlecode.com/svn/trunk/html5.js"></script> | |
<![endif]--> | |
</head> | |
<body class="home"> | |
<div class="ols-loader"> | |
<p></p> | |
</div> | |
<div class="ols-error"> | |
Zolo Realty requires an internet connection to work. | |
</div> | |
<script type="text/javascript" src="cordova.js"></script> | |
<script type="text/javascript" src="js/lib/lodash.js"></script> | |
<script type="text/javascript" src="bower_components/jquery/dist/jquery.js"></script> | |
<script type="text/javascript" src="bower_components/velocity/jquery.velocity.js"></script> | |
<script type="text/javascript" src="bower_components/velocity/velocity.ui.js"></script> | |
<script type="text/javascript" src="js/index.js"></script> | |
<script type="text/javascript"> | |
var blurbs = [ | |
'Grabbing the latest homes from the MLS®…', | |
'Still grabbing the newest listings…', | |
'This is taking a while, there must be a lot…', | |
'Are we there yet?', | |
'Maybe we should just build a home for you?', | |
'The homes might be stuck in the Internet tubes. Still waiting…' | |
]; | |
$(function() { | |
var $p = $('.ols-loader p'); | |
var currentIndex = 0; | |
var change = function() { | |
// Update index in to our array | |
currentIndex++; | |
// Make sure we don't overflow | |
if (currentIndex >= blurbs.length) { | |
currentIndex = 0; | |
} | |
var currentText = blurbs[currentIndex]; | |
$p | |
.velocity( | |
'transition.slideUpIn', | |
{ | |
begin: function() { | |
$p.html(currentText); | |
} | |
} | |
) | |
.delay(1000) | |
.velocity( | |
'transition.slideUpOut' | |
); | |
console.log($p); | |
} | |
setTimeout(change, 500); | |
}); | |
ZoloApp.initialize(); | |
</script> | |
</body> | |
</html> |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment