Photo Gallery by WD – Responsive Photo Gallery - Version 1.5.13

Version Description

  • Fixed: Bug on Gutenberg block functionality.
Download this release

Release Info

Developer webdorado
Plugin Icon 128x128 Photo Gallery by WD – Responsive Photo Gallery
Version 1.5.13
Comparing to
See all releases

Code changes from version 1.5.12 to 1.5.13

Files changed (3) hide show
  1. js/tw-gb/block.js +11 -12
  2. photo-gallery.php +6 -6
  3. readme.txt +4 -1
js/tw-gb/block.js CHANGED
@@ -1,24 +1,24 @@
1
  /**
2
  * 10Web plugins Gutenberg integration
3
- * version 2.0.1
4
  */
5
  ( function ( blocks, element ) {
6
  if ( !window['tw_gb'] ) {
7
  window['tw_gb'] = {};
8
  }
9
- if ( !window['tw_gb'][tw_obj.key] ) {
10
- window['tw_gb'][tw_obj.key] = {
11
- title: tw_obj.plugin_name,
12
- titleSelect: tw_obj.select,
13
- iconUrl: tw_obj.icon_url,
14
  iconSvg: {
15
  width: '20',
16
  height: '20',
17
- src: tw_obj.icon_svg
18
  },
19
  isPopup: true,
20
  data: {
21
- shortcodeUrl: tw_obj.url
22
  }
23
  }
24
  }
@@ -112,7 +112,7 @@
112
  }
113
  };
114
  props.setAttributes( { popupOpened: true } );
115
- if (!shortcode_id && '' != shortcode) {
116
  var shortcode_extract = shortcode.split(' ');
117
  for (i = 0; i < shortcode_extract.length; i++) {
118
  var attributes = shortcode_extract[i].split('=');
@@ -120,7 +120,6 @@
120
  shortcode_id = attributes[1].replace(/"/g, "");
121
  }
122
  }
123
- // shortcode_id = parseInt(shortcode_extract[1].split('=')[1].split('"')[1]);
124
  }
125
  var elem = el( 'form', { className: 'tw-container' }, el( 'div', { className: 'tw-container-wrap' + (pluginData.containerClass ? ' ' + pluginData.containerClass : '') }, el( 'span', {
126
  className: "media-modal-close",
@@ -135,7 +134,7 @@
135
  var shortcodeList = JSON.parse( pluginData.data );
136
  shortcodeList.inputs.forEach( function ( inputItem ) {
137
  if ( inputItem.type === 'select' ) {
138
- children.push( el( 'option', { value: '', dataId: 0 }, tw_obj.empty_item ) );
139
  if ( inputItem.options.length ) {
140
  inputItem.options.forEach( function ( optionItem ) {
141
  var shortcode = '[' + shortcodeList.shortcode_prefix + ' ' + inputItem.shortcode_attibute_name + '="' + optionItem.id + '"]';
@@ -172,7 +171,7 @@
172
  onClick: function () {
173
  props.setAttributes( { popupOpened: true } );
174
  }.bind( this )
175
- }, tw_obj.nothing_selected );
176
  }
177
 
178
  function showShortcode() {
1
  /**
2
  * 10Web plugins Gutenberg integration
3
+ * version 2.0.2
4
  */
5
  ( function ( blocks, element ) {
6
  if ( !window['tw_gb'] ) {
7
  window['tw_gb'] = {};
8
  }
9
+ if ( !window['tw_gb'][tw_obj_translate.key] ) {
10
+ window['tw_gb'][tw_obj_translate.key] = {
11
+ title: tw_obj_translate.plugin_name,
12
+ titleSelect: tw_obj_translate.select,
13
+ iconUrl: tw_obj_translate.icon_url,
14
  iconSvg: {
15
  width: '20',
16
  height: '20',
17
+ src: tw_obj_translate.icon_svg
18
  },
19
  isPopup: true,
20
  data: {
21
+ shortcodeUrl: tw_obj_translate.url
22
  }
23
  }
24
  }
112
  }
113
  };
114
  props.setAttributes( { popupOpened: true } );
115
+ if (!shortcode_id && undefined != shortcode) {
116
  var shortcode_extract = shortcode.split(' ');
117
  for (i = 0; i < shortcode_extract.length; i++) {
118
  var attributes = shortcode_extract[i].split('=');
120
  shortcode_id = attributes[1].replace(/"/g, "");
121
  }
122
  }
 
123
  }
124
  var elem = el( 'form', { className: 'tw-container' }, el( 'div', { className: 'tw-container-wrap' + (pluginData.containerClass ? ' ' + pluginData.containerClass : '') }, el( 'span', {
125
  className: "media-modal-close",
134
  var shortcodeList = JSON.parse( pluginData.data );
135
  shortcodeList.inputs.forEach( function ( inputItem ) {
136
  if ( inputItem.type === 'select' ) {
137
+ children.push( el( 'option', { value: '', dataId: 0 }, tw_obj_translate.empty_item ) );
138
  if ( inputItem.options.length ) {
139
  inputItem.options.forEach( function ( optionItem ) {
140
  var shortcode = '[' + shortcodeList.shortcode_prefix + ' ' + inputItem.shortcode_attibute_name + '="' + optionItem.id + '"]';
171
  onClick: function () {
172
  props.setAttributes( { popupOpened: true } );
173
  }.bind( this )
174
+ }, tw_obj_translate.nothing_selected );
175
  }
176
 
177
  function showShortcode() {
photo-gallery.php CHANGED
@@ -3,7 +3,7 @@
3
  * Plugin Name: Photo Gallery
4
  * Plugin URI: https://10web.io/plugins/wordpress-photo-gallery/
5
  * Description: This plugin is a fully responsive gallery plugin with advanced functionality. It allows having different image galleries for your posts and pages. You can create unlimited number of galleries, combine them into albums, and provide descriptions and tags.
6
- * Version: 1.5.12
7
  * Author: Photo Gallery Team
8
  * Author URI: https://10web.io/pricing/
9
  * License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
@@ -81,8 +81,8 @@ final class BWG {
81
  $this->plugin_dir = WP_PLUGIN_DIR . "/" . plugin_basename(dirname(__FILE__));
82
  $this->plugin_url = plugins_url(plugin_basename(dirname(__FILE__)));
83
  $this->main_file = plugin_basename(__FILE__);
84
- $this->plugin_version = '1.5.12';
85
- $this->db_version = '1.5.12';
86
  $this->prefix = 'bwg';
87
  $this->nicename = __('Photo Gallery', $this->prefix);
88
 
@@ -220,7 +220,7 @@ final class BWG {
220
  //fires after elementor editor styles and scripts are enqueued.
221
  add_action('elementor/editor/after_enqueue_styles', array($this, 'enqueue_editor_styles'), 11);
222
 
223
- // Register 10Web category for Elementor widget if 10Web builder doesn't installed.
224
  add_action('elementor/elements/categories_registered', array($this, 'register_widget_category'), 1, 1);
225
  }
226
 
@@ -250,7 +250,7 @@ final class BWG {
250
  }
251
 
252
  public function register_block_editor_assets($assets) {
253
- $version = '2.0.1';
254
  $js_path = $this->plugin_url . '/js/tw-gb/block.js';
255
  $css_path = $this->plugin_url . '/css/tw-gb/block.css';
256
  if (!isset($assets['version']) || version_compare($assets['version'], $version) === -1) {
@@ -285,7 +285,7 @@ final class BWG {
285
  $assets = apply_filters('tw_get_block_editor_assets', array());
286
  // Not performing unregister or unenqueue as in old versions all are with prefixes.
287
  wp_enqueue_script('tw-gb-block', $assets['js_path'], array( 'wp-blocks', 'wp-element' ), $assets['version']);
288
- wp_localize_script('tw-gb-block', 'tw_obj', array(
289
  'nothing_selected' => __('Nothing selected.', $this->prefix),
290
  'empty_item' => __('- Select -', $this->prefix),
291
  'key' => 'tw/' . $this->prefix,
3
  * Plugin Name: Photo Gallery
4
  * Plugin URI: https://10web.io/plugins/wordpress-photo-gallery/
5
  * Description: This plugin is a fully responsive gallery plugin with advanced functionality. It allows having different image galleries for your posts and pages. You can create unlimited number of galleries, combine them into albums, and provide descriptions and tags.
6
+ * Version: 1.5.13
7
  * Author: Photo Gallery Team
8
  * Author URI: https://10web.io/pricing/
9
  * License: GNU/GPLv3 http://www.gnu.org/licenses/gpl-3.0.html
81
  $this->plugin_dir = WP_PLUGIN_DIR . "/" . plugin_basename(dirname(__FILE__));
82
  $this->plugin_url = plugins_url(plugin_basename(dirname(__FILE__)));
83
  $this->main_file = plugin_basename(__FILE__);
84
+ $this->plugin_version = '1.5.13';
85
+ $this->db_version = '1.5.13';
86
  $this->prefix = 'bwg';
87
  $this->nicename = __('Photo Gallery', $this->prefix);
88
 
220
  //fires after elementor editor styles and scripts are enqueued.
221
  add_action('elementor/editor/after_enqueue_styles', array($this, 'enqueue_editor_styles'), 11);
222
 
223
+ // Register 10Web category for Elementor widget if 10Web builder isn't installed.
224
  add_action('elementor/elements/categories_registered', array($this, 'register_widget_category'), 1, 1);
225
  }
226
 
250
  }
251
 
252
  public function register_block_editor_assets($assets) {
253
+ $version = '2.0.2';
254
  $js_path = $this->plugin_url . '/js/tw-gb/block.js';
255
  $css_path = $this->plugin_url . '/css/tw-gb/block.css';
256
  if (!isset($assets['version']) || version_compare($assets['version'], $version) === -1) {
285
  $assets = apply_filters('tw_get_block_editor_assets', array());
286
  // Not performing unregister or unenqueue as in old versions all are with prefixes.
287
  wp_enqueue_script('tw-gb-block', $assets['js_path'], array( 'wp-blocks', 'wp-element' ), $assets['version']);
288
+ wp_localize_script('tw-gb-block', 'tw_obj_translate', array(
289
  'nothing_selected' => __('Nothing selected.', $this->prefix),
290
  'empty_item' => __('- Select -', $this->prefix),
291
  'key' => 'tw/' . $this->prefix,
readme.txt CHANGED
@@ -3,7 +3,7 @@ Contributors: webdorado,wdsupport,photogallerysupport,10web
3
  Tags: gallery, photo gallery, image gallery, responsive gallery, wordpress gallery plugin, photo albums, gallery slider, gallery lightbox, wordpress photo gallery plugin, fullscreen gallery, watermarking, video gallery
4
  Requires at least: 3.4
5
  Tested up to: 5.0
6
- Stable tag: 1.5.12
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
@@ -279,6 +279,9 @@ Choose whether to display random or the first/last specific number of images.
279
 
280
  == Changelog ==
281
 
 
 
 
282
  = 1.5.12 =
283
  * Added: Number of columns option for Extended Gallery Group view.
284
  * Added: Title/description vertical alignment option for Extended Gallery Group view.
3
  Tags: gallery, photo gallery, image gallery, responsive gallery, wordpress gallery plugin, photo albums, gallery slider, gallery lightbox, wordpress photo gallery plugin, fullscreen gallery, watermarking, video gallery
4
  Requires at least: 3.4
5
  Tested up to: 5.0
6
+ Stable tag: 1.5.13
7
  License: GPLv2 or later
8
  License URI: http://www.gnu.org/licenses/gpl-2.0.html
9
 
279
 
280
  == Changelog ==
281
 
282
+ = 1.5.13 =
283
+ * Fixed: Bug on Gutenberg block functionality.
284
+
285
  = 1.5.12 =
286
  * Added: Number of columns option for Extended Gallery Group view.
287
  * Added: Title/description vertical alignment option for Extended Gallery Group view.