mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 01:27:36 +01:00
Custom Headers: Ensure the ready event fires before fetching the existing headers to apply jQuery.masonry. see #20346, #21820.
git-svn-id: http://core.svn.wordpress.org/trunk@22504 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
bda841315a
commit
156e782313
@ -1,10 +1,13 @@
|
||||
(function($) {
|
||||
// Fetch available headers and apply jQuery.masonry
|
||||
// once the images have loaded.
|
||||
$( function() {
|
||||
var $headers = $('.available-headers');
|
||||
|
||||
var headers = $('.available-headers');
|
||||
headers.imagesLoaded( function() {
|
||||
headers.masonry({
|
||||
itemSelector: '.default-header'
|
||||
$headers.imagesLoaded( function() {
|
||||
$headers.masonry({
|
||||
itemSelector: '.default-header'
|
||||
});
|
||||
});
|
||||
});
|
||||
|
||||
})(jQuery);
|
||||
}(jQuery));
|
||||
|
Loading…
Reference in New Issue
Block a user