Make WordPress Core

Ticket #37011: 37011.8.diff

File 37011.8.diff, 2.2 KB (added by whyisjake, 3 years ago)
  • src/wp-includes/theme.php

     
    38113811                        'show_in_rest' => array(
    38123812                                'schema' => array(
    38133813                                        'properties' => array(
    3814                                                 'width'       => array(
     3814                                                'width'                => array(
    38153815                                                        'type' => 'integer',
    38163816                                                ),
    3817                                                 'height'      => array(
     3817                                                'height'               => array(
    38183818                                                        'type' => 'integer',
    38193819                                                ),
    3820                                                 'flex-width'  => array(
     3820                                                'flex-width'           => array(
    38213821                                                        'type' => 'boolean',
    38223822                                                ),
    3823                                                 'flex-height' => array(
     3823                                                'flex-height'          => array(
    38243824                                                        'type' => 'boolean',
    38253825                                                ),
    3826                                                 'header-text' => array(
     3826                                                'header-text'          => array(
    38273827                                                        'type'  => 'array',
    38283828                                                        'items' => array(
    38293829                                                                'type' => 'string',
    38303830                                                        ),
    38313831                                                ),
     3832                                                'unlink-homepage-logo' => array(
     3833                                                        'type' => 'boolean',
     3834                                                ),
    38323835                                        ),
    38333836                                ),
    38343837                        ),
  • tests/phpunit/tests/rest-api/rest-themes-controller.php

     
    574574        public function test_theme_supports_custom_logo() {
    575575                remove_theme_support( 'custom-logo' );
    576576                $wordpress_logo = array(
    577                         'height'      => 100,
    578                         'width'       => 400,
    579                         'flex-height' => true,
    580                         'flex-width'  => true,
    581                         'header-text' => array( 'site-title', 'site-description' ),
     577                        'height'               => 100,
     578                        'width'                => 400,
     579                        'flex-height'          => true,
     580                        'flex-width'           => true,
     581                        'header-text'          => array( 'site-title', 'site-description' ),
     582                        'unlink-homepage-logo' => false,
    582583                );
    583584                add_theme_support( 'custom-logo', $wordpress_logo );
    584585                $response = self::perform_active_theme_request();
  • .