Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

2.11.3 #1145

Merged
merged 13 commits into from
Nov 27, 2024
4 changes: 2 additions & 2 deletions Modula.php
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
* Plugin URI: https://wp-modula.com/
* Description: Modula is the most powerful, user-friendly WordPress gallery plugin. Add galleries, masonry grids and more in a few clicks.
* Author: WPChill
* Version: 2.11.2
* Version: 2.11.3
* Author URI: https://www.wpchill.com/
* License: GPLv3 or later
* License URI: http://www.gnu.org/licenses/gpl-3.0.html
Expand Down Expand Up @@ -47,7 +47,7 @@
* @since 2.0.2
*/

define( 'MODULA_LITE_VERSION', '2.11.2' );
define( 'MODULA_LITE_VERSION', '2.11.3' );
define( 'MODULA_PATH', plugin_dir_path( __FILE__ ) );
define( 'MODULA_URL', plugin_dir_url( __FILE__ ) );
defined( 'MODULA_PRO_STORE_URL' ) || define( 'MODULA_PRO_STORE_URL', 'https://wp-modula.com' );
Expand Down
2 changes: 1 addition & 1 deletion assets/js/admin/modula-gallery-upload.min.js

Large diffs are not rendered by default.

Original file line number Diff line number Diff line change
@@ -1 +1 @@
<?php return array('dependencies' => array('react', 'wp-api-fetch', 'wp-components', 'wp-element', 'wp-i18n'), 'version' => '1497c3d7b5e7f9e39328');
<?php return array('dependencies' => array('react', 'wp-api-fetch', 'wp-components', 'wp-element', 'wp-i18n'), 'version' => '2b99bd8c07dd045879b3');
2 changes: 1 addition & 1 deletion assets/js/admin/notification-system/notification-system.js

Large diffs are not rendered by default.

34 changes: 6 additions & 28 deletions assets/js/admin/wp-modula-gutenberg.js
Original file line number Diff line number Diff line change
Expand Up @@ -670,40 +670,18 @@ var ModulaEdit = function ModulaEdit(props) {
label: '' === res.title.rendered ? "Unnamed" : escapeHtml(res.title.rendered)
}]
});
jQuery.ajax({
type: 'POST',
data: {
action: 'modula_get_gallery_meta',
id: id,
nonce: modulaVars.nonce
},
url: modulaVars.ajaxURL,
success: function success(result) {
return onGalleryLoaded(id, result);
}
setAttributes({
id: id,
images: res.modulaImages
});
if (idCheck != id || undefined == settings) {
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

!== , ===

getSettings(id);
}
});
};
function escapeHtml(text) {
return text.replace('&#8217;', "'").replace('&#8220;', '"').replace('&#8216;', "'");
}
var onGalleryLoaded = function onGalleryLoaded(id, result) {
if (result.success === false) {
setAttributes({
id: id,
status: 'ready'
});
return;
}
if (idCheck != id || undefined == settings) {
getSettings(id);
}
setAttributes({
id: id,
images: result,
status: 'ready'
});
};
var getSettings = function getSettings(id) {
fetch("".concat(modulaVars.restURL, "wp/v2/modula-gallery/").concat(id)).then(function (res) {
return res.json();
Expand Down
2 changes: 1 addition & 1 deletion assets/js/admin/wp-modula-gutenberg.min.js

Large diffs are not rendered by default.

2 changes: 1 addition & 1 deletion assets/js/admin/wp-modula-upload.min.js

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

3 changes: 3 additions & 0 deletions assets/js/front/modula-fancybox.js
Original file line number Diff line number Diff line change
Expand Up @@ -78,6 +78,9 @@ var modulaFancybox = {
opts.on['*'] = function (fancybox, eventName) {
// replace . from event name with _ and set custom event.
jQuery(document).trigger('modula_fancybox_' + eventName.replace(/\./g, '_'), [fancybox, this]);
// Create custom event for vanilla JS
var event = new CustomEvent('modula_fancybox_' + eventName.replace(/\./g, '_'), { detail: { fancybox: fancybox, instance: this } });
document.dispatchEvent(event);
};

// Slide pause on hover event
Expand Down
Loading