Block Editor: Drop Noto Serif in favor of system fonts.

This aims to improve privacy and performance of the editor.

Follow-up to [37361].

Props Joen, hellofromTonya, garrett-eclipse, aristath, noisysocks, hedgefield, pento, sabernhardt, joyously, yannkozon.
Fixes #46169.
Built from https://develop.svn.wordpress.org/trunk@50155


git-svn-id: http://core.svn.wordpress.org/trunk@49834 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov
2021-02-02 18:37:04 +00:00
parent ea3a1d782a
commit 9dac2542aa
3 changed files with 5 additions and 9 deletions

View File

@@ -1474,7 +1474,7 @@ function wp_default_styles( $styles ) {
$styles->add( 'colors-fresh', false, array( 'wp-admin', 'buttons' ) ); // Old handle.
$styles->add( 'open-sans', $open_sans_font_url ); // No longer used in core as of 4.6.
// Packages styles.
// Noto Serif is no longer used by core, but may be relied upon by themes and plugins.
$fonts_url = '';
/*
@@ -1486,7 +1486,7 @@ function wp_default_styles( $styles ) {
if ( 'off' !== $font_family ) {
$fonts_url = 'https://fonts.googleapis.com/css?family=' . urlencode( $font_family );
}
$styles->add( 'wp-editor-font', $fonts_url );
$styles->add( 'wp-editor-font', $fonts_url ); // No longer used in core as of 5.7.
$styles->add( 'wp-block-library-theme', "/wp-includes/css/dist/block-library/theme$suffix.css" );
@@ -1503,10 +1503,7 @@ function wp_default_styles( $styles ) {
);
$package_styles = array(
'block-editor' => array(
'wp-components',
'wp-editor-font',
),
'block-editor' => array( 'wp-components' ),
'block-library' => array(),
'block-directory' => array(),
'components' => array(),