Make WordPress Core

Ticket #46169: system-fonts.patch

File system-fonts.patch, 1.9 KB (added by Joen, 4 years ago)

First stab at removing Noto Serif

  • .env

    diff --git a/.env b/.env
    index 955eecd127..6f9d4807c7 100644
    a b  
    1010##
    1111
    1212# The site will be available at http://localhost:LOCAL_PORT
    13 LOCAL_PORT=8889
     13LOCAL_PORT=8899
    1414
    1515# Where to run WordPress from. Valid options are 'src' and 'build'.
    16 LOCAL_DIR=src
     16LOCAL_DIR=build
    1717
    1818# The PHP version to use. Valid options are 'latest', and '{version}-fpm'.
    1919LOCAL_PHP=latest
  • 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 4d4ade0d01..af11725dda 100644
    a b function wp_default_styles( $styles ) { 
    14641464
    14651465        // Packages styles.
    14661466        $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         }
    14771467        $styles->add( 'wp-editor-font', $fonts_url );
    14781468
    14791469        $styles->add( 'wp-block-library-theme', "/wp-includes/css/dist/block-library/theme$suffix.css" );