My second JavaScript library in as many days! This new one is called ShiftPanes (like my original names huh?!). Basically, it allows you to declare a container that will hold “pageable” blocks of content within it. It is, again, pretty basic and no frills.

Just declare a container with any class you want, and inside declare multiple containers each with the same (different from the container) class that will act as “panes” (or pages). Then simply include ShiftPanes.js and call it in your $().ready() to initialize (passing the selector for the container, selector for the panes, and optional delay and easing). Don’t forget to include links with a class of “shift” and a rel of “next” or “previous” in order to actually interact with the panes.

Here’s the github: https://github.com/jkat98/ShiftPanes
Here’s a sample page: http://jasonkrol.com/upload/misc/shiftpanes_sample/sample.html

[sourcecode language=”javascript”]

$().ready(function(){

ShiftPanes(‘.container’, ‘.pane’, 800, ‘swing’);

});

[/sourcecode]

[sourcecode language=”html”]

Pane #1:

Pane #2:

[/sourcecode]