From 5214e4f5be933562efae937595752cd2b9ee574a Mon Sep 17 00:00:00 2001 From: Alex Lende Date: Mon, 3 Jun 2024 19:31:28 -0500 Subject: [PATCH] Copy spacingSizes from editor-spacing-sizes --- src/wp-includes/class-wp-theme-json.php | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/src/wp-includes/class-wp-theme-json.php b/src/wp-includes/class-wp-theme-json.php index ea8c2225863a6..18e0872eb4673 100644 --- a/src/wp-includes/class-wp-theme-json.php +++ b/src/wp-includes/class-wp-theme-json.php @@ -3595,6 +3595,13 @@ public static function get_from_editor_settings( $settings ) { $theme_settings['settings']['spacing']['padding'] = $settings['enableCustomSpacing']; } + if ( isset( $settings['spacingSizes'] ) ) { + if ( ! isset( $theme_settings['settings']['spacing'] ) ) { + $theme_settings['settings']['spacing'] = array(); + } + $theme_settings['settings']['spacing']['spacingSizes'] = $settings['spacingSizes']; + } + return $theme_settings; }