Premium Portfolio Features for Phlox theme - Version 1.7.7

Version Description

Download this release

Release Info

Developer averta
Plugin Icon 128x128 Premium Portfolio Features for Phlox theme
Version 1.7.7
Comparing to
See all releases

Code changes from version 1.7.5 to 1.7.7

README.txt CHANGED
@@ -6,8 +6,8 @@ License URI: http://www.gnu.org/licenses/gpl.html
6
  Tags: phlox, gallery, elementor, siteorigin, portfolio, averta, auxin, fullwidth, masonry, timeline, projects, showcase, minimal, wix, flat
7
  Requires PHP: 5.4
8
  Requires at least: 4.6
9
- Tested up to: 4.9.8
10
- Stable tag: 1.7.5
11
  License: GPLv3
12
  License URI: http://www.gnu.org/licenses/gpl.html
13
 
@@ -136,6 +136,10 @@ Bugs can be reported in our [support forums](http://support.averta.net/en/item/p
136
 
137
  == Changelog ==
138
 
 
 
 
 
139
  = Version 1.7.5 / (14.11.2018) =
140
  - [Fix]: Introducing new portfolio element and new filter options.
141
  - [Fix]: Minor bugs fixed.
@@ -232,6 +236,6 @@ Bugs can be reported in our [support forums](http://support.averta.net/en/item/p
232
 
233
  == Upgrade Notice ==
234
 
235
- = 1.7.5 =
236
- - [Fix]: Introducing new portfolio element and new filter options.
237
- - [Fix]: Minor bugs fixed.
6
  Tags: phlox, gallery, elementor, siteorigin, portfolio, averta, auxin, fullwidth, masonry, timeline, projects, showcase, minimal, wix, flat
7
  Requires PHP: 5.4
8
  Requires at least: 4.6
9
+ Tested up to: 5.0.2
10
+ Stable tag: 1.7.7
11
  License: GPLv3
12
  License URI: http://www.gnu.org/licenses/gpl.html
13
 
136
 
137
  == Changelog ==
138
 
139
+ = Version 1.7.7 / (23.12.2018) =
140
+ - [Improvement]: Improvement in Ajax options.
141
+ - [Fix]: Minor bugs fixed.
142
+
143
  = Version 1.7.5 / (14.11.2018) =
144
  - [Fix]: Introducing new portfolio element and new filter options.
145
  - [Fix]: Minor bugs fixed.
236
 
237
  == Upgrade Notice ==
238
 
239
+ = 1.7.7 =
240
+ - [Improvement]: Improvement in Ajax options.
241
+ - [Fix]: Minor bugs fixed.
admin/includes/metaboxes/metabox-fields-portfolio-related.php CHANGED
@@ -255,7 +255,7 @@ function auxpfo_metabox_fields_portfolio_related_metadata(){
255
  ),
256
  ),
257
  'type' => 'text',
258
- 'default' => __( "Browse All Projects", 'auxin-portfolio' ),
259
  ),
260
 
261
  );
255
  ),
256
  ),
257
  'type' => 'text',
258
+ 'default' => ''
259
  ),
260
 
261
  );
auxin-portfolio.php CHANGED
@@ -12,7 +12,7 @@
12
  * Plugin Name: Phlox Portfolio
13
  * Plugin URI: http://phlox.pro/
14
  * Description: Showcase your projects beautifully in Phlox theme
15
- * Version: 1.7.5
16
  * Author: averta
17
  * Author URI: http://averta.net
18
  * License: GPL2
