Build Tools: Minify the package CSS when building.
CSS coming from the `@wordpress` packages wasn't being minified in the build. This had the noteable side effect of causing RTL CSS to not be loaded when `SCRIPT_DEBUG` was set to `false`. Props websupporter. Merges [43905] to trunk. Fixes #45330. Built from https://develop.svn.wordpress.org/trunk@44252 git-svn-id: http://core.svn.wordpress.org/trunk@44082 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
@@ -1852,12 +1852,12 @@ function wp_default_styles( &$styles ) {
|
||||
}
|
||||
$styles->add( 'wp-editor-font', $fonts_url );
|
||||
|
||||
$styles->add( 'wp-block-library-theme', '/wp-includes/css/dist/block-library/theme.css' );
|
||||
$styles->add( 'wp-block-library-theme', "/wp-includes/css/dist/block-library/theme$suffix.css" );
|
||||
$styles->add_data( 'wp-block-library-theme', 'rtl', 'replace' );
|
||||
|
||||
$styles->add(
|
||||
'wp-edit-blocks',
|
||||
'/wp-includes/css/dist/block-library/editor.css',
|
||||
"/wp-includes/css/dist/block-library/editor$suffix.css",
|
||||
array(
|
||||
'wp-components',
|
||||
'wp-editor',
|
||||
@@ -1879,7 +1879,7 @@ function wp_default_styles( &$styles ) {
|
||||
|
||||
foreach ( $package_styles as $package => $dependencies ) {
|
||||
$handle = 'wp-' . $package;
|
||||
$path = '/wp-includes/css/dist/' . $package . '/style.css';
|
||||
$path = "/wp-includes/css/dist/$package/style$suffix.css";
|
||||
|
||||
$styles->add( $handle, $path, $dependencies );
|
||||
$styles->add_data( $handle, 'rtl', 'replace' );
|
||||
|
||||
Reference in New Issue
Block a user