Skip to content

Commit

Permalink
Merge pull request #450 from InfoAmazonia/develop
Browse files Browse the repository at this point in the history
Release 2.11.2
  • Loading branch information
leopiccionia authored Oct 2, 2024
2 parents 4502d56 + 088537c commit 9367973
Show file tree
Hide file tree
Showing 4 changed files with 15 additions and 18 deletions.
7 changes: 5 additions & 2 deletions src/README.txt
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
=== JEO ===
Contributors: earthjournalism
Tested up to: 6.6.2
Stable tag: 2.11.1
Stable tag: 2.11.2
Requires PHP: 7.2
Requires at least: 6.2
License: GPL-2.0+
License URI: http://www.gnu.org/licenses/gpl-2.0.txt
Version: 2.11.1
Version: 2.11.2

The JEO plugin acts as a geojournalism platform that allows news organizations, bloggers and NGOs to publish news stories as layers of information on digital maps.

Expand Down Expand Up @@ -49,6 +49,9 @@ After activating the plugin, a new item will appear on the WordPress dashboard:

== Changelog ==

= 2.11.2 =
*bugfix: Fix regression in interactions loading

= 2.11.1 =
* Improve rendering of maps and storymaps

Expand Down
4 changes: 2 additions & 2 deletions src/jeo.php
Original file line number Diff line number Diff line change
Expand Up @@ -5,7 +5,7 @@
* @wordpress-plugin
* Plugin Name: JEO WP
* Description: Interactive Map blocks for Wordpress Gutenberg
* Version: 2.11.1
* Version: 2.11.2
* License: GPL-2.0+
* License URI: http://www.gnu.org/licenses/gpl-2.0.txt
* Text Domain: jeo
Expand All @@ -22,7 +22,7 @@
* Start at version 1.0.0 and use SemVer - https://semver.org
* Rename this for your plugin and update it as you release new versions.
*/
define( 'JEO_VERSION', '2.11.1' );
define( 'JEO_VERSION', '2.11.2' );

define( 'JEO_BASEPATH', plugin_dir_path( __FILE__ ) );
define( 'JEO_BASEURL', plugins_url('', __FILE__) );
Expand Down
15 changes: 3 additions & 12 deletions src/js/src/jeo-map/class-jeo-map.js
Original file line number Diff line number Diff line change
Expand Up @@ -209,27 +209,18 @@ export default class JeoMap {
}
} );

// Add interactions to style layers
layers.forEach( ( layer ) => {
const currentLayerSettings = mapLayersSettings.find(
( item ) => item.id === layer.attributes.layer_post_id
);
if ( currentLayerSettings.load_as_style ) {
layer.addInteractions( map );
}
} );

// Select reference pointers
firstStyleLayerId = map.style._order[ 0 ];

this.styleLoaded.then( () => {
// Add non-style layers to map (rasters)
layers.forEach( ( layer, index ) => {
const currentLayerSettings = mapLayersSettings.find(
( item ) => item.id === layer.attributes.layer_post_id
);

if ( ! currentLayerSettings.load_as_style ) {
if ( currentLayerSettings.load_as_style ) {
layer.addInteractions( map );
} else {
// If the current layer is below the style, add using fisrt syle layer reference
if ( index < styleLayerIndex ) {
layer.addLayer( map, [ firstStyleLayerId ] );
Expand Down
7 changes: 5 additions & 2 deletions trunk/readme.txt
Original file line number Diff line number Diff line change
@@ -1,12 +1,12 @@
=== JEO ===
Contributors: earthjournalism
Tested up to: 6.6.2
Stable tag: 2.11.1
Stable tag: 2.11.2
Requires PHP: 7.2
Requires at least: 6.2
License: GPL-2.0+
License URI: http://www.gnu.org/licenses/gpl-2.0.txt
Version: 2.11.1
Version: 2.11.2

The JEO plugin acts as a geojournalism platform that allows news organizations, bloggers and NGOs to publish news stories as layers of information on digital maps.

Expand Down Expand Up @@ -49,6 +49,9 @@ After activating the plugin, a new item will appear on the WordPress dashboard:

== Changelog ==

= 2.11.2 =
*bugfix: Fix regression in interactions loading

= 2.11.1 =
* Improve rendering of maps and storymaps

Expand Down

0 comments on commit 9367973

Please sign in to comment.