Grid Navigation Effects with jQuery

Today we want to share some neat grid navigation effects using jQuery. In our examples we will show you ten ways how to navigate through a set of thumbnails. We’ll take a look at some of the possibilities and how to apply the effect.

Today we want to share some neat grid navigation effects using jQuery. In our examples we will show you ten ways how to navigate through a set of thumbnails. We’ll take a look at some of the possibilities and how to apply the effect.

The images used in the demos are by Andrew and Lili and you can see their Behance profile here:
http://www.behance.net/AndrewLili
The images are licensed under the Creative Commons Attribution-NonCommercial 3.0 Unported License.

Take a look at all the examples (you can also navigate from them to all the other examples):

You can use the mousewheel to navigate through the thumbnails.

The HTML structure that the script is based on is basically a list of element and some navigation arrows wrapped by a container with class and id “tj_container”.

Let’s see an example for using the sequential move/fade:

$('#tj_container').gridnav({
	rows	: 2,
	navL	: '#tj_prev',
	navR	: '#tj_next',
	type	: {
		mode		: 'sequpdown', 	
		speed		: 400,			
		easing		: '',			
		factor		: 50,			
		reverse		: false			
	}
});

The following parameters can be used/set:
rows: the number of rows to be shown in the grid
navL/navR: the selectors for the previous and next navigation elements
mode: the type of animation; you can use def | fade | seqfade | updown | sequpdown | showhide | disperse | rows
speed: the speed of the animation for fade, seqfade, updown, sequpdown, showhide, disperse, rows
easing: the easing effect for fade, seqfade, updown, sequpdown, showhide, disperse, rows
factor: delay between each item animation for seqfade, sequpdown; amount of pixels the row move when using rows
reverse: for reversing the order when using sequpdown

We hope you like these little effects and find them useful!

Tagged with:

Manoela Ilic

Manoela is the main tinkerer at Codrops. With a background in coding and passion for all things design, she creates web experiments and keeps frontend professionals informed about the latest trends.

Stay up to date with the latest web design and development news and relevant updates from Codrops.

Feedback 74

Comments are closed.
  1. Clicking on the different example options doesn’t seem to load properly until I refresh the whole page. (using Chrome)

  2. Nice tut! But is there a way to improve javascript performance with Firefox?

    Because the animations are a bit choppy.. In chrome looks awesome πŸ™‚

  3. Wonderful thanks
    Is it possible to put a little pagination ? in addition of the arrows, show the page numbers… Cheers

  4. excellent tut, maybe not production ready but definitely a great idea to work with! thx4sharing

  5. Dear Mary Lou,

    Thanks for publishing this great script!

    If anyone is searching for how to put multiple grid navigations on one page:

    Based on example 6:
    You can replace “1” with as many numbers as you require grids…

    In the java:
    —————–
    $(‘#tj_container1’).gridnav({
    navL : ‘#tj_prev1’,
    navR : ‘#tj_next1’,
    type : {…

    In the html:
    —————–

    Previous
    Next

    Again thanks for this beautiful script, great work!

    Greetings,
    Manuel

  6. About chrome problem, I think some file we doesn’t have sufficient permission to perform on your host.

    You can try $ chmod a+x /host/path/demo/*

    Please check file permission.

  7. Oops the html got replaced…
    Second try:

    In the html:
    —————–
    In the html:
    —————–

    Previous
    Next

  8. div id=”tj_container1″ class=”tj_container”
    div class=”tj_nav”
    span id=”tj_prev1″ class=”tj_prev”
    span id=”tj_next1″ class=”tj_next”

  9. Wow guys… this is really one of your best work. I love all the scripts but I didn’t comment before – I think I will use this with Nextgen for WordPress, as I need pagination but hate the original solution.

  10. Awesome!!! Like This ^_^
    but it seems there is something that must be refined to be supported by all browsers.

  11. @Andrea I think it has to do with the CSS3 transitions, I’ve removed them now and it seems smoother.

    @Assa Can you tell me what is not working? Because it works fine in the latest versions of Chrome, Firefox, Safari and also IE9/IE8/IE7 over here πŸ™‚

    Thank you all! Cheers

  12. Thank you Mary πŸ˜‰ for the trick.

    But Chrome is steel the smoother of FF and IE. Seems Chrome have the best javascript “engine”.

  13. Awesome Work and beautiful effect! works fine in FF4, chrome 12, safari and even IE7.

  14. @Mary
    I use firefox and chrome.
    I faced the same problem like what Stephen said, the effect goes well after the first refresh, but it seems the demo is now better than ever.

    Keep up the wonderful work.

  15. always amazing jQuery tut’s if landing here πŸ˜‰
    like usually….ck ck ck ^:)^ hohohoho \m/

  16. I’m having the same problem as well, using the latest version of Chrome. When I load another grid it looks like its reloading the style sheet. Maybe if you reset it before you load again, it doesnt bug. I had the same problem with colorbox, easy fixed with a function

    but very good job on that anyways!

  17. HI Mary

    How can I change the script so that it runs AUTO so that I could use that as Slideshow also ?

  18. Hi Mary,
    congrats on the script,
    this one is really great and very usefull. Can’t really decide which effect i should use, they all are very impressive πŸ™‚

  19. Awesome as always! I’ll definitely have to give you so much credit for inspiration when I launch πŸ™‚

  20. Amazing work …
    Will try to use this professional.
    Thanks Mary Lou for those beauties

  21. Works great in Firefox, but doesn’t work at all in the latest version of Chrome. It doesn’t appear to lay the images out properly or animate them – they just sit on top of each other.

  22. is there anyway that when we click the image and it would maximize ? how can we do that ? can you guys make as a sample.

  23. Hi Mary,

    Awesome script. I am trying to implement it to my own website but I found a problem. I can’t load more then 27 pictures. 3×3 grid and it only shows 3 pages. So if you could plz help me out here because I am lost as to how to add more pages.

  24. great work Mary!

    I’ve been trying unsuccessfully to hack it a bit for some larger images in a 3 x 2 grid… but when I change the ‘width’ attribute in the CSS it doesn’t seem to recalculate properly and the entire list is off-center (floated to the left)… any ideas?

  25. how can this be implemented with a database of images and text content through php/mysql? If anyone knows this, I need some pointers.

  26. Hi Mary,

    Thanks for sharing that great piece of work. I did modify it to load images for a directory based on a click event. For some reasons, the images are shown, but the scroll effect is not working anymore.

    Basically, what I am doing is replacing the elements with a new one for the new images from the clicked folder.

    Do you have any idea why this happen? and may be how to solve it.

    Thansk …..

  27. wow… one of the best tutorial and very useful for many things. So Mary, thank you very much!

  28. Could anyone make my day and post some code on how to hide the navigation arrows when the beginning or the end of the gallery has been reached?

    (or hide the navigation arrows altogether when there are simply not enough images in the gallery for a second row)

    Greetings,
    Manuel