Crowdsignal Dashboard – Polls, Surveys & more - Version 3.0.7

Version Description

Minor bugfix release

Download this release

Release Info

Developer donncha
Plugin Icon 128x128 Crowdsignal Dashboard – Polls, Surveys & more
Version 3.0.7
Comparing to
See all releases

Code changes from version 3.0.6 to 3.0.7

css/polldaddy.css CHANGED
@@ -27,11 +27,14 @@
27
  }
28
 
29
  #manage-polls {
30
- margin-left: -20px;
31
  margin-right: 0;
32
  margin-top: 0;
33
  }
34
 
 
 
 
 
35
  @media screen and (max-width: 782px) {
36
  #manage-polls {
37
  clear: none;
@@ -52,6 +55,11 @@ h2#polldaddy-header, h2#poll-list-header {
52
  display: inline-block;
53
  }
54
 
 
 
 
 
 
55
  .cs-wrapper {
56
  clear: both;
57
  display: flex;
@@ -61,6 +69,11 @@ h2#polldaddy-header, h2#poll-list-header {
61
  }
62
 
63
  @media screen and (max-width: 782px) {
 
 
 
 
 
64
  .cs-wrapper {
65
  min-height: calc(100% - 60px);
66
  }
@@ -372,7 +385,7 @@ h2#polldaddy-header, h2#poll-list-header {
372
  flex-direction: column;
373
  grid-column: 2 / span 2;
374
  grid-row: 2;
375
- background: white;
376
  padding: 8px 0;
377
  flex-grow: 1;
378
  }
27
  }
28
 
29
  #manage-polls {
 
30
  margin-right: 0;
31
  margin-top: 0;
32
  }
33
 
34
+ #manage-polls:not(.cs-dashboard__crowdsignal_ratings_wrap) {
35
+ margin-left: -20px;
36
+ }
37
+
38
  @media screen and (max-width: 782px) {
39
  #manage-polls {
40
  clear: none;
55
  display: inline-block;
56
  }
57
 
58
+ .cs-pre-wrap {
59
+ background-color: white;
60
+ height: 30px;
61
+ }
62
+
63
  .cs-wrapper {
64
  clear: both;
65
  display: flex;
69
  }
70
 
71
  @media screen and (max-width: 782px) {
72
+ .cs-pre-wrap {
73
+ background-color: white;
74
+ height: 60px;
75
+ }
76
+
77
  .cs-wrapper {
78
  min-height: calc(100% - 60px);
79
  }
385
  flex-direction: column;
386
  grid-column: 2 / span 2;
387
  grid-row: 2;
388
+ background-color: white;
389
  padding: 8px 0;
390
  flex-grow: 1;
391
  }
img/svg/icon-block-project-round.svg ADDED
@@ -0,0 +1,8 @@
 
 
 
 
 
 
 
 
1
+ <svg width="32" height="32" viewBox="0 0 32 32" fill="none" xmlns="http://www.w3.org/2000/svg">
2
+ <circle cx="16" cy="16" r="16" fill="#F3F4F5"/>
3
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M12.4444 9.325H13.3702H15.23H16.77H18.6298H19.5556H22.2222C22.4677 9.325 22.6667 9.53766 22.6667 9.8V23.1C22.6667 23.3623 22.4677 23.575 22.2222 23.575H9.77778C9.53232 23.575 9.33333 23.3623 9.33333 23.1V9.8C9.33333 9.53766 9.53232 9.325 9.77778 9.325H12.4444ZM16 6C14.8389 6 13.8511 6.79307 13.4851 7.9H9.77778C8.79594 7.9 8 8.75066 8 9.8V23.1C8 24.1493 8.79594 25 9.77778 25H22.2222C23.2041 25 24 24.1493 24 23.1V9.8C24 8.75066 23.2041 7.9 22.2222 7.9H18.5149C18.1489 6.79307 17.1611 6 16 6Z" fill="#4CCEE4"/>
4
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M21 13.5H11V12H21V13.5Z" fill="#4CCEE4"/>
5
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M21 17.5H11V16H21V17.5Z" fill="#4CCEE4"/>
6
+ <path fill-rule="evenodd" clip-rule="evenodd" d="M18 21.5H11V20H18V21.5Z" fill="#4CCEE4"/>
7
+ <path d="M16.75 7.75C16.75 8.16421 16.4142 8.5 16 8.5C15.5858 8.5 15.25 8.16421 15.25 7.75C15.25 7.33579 15.5858 7 16 7C16.4142 7 16.75 7.33579 16.75 7.75Z" fill="#4CCEE4"/>
8
+ </svg>
partials/polls-table.php CHANGED
@@ -162,12 +162,24 @@
162
  $results_link = 'https://app.crowdsignal.com/quizzes/' . $item->_id . '/report/overview';