@@ -37,7 +37,10 @@ if ( defined( 'WP_INSTALLING' ) && WP_INSTALLING ) {
37
  * ===========================================================================*/
38
 
39
  // Don't check the requirements if it's frontend or AUXIN_DUBUG set to false
40
- if( is_admin() || false === get_transient( 'auxpfo_plugin_requirements_check' ) ){
 
 
 
41
 
42
  if( ! class_exists( 'Auxin_Plugin_Requirements' ) ){
43
  require_once( plugin_dir_path( __FILE__ ) . 'includes/classes/class-auxin-plugin-requirements.php' );
@@ -51,7 +54,7 @@ if( is_admin() || false === get_transient( 'auxpfo_plugin_requirements_check' )
51
  'name' => __('Phlox Core Elements', 'auxin-portfolio'), // The plugin name.
52
  'basename' => 'auxin-elements/auxin-elements.php', // The plugin basename (typically the folder name and main php file)
53
  'required' => true, // If true, the user will be notified with a notice to install the plugin.
54
- 'version' => '2.3.0', // E.g. 1.0.0. If set, the active plugin must be this version or higher.
55
  'dependency' => true, // If true, and the plugin is activated, the plugin will be loaded before as a dependeny.
56
  'is_callable' => 'AUXELS' // If set, this callable will be be checked for availability to determine if a plugin is active.
57
  )
@@ -61,7 +64,7 @@ if( is_admin() || false === get_transient( 'auxpfo_plugin_requirements_check' )
61
  array(
62
  'name' => __('Phlox Pro', 'auxin-portfolio'), // The theme name.
63
  'id' => 'phlox-pro', // The theme id name.
64
- 'version' => '5.1.0', // E.g. 1.0.0. If set, the active theme must be this version or higher.
65
  'is_callable' => '', // If set, this callable will be be checked for availability to determine if a theme is active.
66
  'theme_requires_const' => 'AUXPFO_REQUIRED_VERSION',
67
  'file_required' => array( get_template_directory() . '/auxin-content/init/dependency.php', get_template_directory() . '/auxin-content/init/constant.php' )
@@ -70,7 +73,7 @@ if( is_admin() || false === get_transient( 'auxpfo_plugin_requirements_check' )
70
  'name' => __('Phlox', 'auxin-portfolio'), // The theme name.
71
  'id' => 'phlox', // The theme id name.
72
  'update_link' => 'themes.php?theme=phlox',
73
- 'version' => '2.3.0', // E.g. 1.0.0. If set, the active theme must be this version or higher.
74
  'is_callable' => '', // If set, this callable will be be checked for availability to determine if a theme is active.
75
  'theme_requires_const' => 'AUXPFO_REQUIRED_VERSION',
76
  'file_required' => array( get_template_directory() . '/auxin-content/init/dependency.php', get_template_directory() . '/auxin-content/init/constant.php' )
12
  * Plugin Name: Phlox Portfolio
13
  * Plugin URI: http://phlox.pro/
14
  * Description: Showcase your projects beautifully in Phlox theme
15
+ * Version: 1.7.7
16
  * Author: averta
17
  * Author URI: http://averta.net
18
  * License: GPL2
37
  * ===========================================================================*/
38
 
39
  // Don't check the requirements if it's frontend or AUXIN_DUBUG set to false
40
+ if( is_admin() ||
41
+ false === get_transient( 'auxpfo_plugin_requirements_check' ) ||
42
+ ! file_exists( get_template_directory() . '/auxin-content/init/dependency.php' )
43
+ ){
44
 
45
  if( ! class_exists( 'Auxin_Plugin_Requirements' ) ){
46
  require_once( plugin_dir_path( __FILE__ ) . 'includes/classes/class-auxin-plugin-requirements.php' );
54
  'name' => __('Phlox Core Elements', 'auxin-portfolio'), // The plugin name.
55
  'basename' => 'auxin-elements/auxin-elements.php', // The plugin basename (typically the folder name and main php file)
56
  'required' => true, // If true, the user will be notified with a notice to install the plugin.
57
+ 'version' => '2.3.4', // E.g. 1.0.0. If set, the active plugin must be this version or higher.
58
  'dependency' => true, // If true, and the plugin is activated, the plugin will be loaded before as a dependeny.
59
  'is_callable' => 'AUXELS' // If set, this callable will be be checked for availability to determine if a plugin is active.
60
  )
64
  array(
65
  'name' => __('Phlox Pro', 'auxin-portfolio'), // The theme name.
66
  'id' => 'phlox-pro', // The theme id name.
67
+ 'version' => '5.1.4', // E.g. 1.0.0. If set, the active theme must be this version or higher.
68
  'is_callable' => '', // If set, this callable will be be checked for availability to determine if a theme is active.
69
  'theme_requires_const' => 'AUXPFO_REQUIRED_VERSION',
70
  'file_required' => array( get_template_directory() . '/auxin-content/init/dependency.php', get_template_directory() . '/auxin-content/init/constant.php' )
73
  'name' => __('Phlox', 'auxin-portfolio'), // The theme name.
74
  'id' => 'phlox', // The theme id name.
75
  'update_link' => 'themes.php?theme=phlox',
76
+ 'version' => '2.3.4', // E.g. 1.0.0. If set, the active theme must be this version or higher.
77
  'is_callable' => '', // If set, this callable will be be checked for availability to determine if a theme is active.
78
  'theme_requires_const' => 'AUXPFO_REQUIRED_VERSION',
79
  'file_required' => array( get_template_directory() . '/auxin-content/init/dependency.php', get_template_directory() . '/auxin-content/init/constant.php' )
includes/define.php CHANGED
@@ -15,7 +15,7 @@ if( ! defined( 'THEME_NAME' ) ){
15
 
16
 
17
 
18
- define( 'AUXPFO_VERSION' , '1.7.5' );
19
 
20
  define( 'AUXPFO_SLUG' , 'auxin-portfolio' );
21
 
15
 
16
 
17
 
18
+ define( 'AUXPFO_VERSION' , '1.7.7' );
19
 
20
  define( 'AUXPFO_SLUG' , 'auxin-portfolio' );
21
 
includes/elements/elementor/recent-portfolios-grid-carousel.php CHANGED
@@ -195,6 +195,45 @@ class Recent_Portfolios_Grid_Carousel extends Widget_Base {
195
  )
196
  );
197
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
198
  $this->add_control(
199
  'deeplink',
200
  array(
@@ -819,6 +858,9 @@ class Recent_Portfolios_Grid_Carousel extends Widget_Base {
819
  'show_title' => $settings['show_title'],
820
  'display_like' => $settings['display_like'],
821
  'show_info' => $settings['show_info'],
 
 
 
822
  'deeplink' => $settings['deeplink'],
823
  'deeplink_slug' => $settings['deeplink_slug'],
824
 
195
  )
196
  );
197
 
198
+ $this->add_control(
199
+ 'preloadable',
200
+ array(
201
+ 'label' => __('Preload image','auxin-portfolio' ),
202
+ 'type' => Controls_Manager::SWITCHER,
203
+ 'label_on' => __( 'On', 'auxin-portfolio' ),
204
+ 'label_off' => __( 'Off', 'auxin-portfolio' ),
205
+ 'return_value' => 'yes',
206
+ 'default' => 'no'
207
+ )
208
+ );
209
+
210
+ $this->add_control(
211
+ 'preload_preview',
212
+ array(
213
+ 'label' => __('While loading image display','auxin-portfolio' ),
214
+ 'label_block' => true,
215
+ 'type' => Controls_Manager::SELECT,
216
+ 'options' => auxin_get_preloadable_previews(),
217
+ 'return_value' => 'yes',
218
+ 'default' => 'yes',
219
+ 'condition' => array(
220
+ 'preloadable' => 'yes'
221
+ )
222
+ )
223
+ );
224
+
225
+ $this->add_control(
226
+ 'preload_bgcolor',
227
+ array(
228
+ 'label' => __( 'Placeholder color while loading image', 'auxin-portfolio' ),
229
+ 'type' => Controls_Manager::COLOR,
230
+ 'condition' => array(
231
+ 'preloadable' => 'yes',
232
+ 'preload_preview' => array('simple-spinner', 'simple-spinner-light', 'simple-spinner-dark')
233
+ )
234
+ )
235
+ );
236
+
237
  $this->add_control(
238
  'deeplink',
239
  array(
858
  'show_title' => $settings['show_title'],
859
  'display_like' => $settings['display_like'],
860
  'show_info' => $settings['show_info'],
861
+ 'preloadable' => $settings['preloadable'],
862
+ 'preload_preview' => $settings['preload_preview'],
863
+ 'preload_bgcolor' => $settings['preload_bgcolor'],
864
  'deeplink' => $settings['deeplink'],
865
  'deeplink_slug' => $settings['deeplink_slug'],
866
 
includes/elements/elementor/recent-portfolios-grid.php CHANGED
@@ -217,6 +217,18 @@ class Recent_Portfolios_Grid extends Widget_Base {
217
  )
218
  );
219
 
 
 
 
 
 
 
 
 
 
 
 
 
220
  $this->end_controls_section();
221
 
222
  /*-------------------------------------------------------------------*/
@@ -1055,6 +1067,7 @@ class Recent_Portfolios_Grid extends Widget_Base {
1055
  'exclude_without_media' => $settings['exclude_without_media'],
1056
  'display_like' => $settings['display_like'],
1057
  'deeplink' => $settings['deeplink'],
 
1058
  'deeplink_slug' => $settings['deeplink_slug'],
1059
  'show_filters' => $settings['show_filters'],
1060
  'filter_by' => $settings['filter_by'],
@@ -1069,7 +1082,7 @@ class Recent_Portfolios_Grid extends Widget_Base {
1069
 
1070
  'paginate' => $settings['paginate'],
1071
  'perpage' => $settings['perpage'],
1072
- 'display_title' => $settings['display_title'],
1073
  'show_info' => $settings['show_info'],
1074
  'image_aspect_ratio' => $settings['image_aspect_ratio'],
1075
  'space' => auxin_get_control_size( $settings['space'] ),
@@ -1082,7 +1095,6 @@ class Recent_Portfolios_Grid extends Widget_Base {
1082
 
1083
  'loadmore_type' => $settings['loadmore_type'],
1084
  'loadmore_label' => $settings['loadmore_label'],
1085
-
1086
  );
1087
 
1088
  echo auxin_widget_recent_portfolios_grid_callback( $args );
217
  )
218
  );
219
 
220
+ $this->add_control(
221
+ 'use_ajax',
222
+ array(
223
+ 'label' => __('Ajax Compatibility', 'auxin-portfolio' ),
224
+ 'description' => __('Using the Ajax feature Makes the performance better', 'auxin-portfolio' ),
225
+ 'type' => Controls_Manager::SWITCHER,
226
+ 'label_on' => __( 'On', 'auxin-portfolio' ),
227
+ 'label_off' => __( 'Off', 'auxin-portfolio' ),
228
+ 'default' => 'no'
229
+ )
230
+ );
231
+
232
  $this->end_controls_section();
233
 
234
  /*-------------------------------------------------------------------*/
1067
  'exclude_without_media' => $settings['exclude_without_media'],
1068
  'display_like' => $settings['display_like'],
1069
  'deeplink' => $settings['deeplink'],
1070
+ 'use_ajax' => $settings['use_ajax'],
1071
  'deeplink_slug' => $settings['deeplink_slug'],
1072
  'show_filters' => $settings['show_filters'],
1073
  'filter_by' => $settings['filter_by'],
1082
 
1083
  'paginate' => $settings['paginate'],
1084
  'perpage' => $settings['perpage'],
1085
+ 'display_title' => $settings['display_title'],
1086
  'show_info' => $settings['show_info'],
1087
  'image_aspect_ratio' => $settings['image_aspect_ratio'],
1088
  'space' => auxin_get_control_size( $settings['space'] ),
1095
 
1096
  'loadmore_type' => $settings['loadmore_type'],
1097
  'loadmore_label' => $settings['loadmore_label'],
 
1098
  );
1099
 
1100
  echo auxin_widget_recent_portfolios_grid_callback( $args );
includes/elements/elementor/recent-portfolios-masonry.php CHANGED
@@ -216,6 +216,18 @@ class Recent_Portfolios_Masonry extends Widget_Base {
216
  )
217
  );
218
 
 
 
 
 
 
 
 
 
 
 
 
 
219
  $this->end_controls_section();
220
 
221
  /*-------------------------------------------------------------------*/
@@ -1038,6 +1050,7 @@ class Recent_Portfolios_Masonry extends Widget_Base {
1038
  'display_like' => $settings['display_like'],
1039
  'deeplink' => $settings['deeplink'],
1040
  'deeplink_slug' => $settings['deeplink_slug'],
 
1041
  'show_filters' => $settings['show_filters'],
1042
  'filter_by' => $settings['filter_by'],
1043
  'filter_style' => $settings['filter_style'],
216
  )
217
  );
218
 
219
+ $this->add_control(
220
+ 'use_ajax',
221
+ array(
222
+ 'label' => __('Ajax Compatibility', 'auxin-portfolio' ),
223
+ 'description' => __('Using the Ajax feature Makes the performance better', 'auxin-portfolio' ),
224
+ 'type' => Controls_Manager::SWITCHER,
225
+ 'label_on' => __( 'On', 'auxin-portfolio' ),
226
+ 'label_off' => __( 'Off', 'auxin-portfolio' ),
227
+ 'default' => 'no'
228
+ )
229
+ );
230
+
231
  $this->end_controls_section();
232
 
233
  /*-------------------------------------------------------------------*/
1050
  'display_like' => $settings['display_like'],
1051
  'deeplink' => $settings['deeplink'],
1052
  'deeplink_slug' => $settings['deeplink_slug'],
1053
+ 'use_ajax' => $settings['use_ajax'],
1054
  'show_filters' => $settings['show_filters'],
1055
  'filter_by' => $settings['filter_by'],
1056
  'filter_style' => $settings['filter_style'],
includes/elements/elementor/recent-portfolios-tile.php CHANGED
@@ -234,6 +234,18 @@ class Recent_Portfolios_Tile extends Widget_Base {
234
  )
235
  );
236
 
 
 
 
 
 
 
 
 
 
 
 
 
237
  $this->end_controls_section();
238
 
239
  /*-------------------------------------------------------------------*/
@@ -948,6 +960,7 @@ class Recent_Portfolios_Tile extends Widget_Base {
948
  'display_like' => false,
949
  'deeplink' => $settings['deeplink'],
950
  'deeplink_slug' => $settings['deeplink_slug'],
 
951
  'show_filters' => $settings['show_filters'],
952
  'filter_by' => $settings['filter_by'],
953
  'filter_style' => $settings['filter_style'],
234
  )
235
  );
236
 
237
+ $this->add_control(
238
+ 'use_ajax',
239
+ array(
240
+ 'label' => __('Ajax Compatibility', 'auxin-portfolio' ),
241
+ 'description' => __('Using the Ajax feature Makes the performance better', 'auxin-portfolio' ),
242
+ 'type' => Controls_Manager::SWITCHER,
243
+ 'label_on' => __( 'On', 'auxin-portfolio' ),
244
+ 'label_off' => __( 'Off', 'auxin-portfolio' ),
245
+ 'default' => 'no'
246
+ )
247
+ );
248
+
249
  $this->end_controls_section();
250
 
251
  /*-------------------------------------------------------------------*/
960
  'display_like' => false,
961
  'deeplink' => $settings['deeplink'],
962
  'deeplink_slug' => $settings['deeplink_slug'],
963
+ 'use_ajax' => $settings['use_ajax'],
964
  'show_filters' => $settings['show_filters'],
965
  'filter_by' => $settings['filter_by'],
966
  'filter_style' => $settings['filter_style'],
includes/elements/recent-portfolios-grid-carousel.php CHANGED
@@ -33,6 +33,11 @@ function auxin_widget_recent_portfolios_grid_carousel_callback( $atts, $shortcod
33
  'hide_between_delay' => '30',
34
  'item_style' => 'classic',
35
  'perpage' => 10,
 
 
 
 
 
36
  'show_title' => 1,
37
  'show_info' => 1,
38
  'image_aspect_ratio' => 0.75,
@@ -229,7 +234,9 @@ function auxin_widget_recent_portfolios_grid_carousel_callback( $atts, $shortcod
229
  'image_from_content' => ! $exclude_without_media, // whether to try to get image from content or not
230
  'add_image_hw' => false, // whether add width and height attr or not
231
  'no_gallery' => true,
232
- 'preloadable' => true,
 
 
233
  'image_sizes' => 'auto',
234
  'srcset_sizes' => 'auto'
235
  ),
33
  'hide_between_delay' => '30',
34
  'item_style' => 'classic',
35
  'perpage' => 10,
36
+
37
+ 'preloadable' => false,
38
+ 'preload_preview' => true,
39
+ 'preload_bgcolor' => '',
40
+
41
  'show_title' => 1,
42
  'show_info' => 1,
43
  'image_aspect_ratio' => 0.75,
234
  'image_from_content' => ! $exclude_without_media, // whether to try to get image from content or not
235
  'add_image_hw' => false, // whether add width and height attr or not
236
  'no_gallery' => true,
237
+ 'preloadable' => $preloadable,
238
+ 'preload_preview' => $preload_preview,
239
+ 'preload_bgcolor' => $preload_bgcolor,
240
  'image_sizes' => 'auto',
241
  'srcset_sizes' => 'auto'
242
  ),
includes/elements/recent-portfolios-tile-carousel.php CHANGED
@@ -440,6 +440,7 @@ function auxin_widget_recent_portfolios_tiles_carousel_callback( $atts, $shortco
440
  'button_style' => 'pattern-1',
441
  'display_title' => true,
442
  'show_info' => true,
 
443
  'extra_classes' => '',
444
  'tax_args' => '',
445
  'extra_column_classes' => '',
@@ -592,14 +593,15 @@ function auxin_widget_recent_portfolios_tiles_carousel_callback( $atts, $shortco
592
  $post_vars = auxin_get_post_format_media(
593
  $post,
594
  array(
595
- 'request_from' => 'archive',
596
- 'media_width' => $phone_break_point,
597
- 'media_size' => 'large',
598
- 'upscale_image' => true,
599
- 'image_from_content' => ! $exclude_without_media,
600
- 'ignore_formats' => array( '*' ),
601
- 'image_sizes' => $item_pattern_info['image_sizes'],
602
- 'srcset_sizes' => $item_pattern_info['srcset_sizes']
 
603
  )
604
  );
605
  $item_classes = $item_pattern_info['classname'];
440
  'button_style' => 'pattern-1',
441
  'display_title' => true,
442
  'show_info' => true,
443
+
444
  'extra_classes' => '',
445
  'tax_args' => '',
446
  'extra_column_classes' => '',
593
  $post_vars = auxin_get_post_format_media(
594
  $post,
595
  array(
596
+ 'request_from' => 'archive',
597
+ 'media_width' => $phone_break_point,
598
+ 'media_size' => 'large',
599
+ 'upscale_image' => true,
600
+ 'image_from_content' => ! $exclude_without_media,
601
+ 'ignore_formats' => array( '*' ),
602
+ 'preloadable' => false,
603
+ 'image_sizes' => $item_pattern_info['image_sizes'],
604
+ 'srcset_sizes' => $item_pattern_info['srcset_sizes']
605
  )
606
  );
607
  $item_classes = $item_pattern_info['classname'];
includes/elements/recent-portfolios.php CHANGED
@@ -791,6 +791,18 @@ function auxin_get_recent_portfolios_master_array( $master_array ) {
791
  'group' => 'Layout',
792
  'edit_field_class' => ''
793
  ),
 
 
 
 
 
 
 
 
 
 
 
 
794
  array(
795
  'heading' => __('Deeplink slug', 'auxin-portfolio' ),
796
  'description' => __('Specifies the deeplink slug value in address bar.', 'auxin-portfolio' ),
@@ -844,66 +856,74 @@ function auxin_widget_recent_portfolios_grid_callback( $atts, $shortcode_content
844
 
845
  // Defining default attributes
846
  $default_atts = array(
847
- 'title' => '', // header title
848
- 'cat' => ' ',
849
- 'num' => '8', // max generated entry
850
- 'only_posts__in' => '', // display only these post IDs. array or string comma separated
851
- 'include' => '', // include these post IDs in result too. array or string comma separated
852
- 'exclude' => '', // exclude these post IDs from result. array or string comma separated
853
- 'posts_per_page' => -1,
854
- 'offset' => '',
855
- 'order_by' => 'date',
856
- 'order' => 'DESC',
857
- 'exclude_without_media' => 0,
858
- 'display_like' => 1,
859
- 'deeplink' => 0,
860
- 'deeplink_slug' => uniqid('portfolio-'),
861
- 'show_filters' => 1,
862
- 'filter_by' => 'portfolio-filter',
863
- 'filter_style' => 'aux-slideup',
864
- 'filter_align' => 'aux-left',
865
- 'reveal_transition_duration' => '600',
866
- 'reveal_between_delay' => '60',
867
- 'hide_transition_duration' => '600',
868
- 'hide_between_delay' => '30',
869
- 'item_style' => 'classic',
870
- 'tile_style_pattern' => 'default',
871
- 'tiles_item_style' => 'overlay',
872
- 'entry_background_color' => '',
873
- 'entry_border_color' => '',
874
- 'paginate' => 1,
875
- 'perpage' => 10,
876
- 'display_title' => true,
877
- 'show_info' => 1,
878
- 'image_aspect_ratio' => 0.75,
879
- 'space' => 30,
880
- 'desktop_cnum' => 4,
881
- 'tablet_cnum' => 'inherit',
882
- 'phone_cnum' => '1',
883
- 'layout' => 'grid',
884
- 'tag' => '',
885
- 'extra_classes' => '',
886
- 'extra_column_classes' => '',
887
- 'custom_el_id' => '',
888
- 'template_part_file' => 'recent-portfolio',
889
- 'extra_template_path' => AUXPFO_PUB_DIR . '/templates/elements',
890
- 'universal_id' => '',
891
- 'query_args' => array(),
892
- 'term' => '',
893
- 'reset_query' => true,
894
- 'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
895
- 'wp_query_args' => array(), // additional wp_query args
896
- 'loadmore_type' => '', // 'next' (more button), 'scroll', 'next-prev'
897
- 'loadmore_label' => 'text',
898
- 'loadmore_per_page' => '',
899
- 'term_field' => 'slug',
900
- 'base' => 'aux_recent_portfolios_grid',
901
- 'base_class' => 'aux-widget-recent-portfolios'
 
 
 
 
 
902
  );
903
 
904
  $result = auxin_get_widget_scafold( $atts, $default_atts, $shortcode_content );
905
  extract( $result['parsed_atts'] );
906
 
 
 
 
907
  ob_start();
908
 
909
  // widget header ------------------------------
@@ -924,6 +944,7 @@ function auxin_widget_recent_portfolios_grid_callback( $atts, $shortcode_content
924
 
925
  $filter_args['include'] = 'portfolio-cat' === $filter_by ? $cat : '';
926
 
 
927
  if ( function_exists('auxin_filter_output') && auxin_is_true ( $show_filters ) && ! $skip_wrappers ) {
928
 
929
  // Filter Markup
@@ -931,7 +952,7 @@ function auxin_widget_recent_portfolios_grid_callback( $atts, $shortcode_content
931
  $filter_args,
932
  $filter_style,
933
  $filter_align,
934
- 'aux-ajax-filters'
935
  );
936
 
937
  }
791
  'group' => 'Layout',
792
  'edit_field_class' => ''
793
  ),
794
+ array(
795
+ 'heading' => __('Ajax Compatibility', 'auxin-portfolio' ),
796
+ 'description' => __('Using the Ajax feature Makes the performance better', 'auxin-portfolio' ),
797
+ 'param_name' => 'use_ajax',
798
+ 'type' => 'aux_switch',
799
+ 'value' => '0',
800
+ 'class' => '',
801
+ 'admin_label' => false,
802
+ 'weight' => '',
803
+ 'group' => 'Layout',
804
+ 'edit_field_class' => ''
805
+ ),
806
  array(
807
  'heading' => __('Deeplink slug', 'auxin-portfolio' ),
808
  'description' => __('Specifies the deeplink slug value in address bar.', 'auxin-portfolio' ),
856
 
857
  // Defining default attributes
858
  $default_atts = array(
859
+ 'title' => '', // header title
860
+ 'cat' => ' ',
861
+ 'num' => '8', // max generated entry
862
+ 'only_posts__in' => '', // display only these post IDs. array or string comma separated
863
+ 'include' => '', // include these post IDs in result too. array or string comma separated
864
+ 'exclude' => '', // exclude these post IDs from result. array or string comma separated
865
+ 'posts_per_page' => -1,
866
+ 'offset' => '',
867
+ 'order_by' => 'date',
868
+ 'order' => 'DESC',
869
+ 'exclude_without_media' => 0,
870
+ 'display_like' => 1,
871
+ 'deeplink' => 0,
872
+ 'use_ajax' => 0,
873
+ 'deeplink_slug' => uniqid('portfolio-'),
874
+ 'show_filters' => 1,
875
+ 'filter_by' => 'portfolio-filter',
876
+ 'filter_style' => 'aux-slideup',
877
+ 'filter_align' => 'aux-left',
878
+ 'reveal_transition_duration' => '600',
879
+ 'reveal_between_delay' => '60',
880
+ 'hide_transition_duration' => '600',
881
+ 'hide_between_delay' => '30',
882
+ 'item_style' => 'classic',
883
+ 'tile_style_pattern' => 'default',
884
+ 'tiles_item_style' => 'overlay',
885
+ 'entry_background_color' => '',
886
+ 'entry_border_color' => '',
887
+ 'paginate' => 1,
888
+ 'perpage' => 10,
889
+ 'crop' => true,
890
+ // 'preloadable' => false,
891
+ // 'preload_preview' => true,
892
+ // 'preload_bgcolor' => '',
893
+ 'display_title' => true,
894
+ 'show_info' => 1,
895
+ 'image_aspect_ratio' => 0.75,
896
+ 'space' => 30,
897
+ 'desktop_cnum' => 4,
898
+ 'tablet_cnum' => 'inherit',
899
+ 'phone_cnum' => '1',
900
+ 'layout' => 'grid',
901
+ 'tag' => '',
902
+ 'extra_classes' => '',
903
+ 'extra_column_classes' => '',
904
+ 'custom_el_id' => '',
905
+ 'template_part_file' => 'recent-portfolio',
906
+ 'extra_template_path' => AUXPFO_PUB_DIR . '/templates/elements',
907
+ 'universal_id' => '',
908
+ 'query_args' => array(),
909
+ 'term' => '',
910
+ 'reset_query' => true,
911
+ 'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
912
+ 'wp_query_args' => array(), // additional wp_query args
913
+ 'loadmore_type' => '', // 'next' (more button), 'scroll', 'next-prev'
914
+ 'loadmore_label' => 'text',
915
+ 'loadmore_per_page' => '',
916
+ 'term_field' => 'slug',
917
+ 'base' => 'aux_recent_portfolios_grid',
918
+ 'base_class' => 'aux-widget-recent-portfolios'
919
  );
920
 
921
  $result = auxin_get_widget_scafold( $atts, $default_atts, $shortcode_content );
922
  extract( $result['parsed_atts'] );
923
 
924
+ $filter_extraclass = '';
925
+ $filter_extraclass .= auxin_is_true( $use_ajax ) ? 'aux-ajax-filters' : 'aux-isotope-filters';
926
+
927
  ob_start();
928
 
929
  // widget header ------------------------------
944
 
945
  $filter_args['include'] = 'portfolio-cat' === $filter_by ? $cat : '';
946
 
947
+
948
  if ( function_exists('auxin_filter_output') && auxin_is_true ( $show_filters ) && ! $skip_wrappers ) {
949
 
950
  // Filter Markup
952
  $filter_args,
953
  $filter_style,
954
  $filter_align,
955
+ $filter_extraclass
956
  );
957
 
958
  }
includes/general-functions.php CHANGED
@@ -45,8 +45,9 @@ if ( ! function_exists('auxpfo_get_portfolio_config') ) {
45
  $defaults = array(
46
  'request_from' => 'archive',
47
  'content_width' => '',
48
- 'preloadable' => true,
49
  'preload_preview' => false,
 
50
  'media_size' => '', // large, medium, thumbnail
51
  'aspect_ratio' => 1,
52
  'add_image_hw' => true, // whether to add with and height attrs to image
@@ -193,6 +194,7 @@ if ( ! function_exists('auxpfo_get_portfolio_config') ) {
193
  'crop' => $crop,
194
  'preloadable' => $preloadable,
195
  'preload_preview' => $preload_preview,
 
196
  'add_hw' => $add_image_hw,
197
  'image_sizes' => $image_sizes,
198
  'srcset_sizes' => $srcset_sizes,
45
  $defaults = array(
46
  'request_from' => 'archive',
47
  'content_width' => '',
48
+ 'preloadable' => false,
49
  'preload_preview' => false,
50
+ 'preload_bgcolor' => '',
51
  'media_size' => '', // large, medium, thumbnail
52
  'aspect_ratio' => 1,
53
  'add_image_hw' => true, // whether to add with and height attrs to image
194
  'crop' => $crop,
195
  'preloadable' => $preloadable,
196
  'preload_preview' => $preload_preview,
197
+ 'preload_bgcolor' => $preload_bgcolor,
198
  'add_hw' => $add_image_hw,
199
  'image_sizes' => $image_sizes,
200
  'srcset_sizes' => $srcset_sizes,
public/assets/js/portfolio.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! Auxin portfolio - v1.7.5 (2018-11-19)
2
  * All required plugins
3
  * http://averta.net/phlox/
4
  */
@@ -30,6 +30,7 @@
30
  args : eval($container.data('element-id') + 'AjaxConfig')
31
  };
32
 
 
33
  $container.AuxIsotope( 'showLoading' );
34
 
35
  $.post( auxpfo.ajax_url, data, function(res){
@@ -38,8 +39,6 @@
38
 
39
  var $data = $(res.data)
40
 
41
- $container.AuxIsotope( 'removeAll' );
42
-
43
  setTimeout(function() {
44
 
45
  $data.each( function( index, element ) {
1
+ /*! Auxin portfolio - v1.7.7 (2018-12-26)
2
  * All required plugins
3
  * http://averta.net/phlox/
4
  */
30
  args : eval($container.data('element-id') + 'AjaxConfig')
31
  };
32
 
33
+ $container.AuxIsotope( 'removeAll' );
34
  $container.AuxIsotope( 'showLoading' );
35
 
36
  $.post( auxpfo.ajax_url, data, function(res){
39
 
40
  var $data = $(res.data)
41
 
 
 
42
  setTimeout(function() {
43
 
44
  $data.each( function( index, element ) {
public/assets/js/portfolio.min.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! Auxin portfolio - v1.7.5 (2018-11-19)
2
  * All required plugins
3
  * http://averta.net/phlox/
4
  */
@@ -6,4 +6,4 @@
6
  *
7
  * ================== public/assets/js/src/init.general.js ===================
8
  **/
9
- !function($){var filterList=$(".aux-widget-recent-portfolios .aux-ajax-filters li[data-filter]");filterList.on("click",function(e){e.preventDefault();var $this=$(this),$container=$this.parents(".aux-widget-recent-portfolios").find(".aux-ajax-view"),data={action:"aux_recent_portfolio_filter_content",term:$this.data("filter"),taxonomy:$container.data("taxonomy"),num:$container.data("num"),order:$container.data("order"),orderby:$container.data("orderby"),n:$container.data("n"),args:eval($container.data("element-id")+"AjaxConfig")};$container.AuxIsotope("showLoading"),$.post(auxpfo.ajax_url,data,function(res){if(res){var $data=$(res.data);$container.AuxIsotope("removeAll"),setTimeout(function(){$data.each(function(index,element){$item=$(element),$item.hasClass("aux-iso-item")&&($container.AuxIsotope("insert",$item),$item.AuxTwoWayHover(),$item.photoSwipe({target:".aux-lightbox-btn",bgOpacity:.97,shareEl:!0}))})},1e3)}})})}(jQuery);
1
+ /*! Auxin portfolio - v1.7.7 (2018-12-26)
2
  * All required plugins
3
  * http://averta.net/phlox/
4
  */
6
  *
7
  * ================== public/assets/js/src/init.general.js ===================
8
  **/
9
+ !function($){var filterList=$(".aux-widget-recent-portfolios .aux-ajax-filters li[data-filter]");filterList.on("click",function(e){e.preventDefault();var $this=$(this),$container=$this.parents(".aux-widget-recent-portfolios").find(".aux-ajax-view"),data={action:"aux_recent_portfolio_filter_content",term:$this.data("filter"),taxonomy:$container.data("taxonomy"),num:$container.data("num"),order:$container.data("order"),orderby:$container.data("orderby"),n:$container.data("n"),args:eval($container.data("element-id")+"AjaxConfig")};$container.AuxIsotope("removeAll"),$container.AuxIsotope("showLoading"),$.post(auxpfo.ajax_url,data,function(res){if(res){var $data=$(res.data);setTimeout(function(){$data.each(function(index,element){$item=$(element),$item.hasClass("aux-iso-item")&&($container.AuxIsotope("insert",$item),$item.AuxTwoWayHover(),$item.photoSwipe({target:".aux-lightbox-btn",bgOpacity:.97,shareEl:!0}))})},1e3)}})})}(jQuery);
public/assets/js/src/init.general.js CHANGED
@@ -18,6 +18,7 @@
18
  args : eval($container.data('element-id') + 'AjaxConfig')
19
  };
20
 
 
21
  $container.AuxIsotope( 'showLoading' );
22
 
23
  $.post( auxpfo.ajax_url, data, function(res){
@@ -26,8 +27,6 @@
26
 
27
  var $data = $(res.data)
28
 
29
- $container.AuxIsotope( 'removeAll' );
30
-
31
  setTimeout(function() {
32
 
33
  $data.each( function( index, element ) {
18
  args : eval($container.data('element-id') + 'AjaxConfig')
19
  };
20
 
21
+ $container.AuxIsotope( 'removeAll' );
22
  $container.AuxIsotope( 'showLoading' );
23
 
24
  $.post( auxpfo.ajax_url, data, function(res){
27
 
28
  var $data = $(res.data)
29
 
 
 
30
  setTimeout(function() {
31
 
32
  $data.each( function( index, element ) {
public/templates/elements/recent-portfolio.php CHANGED
@@ -1,70 +1,70 @@
1
- <?php
2
  function auxin_recent_portfolio( $args= array() ) {
3
-
4
  global $post;
5
 
6
  $defaults = array (
7
- 'title' => '', // header title
8
- 'cat' => ' ',
9
- 'num' => '8', // max generated entry
10
- 'only_posts__in' => '', // display only these post IDs. array or string comma separated
11
- 'include' => '', // include these post IDs in result too. array or string comma separated
12
- 'exclude' => '', // exclude these post IDs from result. array or string comma separated
13
- 'posts_per_page' => -1,
14
- 'offset' => '',
15
- 'order_by' => 'date',
16
- 'order' => 'DESC',
17
- 'exclude_without_media' => 0,
18
- 'display_like' => 1,
19
- 'deeplink' => 0,
20
- 'deeplink_slug' => uniqid('portfolio-'),
21
- 'show_filters' => 1,
22
- 'filter_by' => 'portfolio-filter',
23
- 'filter_style' => 'aux-slideup',
24
- 'filter_align' => 'aux-left',
25
- 'reveal_transition_duration' => '600',
26
- 'reveal_between_delay' => '60',
27
- 'hide_transition_duration' => '600',
28
- 'hide_between_delay' => '30',
29
- 'item_style' => 'classic',
30
- 'tile_style_pattern' => 'default',
31
- 'tiles_item_style' => 'overlay',
32
- 'entry_background_color' => '',
33
- 'entry_border_color' => '',
34
- 'paginate' => 1,
35
- 'perpage' => 10,
36
- 'display_title' => 1,
37
- 'show_info' => 1,
38
- 'image_aspect_ratio' => 0.75,
39
- 'space' => 30,
40
- 'desktop_cnum' => 4,
41
- 'tablet_cnum' => 'inherit',
42
- 'phone_cnum' => '1',
43
- 'layout' => 'grid',
44
- 'tag' => '',
45
- 'content_width' => '',
46
- 'skip_wrappers' => '',
47
- 'extra_classes' => '',
48
- 'extra_column_classes' => '',
49
- 'custom_el_id' => '',
50
- 'template_part_file' => 'recent-portfolio',
51
- 'extra_template_path' => AUXPFO_PUB_DIR . '/templates/elements',
52
- 'universal_id' => '',
53
- 'term' => '',
54
- 'query_args' => array(),
55
- 'reset_query' => true,
56
- 'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
57
- 'wp_query_args' => array(), // additional wp_query args
58
- 'loadmore_type' => '', // 'next' (more button), 'scroll', 'next-prev'
59
- 'loadmore_label' => 'text',
60
- 'loadmore_per_page' => '',
61
- 'term_field' => 'slug',
62
- 'base' => 'aux_recent_portfolios_grid',
63
- 'base_class' => 'aux-widget-recent-portfolios',
64
-
65
  );
66
 
67
- $args = wp_parse_args( $args, $defaults );
68
  extract( $args );
69
 
70
  $isotope_id = uniqid();
@@ -72,7 +72,6 @@ function auxin_recent_portfolio( $args= array() ) {
72
  $is_tiles = false;
73
  $is_masonry = false;
74
  $is_grid = false;
75
- $crop = true;
76
  $output = '';
77
  $post_counter = 0;
78
  $item_classes = '';
@@ -115,12 +114,12 @@ function auxin_recent_portfolio( $args= array() ) {
115
  $column_media_height = '';
116
  $column_media_width = $content_width;
117
  break;
118
- default:
119
  $is_grid = true;
120
  $isotope_layout = 'fitRows';
121
  break;
122
  }
123
-
124
  // check item style and define related variables
125
  switch ( $item_style ) {
126
  case 'classic-lightbox':
@@ -166,17 +165,17 @@ function auxin_recent_portfolio( $args= array() ) {
166
  $template_file = 'column';
167
  }
168
 
169
- // Isotope Attributes
170
  $isoxin_attrs = 'data-lazyload="true" data-space="'.esc_attr( $space ).'" data-pagination="'. ( $paginate ? 'true' : 'false' ) . '" data-deeplink="'. ( $deeplink ? 'true' : 'false' ) . '"';
171
  $isoxin_attrs .= ' data-slug="'. esc_attr( $deeplink_slug ).'" data-perpage="'.esc_attr( $perpage ).'" data-layout="'.esc_attr( $isotope_layout ).'"';
172
  $isoxin_attrs .= ' data-reveal-transition-duration="'. esc_attr( $reveal_transition_duration ).'" data-reveal-between-delay="'.esc_attr( $reveal_between_delay ).'"';
173
  $isoxin_attrs .= ' data-hide-transition-duration="'. esc_attr( $hide_transition_duration ).'" data-hide-between-delay="'.esc_attr( $hide_between_delay ).'"';
174
-
175
  $ajaxAttrs = ' data-num="'. $num .'" data-order="'. $order .'" data-orderby="'. $order_by .'" data-taxonomy="'. $filter_by .'" data-n="'. wp_create_nonce( 'aux_ajax_filterable_portfolio' ) .'"';
176
  $isoxin_attrs .= $ajaxAttrs;
177
 
178
  $wrapper_classes .= $show_lightbox ? ' aux-lightbox-gallery' : '';
179
-
180
  $filter_by = auxin_is_true( $show_filters ) || 'archive' === $called_from || 'taxonomy' === $called_from ? $filter_by : 'portfolio-cat';
181
 
182
  /**
@@ -185,7 +184,7 @@ function auxin_recent_portfolio( $args= array() ) {
185
 
186
  if ( empty ( $term ) ) {
187
 
188
- if ( empty( $cat ) || $cat == " " || ( is_array( $cat ) && ( sizeof( $cat ) == 1 && in_array( ' ', $cat ) ) ) ) {
189
  $tax_args = array();
190
  } else if ( is_array( $cat ) ) {
191
  $tax_args = array(
@@ -237,14 +236,14 @@ function auxin_recent_portfolio( $args= array() ) {
237
  $have_posts = $wp_query->have_posts();
238
 
239
  if( $have_posts ){
240
-
241
  if ( ! $skip_wrappers ) {
242
  // Generate Wrapper Markup
243
  echo sprintf( '<div id="%s" data-element-id="%s" class="%s" %s>', esc_attr( $isotope_id ), esc_attr( $universal_id ), esc_attr( $wrapper_classes ), $isoxin_attrs);
244
- // Loading markup for Ajax LoadMore
245
  echo '<div class="aux-items-loading aux-loading-hide"><div class="aux-loading-loop"><svg class="aux-circle" width="100%" height="100%" viewBox="0 0 42 42"><circle class="aux-stroke-bg" r="20" cx="21" cy="21" fill="none"></circle><circle class="aux-progress" r="20" cx="21" cy="21" fill="none" transform="rotate(-90 21 21)"></circle></svg></div></div>';
246
  //End of Loading markup
247
- }
248
 
249
  while ( $wp_query->have_posts() ) {
250
 
@@ -269,8 +268,7 @@ function auxin_recent_portfolio( $args= array() ) {
269
  'media_width' => 726,
270
  'media_size' => $tile_pattern_info['size'],
271
  'upscale_image' => true,
272
- 'preloadable' => true,
273
- 'preload_preview' => false,
274
  'crop' => true,
275
  'add_image_hw' => true, // whether add width and height attr or not
276
  'image_sizes' => $tile_pattern_info['image_sizes'],
@@ -280,7 +278,7 @@ function auxin_recent_portfolio( $args= array() ) {
280
 
281
  $item_classes = $tile_pattern_info['classname'];
282
  $item_inner_classes = '';
283
-
284
  } else {
285
 
286
  $post_vars = auxpfo_get_portfolio_config(
@@ -308,11 +306,18 @@ function auxin_recent_portfolio( $args= array() ) {
308
  $post_counter --;
309
  continue;
310
  }
311
-
312
- // Extra conditions
313
  $item_classes .= $is_boxed ? ' aux-entry-boxed' : '';
314
  $item_classes .= !empty( $loadmore_type ) ? ' aux-ajax-item' : '';
315
 
 
 
 
 
 
 
 
 
316
  // // Lightbox attributes
317
  if ( $show_lightbox ) {
318
  $attach_id = get_post_thumbnail_id($post->ID);
@@ -330,12 +335,12 @@ function auxin_recent_portfolio( $args= array() ) {
330
  }
331
 
332
  include auxin_get_template_file( 'theme-parts/entry/portfolio', $template_file, AUXPFO()->template_path() );
333
-
334
-
335
  echo '</div>';
336
 
337
  }
338
-
339
  if( ! $skip_wrappers ) {
340
 
341
  // End of Wrapper Markup
@@ -346,7 +351,7 @@ function auxin_recent_portfolio( $args= array() ) {
346
  echo auxin_get_load_more_controller( $loadmore_type, $loadmore_label );
347
  }
348
 
349
- }
350
 
351
  if ( $is_boxed ) {
352
  // Set background color style
1
+ <?php
2
  function auxin_recent_portfolio( $args= array() ) {
3
+
4
  global $post;
5
 
6
  $defaults = array (
7
+ 'title' => '', // header title
8
+ 'cat' => ' ',
9
+ 'num' => '8', // max generated entry
10
+ 'only_posts__in' => '', // display only these post IDs. array or string comma separated
11
+ 'include' => '', // include these post IDs in result too. array or string comma separated
12
+ 'exclude' => '', // exclude these post IDs from result. array or string comma separated
13
+ 'posts_per_page' => -1,
14
+ 'offset' => '',
15
+ 'order_by' => 'date',
16
+ 'order' => 'DESC',
17
+ 'exclude_without_media' => 0,
18
+ 'display_like' => 1,
19
+ 'deeplink' => 0,
20
+ 'deeplink_slug' => uniqid('portfolio-'),
21
+ 'show_filters' => 1,
22
+ 'filter_by' => 'portfolio-filter',
23
+ 'filter_style' => 'aux-slideup',
24
+ 'filter_align' => 'aux-left',
25
+ 'reveal_transition_duration' => '600',
26
+ 'reveal_between_delay' => '60',
27
+ 'hide_transition_duration' => '600',
28
+ 'hide_between_delay' => '30',
29
+ 'item_style' => 'classic',
30
+ 'tile_style_pattern' => 'default',
31
+ 'tiles_item_style' => 'overlay',
32
+ 'entry_background_color' => '',
33
+ 'entry_border_color' => '',
34
+ 'paginate' => 1,
35
+ 'perpage' => 10,
36
+ 'crop' => true,
37
+ 'display_title' => 1,
38
+ 'show_info' => 1,
39
+ 'image_aspect_ratio' => 0.75,
40
+ 'space' => 30,
41
+ 'desktop_cnum' => 4,
42
+ 'tablet_cnum' => 'inherit',
43
+ 'phone_cnum' => '1',
44
+ 'layout' => 'grid',
45
+ 'tag' => '',
46
+ 'content_width' => '',
47
+ 'skip_wrappers' => '',
48
+ 'extra_classes' => '',
49
+ 'extra_column_classes' => '',
50
+ 'custom_el_id' => '',
51
+ 'template_part_file' => 'recent-portfolio',
52
+ 'extra_template_path' => AUXPFO_PUB_DIR . '/templates/elements',
53
+ 'universal_id' => '',
54
+ 'term' => '',
55
+ 'query_args' => array(),
56
+ 'reset_query' => true,
57
+ 'use_wp_query' => false, // true to use the global wp_query, false to use internal custom query
58
+ 'wp_query_args' => array(), // additional wp_query args
59
+ 'loadmore_type' => '', // 'next' (more button), 'scroll', 'next-prev'
60
+ 'loadmore_label' => 'text',
61
+ 'loadmore_per_page' => '',
62
+ 'term_field' => 'slug',
63
+ 'base' => 'aux_recent_portfolios_grid',
64
+ 'base_class' => 'aux-widget-recent-portfolios',
65
  );
66
 
67
+ $args = wp_parse_args( $args, $defaults );
68
  extract( $args );
69
 
70
  $isotope_id = uniqid();
72
  $is_tiles = false;
73
  $is_masonry = false;
74
  $is_grid = false;
 
75
  $output = '';
76
  $post_counter = 0;
77
  $item_classes = '';
114
  $column_media_height = '';
115
  $column_media_width = $content_width;
116
  break;
117
+ default:
118
  $is_grid = true;
119
  $isotope_layout = 'fitRows';
120
  break;
121
  }
122
+
123
  // check item style and define related variables
124
  switch ( $item_style ) {
125
  case 'classic-lightbox':
165
  $template_file = 'column';
166
  }
167
 
168
+ // Isotope Attributes
169
  $isoxin_attrs = 'data-lazyload="true" data-space="'.esc_attr( $space ).'" data-pagination="'. ( $paginate ? 'true' : 'false' ) . '" data-deeplink="'. ( $deeplink ? 'true' : 'false' ) . '"';
170
  $isoxin_attrs .= ' data-slug="'. esc_attr( $deeplink_slug ).'" data-perpage="'.esc_attr( $perpage ).'" data-layout="'.esc_attr( $isotope_layout ).'"';
171
  $isoxin_attrs .= ' data-reveal-transition-duration="'. esc_attr( $reveal_transition_duration ).'" data-reveal-between-delay="'.esc_attr( $reveal_between_delay ).'"';
172
  $isoxin_attrs .= ' data-hide-transition-duration="'. esc_attr( $hide_transition_duration ).'" data-hide-between-delay="'.esc_attr( $hide_between_delay ).'"';
173
+
174
  $ajaxAttrs = ' data-num="'. $num .'" data-order="'. $order .'" data-orderby="'. $order_by .'" data-taxonomy="'. $filter_by .'" data-n="'. wp_create_nonce( 'aux_ajax_filterable_portfolio' ) .'"';
175
  $isoxin_attrs .= $ajaxAttrs;
176
 
177
  $wrapper_classes .= $show_lightbox ? ' aux-lightbox-gallery' : '';
178
+
179
  $filter_by = auxin_is_true( $show_filters ) || 'archive' === $called_from || 'taxonomy' === $called_from ? $filter_by : 'portfolio-cat';
180
 
181
  /**
184
 
185
  if ( empty ( $term ) ) {
186
 
187
+ if ( empty( $cat ) || $cat == " " || ( is_array( $cat ) && ( sizeof( $cat ) == 1 && in_array( ' ', $cat ) ) ) ) {
188
  $tax_args = array();
189
  } else if ( is_array( $cat ) ) {
190
  $tax_args = array(
236
  $have_posts = $wp_query->have_posts();
237
 
238
  if( $have_posts ){
239
+
240
  if ( ! $skip_wrappers ) {
241
  // Generate Wrapper Markup
242
  echo sprintf( '<div id="%s" data-element-id="%s" class="%s" %s>', esc_attr( $isotope_id ), esc_attr( $universal_id ), esc_attr( $wrapper_classes ), $isoxin_attrs);
243
+ // Loading markup for Ajax LoadMore
244
  echo '<div class="aux-items-loading aux-loading-hide"><div class="aux-loading-loop"><svg class="aux-circle" width="100%" height="100%" viewBox="0 0 42 42"><circle class="aux-stroke-bg" r="20" cx="21" cy="21" fill="none"></circle><circle class="aux-progress" r="20" cx="21" cy="21" fill="none" transform="rotate(-90 21 21)"></circle></svg></div></div>';
245
  //End of Loading markup
246
+ }
247
 
248
  while ( $wp_query->have_posts() ) {
249
 
268
  'media_width' => 726,
269
  'media_size' => $tile_pattern_info['size'],
270
  'upscale_image' => true,
271
+ 'preloadable' => false, // pass null to disable lazyloading while respecting the "sizes" => "auto"
 
272
  'crop' => true,
273
  'add_image_hw' => true, // whether add width and height attr or not
274
  'image_sizes' => $tile_pattern_info['image_sizes'],
278
 
279
  $item_classes = $tile_pattern_info['classname'];
280
  $item_inner_classes = '';
281
+
282
  } else {
283
 
284
  $post_vars = auxpfo_get_portfolio_config(
306
  $post_counter --;
307
  continue;
308
  }
309
+ // Extra conditions
 
310
  $item_classes .= $is_boxed ? ' aux-entry-boxed' : '';
311
  $item_classes .= !empty( $loadmore_type ) ? ' aux-ajax-item' : '';
312
 
313
+ if ( $show_filters && ! auxin_is_true( $use_ajax ) ) {
314
+ $filters = wp_get_post_terms( $post->ID, $filter_by );
315
+ foreach ( $filters as $filter ) {
316
+ $item_classes .= ' '. $filter->slug;
317
+ }
318
+ }
319
+
320
+
321
  // // Lightbox attributes
322
  if ( $show_lightbox ) {
323
  $attach_id = get_post_thumbnail_id($post->ID);
335
  }
336
 
337
  include auxin_get_template_file( 'theme-parts/entry/portfolio', $template_file, AUXPFO()->template_path() );
338
+
339
+
340
  echo '</div>';
341
 
342
  }
343
+
344
  if( ! $skip_wrappers ) {
345
 
346
  // End of Wrapper Markup
351
  echo auxin_get_load_more_controller( $loadmore_type, $loadmore_label );
352
  }
353
 
354
+ }
355
 
356
  if ( $is_boxed ) {
357
  // Set background color style