PowerPack Addons for Elementor (Instagram Feed, Pricing Table, Forms Stylers, Display Conditions, Free Elementor Widgets and Elementor Templates) - Version 2.2.1

Version Description

  • November 2, 2020 =
  • Fixed: Instagram Feed - Feed was not working
Download this release

Release Info

Developer ideaboxcreations
Plugin Icon 128x128 PowerPack Addons for Elementor (Instagram Feed, Pricing Table, Forms Stylers, Display Conditions, Free Elementor Widgets and Elementor Templates)
Version 2.2.1
Comparing to
See all releases

Code changes from version 2.2.0 to 2.2.1

Files changed (5) hide show
  1. changelog.txt +4 -0
  2. package.json +1 -1
  3. plugin.php +43 -32
  4. powerpack-lite-elementor.php +2 -2
  5. readme.txt +3 -0
changelog.txt CHANGED
@@ -1,3 +1,7 @@
 
 
 
 
1
  == 2.2.0 ==
2
  Release date: October 27, 2020
3
  * New: Added page templates in PowerPack Template Library
1
+ == 2.2.1 ==
2
+ Release date: November 2, 2020
3
+ * Fixed: Instagram Feed - Feed was not working
4
+
5
  == 2.2.0 ==
6
  Release date: October 27, 2020
7
  * New: Added page templates in PowerPack Template Library
