diff -r 7b1b88e27a20 -r 48c4eec2b7e6 wp/wp-includes/functions.wp-styles.php --- a/wp/wp-includes/functions.wp-styles.php Thu Sep 29 08:06:27 2022 +0200 +++ b/wp/wp-includes/functions.wp-styles.php Fri Sep 05 18:40:08 2025 +0200 @@ -9,12 +9,12 @@ */ /** - * Initialize $wp_styles if it has not been set. + * Initializes $wp_styles if it has not been set. + * + * @since 4.2.0 * * @global WP_Styles $wp_styles * - * @since 4.2.0 - * * @return WP_Styles WP_Styles instance. */ function wp_styles() { @@ -28,15 +28,15 @@ } /** - * Display styles that are in the $handles queue. + * Displays styles that are in the $handles queue. * * Passing an empty array to $handles prints the queue, * passing an array with one string prints that style, * and passing an array of strings prints those styles. * - * @global WP_Styles $wp_styles The WP_Styles object for printing styles. + * @since 2.6.0 * - * @since 2.6.0 + * @global WP_Styles $wp_styles The WP_Styles object for printing styles. * * @param string|bool|array $handles Styles to be printed. Default 'false'. * @return string[] On success, an array of handles of processed WP_Dependencies items; otherwise, an empty array. @@ -69,7 +69,7 @@ } /** - * Add extra CSS styles to a registered stylesheet. + * Adds extra CSS styles to a registered stylesheet. * * Styles will only be added if the stylesheet is already in the queue. * Accepts a string $data containing the CSS. If two or more CSS code blocks @@ -105,7 +105,7 @@ } /** - * Register a CSS stylesheet. + * Registers a CSS stylesheet. * * @see WP_Dependencies::add() * @link https://www.w3.org/TR/CSS2/media.html#media-types List of CSS media types. @@ -114,7 +114,7 @@ * @since 4.3.0 A return value was added. * * @param string $handle Name of the stylesheet. Should be unique. - * @param string|bool $src Full URL of the stylesheet, or path of the stylesheet relative to the WordPress root directory. + * @param string|false $src Full URL of the stylesheet, or path of the stylesheet relative to the WordPress root directory. * If source is set to false, stylesheet is an alias of other stylesheets it depends on. * @param string[] $deps Optional. An array of registered stylesheet handles this stylesheet depends on. Default empty array. * @param string|bool|null $ver Optional. String specifying stylesheet version number, if it has one, which is added to the URL @@ -133,7 +133,7 @@ } /** - * Remove a registered stylesheet. + * Removes a registered stylesheet. * * @see WP_Dependencies::remove() * @@ -148,7 +148,7 @@ } /** - * Enqueue a CSS stylesheet. + * Enqueues a CSS stylesheet. * * Registers the style if source provided (does NOT overwrite) and enqueues. * @@ -184,7 +184,7 @@ } /** - * Remove a previously enqueued CSS stylesheet. + * Removes a previously enqueued CSS stylesheet. * * @see WP_Dependencies::dequeue() * @@ -199,23 +199,23 @@ } /** - * Check whether a CSS stylesheet has been added to the queue. + * Checks whether a CSS stylesheet has been added to the queue. * * @since 2.8.0 * * @param string $handle Name of the stylesheet. - * @param string $list Optional. Status of the stylesheet to check. Default 'enqueued'. + * @param string $status Optional. Status of the stylesheet to check. Default 'enqueued'. * Accepts 'enqueued', 'registered', 'queue', 'to_do', and 'done'. * @return bool Whether style is queued. */ -function wp_style_is( $handle, $list = 'enqueued' ) { +function wp_style_is( $handle, $status = 'enqueued' ) { _wp_scripts_maybe_doing_it_wrong( __FUNCTION__, $handle ); - return (bool) wp_styles()->query( $handle, $list ); + return (bool) wp_styles()->query( $handle, $status ); } /** - * Add metadata to a CSS stylesheet. + * Adds metadata to a CSS stylesheet. * * Works only if the stylesheet has already been registered. * @@ -226,7 +226,7 @@ * 'alt' bool For rel="alternate stylesheet". * 'title' string For preferred/alternate stylesheets. * 'path' string The absolute path to a stylesheet. Stylesheet will - * load inline when 'path'' is set. + * load inline when 'path' is set. * * @see WP_Dependencies::add_data() *