Version Description
- Fixes a rare issue that prevented some users from seeing the Statistics chart (thanks Zsolt!)
Release notes
Download this release
Release Info
Developer | hcabrera |
Plugin | WordPress Popular Posts |
Version | 5.4.2 |
Comparing to | |
See all releases |
Code changes from version 5.4.1 to 5.4.2
- assets/js/chart.js +11 -10
- readme.txt +7 -1
- wordpress-popular-posts.php +2 -2
assets/js/chart.js
CHANGED
@@ -161,20 +161,21 @@ var WPPChart = (function() {
|
|
161 |
config.data.datasets[1].label = data.datasets[1].label;
|
162 |
config.data.datasets[1].data = data.datasets[1].data;
|
163 |
|
|
|
164 |
|
165 |
-
var rgb_comments = HexToRGB(
|
166 |
config.data.datasets[1].backgroundColor = "rgba(" + rgb_comments.r + ", " + rgb_comments.g + ", " + rgb_comments.b + ", 0.9)";
|
167 |
-
config.data.datasets[1].borderColor =
|
168 |
-
config.data.datasets[1].pointBorderColor =
|
169 |
-
config.data.datasets[1].pointHoverBackgroundColor =
|
170 |
-
config.data.datasets[1].pointHoverBorderColor =
|
171 |
|
172 |
-
var rgb_views = HexToRGB(
|
173 |
config.data.datasets[0].backgroundColor = "rgba(" + rgb_views.r + ", " + rgb_views.g + ", " + rgb_views.b + ", 0.7)";
|
174 |
-
config.data.datasets[0].borderColor =
|
175 |
-
config.data.datasets[0].pointBorderColor =
|
176 |
-
config.data.datasets[0].pointHoverBackgroundColor =
|
177 |
-
config.data.datasets[0].pointHoverBorderColor =
|
178 |
|
179 |
chart = new Chart(cvs, config);
|
180 |
};
|
161 |
config.data.datasets[1].label = data.datasets[1].label;
|
162 |
config.data.datasets[1].data = data.datasets[1].data;
|
163 |
|
164 |
+
var colors_arr = wpp_chart_params.colors.slice(-2);
|
165 |
|
166 |
+
var rgb_comments = HexToRGB(colors_arr[0]);
|
167 |
config.data.datasets[1].backgroundColor = "rgba(" + rgb_comments.r + ", " + rgb_comments.g + ", " + rgb_comments.b + ", 0.9)";
|
168 |
+
config.data.datasets[1].borderColor = colors_arr[0];
|
169 |
+
config.data.datasets[1].pointBorderColor = colors_arr[0];
|
170 |
+
config.data.datasets[1].pointHoverBackgroundColor = colors_arr[0];
|
171 |
+
config.data.datasets[1].pointHoverBorderColor = colors_arr[0];
|
172 |
|
173 |
+
var rgb_views = HexToRGB(colors_arr[1]);
|
174 |
config.data.datasets[0].backgroundColor = "rgba(" + rgb_views.r + ", " + rgb_views.g + ", " + rgb_views.b + ", 0.7)";
|
175 |
+
config.data.datasets[0].borderColor = colors_arr[1];
|
176 |
+
config.data.datasets[0].pointBorderColor = colors_arr[1];
|
177 |
+
config.data.datasets[0].pointHoverBackgroundColor = colors_arr[1];
|
178 |
+
config.data.datasets[0].pointHoverBorderColor = colors_arr[1];
|
179 |
|
180 |
chart = new Chart(cvs, config);
|
181 |
};
|
readme.txt
CHANGED
@@ -5,7 +5,7 @@ Tags: popular, posts, widget, popularity, top
|
|
5 |
Requires at least: 4.9
|
6 |
Tested up to: 5.8
|
7 |
Requires PHP: 5.4
|
8 |
-
Stable tag: 5.4.
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
@@ -97,6 +97,12 @@ The FAQ section has been moved [here](https://github.com/cabrerahector/wordpress
|
|
97 |
|
98 |
== Changelog ==
|
99 |
|
|
|
|
|
|
|
|
|
|
|
|
|
100 |
= 5.4.1 =
|
101 |
|
102 |
**If you're using a caching plugin flushing its cache after upgrading to this version is highly recommended.**
|
5 |
Requires at least: 4.9
|
6 |
Tested up to: 5.8
|
7 |
Requires PHP: 5.4
|
8 |
+
Stable tag: 5.4.2
|
9 |
License: GPLv2 or later
|
10 |
License URI: http://www.gnu.org/licenses/gpl-2.0.html
|
11 |
|
97 |
|
98 |
== Changelog ==
|
99 |
|
100 |
+
= 5.4.2 =
|
101 |
+
|
102 |
+
- Fixes a rare issue that prevented some users from seeing the Statistics chart (thanks Zsolt!)
|
103 |
+
|
104 |
+
[Release notes](https://cabrerahector.com/wordpress/wordpress-popular-posts-5-4-widget-block-improvements-plus-prep-work-for-csp-support/#5.4.2)
|
105 |
+
|
106 |
= 5.4.1 =
|
107 |
|
108 |
**If you're using a caching plugin flushing its cache after upgrading to this version is highly recommended.**
|
wordpress-popular-posts.php
CHANGED
@@ -16,7 +16,7 @@
|
|
16 |
* Plugin Name: WordPress Popular Posts
|
17 |
* Plugin URI: https://wordpress.org/plugins/wordpress-popular-posts/
|
18 |
* Description: A highly customizable widget that displays the most popular posts on your blog.
|
19 |
-
* Version: 5.4.
|
20 |
* Author: Hector Cabrera
|
21 |
* Author URI: https://cabrerahector.com/
|
22 |
* License: GPL-2.0+
|
@@ -29,7 +29,7 @@ if ( ! defined( 'WPINC' ) ) {
|
|
29 |
die();
|
30 |
}
|
31 |
|
32 |
-
define('WPP_VERSION', '5.4.
|
33 |
define('WPP_MIN_PHP_VERSION', '5.4');
|
34 |
define('WPP_MIN_WP_VERSION', '4.9');
|
35 |
|
16 |
* Plugin Name: WordPress Popular Posts
|
17 |
* Plugin URI: https://wordpress.org/plugins/wordpress-popular-posts/
|
18 |
* Description: A highly customizable widget that displays the most popular posts on your blog.
|
19 |
+
* Version: 5.4.2
|
20 |
* Author: Hector Cabrera
|
21 |
* Author URI: https://cabrerahector.com/
|
22 |
* License: GPL-2.0+
|
29 |
die();
|
30 |
}
|
31 |
|
32 |
+
define('WPP_VERSION', '5.4.2');
|
33 |
define('WPP_MIN_PHP_VERSION', '5.4');
|
34 |
define('WPP_MIN_WP_VERSION', '4.9');
|
35 |
|