NicoNoReorganize

NicoNoReorganize is a Jquery plugin that reorganize elements in a grid template

Live Demo

How to use

head :

<!-- Use Jquery version 1.8 + -->
<script src="js/jquery-1.8.3.min.js"></script>
<!-- Call nicoNoReorganize plugin file -->
<script src="js/nicoNoReorganize.js"></script>

HTML :

<div id="reorganize"> <!-- Use an unique ID -->
   <img src="img/01.jpg" />
   <img src="img/02.jpg" />
   <img src="img/03.jpg" />
   <img src="img/04.jpg" />
   <img src="img/05.jpg" />
</div>

Javascript :

<script type="text/javascript">
   $(window).load(function(){ // the call must be made inside the $(window).load() event
      $("#reorganize").nicoNoReorganize();
   });
</script>

// Which is equivalent to :

<script type="text/javascript">
   $(window).load(function(){
       $("#reorganize").nicoNoReorganize({
         delay:200,
         speed:400,
         center:true,
         shuffle:true
      });
   });
</script>

Options

Option name Type Default Exemple Description
delay int 200 100 Delay beetween mooving each element
speed int 400 400 Speed of mooving elements
center bool false true Auto center elements on launch and resize event
shuffle bool false true Shuffle elements on launch and resize event

Copyrights ©NicoNoClaste 2013 2024