diff options
author | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 07:57:30 +0000 |
---|---|---|
committer | Daniel Baumann <daniel.baumann@progress-linux.org> | 2024-04-17 07:57:30 +0000 |
commit | fa9a33d818470a5796f0ff8797f98b510ed8de18 (patch) | |
tree | bde6a1eede376f9b5df5898ce812330152984d8e /wp-includes/class-wp-theme-json-resolver.php | |
parent | Releasing progress-linux version 6.4.3+dfsg1-1~progress7.99u1. (diff) | |
download | wordpress-fa9a33d818470a5796f0ff8797f98b510ed8de18.tar.xz wordpress-fa9a33d818470a5796f0ff8797f98b510ed8de18.zip |
Merging upstream version 6.5+dfsg1.
Signed-off-by: Daniel Baumann <daniel.baumann@progress-linux.org>
Diffstat (limited to 'wp-includes/class-wp-theme-json-resolver.php')
-rw-r--r-- | wp-includes/class-wp-theme-json-resolver.php | 17 |
1 files changed, 15 insertions, 2 deletions
diff --git a/wp-includes/class-wp-theme-json-resolver.php b/wp-includes/class-wp-theme-json-resolver.php index 90710a5..3ad5ecf 100644 --- a/wp-includes/class-wp-theme-json-resolver.php +++ b/wp-includes/class-wp-theme-json-resolver.php @@ -312,8 +312,16 @@ class WP_Theme_JSON_Resolver { } $theme_support_data['settings']['color']['defaultGradients'] = $default_gradients; - // Classic themes without a theme.json don't support global duotone. - $theme_support_data['settings']['color']['defaultDuotone'] = false; + if ( ! isset( $theme_support_data['settings']['shadow'] ) ) { + $theme_support_data['settings']['shadow'] = array(); + } + /* + * Shadow presets are explicitly disabled for classic themes until a + * decision is made for whether the default presets should match the + * other presets or if they should be disabled by default in classic + * themes. See https://github.com/WordPress/gutenberg/issues/59989. + */ + $theme_support_data['settings']['shadow']['defaultPresets'] = false; // Allow themes to enable link color setting via theme_support. if ( current_theme_supports( 'link-color' ) ) { @@ -327,6 +335,11 @@ class WP_Theme_JSON_Resolver { $theme_support_data['settings']['border']['style'] = true; $theme_support_data['settings']['border']['width'] = true; } + + // Allow themes to enable appearance tools via theme_support. + if ( current_theme_supports( 'appearance-tools' ) ) { + $theme_support_data['settings']['appearanceTools'] = true; + } } $with_theme_supports = new WP_Theme_JSON( $theme_support_data ); $with_theme_supports->merge( static::$theme ); |