From 20651de171109e8962154803d7a5b2cad00b7b98 Mon Sep 17 00:00:00 2001 From: Boone Gorges Date: Thu, 17 Dec 2015 16:27:28 +0000 Subject: [PATCH] Introduce 'tag-link-position-x' class to tag cloud links. The new class describes the cardinal position of a link in the cloud, allowing more fine-grained CSS and JS targeting. Props Mte90, chmac. Fixes #5172. Built from https://develop.svn.wordpress.org/trunk@35984 git-svn-id: http://core.svn.wordpress.org/trunk@35949 1a063a9b-81f0-0310-95a4-ce76da25c4cd --- wp-includes/category-template.php | 3 ++- wp-includes/version.php | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/wp-includes/category-template.php b/wp-includes/category-template.php index 68cd74c8e5..971434baf2 100644 --- a/wp-includes/category-template.php +++ b/wp-includes/category-template.php @@ -904,7 +904,8 @@ function wp_generate_tag_cloud( $tags, $args = '' ) { // generate the output links array foreach ( $tags_data as $key => $tag_data ) { - $a[] = "" . esc_html( $tag_data['name'] ) . ""; + $class = $tag_data['class'] . ' tag-link-position-' . ( $key + 1 ); + $a[] = "" . esc_html( $tag_data['name'] ) . ""; } switch ( $args['format'] ) { diff --git a/wp-includes/version.php b/wp-includes/version.php index 56f5e35e0a..71e991cb6e 100644 --- a/wp-includes/version.php +++ b/wp-includes/version.php @@ -4,7 +4,7 @@ * * @global string $wp_version */ -$wp_version = '4.5-alpha-35983'; +$wp_version = '4.5-alpha-35984'; /** * Holds the WordPress DB revision, increments when changes are made to the WordPress DB schema.