mirror of
https://github.com/nunocoracao/blowfish.git
synced 2026-01-30 15:31:52 +00:00
config redirect
This commit is contained in:
+44
@@ -0,0 +1,44 @@
|
||||
<!doctype html>
|
||||
<html>
|
||||
<head>
|
||||
<meta charset="utf-8">
|
||||
|
||||
<title>Browserify</title>
|
||||
|
||||
<link rel="stylesheet" href="../css/examples.css" />
|
||||
|
||||
</head>
|
||||
<body>
|
||||
|
||||
<h1>Browserify</h1>
|
||||
|
||||
<div id="basic" class="container">
|
||||
<div class="item w4"></div>
|
||||
<div class="item h4"></div>
|
||||
<div class="item w2"></div>
|
||||
<div class="item h4"></div>
|
||||
<div class="item"></div>
|
||||
<div class="item"></div>
|
||||
<div class="item h2"></div>
|
||||
<div class="item w4"></div>
|
||||
<div class="item w2"></div>
|
||||
<div class="item"></div>
|
||||
<div class="item"></div>
|
||||
<div class="item w2 h2"></div>
|
||||
<div class="item"></div>
|
||||
<div class="item"></div>
|
||||
<div class="item h4"></div>
|
||||
<div class="item"></div>
|
||||
<div class="item w4"></div>
|
||||
<div class="item"></div>
|
||||
<div class="item w2"></div>
|
||||
<div class="item"></div>
|
||||
<div class="item h2"></div>
|
||||
<div class="item"></div>
|
||||
<div class="item h2"></div>
|
||||
</div>
|
||||
|
||||
<script src="bundle.js"></script>
|
||||
|
||||
</body>
|
||||
</html>
|
||||
+14790
File diff suppressed because it is too large
Load Diff
+24
@@ -0,0 +1,24 @@
|
||||
// ----- jQuery ----- //
|
||||
|
||||
var Packery = require('../../js/packery');
|
||||
var Draggabilly = require('draggabilly');
|
||||
var $ = require('jquery');
|
||||
var jQBridget = require('jquery-bridget');
|
||||
|
||||
$.bridget( 'packery', Packery );
|
||||
|
||||
var $container = $('#basic').packery({
|
||||
columnWidth: 50,
|
||||
rowHeight: 50
|
||||
});
|
||||
|
||||
var pckry = $container.data('packery');
|
||||
|
||||
$.each( pckry.items, function( i, item ) {
|
||||
var draggie = new Draggabilly( item.element );
|
||||
$container.packery( 'bindDraggabillyEvents', draggie );
|
||||
});
|
||||
|
||||
$container.packery( 'on', 'dragItemPositioned', function( pckry, item ) {
|
||||
console.log( 'drag item positioned', item.position.x, item.position.y );
|
||||
});
|
||||
+23
@@ -0,0 +1,23 @@
|
||||
// ----- vanilla JS ----- //
|
||||
|
||||
var Packery = require('../../js/packery');
|
||||
var Draggabilly = require('draggabilly');
|
||||
|
||||
var pckry = new Packery( '#basic', {
|
||||
columnWidth: 50,
|
||||
rowHeight: 50
|
||||
});
|
||||
|
||||
var draggies = [];
|
||||
var item, draggie;
|
||||
|
||||
for ( var i=0, len = pckry.items.length; i < len; i++ ) {
|
||||
item = pckry.items[i].element;
|
||||
draggie = new Draggabilly( item );
|
||||
pckry.bindDraggabillyEvents( draggie );
|
||||
draggies.push( draggie );
|
||||
}
|
||||
|
||||
pckry.on( 'dragItemPositioned', function( pckry, item ) {
|
||||
console.log( 'drag item positioned', item.position.x, item.position.y );
|
||||
});
|
||||
Reference in New Issue
Block a user