Filter & sort magical layouts http://isotope.metafizzy.co
You can not select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
 
 
 

77 lines
1.9 KiB

<!doctype html>
<html>
<head>
<meta charset="utf-8">
<title>transition bug</title>
<link rel="stylesheet" href="sandbox.css" />
<style>
#container { width: 100%; }
</style>
</head>
<body>
<h1>transition bug</h1>
<div>
<button id="bug-me">Bug me</button>
</div>
<div id="container">
<!-- <div class="element post-transition metal " data-symbol="Tl" data-category="post-transition">
<p class="number">81</p>
<h3 class="symbol">H</h3>
<h2 class="name">Thallium</h2>
<p class="weight">58.3833</p>
</div> -->
<div class="element metalloid " data-symbol="Sb" data-category="metalloid">
<p class="number">51</p>
<h3 class="symbol">Sb</h3>
<h2 class="name">Antimony</h2>
<p class="weight">121.76</p>
</div>
</div>
<script src="../bower_components/ev-emitter/ev-emitter.js"></script>
<script src="../bower_components/get-size/get-size.js"></script>
<script src="../bower_components/jquery-bridget/jquery-bridget.js"></script>
<script src="../bower_components/desandro-matches-selector/matches-selector.js"></script>
<script src="../bower_components/fizzy-ui-utils/utils.js"></script>
<script src="../bower_components/outlayer/item.js"></script>
<script src="../bower_components/outlayer/outlayer.js"></script>
<script src="../js/item.js"></script>
<script src="../js/layout-mode.js"></script>
<script src="../js/isotope.js"></script>
<script src="../js/layout-modes/fit-rows.js"></script>
<script src="../js/layout-modes/vertical.js"></script>
<script>
var container = document.querySelector('#container');
var iso = window.iso = new Isotope( container, {
layoutMode: 'fitRows',
transitionDuration: '2s'
});
var item = iso.items[0];
var bugButton = document.querySelector('#bug-me');
bugButton.addEventListener( 'click', function() {
item.reveal();
item.moveTo( 200, 100 );
setTimeout( function() {
item.moveTo( 100, 50 );
}, 1500 );
});
</script>
</body>
</html>