@abi-software/mapintegratedvuer 1.2.1-beta.2 → 1.2.1-beta.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@abi-software/mapintegratedvuer",
3
- "version": "1.2.1-beta.2",
3
+ "version": "1.2.1-beta.3",
4
4
  "license": "Apache-2.0",
5
5
  "scripts": {
6
6
  "serve": "vite --host --force",
@@ -50,8 +50,8 @@
50
50
  "*.js"
51
51
  ],
52
52
  "dependencies": {
53
- "@abi-software/flatmapvuer": "^1.2.0-beta.2",
54
- "@abi-software/map-side-bar": "^2.2.1-beta.4",
53
+ "@abi-software/flatmapvuer": "^1.2.0-beta.3",
54
+ "@abi-software/map-side-bar": "^2.2.1-beta.5",
55
55
  "@abi-software/map-utilities": "^0.0.0-beta.4",
56
56
  "@abi-software/plotvuer": "1.0.0",
57
57
  "@abi-software/scaffoldvuer": "^1.2.1-beta.0",
@@ -186,6 +186,7 @@ export default {
186
186
  target: value
187
187
  });
188
188
  this.$nextTick(() => {
189
+ EventBus.emit('connectivity-info-close');
189
190
  setTimeout(() => {
190
191
  this.$emit("chooser-changed");
191
192
  }, 1200);
@@ -35,6 +35,7 @@
35
35
  @hover-changed="hoverChanged($event)"
36
36
  @contextUpdate="contextUpdate($event)"
37
37
  @datalink-clicked="datalinkClicked($event)"
38
+ @show-connectivity="onShowConnectivity"
38
39
  />
39
40
  <SplitDialog
40
41
  :entries="entries"
@@ -262,6 +263,20 @@ export default {
262
263
  }
263
264
  payload.data.cb(suggestions);
264
265
  },
266
+ /**
267
+ * This event is emitted when the show connectivity button in sidebar is clicked.
268
+ * This will move the map to the highlighted connectivity area.
269
+ * @arg featureIds
270
+ */
271
+ onShowConnectivity: function (featureIds) {
272
+ const splitFlowState = this.splitFlowStore.getState();
273
+ const activeView = splitFlowState?.activeView || '';
274
+ // offset sidebar only on singlepanel and 2horpanel views
275
+ EventBus.emit('show-connectivity', {
276
+ featureIds: featureIds,
277
+ offset: activeView === 'singlepanel' || activeView === '2horpanel'
278
+ });
279
+ },
265
280
  hoverChanged: function (data) {
266
281
  const hoverEntries = data && data.anatomy ? data.anatomy : []
267
282
  this.settingsStore.updateHoveredMarkers(hoverEntries);
@@ -170,6 +170,17 @@ export default {
170
170
  EventBus.on("markerUpdate", () => {
171
171
  this.flatmapMarkerUpdate(undefined);
172
172
  });
173
+
174
+ EventBus.on('show-connectivity', (payload) => {
175
+ const { featureIds, offset } = payload;
176
+ const currentFlatmap = this.$refs.flatmap;
177
+ if (currentFlatmap) {
178
+ currentFlatmap.moveMap(featureIds, {
179
+ offsetX: offset ? -200 : 0,
180
+ zoom: 4,
181
+ });
182
+ }
183
+ });
173
184
  },
174
185
  };
175
186
  </script>
@@ -55,7 +55,7 @@ import {
55
55
  import DyncamicMarkerMixin from "../../mixins/DynamicMarkerMixin";
56
56
 
57
57
  import YellowStar from "../../icons/yellowstar";
58
-
58
+
59
59
  import { MultiFlatmapVuer } from "@abi-software/flatmapvuer";
60
60
  import "@abi-software/flatmapvuer/dist/style.css";
61
61
  import { HelpModeDialog } from '@abi-software/map-utilities'
@@ -430,6 +430,19 @@ export default {
430
430
  this.getAvailableTerms();
431
431
  this.getFeaturedDatasets();
432
432
 
433
+ EventBus.on('show-connectivity', (payload) => {
434
+ const { featureIds, offset } = payload;
435
+ if (this.flatmapReady && this.$refs.multiflatmap) {
436
+ const currentFlatmap = this.$refs.multiflatmap.getCurrentFlatmap();
437
+ if (currentFlatmap) {
438
+ currentFlatmap.moveMap(featureIds, {
439
+ offsetX: offset ? -200 : 0,
440
+ zoom: 4,
441
+ });
442
+ }
443
+ }
444
+ });
445
+
433
446
  EventBus.on("markerUpdate", () => {
434
447
  if (this.flatmapReady) {
435
448
  this.flatmapMarkerUpdate(this.$refs.multiflatmap.getCurrentFlatmap().mapImp);