Make WordPress Core


Ignore:
Timestamp:
07/24/2024 12:24:31 AM (12 months ago)
Author:
noisysocks
Message:

Block themes: Enable block-level background image styles

Allows defining background images for blocks in theme.json.

Syncs PHP changes from https://github.com/WordPress/gutenberg/pull/60100.

Props ramonopoly, aaronrobertshaw.
Fixes #61588.

File:
1 edited

Legend:

Unmodified
Added
Removed
  • trunk/src/wp-includes/class-wp-theme-json.php

    r58749 r58797  
    521521    const VALID_STYLES = array(
    522522        'background' => array(
    523             'backgroundImage'    => 'top',
    524             'backgroundPosition' => 'top',
    525             'backgroundRepeat'   => 'top',
    526             'backgroundSize'     => 'top',
     523            'backgroundImage'    => null,
     524            'backgroundPosition' => null,
     525            'backgroundRepeat'   => null,
     526            'backgroundSize'     => null,
    527527        ),
    528528        'border'     => array(
Note: See TracChangeset for help on using the changeset viewer.