mirror of
https://github.com/WordPress/WordPress.git
synced 2024-12-23 01:27:36 +01:00
Editor: disable shadow.defaultPresets
for classic themes.
With this change default shadow presets are never shown for classic themes, and classic themes have no options for adding custom ones. This essentially reverts [57717] and [57827] / [57828], which had unintended consequences. Props ajlende, oandregal, madhudollu, swissspidy, get_dave, andrewserong, desrosj. Fixes #60815. Built from https://develop.svn.wordpress.org/trunk@57885 git-svn-id: http://core.svn.wordpress.org/trunk@57386 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
parent
af0a8e253d
commit
0c4eec233d
@ -312,6 +312,17 @@ class WP_Theme_JSON_Resolver {
|
||||
}
|
||||
$theme_support_data['settings']['color']['defaultGradients'] = $default_gradients;
|
||||
|
||||
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' ) ) {
|
||||
$theme_support_data['settings']['color']['link'] = true;
|
||||
|
@ -658,7 +658,7 @@ class WP_Theme_JSON {
|
||||
* @since 6.0.0
|
||||
* @since 6.2.0 Added `dimensions.minHeight` and `position.sticky`.
|
||||
* @since 6.4.0 Added `background.backgroundImage`.
|
||||
* @since 6.5.0 Added `background.backgroundSize`, `dimensions.aspectRatio`, and `shadow.defaultPresets`.
|
||||
* @since 6.5.0 Added `background.backgroundSize` and `dimensions.aspectRatio`.
|
||||
* @var array
|
||||
*/
|
||||
const APPEARANCE_TOOLS_OPT_INS = array(
|
||||
@ -679,7 +679,6 @@ class WP_Theme_JSON {
|
||||
array( 'spacing', 'margin' ),
|
||||
array( 'spacing', 'padding' ),
|
||||
array( 'typography', 'lineHeight' ),
|
||||
array( 'shadow', 'defaultPresets' ),
|
||||
);
|
||||
|
||||
/**
|
||||
|
@ -191,7 +191,7 @@
|
||||
"text": true
|
||||
},
|
||||
"shadow": {
|
||||
"defaultPresets": false,
|
||||
"defaultPresets": true,
|
||||
"presets": [
|
||||
{
|
||||
"name": "Natural",
|
||||
|
@ -16,7 +16,7 @@
|
||||
*
|
||||
* @global string $wp_version
|
||||
*/
|
||||
$wp_version = '6.6-alpha-57883';
|
||||
$wp_version = '6.6-alpha-57885';
|
||||
|
||||
/**
|
||||
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.
|
||||
|
Loading…
Reference in New Issue
Block a user