Sidekick - Version 2.4.0

Version Description

  • WordPress Customizer support
  • Platform fixes
  • Caption display optimizations
  • Walkthroughs started in modal windows or customizer will first
Download this release

Release Info

Developer raptor235
Plugin Icon 128x128 Sidekick
Version 2.4.0
Comparing to
See all releases

Code changes from version 2.3.1 to 2.4.0

Files changed (5) hide show
  1. js/sidekick_admin.js +1 -3
  2. readme.txt +7 -1
  3. sidekick.php +27 -18
  4. sidekick_embed.php +27 -35
  5. sk_init.php +0 -17
js/sidekick_admin.js CHANGED
@@ -404,12 +404,10 @@ function sk_populate(data){
404
  jQuery('#toggle_composer').trigger('click');
405
  });
406
 
407
- load_sites_by_status('unactivated');
408
- // return;
409
-
410
  if (typeof sk_ms_admin !== 'undefined' && sk_ms_admin) {
411
 
412
  // Multisite
 
413
 
414
  var clicked_button;
415
 
404
  jQuery('#toggle_composer').trigger('click');
405
  });
406
 
 
 
 
407
  if (typeof sk_ms_admin !== 'undefined' && sk_ms_admin) {
408
 
409
  // Multisite
410
+ load_sites_by_status('unactivated');
411
 
412
  var clicked_button;
413
 
readme.txt CHANGED
@@ -4,7 +4,7 @@ Donate link: http://www.sidekick.pro
4
  Tags: help, tutorial, training, learn, learning, sidekick, guide, teach, video, manual, videos, wphelp, support, instructions, question, questions, answers, answer, clippy, q&a, wpuniversity, helper, walkthrough
5
  Requires at least: 3.7
6
  Tested up to: 4.2
7
- Stable tag: 2.3.1
8
  License: GNU Version 2 or Any Later Version
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
@@ -145,6 +145,12 @@ We read and respond to every piece of feedback we get.
145
 
146
  == Changelog ==
147
 
 
 
 
 
 
 
148
  = 2.3.1 =
149
  * Critical bug fix post status transition
150
 
4
  Tags: help, tutorial, training, learn, learning, sidekick, guide, teach, video, manual, videos, wphelp, support, instructions, question, questions, answers, answer, clippy, q&a, wpuniversity, helper, walkthrough
5
  Requires at least: 3.7
6
  Tested up to: 4.2
7
+ Stable tag: 2.4.0
8
  License: GNU Version 2 or Any Later Version
9
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
10
 
145
 
146
  == Changelog ==
147
 
148
+ = 2.4.0 =
149
+ * WordPress Customizer support
150
+ * Platform fixes
151
+ * Caption display optimizations
152
+ * Walkthroughs started in modal windows or customizer will first
153
+
154
  = 2.3.1 =
155
  * Critical bug fix post status transition
156
 
sidekick.php CHANGED
@@ -6,7 +6,7 @@ Plugin URL: http://wordpress.org/plugins/sidekick/
6
  Description: Adds a real-time WordPress training walkthroughs right in your Dashboard
7
  Requires at least: 4.0
8
  Tested up to: 4.1.1
9
- Version: 2.3.1
10
  Author: Sidekick.pro
11
  Author URI: http://www.sidekick.pro
12
  */
@@ -17,7 +17,7 @@ if ( ! defined( 'PLAYER_PATH' ) ) define( 'PLAYER_PATH', 'tag/latest' );
17
  if ( ! defined( 'PLAYER_FILE' ) ) define( 'PLAYER_FILE', 'sidekick.min.js' );
18
  if ( ! defined( 'COMPOSER_DOMAIN' ) ) define( 'COMPOSER_DOMAIN', 'composer.sidekick.pro' );
19
  if ( ! defined( 'COMPOSER_PATH' ) ) define( 'COMPOSER_PATH', 'tag/latest' );
20
- if ( ! defined( 'SK_EMBED_PARTNER' ) ) define( 'SK_EMBED_PARTNER', '' );
21
 
22
  if ( ! function_exists('mlog')) {
23
  function mlog(){}
@@ -50,9 +50,14 @@ if (!class_exists('Sidekick')){
50
  }
51
 
52
  function enqueue(){
53
- wp_enqueue_script('sidekick' ,"//" . PLAYER_DOMAIN ."/" . PLAYER_PATH . "/" . PLAYER_FILE, array('backbone','jquery','underscore','jquery-effects-highlight'),null);
54
- wp_enqueue_style('wp-pointer');
55
- wp_enqueue_script('wp-pointer');
 
 
 
 
 
56
  }
57
 
58
  function setup_menu(){
@@ -295,7 +300,7 @@ if (!class_exists('Sidekick')){
295
  disable_wts: <?php echo $disabled_wts ?>,
296
  disable_network_wts: <?php echo $disabled_network_wts ?>,
297
  main_soft_name: 'WordPress',
298
- embeded: false,
299
 
300
  // User Settings
301
  activation_id: '<?php echo $activation_id ?>',
@@ -319,15 +324,15 @@ if (!class_exists('Sidekick')){
319
  hide_taskbar_config_button: <?php echo ($sk_hide_config_taskbar_button ? "true" : "false") ?>,
320
 
321
  // Platform Info
322
- library_version: 2,
323
- platform_id: 1,
324
- embed_partner: '<?php echo SK_EMBED_PARTNER ?>',
325
 
326
  // Generic Info
327
  just_activated: <?php echo ($sk_just_activated) ? "true" : "false" ?>,
328
  show_login: <?php echo ($sk_just_activated) ? "true" : "false" ?>,
329
  platform_version: null,
330
- plugin_version: '2.3.1',
331
 
332
  // SIDEKICK URLS
333
  assets: '<?php echo SK_ASSETS ?>',
@@ -346,6 +351,10 @@ if (!class_exists('Sidekick')){
346
  current_url: '<?php echo $current_url ?>'
347
  }
348
 
 
 
 
 
349
  var skc_config = {
350
  audioPlaceholderUrl: '<?php echo SK_ASSETS ?>walkthrough-audio-placeholder.mp3',
351
  audioBaseUrl: '<?php echo SK_AUDIO ?>',
@@ -426,7 +435,7 @@ if (!class_exists('Sidekick')){
426
  function check_ver(){
427
 
428
  if (isset($_GET['sk_ver_check'])){
429
- $data = json_encode('2.3.1');
430
 
431
  if(array_key_exists('callback', $_GET)){
432
 
@@ -503,15 +512,15 @@ if (!class_exists('Sidekick')){
503
  add_action('wp_ajax_sk_save', array($sidekick,'ajax_save'));
504
  add_action('admin_notices', array($sidekick,'admin_notice'));
505
 
506
- if (!defined('SK_PLUGIN_DEGBUG')){
507
- require_once('sk_init.php');
508
- }
509
-
510
- if (!(isset($_GET['tab']) && $_GET['tab'] == 'plugin-information') && !defined('IFRAME_REQUEST')) {
511
- add_action('admin_footer', array($sidekick,'footer'));
512
  add_action('customize_controls_print_footer_scripts', array($sidekick,'footer'));
 
 
 
 
513
  }
514
-
515
  // Not working right now
516
  // add_action('transition_post_status',array($sidekick,'delete_sk_get_post_types_and_statuses'));
517
  // add_action('clean_post_cache',array($sidekick,'delete_sk_get_post_types_and_statuses'));
6
  Description: Adds a real-time WordPress training walkthroughs right in your Dashboard
7
  Requires at least: 4.0
8
  Tested up to: 4.1.1
9
+ Version: 2.4.0
10
  Author: Sidekick.pro
11
  Author URI: http://www.sidekick.pro
12
  */
17
  if ( ! defined( 'PLAYER_FILE' ) ) define( 'PLAYER_FILE', 'sidekick.min.js' );
18
  if ( ! defined( 'COMPOSER_DOMAIN' ) ) define( 'COMPOSER_DOMAIN', 'composer.sidekick.pro' );
19
  if ( ! defined( 'COMPOSER_PATH' ) ) define( 'COMPOSER_PATH', 'tag/latest' );
20
+ if ( ! defined( 'SK_EMBEDDED_PARTNER' ) ) define( 'SK_EMBEDDED_PARTNER', '' );
21
 
22
  if ( ! function_exists('mlog')) {
23
  function mlog(){}
50
  }
51
 
52
  function enqueue(){
53
+ $prod_build = apply_filters( 'sk_build', true );
54
+ if ($prod_build) {
55
+ wp_enqueue_script('sidekick' ,"//" . PLAYER_DOMAIN ."/" . PLAYER_PATH . "/" . PLAYER_FILE, array('backbone','jquery','underscore','jquery-effects-highlight'),null);
56
+ wp_enqueue_style('wp-pointer');
57
+ wp_enqueue_script('wp-pointer');
58
+ } else {
59
+ do_action( 'sk_enqueue' );
60
+ }
61
  }
62
 
63
  function setup_menu(){
300
  disable_wts: <?php echo $disabled_wts ?>,
301
  disable_network_wts: <?php echo $disabled_network_wts ?>,
302
  main_soft_name: 'WordPress',
303
+ embedded: false,
304
 
305
  // User Settings
306
  activation_id: '<?php echo $activation_id ?>',
324
  hide_taskbar_config_button: <?php echo ($sk_hide_config_taskbar_button ? "true" : "false") ?>,
325
 
326
  // Platform Info
327
+ library_version: 2,
328
+ platform_id: 1,
329
+ embedded_partner: '<?php echo SK_EMBEDDED_PARTNER ?>', // Track the emb
330
 
331
  // Generic Info
332
  just_activated: <?php echo ($sk_just_activated) ? "true" : "false" ?>,
333
  show_login: <?php echo ($sk_just_activated) ? "true" : "false" ?>,
334
  platform_version: null,
335
+ plugin_version: '2.4.0',
336
 
337
  // SIDEKICK URLS
338
  assets: '<?php echo SK_ASSETS ?>',
351
  current_url: '<?php echo $current_url ?>'
352
  }
353
 
354
+ sk_config.onBeforePlay = [
355
+ {path: 'a.customize-controls-close,a.media-modal-close', event: 'click'}
356
+ ];
357
+
358
  var skc_config = {
359
  audioPlaceholderUrl: '<?php echo SK_ASSETS ?>walkthrough-audio-placeholder.mp3',
360
  audioBaseUrl: '<?php echo SK_AUDIO ?>',
435
  function check_ver(){
436
 
437
  if (isset($_GET['sk_ver_check'])){
438
+ $data = json_encode('2.4.0');
439
 
440
  if(array_key_exists('callback', $_GET)){
441
 
512
  add_action('wp_ajax_sk_save', array($sidekick,'ajax_save'));
513
  add_action('admin_notices', array($sidekick,'admin_notice'));
514
 
515
+ if (!(isset($_GET['tab']) && $_GET['tab'] == 'plugin-information')) {
516
+ add_action('admin_footer', array($sidekick,'footer'));
 
 
 
 
517
  add_action('customize_controls_print_footer_scripts', array($sidekick,'footer'));
518
+ add_action('admin_enqueue_scripts', array($sidekick,'enqueue'));
519
+ add_action('admin_enqueue_scripts', array($sidekick,'enqueue_required'));
520
+ add_action('customize_controls_enqueue_scripts', array($sidekick,'enqueue'),1000);
521
+ add_action('customize_controls_enqueue_scripts', array($sidekick,'enqueue_required'),1000);
522
  }
523
+
524
  // Not working right now
525
  // add_action('transition_post_status',array($sidekick,'delete_sk_get_post_types_and_statuses'));
526
  // add_action('clean_post_cache',array($sidekick,'delete_sk_get_post_types_and_statuses'));
sidekick_embed.php CHANGED
@@ -8,7 +8,7 @@ Description: Adds a real-time WordPress training walkthroughs right in your Dash
8
  We recommend not activating SIDEKICK automatically for people but via an Opt-In process when they configure your own theme or plugin.
9
  Requires at least: 4.0
10
  Tested up to: 4.1.1
11
- Version: 2.3.1
12
  Author: Sidekick.pro
13
  Author URI: http://www.sidekick.pro
14
  */
@@ -19,7 +19,7 @@ if ( ! defined( 'PLAYER_PATH' ) ) define( 'PLAYER_PATH', 'tag/latest' );
19
  if ( ! defined( 'PLAYER_FILE' ) ) define( 'PLAYER_FILE', 'sidekick.min.js' );
20
  if ( ! defined( 'COMPOSER_DOMAIN' ) ) define( 'COMPOSER_DOMAIN', 'composer.sidekick.pro' );
21
  if ( ! defined( 'COMPOSER_PATH' ) ) define( 'COMPOSER_PATH', 'tag/latest' );
22
- if ( ! defined( 'SK_EMBED_PARTNER' ) ) define( 'SK_EMBED_PARTNER', '' );
23
 
24
  if ( ! function_exists('mlog')) {
25
  function mlog(){}
@@ -55,9 +55,14 @@ if (!$sidekick_active && !class_exists('Sidekick')){
55
  }
56
 
57
  function enqueue(){
58
- wp_enqueue_script('sidekick' ,"//" . PLAYER_DOMAIN ."/" . PLAYER_PATH . "/" . PLAYER_FILE, array('backbone','jquery','underscore','jquery-effects-highlight'),null);
59
- wp_enqueue_style('wp-pointer');
60
- wp_enqueue_script('wp-pointer');
 
 
 
 
 
61
  }
62
 
63
  function setup_menu(){
@@ -558,7 +563,7 @@ if (!$sidekick_active && !class_exists('Sidekick')){
558
  disable_wts: <?php echo $disabled_wts ?>,
559
  disable_network_wts: <?php echo $disabled_network_wts ?>,
560
  main_soft_name: 'WordPress',
561
- embeded: true,
562
 
563
  // User Settings
564
  activation_id: '<?php echo $activation_id ?>',
@@ -582,15 +587,15 @@ if (!$sidekick_active && !class_exists('Sidekick')){
582
  hide_taskbar_config_button: <?php echo ($sk_hide_config_taskbar_button ? "true" : "false") ?>,
583
 
584
  // Platform Info
585
- library_version: 2,
586
- platform_id: 1,
587
- embed_partner: '<?php echo SK_EMBED_PARTNER ?>',
588
 
589
  // Generic Info
590
  just_activated: <?php echo ($sk_just_activated) ? "true" : "false" ?>,
591
  show_login: <?php echo ($sk_just_activated) ? "true" : "false" ?>,
592
  platform_version: null,
593
- plugin_version: '2.3.1',
594
 
595
  // SIDEKICK URLS
596
  assets: '<?php echo SK_ASSETS ?>',
@@ -609,6 +614,10 @@ if (!$sidekick_active && !class_exists('Sidekick')){
609
  current_url: '<?php echo $current_url ?>'
610
  }
611
 
 
 
 
 
612
  var skc_config = {
613
  audioPlaceholderUrl: '<?php echo SK_ASSETS ?>walkthrough-audio-placeholder.mp3',
614
  audioBaseUrl: '<?php echo SK_AUDIO ?>',
@@ -689,7 +698,7 @@ if (!$sidekick_active && !class_exists('Sidekick')){
689
  function check_ver(){
690
 
691
  if (isset($_GET['sk_ver_check'])){
692
- $data = json_encode('2.3.1');
693
 
694
  if(array_key_exists('callback', $_GET)){
695
 
@@ -766,32 +775,15 @@ if (!$sidekick_active && !class_exists('Sidekick')){
766
  add_action('wp_ajax_sk_save', array($sidekick,'ajax_save'));
767
  add_action('admin_notices', array($sidekick,'admin_notice'));
768
 
769
- {
770
-
771
-
772
- if (defined('SK_PLUGIN_DEGBUG')) {
773
- // mlog('PHP: Sidekick run debug class');
774
- $sidekick = new SidekickDev;
775
- }
776
-
777
- if (!(isset($_GET['tab']) && $_GET['tab'] == 'plugin-information') && !defined('IFRAME_REQUEST')) {
778
- add_action('admin_enqueue_scripts', array($sidekick,'enqueue'));
779
- add_action('admin_enqueue_scripts', array($sidekick,'enqueue_required'));
780
- add_action('customize_controls_enqueue_scripts', array($sidekick,'enqueue'));
781
-
782
- if (defined('SK_PLUGIN_DEGBUG')) {
783
- add_action('admin_footer', array($sidekick,'footer_dev'));
784
- add_action('customize_controls_print_footer_scripts', array($sidekick,'footer_dev'));
785
- }
786
- }
787
-
788
- }
789
-
790
- if (!(isset($_GET['tab']) && $_GET['tab'] == 'plugin-information') && !defined('IFRAME_REQUEST')) {
791
- add_action('admin_footer', array($sidekick,'footer'));
792
  add_action('customize_controls_print_footer_scripts', array($sidekick,'footer'));
 
 
 
 
793
  }
794
-
795
  // Not working right now
796
  // add_action('transition_post_status',array($sidekick,'delete_sk_get_post_types_and_statuses'));
797
  // add_action('clean_post_cache',array($sidekick,'delete_sk_get_post_types_and_statuses'));
8
  We recommend not activating SIDEKICK automatically for people but via an Opt-In process when they configure your own theme or plugin.
9
  Requires at least: 4.0
10
  Tested up to: 4.1.1
11
+ Version: 2.4.0
12
  Author: Sidekick.pro
13
  Author URI: http://www.sidekick.pro
14
  */
19
  if ( ! defined( 'PLAYER_FILE' ) ) define( 'PLAYER_FILE', 'sidekick.min.js' );
20
  if ( ! defined( 'COMPOSER_DOMAIN' ) ) define( 'COMPOSER_DOMAIN', 'composer.sidekick.pro' );
21
  if ( ! defined( 'COMPOSER_PATH' ) ) define( 'COMPOSER_PATH', 'tag/latest' );
22
+ if ( ! defined( 'SK_EMBEDDED_PARTNER' ) ) define( 'SK_EMBEDDED_PARTNER', '' );
23
 
24
  if ( ! function_exists('mlog')) {
25
  function mlog(){}
55
  }
56
 
57
  function enqueue(){
58
+ $prod_build = apply_filters( 'sk_build', true );
59
+ if ($prod_build) {
60
+ wp_enqueue_script('sidekick' ,"//" . PLAYER_DOMAIN ."/" . PLAYER_PATH . "/" . PLAYER_FILE, array('backbone','jquery','underscore','jquery-effects-highlight'),null);
61
+ wp_enqueue_style('wp-pointer');
62
+ wp_enqueue_script('wp-pointer');
63
+ } else {
64
+ do_action( 'sk_enqueue' );
65
+ }
66
  }
67
 
68
  function setup_menu(){
563
  disable_wts: <?php echo $disabled_wts ?>,
564
  disable_network_wts: <?php echo $disabled_network_wts ?>,
565
  main_soft_name: 'WordPress',
566
+ embedded: false,
567
 
568
  // User Settings
569
  activation_id: '<?php echo $activation_id ?>',
587
  hide_taskbar_config_button: <?php echo ($sk_hide_config_taskbar_button ? "true" : "false") ?>,
588
 
589
  // Platform Info
590
+ library_version: 2,
591
+ platform_id: 1,
592
+ embedded_partner: '<?php echo SK_EMBEDDED_PARTNER ?>', // Track the emb
593
 
594
  // Generic Info
595
  just_activated: <?php echo ($sk_just_activated) ? "true" : "false" ?>,
596
  show_login: <?php echo ($sk_just_activated) ? "true" : "false" ?>,
597
  platform_version: null,
598
+ plugin_version: '2.4.0',
599
 
600
  // SIDEKICK URLS
601
  assets: '<?php echo SK_ASSETS ?>',
614
  current_url: '<?php echo $current_url ?>'
615
  }
616
 
617
+ sk_config.onBeforePlay = [
618
+ {path: 'a.customize-controls-close,a.media-modal-close', event: 'click'}
619
+ ];
620
+
621
  var skc_config = {
622
  audioPlaceholderUrl: '<?php echo SK_ASSETS ?>walkthrough-audio-placeholder.mp3',
623
  audioBaseUrl: '<?php echo SK_AUDIO ?>',
698
  function check_ver(){
699
 
700
  if (isset($_GET['sk_ver_check'])){
701
+ $data = json_encode('2.4.0');
702
 
703
  if(array_key_exists('callback', $_GET)){
704
 
775
  add_action('wp_ajax_sk_save', array($sidekick,'ajax_save'));
776
  add_action('admin_notices', array($sidekick,'admin_notice'));
777
 
778
+ if (!(isset($_GET['tab']) && $_GET['tab'] == 'plugin-information')) {
779
+ add_action('admin_footer', array($sidekick,'footer'));
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
780
  add_action('customize_controls_print_footer_scripts', array($sidekick,'footer'));
781
+ add_action('admin_enqueue_scripts', array($sidekick,'enqueue'));
782
+ add_action('admin_enqueue_scripts', array($sidekick,'enqueue_required'));
783
+ add_action('customize_controls_enqueue_scripts', array($sidekick,'enqueue'),1000);
784
+ add_action('customize_controls_enqueue_scripts', array($sidekick,'enqueue_required'),1000);
785
  }
786
+
787
  // Not working right now
788
  // add_action('transition_post_status',array($sidekick,'delete_sk_get_post_types_and_statuses'));
789
  // add_action('clean_post_cache',array($sidekick,'delete_sk_get_post_types_and_statuses'));
sk_init.php DELETED
@@ -1,17 +0,0 @@
1
- <?php
2
-
3
- if (defined('SK_PLUGIN_DEGBUG')) {
4
- // mlog('PHP: Sidekick run debug class');
5
- $sidekick = new SidekickDev;
6
- }
7
-
8
- if (!(isset($_GET['tab']) && $_GET['tab'] == 'plugin-information') && !defined('IFRAME_REQUEST')) {
9
- add_action('admin_enqueue_scripts', array($sidekick,'enqueue'));
10
- add_action('admin_enqueue_scripts', array($sidekick,'enqueue_required'));
11
- add_action('customize_controls_enqueue_scripts', array($sidekick,'enqueue'));
12
-
13
- if (defined('SK_PLUGIN_DEGBUG')) {
14
- add_action('admin_footer', array($sidekick,'footer_dev'));
15
- add_action('customize_controls_print_footer_scripts', array($sidekick,'footer_dev'));
16
- }
17
- }