WordPress.org

Make WordPress Core

Ticket #48031: 48031.patch

File 48031.patch, 1.4 KB (added by pierlo, 13 months ago)

Upgrade Masonry to v4.2.2

  • package.json

    diff --git package-lock.json package-lock.json
    index c09426b894..4f884f6e4e 100644
     
    111111                "jquery-hoverintent": "1.8.3",
    112112                "jquery-ui": "https://github.com/jquery/jquery-ui/archive/1.11.4.tar.gz",
    113113                "lodash": "4.17.15",
    114                 "masonry-layout": "3.3.2",
     114                "masonry-layout": "4.2.2",
    115115                "moment": "2.22.2",
    116116                "polyfill-library": "3.27.4",
    117117                "react": "16.8.4",
  • src/wp-includes/script-loader.php

    diff --git src/wp-includes/script-loader.php src/wp-includes/script-loader.php
    index 4ad643008c..641453712b 100644
    function wp_default_scripts( &$scripts ) { 
    10921092        // Masonry v2 depended on jQuery. v3 does not. The older jquery-masonry handle is a shiv.
    10931093        // It sets jQuery as a dependency, as the theme may have been implicitly loading it this way.
    10941094        $scripts->add( 'imagesloaded', '/wp-includes/js/imagesloaded.min.js', array(), '3.2.0', 1 );
    1095         $scripts->add( 'masonry', '/wp-includes/js/masonry.min.js', array( 'imagesloaded' ), '3.3.2', 1 );
     1095        $scripts->add( 'masonry', '/wp-includes/js/masonry.min.js', array( 'imagesloaded' ), '4.2.2', 1 );
    10961096        $scripts->add( 'jquery-masonry', "/wp-includes/js/jquery/jquery.masonry$dev_suffix.js", array( 'jquery', 'masonry' ), '3.1.2b', 1 );
    10971097
    10981098        $scripts->add( 'thickbox', '/wp-includes/js/thickbox/thickbox.js', array( 'jquery' ), '3.1-20121105', 1 );