MoxingBoxes jQuery Plugin (demo)
- WordPress plugin - by Craftyhub.
- Documentation now maintained in the wiki pages.
- Original post at CSS-Tricks.
- Latest MovingBoxes demo.
- Having trouble getting MovingBoxes installed? Ask for help in the CSS-Tricks forums.
- Have an issue or find an error? Submit it here.
(Only the most recent changes are shown below, see the wiki page for a complete listing)
-
Updated the API used to change panels. It will now accept a jQuery object of the panel or an element anywhere inside panel:
// go to panel 3 var lnk3 = $('.link3'); // link inside panel 3 $('#boxes').movingBoxes(lnk3, function(api){ alert('Now on panel #' + api.curPanel); });
You can also call the api directly
// go to panel 3 var api = $('#boxes').data('movingBoxes'), // movingboxes object (api) lnk3 = $('.link3'); // link inside panel 3 api.change(lnk3, function(api){ alert('Now on panel #' + api.curPanel); });
-
Fixed the issue with the first panel not positioning correctly when the hash is not set.
-
Fixed issues with dealing with only one panel:
- MovingBoxes with one or less panels will now properly hide the navigation arrows.
- Starting with two panels and the first slide selected, when the second one was removed, the first panel would not resize. It does now!
-
Fixed an issue that occurred when the indicated hash panel didn't exist - the first cloned slide used to display instead.
- MovingBoxes will no longer start on the first cloned panel when the
wrap
option is set totrue
. Fixes issue #97.
- Added a method to check when all images have loaded, then reevaluate the height of each panel.
- The plugin that was incorporated is called imagesLoaded.
- This entailed rewritting and fixing the plugin initialization function (issue #92 and initAnimation problems (issue #79).
- I hope this also includes fixing whatever is going on in issue #62.
- Added a
delayBeforeAnimate
option: - Modified the layout so that the UL now gets the margin to center the panels within the frame instead of the first LI. This fixes the animation jump seen when switching from the second to first panel.
- Removed byte order mark (BOM) from the js files. Fix for issue #94.
- Added new styling to the demo pages (Chris)
- Updated to jQuery v1.8
- Included padding and margins in the panel position calculation to better center them.
-
Sorry for the inconvience, but we've moved the MovingBoxes repository from chriscoyier's account over to the CSS-Tricks organization's account.
-
Changed all links to point to the correct repository.
-
If you run into a jsFiddle demo that doesn't work, just update the resources links; but please don't link directly to these files from your site, use these files for demo purposes only.
http://css-tricks.github.com/MovingBoxes/css/movingboxes.css http://css-tricks.github.com/MovingBoxes/js/jquery.movingboxes.js
- The
initAnimation
option should again prevent the initial animation. Fix for issue #79.