163
  $edit_link = 'https://app.crowdsignal.com/quizzes/' . $item->_id . '/question';
164
  $icon_url = 'img/svg/icon-block-quiz-round.svg';
165
- } else {
166
  $edit_post = false;
167
  $item_post_link = false;
168
  $results_link = 'https://app.crowdsignal.com/ratings/' . $item->_id . '/results/';
169
  $edit_link = 'https://app.crowdsignal.com/ratings/' . $item->_id . '/edit/';
170
  $icon_url = 'img/svg/icon-block-rating-round.svg';
 
 
 
 
 
 
 
 
 
 
 
 
171
  }
172
 
173
  $icon_url = $resource_path . $icon_url; // phpcs:ignore -- variable comes from controller
162
  $results_link = 'https://app.crowdsignal.com/quizzes/' . $item->_id . '/report/overview';
163
  $edit_link = 'https://app.crowdsignal.com/quizzes/' . $item->_id . '/question';
164
  $icon_url = 'img/svg/icon-block-quiz-round.svg';
165
+ } elseif ( 'rating' === $item->type ) {
166
  $edit_post = false;
167
  $item_post_link = false;
168
  $results_link = 'https://app.crowdsignal.com/ratings/' . $item->_id . '/results/';
169
  $edit_link = 'https://app.crowdsignal.com/ratings/' . $item->_id . '/edit/';
170
  $icon_url = 'img/svg/icon-block-rating-round.svg';
171
+ } elseif ( 'project' === $item->type ) {
172
+ $edit_post = false;
173
+ $item_post_link = false;
174
+ $results_link = 'https://app.crowdsignal.com/project/' . $item->_id . '/results/';
175
+ $edit_link = 'https://app.crowdsignal.com/project/' . $item->_id;
176
+ $icon_url = 'img/svg/icon-block-project-round.svg';
177
+ } else { // show a generic icon and generic links to app.crowdsignal.com for unhandled item types
178
+ $edit_post = false;
179
+ $item_post_link = false;
180
+ $results_link = false;
181
+ $edit_link = 'https://app.crowdsignal.com/dashboard/';
182
+ $icon_url = 'img/svg/cs-logo2.svg';
183
  }
184
 
185
  $icon_url = $resource_path . $icon_url; // phpcs:ignore -- variable comes from controller
polldaddy-org.php CHANGED
@@ -63,7 +63,7 @@ class WPORG_Polldaddy extends WP_Polldaddy {
63
  if ( $page == 'ratings' )
64
  return (stripos( $admin_title, $page ) === false ? __( "Ratings", "polldaddy" ) : '' ).$admin_title;
65
  elseif ( $page == 'polls' )
66
- return (stripos( $admin_title, $page ) === false ? __( "Polls", "polldaddy" ) : '' ).$admin_title;
67
 
68
  return $admin_title;
69
  }
63
  if ( $page == 'ratings' )
64
  return (stripos( $admin_title, $page ) === false ? __( "Ratings", "polldaddy" ) : '' ).$admin_title;
65
  elseif ( $page == 'polls' )
66
+ return (stripos( $admin_title, $page ) === false ? __( "Dashboard", "polldaddy" ) : '' ) . ' | ' . $admin_title;
67
 
68
  return $admin_title;
69
  }
polldaddy.php CHANGED
@@ -5,7 +5,7 @@
5
  * Description: Create and manage Crowdsignal polls and ratings in WordPress
6
  * Author: Automattic, Inc.
7
  * Author URL: https://crowdsignal.com/
8
- * Version: 3.0.6
9
  */
10
 
11
  // To hardcode your Polldaddy PartnerGUID (API Key), add the (uncommented) line below with the PartnerGUID to your `wp-config.php`
@@ -1715,12 +1715,14 @@ class WP_Polldaddy {
1715
  $poll = (int) $poll;
1716
  $style = (int) $style;
1717
  $rating = esc_html( $rating );
 
1718
  ?>
1719
 
1720
- <div class="wrap" id="manage-polls">
1721
  <div class="cs-wrapper">
1722
  <?php
1723
  if ( 'polls' === $page ) {
 
1724
  if ( ! $this->is_author && in_array( $action, array( 'edit', 'edit-poll', 'create-poll', 'edit-style', 'create-style', 'list-styles' ), true ) ) { // check user privileges has access to action.
1725
  $action = '';
1726
  }
5
  * Description: Create and manage Crowdsignal polls and ratings in WordPress
6
  * Author: Automattic, Inc.
7
  * Author URL: https://crowdsignal.com/
8
+ * Version: 3.0.7
9
  */
10
 
11
  // To hardcode your Polldaddy PartnerGUID (API Key), add the (uncommented) line below with the PartnerGUID to your `wp-config.php`
1715
  $poll = (int) $poll;
1716
  $style = (int) $style;
1717
  $rating = esc_html( $rating );
1718
+ $wrap_style = $page === 'polls' ? 'polls' : 'ratings';
1719
  ?>
1720
 
1721
+ <div class="wrap cs-dashboard__crowdsignal_<?php echo $wrap_style ; ?>_wrap" id="manage-polls">
1722
  <div class="cs-wrapper">
1723
  <?php
1724
  if ( 'polls' === $page ) {
1725
+ ?><div class="cs-pre-wrap"></div><?php
1726
  if ( ! $this->is_author && in_array( $action, array( 'edit', 'edit-poll', 'create-poll', 'edit-style', 'create-style', 'list-styles' ), true ) ) { // check user privileges has access to action.
1727
  $action = '';
1728
  }
readme.txt CHANGED
@@ -1,10 +1,10 @@
1
  === Crowdsignal Dashboard - Polls, Surveys & more ===
2
- Contributors: donncha, ice9js, cgastrell, digitalwaveride, jcheringer
3
  Tags: crowdsignal, polls, poll, polldaddy, wppolls, vote, polling, surveys, rate, rating, ratings
4
  Requires at least: 5.5
5
  Requires PHP: 5.6
6
- Tested up to: 5.8.3
7
- Stable tag: 3.0.6
8
 
9
  == Description ==
10
 
@@ -89,10 +89,15 @@ This is possible if your server or network is blocking outgoing calls to Crowdsi
89
  Make sure to whitelist `api.crowdsignal.com` in your firewall to fix this.
90
 
91
  == Upgrade Notice ==
92
- Revamp wp-admin styles: Crowdsignal dashboard
93
 
94
  == Changelog ==
95
 
 
 
 
 
 
96
  = 3.0.6
97
  * Fix CSS so it doesn't conflict with Jetpack. Fix disconnect form. (75)
98
  * Fix typo (76)
1
  === Crowdsignal Dashboard - Polls, Surveys & more ===
2
+ Contributors: donncha, ice9js, cgastrell, digitalwaveride, jcheringer, thestevek
3
  Tags: crowdsignal, polls, poll, polldaddy, wppolls, vote, polling, surveys, rate, rating, ratings
4
  Requires at least: 5.5
5
  Requires PHP: 5.6
6
+ Tested up to: 5.9
7
+ Stable tag: 3.0.7
8
 
9
  == Description ==
10
 
89
  Make sure to whitelist `api.crowdsignal.com` in your firewall to fix this.
90
 
91
  == Upgrade Notice ==
92
+ Minor bugfix release
93
 
94
  == Changelog ==
95
 
96
+ = 3.0.7
97
+ * Small fixes to setting page styles. (78)
98
+ * Fix the title of the Dashboard page. (79)
99
+ * Add icon and links for projects to the Dashboard. (80)
100
+
101
  = 3.0.6
102
  * Fix CSS so it doesn't conflict with Jetpack. Fix disconnect form. (75)
103
  * Fix typo (76)