From c0575129156a487b71643c517946b3ac7ebafec1 Mon Sep 17 00:00:00 2001 From: Kevin Pliester <5339107+pixelbart@users.noreply.github.com> Date: Tue, 6 Apr 2021 12:16:57 +0200 Subject: [PATCH] 4.4.31 --- core/assets/css/admin-columns.css | 11 +++++++++++ core/modules/class-admin.php | 6 ++++++ core/tabs/class-details.php | 1 + helpful.php | 2 +- readme.txt | 2 +- templates/tabs/tab-details.php | 8 ++++++++ 6 files changed, 28 insertions(+), 2 deletions(-) create mode 100644 core/assets/css/admin-columns.css diff --git a/core/assets/css/admin-columns.css b/core/assets/css/admin-columns.css new file mode 100644 index 0000000..5166942 --- /dev/null +++ b/core/assets/css/admin-columns.css @@ -0,0 +1,11 @@ +.column-helpful-pro { + width: 125px !important; +} + +.column-helpful-contra { + width: 125px !important; +} + +.column-helpful-feedback { + width: 125px !important; +} \ No newline at end of file diff --git a/core/modules/class-admin.php b/core/modules/class-admin.php index 9dc7c98..7f84fdd 100644 --- a/core/modules/class-admin.php +++ b/core/modules/class-admin.php @@ -113,6 +113,12 @@ public function callback_admin_page() */ public function enqueue_scripts( $hook_suffix ) { + /* shrink admin columns */ + if ( 'on' === get_option( 'helpful_shrink_admin_columns' ) ) { + $file = plugins_url( 'core/assets/css/admin-columns.css', HELPFUL_FILE ); + wp_enqueue_style( 'helpful-admin-columns', $file ); + } + if ( 'toplevel_page_helpful' !== $hook_suffix ) { return; } diff --git a/core/tabs/class-details.php b/core/tabs/class-details.php index 19a0a8b..428b040 100644 --- a/core/tabs/class-details.php +++ b/core/tabs/class-details.php @@ -82,6 +82,7 @@ public function register_settings() 'helpful_metabox', 'helpful_widget_hide_publication', 'helpful_hide_admin_columns', + 'helpful_shrink_admin_columns', 'helpful_feedback_widget', 'helpful_feedback_disabled', ]; diff --git a/helpful.php b/helpful.php index f5fa7b8..3df7b7a 100644 --- a/helpful.php +++ b/helpful.php @@ -2,7 +2,7 @@ /** * Plugin Name: Helpful * Description: Add a fancy feedback form under your posts or post-types and ask your visitors a question. Give them the abbility to vote with yes or no. - * Version: 4.4.30 + * Version: 4.4.31 * Author: Pixelbart * Author URI: https://pixelbart.de * Text Domain: helpful diff --git a/readme.txt b/readme.txt index 2bacf4a..a5ccc4a 100644 --- a/readme.txt +++ b/readme.txt @@ -5,7 +5,7 @@ Tags: helpful, poll, feedback, reviews, vote, review, voting Requires at least: 4.6 Tested up to: 5.7 Requires PHP: 5.6.20 -Stable tag: 4.4.30 +Stable tag: 4.4.31 License: MIT License License URI: https://opensource.org/licenses/MIT diff --git a/templates/tabs/tab-details.php b/templates/tabs/tab-details.php index 5e595f8..783e738 100644 --- a/templates/tabs/tab-details.php +++ b/templates/tabs/tab-details.php @@ -122,6 +122,14 @@ + +
+ +