Skip to content

Instantly share code, notes, and snippets.

@tkuichooseyou
Created November 7, 2013 01:37
Show Gist options
  • Save tkuichooseyou/7347471 to your computer and use it in GitHub Desktop.
Save tkuichooseyou/7347471 to your computer and use it in GitHub Desktop.
fontbomb test with leap js
<!DOCTYPE html>
<html>
<head>
<title>Leap Cursor Library - Basic Usage</title>
<link rel="stylesheet" type="text/css" href="../build/css/leap-manager.css">
<style type="text/css">
.button {
color:white;
display:inline-block;
padding:30px;
background-color: lightpink;
transition-duration: 1s;
}
.button.hover {
background-color: orangered;
}
.button.leap-down {
background-color: slateblue;
}
</style>
<script type="text/javascript" src="../build/js/leap-manager.min.js"></script>
<script type="text/javascript" src="../lib/js/leap.min.js"></script>
</head>
<body>
<div class="button leap-interactive">Click Me</div>
<div class="button leap-interactive">Click Me</div>
<div class="button leap-interactive">Click Me</div>
<div class="button leap-interactive">Click Me</div>
<div class="button leap-interactive">Click Me</div>
<div>
<p>
Lorem Ipsum is simply dummy text of the printing and typesetting industry. Lorem Ipsum has been the industry's standard dummy text ever since the 1500s, when an unknown printer took a galley of type and scrambled it to make a type specimen book. It has survived not only five centuries, but also the leap into electronic typesetting, remaining essentially unchanged. It was popularised in the 1960s with the release of Letraset sheets containing Lorem Ipsum passages, and more recently with desktop publishing software like Aldus PageMaker including versions of Lorem Ipsum.
It is a long established fact that a reader will be distracted by the readable content of a page when looking at its layout. The point of using Lorem Ipsum is that it has a more-or-less normal distribution of letters, as opposed to using 'Content here, content here', making it look like readable English. Many desktop publishing packages and web page editors now use Lorem Ipsum as their default model text, and a search for 'lorem ipsum' will uncover many web sites still in their infancy. Various versions have evolved over the years, sometimes by accident, sometimes on purpose (injected humour and the like).
</p>
</div>
<div class="output"></div>
<script type="text/javascript">
var buttons = document.querySelectorAll("div.button");
var output = document.querySelector("div.output");
var count = 0;
for (var i = 0; i < buttons.length; i++) {
buttons[i].addEventListener("click", function(e){
output.innerHTML += count + ": Button Clicked</br>";
count++;
});
};
LeapManager.init({
maxCursors:5,
enableHoverTap: false,
enablePressDown: true
});
</script>
<script src="../lib/fontbombtest.js"></script>
</body>
</html>
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment