Premium Portfolio Features for Phlox theme - Version 2.2.1

Version Description

Download this release

Release Info

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

Code changes from version 2.2.0 to 2.2.1

README.txt CHANGED
@@ -7,7 +7,7 @@ Tags: phlox, gallery, elementor, siteorigin, portfolio, averta, auxin, fullwidth
7
  Requires PHP: 5.6
8
  Requires at least: 4.6
9
  Tested up to: 5.7.0
10
- Stable tag: 2.2.0
11
  License: GPLv3
12
  License URI: http://www.gnu.org/licenses/gpl.html
13
 
7
  Requires PHP: 5.6
8
  Requires at least: 4.6
9
  Tested up to: 5.7.0
10
+ Stable tag: 2.2.1
11
  License: GPLv3
12
  License URI: http://www.gnu.org/licenses/gpl.html
13
 
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: 2.2.0
16
  * Author: averta
17
  * Author URI: http://averta.net
18
  * License: GPL2
12
  * Plugin Name: Phlox Portfolio
13
  * Plugin URI: http://phlox.pro/
14
  * Description: Showcase your projects beautifully in Phlox theme
15
+ * Version: 2.2.1
16
  * Author: averta
17
  * Author URI: http://averta.net
18
  * License: GPL2
includes/define.php CHANGED
@@ -15,7 +15,7 @@ if( ! defined( 'THEME_NAME' ) ){
15
 
16
 
17
 
18
- define( 'AUXPFO_VERSION' , '2.2.0' );
19
 
20
  define( 'AUXPFO_SLUG' , 'auxin-portfolio' );
21
 
15
 
16
 
17
 
18
+ define( 'AUXPFO_VERSION' , '2.2.1' );
19
 
20
  define( 'AUXPFO_SLUG' , 'auxin-portfolio' );
21
 
includes/elements/elementor/class-auxpfo-elementor-elements.php CHANGED
@@ -149,6 +149,9 @@ final class Elements {
149
 
150
  // Register Admin Scripts
151
  // add_action( 'elementor/editor/before_enqueue_scripts' , array( $this, 'editor_scripts' ) );
 
 
 
152
  }
153
 
154
  /**
@@ -257,6 +260,39 @@ final class Elements {
257
 
258
  return ( ( ( is_single() && get_post_type() == 'portfolio' ) || is_post_type_archive( 'portfolio' ) ) || $need_override_location ) ;
259
  }
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
260
  }
261
 
262
  Elements::instance();
149
 
150
  // Register Admin Scripts
151
  // add_action( 'elementor/editor/before_enqueue_scripts' , array( $this, 'editor_scripts' ) );
152
+
153
+ // Register dynamic tags
154
+ add_action( 'elementor/dynamic_tags/register_tags', [ $this, 'register_tag' ] );
155
  }
156
 
157
  /**
260
 
261
  return ( ( ( is_single() && get_post_type() == 'portfolio' ) || is_post_type_archive( 'portfolio' ) ) || $need_override_location ) ;
262
  }
263
+
264
+ /**
265
+ * @param \Elementor\Core\DynamicTags\Manager $dynamic_tags
266
+ */
267
+ public function register_tag( $dynamic_tags ) {
268
+
269
+ $tags = array(
270
+ 'aux-portfolios-url' => array(
271
+ 'file' => AUXPFO_INC_DIR . '/elements/elementor/dynamic-tags/portfolios-url.php',
272
+ 'class' => 'DynamicTags\Auxin_Portfolios_Url',
273
+ 'group' => 'URL',
274
+ 'title' => 'URL',
275
+ )
276
+ );
277
+
278
+ foreach ( $tags as $tags_type => $tags_info ) {
279
+ if( ! empty( $tags_info['file'] ) && ! empty( $tags_info['class'] ) ){
280
+ // In our Dynamic Tag we use a group named request-variables so we need
281
+ // To register that group as well before the tag
282
+ \Elementor\Plugin::instance()->dynamic_tags->register_group( $tags_info['group'] , [
283
+ 'title' => $tags_info['title']
284
+ ] );
285
+
286
+ include_once( $tags_info['file'] );
287
+ if( class_exists( $tags_info['class'] ) ){
288
+ $class_name = $tags_info['class'];
289
+ } elseif( class_exists( __NAMESPACE__ . '\\' . $tags_info['class'] ) ){
290
+ $class_name = __NAMESPACE__ . '\\' . $tags_info['class'];
291
+ }
292
+ $dynamic_tags->register_tag( $class_name );
293
+ }
294
+ }
295
+ }
296
  }
297
 
298
  Elements::instance();
includes/elements/elementor/dynamic-tags/portfolios-url.php ADDED
@@ -0,0 +1,81 @@
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
1
+ <?php
2
+ namespace Auxin\Plugin\Portfolio\Elementor\DynamicTags;
3
+
4
+ use Elementor\Controls_Manager;
5
+ use Elementor\Core\DynamicTags\Tag;
6
+ use Elementor\Modules\DynamicTags\Module as TagsModule;
7
+
8
+ if ( ! defined( 'ABSPATH' ) ) {
9
+ exit; // Exit if accessed directly
10
+ }
11
+
12
+ class Auxin_Portfolios_Url extends Tag {
13
+
14
+ public function get_name() {
15
+ return 'aux-portfolios-url';
16
+ }
17
+
18
+ public function get_title() {
19
+ return __( 'Portfolios URL', 'auxin-portfolio' );
20
+ }
21
+
22
+ public function get_group() {
23
+ return 'URL';
24
+ }
25
+
26
+ public function get_categories() {
27
+ return [
28
+ TagsModule::URL_CATEGORY
29
+ ];
30
+ }
31
+
32
+ public function get_posts_list() {
33
+
34
+ $items = [
35
+ '' => __( 'Select...', 'auxin-portfolio' ),
36
+ ];
37
+ $posts = get_posts( array(
38
+ 'post_type' =>'portfolio',
39
+ 'numberposts' => -1
40
+ ) );
41
+
42
+ foreach ( $posts as $post ) {
43
+ $items[ $post->ID ] = $post->post_title;
44
+ }
45
+
46
+ return $items;
47
+ }
48
+
49
+ public function is_settings_required() {
50
+ return true;
51
+ }
52
+
53
+ protected function _register_controls() {
54
+ $this->add_control(
55
+ 'key',
56
+ [
57
+ 'label' => __( 'Portfolios URL', 'auxin-portfolio' ),
58
+ 'type' => Controls_Manager::SELECT,
59
+ 'options' => $this->get_posts_list(),
60
+ 'default' => ''
61
+ ]
62
+ );
63
+ }
64
+
65
+ protected function get_post_url() {
66
+ if( $key = $this->get_settings( 'key' ) ){
67
+ return get_permalink( $key );
68
+ }
69
+
70
+ return '';
71
+ }
72
+
73
+ public function get_value() {
74
+ return $this->get_post_url();
75
+ }
76
+
77
+ public function render() {
78
+ echo $this->get_post_url();
79
+ }
80
+
81
+ }
languages/auxin-portfolio-fa_IR.po CHANGED
@@ -2,7 +2,7 @@ msgid ""
2
  msgstr ""
3
  "Project-Id-Version: Phlox Portfolio\n"
4
  "Report-Msgid-Bugs-To: http://averta.net/phlox/wordpress-theme/\n"
5
- "POT-Creation-Date: 2021-06-29 06:22:09+00:00\n"
6
  "PO-Revision-Date: 2017-12-20 13:38+0330\n"
7
  "Last-Translator: \n"
8
  "Language-Team: \n"
@@ -781,6 +781,15 @@ msgid ""
781
  "project."
782
  msgstr ""
783
 
 
 
 
 
 
 
 
 
 
784
  #: includes/elements/elementor/recent-portfolios-grid-carousel.php:56
785
  msgid "Grid Carousel Portfolios"
786
  msgstr ""
2
  msgstr ""
3
  "Project-Id-Version: Phlox Portfolio\n"
4
  "Report-Msgid-Bugs-To: http://averta.net/phlox/wordpress-theme/\n"
5
+ "POT-Creation-Date: 2021-08-08 09:52:11+00:00\n"
6
  "PO-Revision-Date: 2017-12-20 13:38+0330\n"
7
  "Last-Translator: \n"
8
  "Language-Team: \n"
781
  "project."
782
  msgstr ""
783
 
784
+ #: includes/elements/elementor/dynamic-tags/portfolios-url.php:19
785
+ #: includes/elements/elementor/dynamic-tags/portfolios-url.php:57
786
+ msgid "Portfolios URL"
787
+ msgstr ""
788
+
789
+ #: includes/elements/elementor/dynamic-tags/portfolios-url.php:35
790
+ msgid "Select..."
791
+ msgstr ""
792
+
793
  #: includes/elements/elementor/recent-portfolios-grid-carousel.php:56
794
  msgid "Grid Carousel Portfolios"
795
  msgstr ""
languages/auxin-portfolio.pot CHANGED
@@ -1,9 +1,9 @@
1
  # Averta Copyright (c) {2021}
2
  msgid ""
3
  msgstr ""
4
- "Project-Id-Version: Phlox Portfolio 2.2.0\n"
5
  "Report-Msgid-Bugs-To: http://averta.net/phlox/wordpress-theme/\n"
6
- "POT-Creation-Date: 2021-06-29 06:22:09+00:00\n"
7
  "MIME-Version: 1.0\n"
8
  "Content-Type: text/plain; charset=utf-8\n"
9
  "Content-Transfer-Encoding: 8bit\n"
@@ -781,6 +781,15 @@ msgid ""
781
  "project."
782
  msgstr ""
783
 
 
 
 
 
 
 
 
 
 
784
  #: includes/elements/elementor/recent-portfolios-grid-carousel.php:56
785
  msgid "Grid Carousel Portfolios"
786
  msgstr ""
1
  # Averta Copyright (c) {2021}
2
  msgid ""
3
  msgstr ""
4
+ "Project-Id-Version: Phlox Portfolio 2.2.1\n"
5
  "Report-Msgid-Bugs-To: http://averta.net/phlox/wordpress-theme/\n"
6
+ "POT-Creation-Date: 2021-08-08 09:52:11+00:00\n"
7
  "MIME-Version: 1.0\n"
8
  "Content-Type: text/plain; charset=utf-8\n"
9
  "Content-Transfer-Encoding: 8bit\n"
781
  "project."
782
  msgstr ""
783
 
784
+ #: includes/elements/elementor/dynamic-tags/portfolios-url.php:19
785
+ #: includes/elements/elementor/dynamic-tags/portfolios-url.php:57
786
+ msgid "Portfolios URL"
787
+ msgstr ""
788
+
789
+ #: includes/elements/elementor/dynamic-tags/portfolios-url.php:35
790
+ msgid "Select..."
791
+ msgstr ""
792
+
793
  #: includes/elements/elementor/recent-portfolios-grid-carousel.php:56
794
  msgid "Grid Carousel Portfolios"
795
  msgstr ""
public/assets/js/portfolio.js CHANGED
@@ -1,4 +1,4 @@
1
- /*! 2.2.0
2
  * All required plugins
3
  * http://averta.net/phlox/
4
  */
1
+ /*! 2.2.1
2
  * All required plugins
3
  * http://averta.net/phlox/
4
  */