From c3c4dade7ddcb7825498cd5865c20f8463dfaaa7 Mon Sep 17 00:00:00 2001 From: Sergey Biryukov Date: Mon, 27 Oct 2025 11:17:36 +0000 Subject: [PATCH] Twenty Twenty-One: Document the `twenty_twenty_one_content_width` filter. Includes removing an unnecessary PHPCS ignore annotation. The linked WPCS issue is not open anymore, and [https://github.com/WordPress/WordPress-Coding-Standards/pull/1773 WordPress/WordPress-Coding-Standards#1773] indicates that the test now makes an exception for `$content_width`. Follow-up to [49216]. Props viralsampat, pmbaldha, sabernhardt. Fixes #63664. Built from https://develop.svn.wordpress.org/trunk@61070 git-svn-id: http://core.svn.wordpress.org/trunk@60406 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-content/themes/twentytwentyone/functions.php | 10 +++++++--- wp-includes/version.php | 2 +- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/wp-content/themes/twentytwentyone/functions.php b/wp-content/themes/twentytwentyone/functions.php index 993025f272..02d2a1dc9b 100644 --- a/wp-content/themes/twentytwentyone/functions.php +++ b/wp-content/themes/twentytwentyone/functions.php @@ -375,9 +375,13 @@ add_action( 'widgets_init', 'twenty_twenty_one_widgets_init' ); * @return void */ function twenty_twenty_one_content_width() { - // This variable is intended to be overruled from themes. - // Open WPCS issue: {@link https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards/issues/1043}. - // phpcs:ignore WordPress.NamingConventions.PrefixAllGlobals.NonPrefixedVariableFound + /** + * Filters Twenty Twenty-One content width of the theme. + * + * @since Twenty Twenty-One 1.0 + * + * @param int $content_width Content width in pixels. + */ $GLOBALS['content_width'] = apply_filters( 'twenty_twenty_one_content_width', 750 ); } add_action( 'after_setup_theme', 'twenty_twenty_one_content_width', 0 ); diff --git a/wp-includes/version.php b/wp-includes/version.php index 19d9aa3181..5dc9d6dc6c 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -16,7 +16,7 @@ * * @global string $wp_version */ -$wp_version = '6.9-beta1-61069'; +$wp_version = '6.9-beta1-61070'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.