package.json CHANGED
@@ -1,6 +1,6 @@
1
  {
2
  "name": "powerpack-lite-for-elementor",
3
- "version": "2.2.0",
4
  "description": "Extend Elementor Page Builder with 50+ Creative Widgets.",
5
  "keywords": [],
6
  "author": "IdeaBox Creations",
1
  {
2
  "name": "powerpack-lite-for-elementor",
3
+ "version": "2.2.1",
4
  "description": "Extend Elementor Page Builder with 50+ Creative Widgets.",
5
  "keywords": [],
6
  "author": "IdeaBox Creations",
plugin.php CHANGED
@@ -4,7 +4,8 @@ namespace PowerpackElementsLite;
4
  use Elementor\Utils;
5
  use PowerpackElementsLite\Classes\PP_Config;
6
 
7
- if ( ! defined( 'ABSPATH' ) ) { exit; } // Exit if accessed directly
 
8
 
9
  /**
10
  * Main class plugin
@@ -94,7 +95,7 @@ class PowerpackLitePlugin {
94
  $filename = POWERPACK_ELEMENTS_LITE_PATH . $filename . '.php';
95
 
96
  if ( is_readable( $filename ) ) {
97
- include( $filename );
98
  }
99
  }
100
 
@@ -118,7 +119,7 @@ class PowerpackLitePlugin {
118
  $this->_localize_settings[ $setting_key ] = array_replace_recursive( $this->_localize_settings[ $setting_key ], $setting_value );
119
  }
120
 
121
- /**
122
  * Enqueue frontend styles
123
  *
124
  * @since 1.3.3
@@ -132,22 +133,22 @@ class PowerpackLitePlugin {
132
  [],
133
  POWERPACK_ELEMENTS_LITE_VER
134
  );
135
-
136
  wp_register_style(
137
  'odometer',
138
  POWERPACK_ELEMENTS_LITE_URL . 'assets/lib/odometer/odometer-theme-default.css',
139
  [],
140
  POWERPACK_ELEMENTS_LITE_VER
141
  );
142
-
143
  wp_register_style(
144
  'twentytwenty',
145
  POWERPACK_ELEMENTS_LITE_URL . 'assets/lib/twentytwenty/twentytwenty.css',
146
  [],
147
  POWERPACK_ELEMENTS_LITE_VER
148
  );
149
-
150
- if ( class_exists( 'GFCommon' ) ) {
151
  $gf_forms = \RGFormsModel::get_forms( null, 'title' );
152
  foreach ( $gf_forms as $form ) {
153
  if ( '0' !== $form->id ) {
@@ -157,12 +158,12 @@ class PowerpackLitePlugin {
157
  }
158
  }
159
 
160
- if ( function_exists( 'wpforms' ) ) {
161
- wpforms()->frontend->assets_css();
162
- }
163
  }
164
 
165
- /**
166
  * Enqueue frontend scripts
167
  *
168
  * @since 1.3.3
@@ -170,7 +171,7 @@ class PowerpackLitePlugin {
170
  * @access public
171
  */
172
  public function enqueue_frontend_scripts() {
173
- $settings = \PowerpackElementsLite\Classes\PP_Admin_Settings::get_settings();
174
  $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
175
 
176
  wp_register_script(
@@ -193,6 +194,16 @@ class PowerpackLitePlugin {
193
  true
194
  );
195
 
 
 
 
 
 
 
 
 
 
 
196
  wp_register_script(
197
  'twentytwenty',
198
  POWERPACK_ELEMENTS_LITE_URL . 'assets/lib/twentytwenty/jquery.twentytwenty.js',
@@ -311,7 +322,7 @@ class PowerpackLitePlugin {
311
  wp_localize_script( 'jquery', 'pp', $pp_localize );
312
  }
313
 
314
- /**
315
  * Enqueue editor styles
316
  *
317
  * @since 1.3.3
@@ -325,7 +336,7 @@ class PowerpackLitePlugin {
325
  [],
326
  POWERPACK_ELEMENTS_LITE_VER
327
  );
328
-
329
  wp_enqueue_style(
330
  'powerpack-icons',
331
  POWERPACK_ELEMENTS_LITE_URL . 'assets/lib/ppicons/css/powerpack-icons.css',
@@ -334,7 +345,7 @@ class PowerpackLitePlugin {
334
  );
335
  }
336
 
337
- /**
338
  * Enqueue editor scripts
339
  *
340
  * @since 1.3.3
@@ -351,7 +362,7 @@ class PowerpackLitePlugin {
351
  POWERPACK_ELEMENTS_LITE_VER,
352
  true
353
  );
354
-
355
  wp_enqueue_script(
356
  'magnific-popup',
357
  POWERPACK_ELEMENTS_LITE_URL . 'assets/lib/magnific-popup/jquery.magnific-popup.min.js',
@@ -367,7 +378,7 @@ class PowerpackLitePlugin {
367
 
368
  public function enqueue_editor_preview_styles() {
369
  $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
370
-
371
  wp_enqueue_style( 'odometer' );
372
  wp_enqueue_style( 'twentytwenty' );
373
  }
@@ -416,26 +427,26 @@ class PowerpackLitePlugin {
416
  );
417
  }
418
 
419
- public function get_promotion_widgets($config) {
420
 
421
- if (is_pp_elements_active()) {
422
- return $config;
423
- }
424
 
425
- $promotion_widgets = [];
426
 
427
- if (isset($config['promotionWidgets'])) {
428
- $promotion_widgets = $config['promotionWidgets'];
429
- }
430
 
431
  $pro_widgets = PP_Config::get_pro_widgets();
432
 
433
- $combine_array = array_merge($promotion_widgets, $pro_widgets);
434
 
435
- $config['promotionWidgets'] = $combine_array;
436
 
437
- return $config;
438
- }
439
 
440
  protected function add_actions() {
441
  add_action( 'elementor/init', [ $this, 'elementor_init' ] );
@@ -444,14 +455,14 @@ class PowerpackLitePlugin {
444
  add_action( 'elementor/controls/controls_registered', [ $this, 'include_group_controls' ] );
445
 
446
  add_action( 'elementor/editor/after_enqueue_scripts', [ $this, 'enqueue_editor_scripts' ] );
447
- add_action( 'elementor/editor/after_enqueue_styles', [ $this, 'enqueue_editor_styles' ] );
448
 
449
- add_action( 'elementor/preview/enqueue_styles', [ $this, 'enqueue_editor_preview_styles' ] );
450
 
451
  add_action( 'elementor/frontend/after_register_scripts', [ $this, 'enqueue_frontend_scripts' ] );
452
  add_action( 'elementor/frontend/after_enqueue_styles', [ $this, 'enqueue_frontend_styles' ] );
453
 
454
- add_filter('elementor/editor/localize_settings', [$this, 'get_promotion_widgets']);
455
  }
456
 
457
  /**
4
  use Elementor\Utils;
5
  use PowerpackElementsLite\Classes\PP_Config;
6
 
7
+ if ( ! defined( 'ABSPATH' ) ) {
8
+ exit; } // Exit if accessed directly
9
 
10
  /**
11
  * Main class plugin
95
  $filename = POWERPACK_ELEMENTS_LITE_PATH . $filename . '.php';
96
 
97
  if ( is_readable( $filename ) ) {
98
+ include $filename;
99
  }
100
  }
101
 
119
  $this->_localize_settings[ $setting_key ] = array_replace_recursive( $this->_localize_settings[ $setting_key ], $setting_value );
120
  }
121
 
122
+ /**
123
  * Enqueue frontend styles
124
  *
125
  * @since 1.3.3
133
  [],
134
  POWERPACK_ELEMENTS_LITE_VER
135
  );
136
+
137
  wp_register_style(
138
  'odometer',
139
  POWERPACK_ELEMENTS_LITE_URL . 'assets/lib/odometer/odometer-theme-default.css',
140
  [],
141
  POWERPACK_ELEMENTS_LITE_VER
142
  );
143
+
144
  wp_register_style(
145
  'twentytwenty',
146
  POWERPACK_ELEMENTS_LITE_URL . 'assets/lib/twentytwenty/twentytwenty.css',
147
  [],
148
  POWERPACK_ELEMENTS_LITE_VER
149
  );
150
+
151
+ if ( class_exists( 'GFCommon' ) ) {
152
  $gf_forms = \RGFormsModel::get_forms( null, 'title' );
153
  foreach ( $gf_forms as $form ) {
154
  if ( '0' !== $form->id ) {
158
  }
159
  }
160
 
161
+ if ( function_exists( 'wpforms' ) ) {
162
+ wpforms()->frontend->assets_css();
163
+ }
164
  }
165
 
166
+ /**
167
  * Enqueue frontend scripts
168
  *
169
  * @since 1.3.3
171
  * @access public
172
  */
173
  public function enqueue_frontend_scripts() {
174
+ $settings = \PowerpackElementsLite\Classes\PP_Admin_Settings::get_settings();
175
  $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
176
 
177
  wp_register_script(
194
  true
195
  );
196
 
197
+ wp_localize_script(
198
+ 'pp-instagram',
199
+ 'ppInsta',
200
+ array(
201
+ 'invalid_username' => __( 'The <b>username</b> added is not a valid Instagram Username. Check browser console for more details.', 'powerpack' ),
202
+ 'private_account' => __( 'This account is private.', 'powerpack' ),
203
+ 'no_images' => __( 'No <i>images</i> were found in the Instagram profile for <b>', 'powerpack' ),
204
+ )
205
+ );
206
+
207
  wp_register_script(
208
  'twentytwenty',
209
  POWERPACK_ELEMENTS_LITE_URL . 'assets/lib/twentytwenty/jquery.twentytwenty.js',
322
  wp_localize_script( 'jquery', 'pp', $pp_localize );
323
  }
324
 
325
+ /**
326
  * Enqueue editor styles
327
  *
328
  * @since 1.3.3
336
  [],
337
  POWERPACK_ELEMENTS_LITE_VER
338
  );
339
+
340
  wp_enqueue_style(
341
  'powerpack-icons',
342
  POWERPACK_ELEMENTS_LITE_URL . 'assets/lib/ppicons/css/powerpack-icons.css',
345
  );
346
  }
347
 
348
+ /**
349
  * Enqueue editor scripts
350
  *
351
  * @since 1.3.3
362
  POWERPACK_ELEMENTS_LITE_VER,
363
  true
364
  );
365
+
366
  wp_enqueue_script(
367
  'magnific-popup',
368
  POWERPACK_ELEMENTS_LITE_URL . 'assets/lib/magnific-popup/jquery.magnific-popup.min.js',
378
 
379
  public function enqueue_editor_preview_styles() {
380
  $suffix = defined( 'SCRIPT_DEBUG' ) && SCRIPT_DEBUG ? '' : '.min';
381
+
382
  wp_enqueue_style( 'odometer' );
383
  wp_enqueue_style( 'twentytwenty' );
384
  }
427
  );
428
  }
429
 
430
+ public function get_promotion_widgets( $config ) {
431
 
432
+ if ( is_pp_elements_active() ) {
433
+ return $config;
434
+ }
435
 
436
+ $promotion_widgets = [];
437
 
438
+ if ( isset( $config['promotionWidgets'] ) ) {
439
+ $promotion_widgets = $config['promotionWidgets'];
440
+ }
441
 
442
  $pro_widgets = PP_Config::get_pro_widgets();
443
 
444
+ $combine_array = array_merge( $promotion_widgets, $pro_widgets );
445
 
446
+ $config['promotionWidgets'] = $combine_array;
447
 
448
+ return $config;
449
+ }
450
 
451
  protected function add_actions() {
452
  add_action( 'elementor/init', [ $this, 'elementor_init' ] );
455
  add_action( 'elementor/controls/controls_registered', [ $this, 'include_group_controls' ] );
456
 
457
  add_action( 'elementor/editor/after_enqueue_scripts', [ $this, 'enqueue_editor_scripts' ] );
458
+ add_action( 'elementor/editor/after_enqueue_styles', [ $this, 'enqueue_editor_styles' ] );
459
 
460
+ add_action( 'elementor/preview/enqueue_styles', [ $this, 'enqueue_editor_preview_styles' ] );
461
 
462
  add_action( 'elementor/frontend/after_register_scripts', [ $this, 'enqueue_frontend_scripts' ] );
463
  add_action( 'elementor/frontend/after_enqueue_styles', [ $this, 'enqueue_frontend_styles' ] );
464
 
465
+ add_filter( 'elementor/editor/localize_settings', [ $this, 'get_promotion_widgets' ] );
466
  }
467
 
468
  /**
powerpack-lite-elementor.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: PowerPack Lite for Elementor
4
  * Plugin URI: https://powerpackelements.com
5
  * Description: Custom addons for Elementor page builder.
6
- * Version: 2.2.0
7
  * Author: IdeaBox Creations
8
  * Author URI: http://ideabox.io/
9
  * License: GNU General Public License v2.0
@@ -14,7 +14,7 @@
14
 
15
  if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
16
 
17
- define( 'POWERPACK_ELEMENTS_LITE_VER', '2.2.0' );
18
  define( 'POWERPACK_ELEMENTS_LITE_PATH', plugin_dir_path( __FILE__ ) );
19
  define( 'POWERPACK_ELEMENTS_LITE_BASE', plugin_basename( __FILE__ ) );
20
  define( 'POWERPACK_ELEMENTS_LITE_URL', plugins_url( '/', __FILE__ ) );
3
  * Plugin Name: PowerPack Lite for Elementor
4
  * Plugin URI: https://powerpackelements.com
5
  * Description: Custom addons for Elementor page builder.
6
+ * Version: 2.2.1
7
  * Author: IdeaBox Creations
8
  * Author URI: http://ideabox.io/
9
  * License: GNU General Public License v2.0
14
 
15
  if ( ! defined( 'ABSPATH' ) ) exit; // Exit if accessed directly
16
 
17
+ define( 'POWERPACK_ELEMENTS_LITE_VER', '2.2.1' );
18
  define( 'POWERPACK_ELEMENTS_LITE_PATH', plugin_dir_path( __FILE__ ) );
19
  define( 'POWERPACK_ELEMENTS_LITE_BASE', plugin_basename( __FILE__ ) );
20
  define( 'POWERPACK_ELEMENTS_LITE_URL', plugins_url( '/', __FILE__ ) );
readme.txt CHANGED
@@ -206,6 +206,9 @@ Not at all! All the widgets and settings are easy to use with drag & drop interf
206
 
207
  == Changelog ==
208
 
 
 
 
209
  = 2.2.0 - October 27, 2020 =
210
  * New: Added page templates in PowerPack Template Library
211
  * Fixed: Flip Box - Link was not working if fade effect is selected
206
 
207
  == Changelog ==
208
 
209
+ = 2.2.1 - November 2, 2020 =
210
+ * Fixed: Instagram Feed - Feed was not working
211
+
212
  = 2.2.0 - October 27, 2020 =
213
  * New: Added page templates in PowerPack Template Library
214
  * Fixed: Flip Box - Link was not working if fade effect is selected