Twenty Twenty-One: Use third-person singular verbs for function descriptions.

Reference: [https://developer.wordpress.org/coding-standards/inline-documentation-standards/php/#documenting-tips PHP Documentation Standards: Documenting Tips].

Props vladimiraus, mukesh27, SergeyBiryukov.
See #63692.
Built from https://develop.svn.wordpress.org/trunk@60537


git-svn-id: http://core.svn.wordpress.org/trunk@59873 1a063a9b-81f0-0310-95a4-ce76da25c4cd
This commit is contained in:
Sergey Biryukov
2025-08-04 20:55:31 +00:00
parent 807d44133f
commit ff0f834484
26 changed files with 46 additions and 46 deletions

View File

@@ -1,5 +1,5 @@
/**
* Get luminance from a HEX color.
* Gets luminance from a HEX color.
*
* @since Twenty Twenty-One 1.0
*
@@ -13,7 +13,7 @@ function twentytwentyoneGetHexLum( hex ) { // jshint ignore:line
}
/**
* Get RGB from HEX.
* Gets RGB from HEX.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -6,9 +6,9 @@ if ( document.body.classList.contains( 'twentytwentyone-supports-dark-theme' ) )
}
/**
* Once the editor loads, add the dark mode class.
* Adds the dark mode class once the editor loads.
*
* Wait for the editor to load by periodically checking for an element, then we add the classes.
* Waits for the editor to load by periodically checking for an element, then adds the classes.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -5,7 +5,7 @@
*/
/**
* Toggle an attribute's value
* Toggles an attribute's value
*
* @since Twenty Twenty-One 1.0
*
@@ -66,7 +66,7 @@ function twentytwentyoneSubmenuPosition( li ) {
}
/**
* Handle clicks on submenu toggles.
* Handles clicks on submenu toggles.
*
* @since Twenty Twenty-One 1.0
*
@@ -134,7 +134,7 @@ function twentytwentyoneExpandSubMenu( el ) { // jshint ignore:line
} );
/**
* Trap keyboard navigation in the menu modal.
* Traps keyboard navigation in the menu modal.
* Adapted from Twenty Twenty.
*
* @since Twenty Twenty-One 1.0
@@ -180,7 +180,7 @@ function twentytwentyoneExpandSubMenu( el ) { // jshint ignore:line
} );
/**
* Close menu and scroll to anchor when an anchor link is clicked.
* Closes menu and scrolls to anchor when an anchor link is clicked.
* Adapted from Twenty Twenty.
*
* @since Twenty Twenty-One 1.1

View File

@@ -5,7 +5,7 @@
*/
/**
* Add max-width & max-height to <iframe> elements, depending on their width & height props.
* Adds max-width & max-height to <iframe> elements, depending on their width & height props.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -13,7 +13,7 @@
class Twenty_Twenty_One_Custom_Colors {
/**
* Instantiate the object.
* Instantiates the object.
*
* @since Twenty Twenty-One 1.0
*/
@@ -30,7 +30,7 @@ class Twenty_Twenty_One_Custom_Colors {
}
/**
* Determine the luminance of the given color and then return #fff or #000 so that the text is always readable.
* Determines the luminance of the given color and then returns #fff or #000 so that the text is always readable.
*
* @since Twenty Twenty-One 1.0
*
@@ -42,9 +42,9 @@ class Twenty_Twenty_One_Custom_Colors {
}
/**
* Generate color variables.
* Generates color variables.
*
* Adjust the color value of the CSS variables depending on the background color theme mod.
* Adjusts the color value of the CSS variables depending on the background color theme mod.
* Both text and link colors needs to be updated.
* The code below needs to be updated, because the colors are no longer theme mods.
*
@@ -111,7 +111,7 @@ class Twenty_Twenty_One_Custom_Colors {
}
/**
* Get luminance from a HEX color.
* Gets luminance from a HEX color.
*
* @static
*

View File

@@ -25,7 +25,7 @@ class Twenty_Twenty_One_Customize_Color_Control extends WP_Customize_Color_Contr
public $type = 'twenty-twenty-one-color';
/**
* Colorpicker palette
* Colorpicker palette.
*
* @since Twenty Twenty-One 1.0
*
@@ -34,7 +34,7 @@ class Twenty_Twenty_One_Customize_Color_Control extends WP_Customize_Color_Contr
public $palette;
/**
* Enqueue control related scripts/styles.
* Enqueues control related scripts/styles.
*
* @since Twenty Twenty-One 1.0
*
@@ -54,7 +54,7 @@ class Twenty_Twenty_One_Customize_Color_Control extends WP_Customize_Color_Contr
}
/**
* Refresh the parameters passed to the JavaScript via JSON.
* Refreshes the parameters passed to the JavaScript via JSON.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -16,7 +16,7 @@ if ( ! class_exists( 'Twenty_Twenty_One_Customize' ) ) {
class Twenty_Twenty_One_Customize {
/**
* Constructor. Instantiate the object.
* Constructor. Instantiates the object.
*
* @since Twenty Twenty-One 1.0
*/
@@ -25,7 +25,7 @@ if ( ! class_exists( 'Twenty_Twenty_One_Customize' ) ) {
}
/**
* Register customizer options.
* Registers customizer options.
*
* @since Twenty Twenty-One 1.0
*
@@ -144,7 +144,7 @@ if ( ! class_exists( 'Twenty_Twenty_One_Customize' ) ) {
}
/**
* Sanitize boolean for checkbox.
* Sanitizes a boolean for checkbox.
*
* @since Twenty Twenty-One 1.0
*
@@ -156,7 +156,7 @@ if ( ! class_exists( 'Twenty_Twenty_One_Customize' ) ) {
}
/**
* Render the site title for the selective refresh partial.
* Renders the site title for the selective refresh partial.
*
* @since Twenty Twenty-One 1.0
*
@@ -167,7 +167,7 @@ if ( ! class_exists( 'Twenty_Twenty_One_Customize' ) ) {
}
/**
* Render the site tagline for the selective refresh partial.
* Renders the site tagline for the selective refresh partial.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -22,7 +22,7 @@ while ( have_posts() ) {
<figure class="wp-block-image">
<?php
/**
* Filter the default image attachment size.
* Filters the default image attachment size.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -12,7 +12,7 @@
*/
/**
* Display upgrade notice on theme switch.
* Displays upgrade notice on theme switch.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -12,7 +12,7 @@
if ( function_exists( 'register_block_pattern_category' ) ) {
/**
* Register Block Pattern Category.
* Registers Block Pattern Category.
*
* @since Twenty Twenty-One 1.0
*
@@ -32,7 +32,7 @@ if ( function_exists( 'register_block_pattern_category' ) ) {
*/
if ( function_exists( 'register_block_pattern' ) ) {
/**
* Register Block Pattern.
* Registers Block Pattern.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -11,7 +11,7 @@
if ( function_exists( 'register_block_style' ) ) {
/**
* Register block styles.
* Registers block styles.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -8,7 +8,7 @@
*/
/**
* Generate CSS.
* Generates CSS.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -13,7 +13,7 @@
*/
/**
* Add a button to top-level menu items that has sub-menus.
* Adds a button to top-level menu items that has sub-menus.
* An icon is added using CSS depending on the value of aria-expanded.
*
* @since Twenty Twenty-One 1.0

View File

@@ -53,7 +53,7 @@ function twenty_twenty_one_post_classes( $classes ) {
add_filter( 'post_class', 'twenty_twenty_one_post_classes', 10, 3 );
/**
* Add a pingback url auto-discovery header for single posts, pages, or attachments.
* Adds a pingback url auto-discovery header for single posts, pages, or attachments.
*
* @since Twenty Twenty-One 1.0
*
@@ -67,7 +67,7 @@ function twenty_twenty_one_pingback_header() {
add_action( 'wp_head', 'twenty_twenty_one_pingback_header' );
/**
* Remove the `no-js` class from body if JS is supported.
* Removes the `no-js` class from body if JS is supported.
*
* @since Twenty Twenty-One 1.0
*
@@ -215,7 +215,7 @@ function twenty_twenty_one_change_calendar_nav_arrows( $calendar_output ) {
add_filter( 'get_calendar', 'twenty_twenty_one_change_calendar_nav_arrows' );
/**
* Get custom CSS.
* Gets custom CSS.
*
* Return CSS for non-latin language, if available, or null
*
@@ -343,7 +343,7 @@ function twenty_twenty_one_get_non_latin_css( $type = 'front-end' ) {
}
/**
* Print the first instance of a block in the content, and then break away.
* Prints the first instance of a block in the content, and then break away.
*
* @since Twenty Twenty-One 1.0
*
@@ -406,7 +406,7 @@ function twenty_twenty_one_print_first_instance_of_block( $block_name, $content
}
/**
* Retrieve protected post password form content.
* Retrieves protected post password form content.
*
* @since Twenty Twenty-One 1.0
* @since Twenty Twenty-One 1.4 Corrected parameter name for `$output`,

View File

@@ -212,7 +212,7 @@ if ( ! function_exists( 'twenty_twenty_one_post_thumbnail' ) ) {
if ( ! function_exists( 'twenty_twenty_one_the_posts_navigation' ) ) {
/**
* Print the next and previous posts navigation.
* Prints the next and previous posts navigation.
*
* @since Twenty Twenty-One 1.0
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Show the appropriate content for the Aside post format.
* Shows the appropriate content for the Aside post format.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Show the appropriate content for the Audio post format.
* Shows the appropriate content for the Audio post format.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Show the appropriate content for the Chat post format.
* Shows the appropriate content for the Chat post format.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Show the appropriate content for the Gallery post format.
* Shows the appropriate content for the Gallery post format.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Show the appropriate content for the Image post format.
* Shows the appropriate content for the Image post format.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Show the appropriate content for the Link post format.
* Shows the appropriate content for the Link post format.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Show the appropriate content for the Quote post format.
* Shows the appropriate content for the Quote post format.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Show the appropriate content for the Status post format.
* Shows the appropriate content for the Status post format.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Show the appropriate content for the Video post format.
* Shows the appropriate content for the Video post format.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*

View File

@@ -1,6 +1,6 @@
<?php
/**
* Show the excerpt.
* Shows the excerpt.
*
* @link https://developer.wordpress.org/themes/basics/template-hierarchy/
*

View File

@@ -16,7 +16,7 @@
*
* @global string $wp_version
*/
$wp_version = '6.9-alpha-60536';
$wp_version = '6.9-alpha-60537';
/**
* Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.