-
Notifications
You must be signed in to change notification settings - Fork 4.2k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge branch 'trunk' into update/selectcontrol-margin
- Loading branch information
Showing
97 changed files
with
2,493 additions
and
659 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,28 @@ | ||
<?php | ||
/** | ||
* Adds settings to the block editor. | ||
* | ||
* @package gutenberg | ||
*/ | ||
|
||
/** | ||
* Adds styles and __experimentalFeatures to the block editor settings. | ||
* | ||
* @param array $settings Existing block editor settings. | ||
* | ||
* @return array New block editor settings. | ||
*/ | ||
function gutenberg_get_block_editor_settings_6_2( $settings ) { | ||
if ( wp_theme_has_theme_json() ) { | ||
// Add the custom CSS as separate style sheet so any invalid CSS entered by users does not break other global styles. | ||
$settings['styles'][] = array( | ||
'css' => gutenberg_get_global_stylesheet( array( 'custom-css' ) ), | ||
'__unstableType' => 'user', | ||
'isGlobalStyles' => true, | ||
); | ||
} | ||
|
||
return $settings; | ||
} | ||
|
||
add_filter( 'block_editor_settings_all', 'gutenberg_get_block_editor_settings_6_2', PHP_INT_MAX ); |
Oops, something went wrong.