Make WordPress Core

Ticket #46169: system-fonts.2.patch

File system-fonts.2.patch, 1.8 KB (added by Joen, 4 years ago)
  • src/wp-admin/edit-form-blocks.php

    diff --git a/src/wp-admin/edit-form-blocks.php b/src/wp-admin/edit-form-blocks.php
    index 03f80700ba..bcc2a26260 100644
    a b $styles = array( 
    191191);
    192192
    193193/* translators: Use this to specify the CSS font family for the default font. */
    194 $locale_font_family = esc_html_x( 'Noto Serif', 'CSS Font Family for Editor Font' );
     194$locale_font_family = '-apple-system,BlinkMacSystemFont,"Segoe UI",Roboto,Oxygen-Sans,Ubuntu,Cantarell,"Helvetica Neue",sans-serif';
    195195$styles[]           = array(
    196196        'css' => "body { font-family: '$locale_font_family' }",
    197197);
  • src/wp-includes/script-loader.php

    diff --git a/src/wp-includes/script-loader.php b/src/wp-includes/script-loader.php
    index 277c9c4f84..0917a9a41f 100644
    a b function wp_default_styles( $styles ) { 
    14631463        $styles->add( 'open-sans', $open_sans_font_url ); // No longer used in core as of 4.6.
    14641464
    14651465        // Packages styles.
    1466         $fonts_url = '';
    1467 
    1468         /*
    1469          * translators: Use this to specify the proper Google Font name and variants
    1470          * to load that is supported by your language. Do not translate.
    1471          * Set to 'off' to disable loading.
    1472          */
    1473         $font_family = _x( 'Noto Serif:400,400i,700,700i', 'Google Font Name and Variants' );
    1474         if ( 'off' !== $font_family ) {
    1475                 $fonts_url = 'https://fonts.googleapis.com/css?family=' . urlencode( $font_family );
    1476         }
    1477         $styles->add( 'wp-editor-font', $fonts_url );
    1478 
    14791466        $styles->add( 'wp-block-library-theme', "/wp-includes/css/dist/block-library/theme$suffix.css" );
    14801467
    14811468        $styles->add(
    function wp_default_styles( $styles ) { 
    14931480        $package_styles = array(
    14941481                'block-editor'         => array(
    14951482                        'wp-components',
    1496                         'wp-editor-font',
    14971483                ),
    14981484                'block-library'        => array(),
    14991485                'block-directory'      => array(),