Skip to content
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions src/wp-includes/script-loader.php
Original file line number Diff line number Diff line change
Expand Up @@ -2988,6 +2988,7 @@ function wp_enqueue_global_styles_css_custom_properties() {
*
* @since 5.9.1
* @since 6.1.0 Added the `$priority` parameter.
* @deprecated 6.2.0 Use wp_style_engine_get_stylesheet_from_css_rules() instead.

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
* @deprecated 6.2.0 Use wp_style_engine_get_stylesheet_from_css_rules() instead.
* @deprecated 6.3.0 Use wp_style_engine_get_stylesheet_from_css_rules() instead.

*
* For block themes, styles are loaded in the head.
* For classic ones, styles are loaded in the body because the wp_head action happens before render_block.
Expand All @@ -2998,6 +2999,7 @@ function wp_enqueue_global_styles_css_custom_properties() {
* @param int $priority To set the priority for the add_action.
*/
function wp_enqueue_block_support_styles( $style, $priority = 10 ) {

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This function should be moved to wp-includes/deprecated.php.

_deprecated_function( __FUNCTION__, '6.2.0', 'wp_style_engine_get_stylesheet_from_css_rules()' );

Copy link
Copy Markdown
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
_deprecated_function( __FUNCTION__, '6.2.0', 'wp_style_engine_get_stylesheet_from_css_rules()' );
_deprecated_function( __FUNCTION__, '6.3.0', 'wp_style_engine_get_stylesheet_from_css_rules()' );

$action_hook_name = 'wp_footer';

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
$action_hook_name = 'wp_footer';
$action_hook_name = 'wp_footer';

Empty new line to separate the deprecation from the original function's code.

if ( wp_is_block_theme() ) {
$action_hook_name = 'wp_head';
Expand Down