From 37ba9480d44183fef765f0efa27a3f221b040dae Mon Sep 17 00:00:00 2001 From: Tetrakern <26898880+Tetrakern@users.noreply.github.com> Date: Sun, 20 Aug 2023 01:04:49 +0200 Subject: [PATCH] Clean up some more comments --- collections.php | 4 +-- footer.php | 6 ++-- header.php | 2 +- includes/functions/_acf.php | 2 +- includes/functions/_admin.php | 2 +- includes/functions/_api.php | 8 ++--- includes/functions/_customizer-settings.php | 8 ++--- includes/functions/_customizer.php | 35 ++++++++++++--------- recommendations.php | 4 +-- 9 files changed, 38 insertions(+), 33 deletions(-) diff --git a/collections.php b/collections.php index 6e2f8ef4..872ca923 100644 --- a/collections.php +++ b/collections.php @@ -10,8 +10,8 @@ * @subpackage Fictioneer * @since 5.0 * - * @internal ('fictioneer_filter_and_search_id') ACF field. You can use this ID for plugins. - * @internal ('fictioneer_short_name') ACF field. Meant for an abbreviated page name. + * @internal ('fictioneer_filter_and_search_id') ACF field. You can use this ID for plugins. + * @internal ('fictioneer_short_name') ACF field. Meant for an abbreviated page name. */ ?> diff --git a/footer.php b/footer.php index 1ca3d0df..89d6400d 100644 --- a/footer.php +++ b/footer.php @@ -14,9 +14,9 @@ * @see partials/_consent-banner.php * @see wp_footer() * - * @internal $args['post_id'] Optional. Current post ID. - * @internal $args['post_type'] Optional. Current post type. - * @internal $args['breadcrumbs'] Array of breadcrumb tuples with label (0) and link (1). + * @internal $args['post_id'] Optional. Current post ID. + * @internal $args['post_type'] Optional. Current post type. + * @internal $args['breadcrumbs'] Array of breadcrumb tuples with label (0) and link (1). */ ?> diff --git a/header.php b/header.php index 77d64be5..d30d1527 100644 --- a/header.php +++ b/header.php @@ -15,7 +15,7 @@ * @see fictioneer_output_head_meta() * @see fictioneer_output_head_critical_scripts() * - * @internal $args Array of arguments passed to the template. + * @internal $args Array of arguments passed to the template. */ ?> diff --git a/includes/functions/_acf.php b/includes/functions/_acf.php index 7e5d70dd..dc06f48f 100644 --- a/includes/functions/_acf.php +++ b/includes/functions/_acf.php @@ -115,7 +115,7 @@ if ( FICTIONEER_FILTER_STORY_CHAPTERS ) { * * @since Fictioneer 5.0 * - * @param int $post_id The post ID. + * @param int $post_id The post ID. */ function fictioneer_update_post_relationships( $post_id ) { diff --git a/includes/functions/_admin.php b/includes/functions/_admin.php index 161918e0..e0d01e23 100644 --- a/includes/functions/_admin.php +++ b/includes/functions/_admin.php @@ -182,7 +182,7 @@ if ( current_user_can( 'install_themes' ) ) { * * @since Fictioneer 5.2.5 * - * @param array $args The list of removable query arguments. + * @param array $args The list of removable query arguments. * * @return array The modified list of removable query arguments. */ diff --git a/includes/functions/_api.php b/includes/functions/_api.php index 04e10f6c..d7e5c557 100644 --- a/includes/functions/_api.php +++ b/includes/functions/_api.php @@ -10,8 +10,8 @@ if ( ! function_exists( 'fictioneer_api_get_story_node' ) ) { * * @since Fictioneer 5.1 * - * @param int $story_id ID of the story. - * @param boolean $with_chapters Whether to include chapters. Default true. + * @param int $story_id ID of the story. + * @param boolean $with_chapters Whether to include chapters. Default true. * * @return array|boolean Either array with story data or false if not valid. */ @@ -245,7 +245,7 @@ if ( ! function_exists( 'fictioneer_api_request_story' ) ) { * @since Fictioneer 5.1 * @link https://developer.wordpress.org/rest-api/extending-the-rest-api/adding-custom-endpoints/ * - * @param WP_REST_Request $WP_REST_Request Request object. + * @param WP_REST_Request $WP_REST_Request Request object. * * @return WP_REST_Response|WP_Error Response or error. */ @@ -324,7 +324,7 @@ if ( ! function_exists( 'fictioneer_api_request_stories' ) ) { * @since Fictioneer 5.1 * @link https://developer.wordpress.org/rest-api/extending-the-rest-api/adding-custom-endpoints/ * - * @param WP_REST_Request $WP_REST_Request Request object. + * @param WP_REST_Request $WP_REST_Request Request object. */ function fictioneer_api_request_stories( WP_REST_Request $data ) { diff --git a/includes/functions/_customizer-settings.php b/includes/functions/_customizer-settings.php index 0c0dc9a4..0ec39284 100644 --- a/includes/functions/_customizer-settings.php +++ b/includes/functions/_customizer-settings.php @@ -26,7 +26,7 @@ if ( class_exists( 'WP_Customize_Control' ) ) { * * @since 4.7 * - * @param WP_Customize_Manager $manager The customizer instance. + * @param WP_Customize_Manager $manager The customizer instance. */ function fictioneer_add_light_mode_customizer_settings( $manager ) { @@ -1077,7 +1077,7 @@ function fictioneer_add_light_mode_customizer_settings( $manager ) { * * @since 4.7 * - * @param WP_Customize_Manager $manager The customizer instance. + * @param WP_Customize_Manager $manager The customizer instance. */ function fictioneer_add_dark_mode_customizer_settings( $manager ) { @@ -2107,7 +2107,7 @@ function fictioneer_add_dark_mode_customizer_settings( $manager ) { * * @since 4.7 * - * @param WP_Customize_Manager $manager The customizer instance. + * @param WP_Customize_Manager $manager The customizer instance. */ function fictioneer_add_layout_customizer_settings( $manager ) { @@ -2734,7 +2734,7 @@ function fictioneer_add_layout_customizer_settings( $manager ) { * @since 3.0 * @since 4.7 Expanded settings to customize color scheme. * - * @param WP_Customize_Manager $manager The customizer instance. + * @param WP_Customize_Manager $manager The customizer instance. */ function fictioneer_add_customizers( $manager ) { diff --git a/includes/functions/_customizer.php b/includes/functions/_customizer.php index 74fce5c3..e098bfe4 100644 --- a/includes/functions/_customizer.php +++ b/includes/functions/_customizer.php @@ -14,8 +14,9 @@ if ( ! function_exists( 'fictioneer_hex_to_rgb' ) ) { * @since Fictioneer 4.7 * @link https://github.com/SimonWaldherr/ColorConverter.php * - * @param string $input The to be converted hex (six digits). - * @return array RGB values as array. + * @param string $input The to be converted hex (six digits). + * + * @return array RGB values as array. */ function fictioneer_hex_to_rgb( $input ) { @@ -63,9 +64,10 @@ if ( ! function_exists( 'fictioneer_rgb_to_hsl' ) ) { * @since Fictioneer 4.7 * @link https://github.com/SimonWaldherr/ColorConverter.php * - * @param array $input The to be converted RGB. - * @param int $precision Rounding precision. Default 0. - * @return array HSL values as array. + * @param array $input The to be converted RGB. + * @param int $precision Rounding precision. Default 0. + * + * @return array HSL values as array. */ function fictioneer_rgb_to_hsl( $input, $precision = 0 ) { @@ -110,7 +112,8 @@ if ( ! function_exists( 'fictioneer_minify_css' ) ) { * @link https://stackoverflow.com/a/15195752/17140970 * @link https://stackoverflow.com/a/44350195/17140970 * - * @param string $string The to be minified CSS string. + * @param string $string The to be minified CSS string. + * * @return string The minified CSS string. */ @@ -167,15 +170,15 @@ if ( ! function_exists( 'fictioneer_minify_css' ) ) { if ( ! function_exists( 'fictioneer_get_css_clamp' ) ) { /** - * Generate a high-precision CSS clamp. + * Generate a high-precision CSS clamp * * @since Fictioneer 4.7 * - * @param int $min The minimum value. - * @param int $max The maximum value. - * @param int $wmin The minimum viewport value. - * @param int $wmax The maximum viewport value. - * @param string $unit The relative clamp unit. Default 'vw'. + * @param int $min The minimum value. + * @param int $max The maximum value. + * @param int $wmin The minimum viewport value. + * @param int $wmax The maximum viewport value. + * @param string $unit The relative clamp unit. Default 'vw'. * * @return string The calculated clamp. */ @@ -201,8 +204,9 @@ if ( ! function_exists( 'fictioneer_hsl_code' ) ) { * * @since Fictioneer 4.7 * - * @param string $hex The color as hex. - * @param string $output Switch output style. Default 'default'. + * @param string $hex The color as hex. + * @param string $output Switch output style. Default 'default'. + * * @return string The converted color. */ @@ -236,7 +240,8 @@ if ( ! function_exists( 'fictioneer_hsl_font_code' ) ) { * @since Fictioneer 4.7 * @see fictioneer_hsl_code( $hex, $output ) * - * @param string $hex The color as hex. + * @param string $hex The color as hex. + * * @return string The converted color. */ diff --git a/recommendations.php b/recommendations.php index 9fa53c32..ea728dbf 100644 --- a/recommendations.php +++ b/recommendations.php @@ -10,8 +10,8 @@ * @subpackage Fictioneer * @since 3.0 * - * @internal ('fictioneer_filter_and_search_id') ACF field. You can use this ID for plugins. - * @internal ('fictioneer_short_name') ACF field. Meant for an abbreviated page name. + * @internal ('fictioneer_filter_and_search_id') ACF field. You can use this ID for plugins. + * @internal ('fictioneer_short_name') ACF field. Meant for an abbreviated page name. */ ?>