@abi-software/mapintegratedvuer 1.13.0 → 1.13.1
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/dist/{ContentMixin-DE9Pk_KF.js → ContentMixin-Cf4ti-Vc.js} +116 -102
- package/dist/{Flatmap-BdSINIH3.js → Flatmap-DRaM5H0L.js} +11 -10
- package/dist/{Iframe-DL3E0cnI.js → Iframe-DMyBLdD3.js} +2 -2
- package/dist/{MultiFlatmap-DKPBFc_Y.js → MultiFlatmap-CgvcY__u.js} +30 -27
- package/dist/{Plot-_ca3lFZI.js → Plot-BDAChTio.js} +2 -2
- package/dist/{Scaffold-DxH7TMFn.js → Scaffold-CXo37tTA.js} +2 -2
- package/dist/{Simulation-ewRVK6sW.js → Simulation-B4f-ubkl.js} +2 -2
- package/dist/{index-BHZwLSRu.js → index-CDhuA6QJ.js} +31 -8
- package/dist/mapintegratedvuer.js +1 -1
- package/dist/mapintegratedvuer.umd.cjs +4 -4
- package/dist/{style-IHXUSXDX.js → style-BeNQcAFm.js} +1 -1
- package/dist/style.css +1 -1
- package/package.json +1 -1
- package/src/components/ContentVuer.vue +3 -0
- package/src/components/ContextCard.vue +3 -0
- package/src/components/SplitDialog.vue +27 -0
- package/src/components/SplitFlow.vue +8 -0
- package/src/components/viewers/Flatmap.vue +2 -1
- package/src/components/viewers/MultiFlatmap.vue +4 -1
- package/src/mixins/ContentMixin.js +20 -0
- package/src/stores/settings.js +4 -0
package/package.json
CHANGED
|
@@ -170,6 +170,9 @@ export default {
|
|
|
170
170
|
onLoadConnectivityDetail: function(payload) {
|
|
171
171
|
this.$refs.viewer?.getKnowledgeTooltip(payload);
|
|
172
172
|
},
|
|
173
|
+
toggleMinimap: function(option, prevState) {
|
|
174
|
+
this.$refs.viewer?.toggleMinimap(option, prevState);
|
|
175
|
+
},
|
|
173
176
|
},
|
|
174
177
|
data: function () {
|
|
175
178
|
return {
|
|
@@ -470,6 +470,32 @@ export default {
|
|
|
470
470
|
|
|
471
471
|
EventBus.emit("connectivity-knowledge", connectivitiesPayload);
|
|
472
472
|
},
|
|
473
|
+
updateFlatmapMinimap: function () {
|
|
474
|
+
const activePaneIDs = this.splitFlowStore.getActivePaneIds();
|
|
475
|
+
let contents = this.$refs['content'];
|
|
476
|
+
let multiFlatmapContents = [];
|
|
477
|
+
|
|
478
|
+
// Only multiFlatmap viewer has minimap
|
|
479
|
+
for (let i = 0; i < contents.length; i++) {
|
|
480
|
+
if (contents[i].viewerType === 'MultiFlatmap') {
|
|
481
|
+
multiFlatmapContents.push(contents[i]);
|
|
482
|
+
}
|
|
483
|
+
}
|
|
484
|
+
|
|
485
|
+
// Prioritize visible contents so minimap initializes with visible maps first
|
|
486
|
+
multiFlatmapContents.sort((a, b) => {
|
|
487
|
+
return b.isVisible() - a.isVisible();
|
|
488
|
+
});
|
|
489
|
+
|
|
490
|
+
// Disable minimap when there are more than four panel in map-viewer
|
|
491
|
+
const minimapShow = activePaneIDs.length > 4 ? false : true;
|
|
492
|
+
const prevMinimapState = this.settingsStore.displayMinimap;
|
|
493
|
+
|
|
494
|
+
this.settingsStore.updateDisplayMinimap(minimapShow);
|
|
495
|
+
multiFlatmapContents.forEach((content) => {
|
|
496
|
+
content.toggleMinimap(minimapShow, prevMinimapState);
|
|
497
|
+
});
|
|
498
|
+
},
|
|
473
499
|
},
|
|
474
500
|
computed: {
|
|
475
501
|
...mapStores(useSplitFlowStore, useConnectivitiesStore, useSettingsStore),
|
|
@@ -486,6 +512,7 @@ export default {
|
|
|
486
512
|
mounted: function () {
|
|
487
513
|
EventBus.on("PaneResize", payload => {
|
|
488
514
|
this.setStyles(payload.refName, payload.rect);
|
|
515
|
+
this.updateFlatmapMinimap();
|
|
489
516
|
});
|
|
490
517
|
EventBus.on("PaneUnmounted", payload => {
|
|
491
518
|
this.hidePane(payload.refName);
|
|
@@ -869,6 +869,13 @@ export default {
|
|
|
869
869
|
trackEvent: function (data) {
|
|
870
870
|
Tagging.sendEvent(data);
|
|
871
871
|
},
|
|
872
|
+
updateFlatmapMinimap: function () {
|
|
873
|
+
const splitdialog = this.$refs.splitdialog;
|
|
874
|
+
|
|
875
|
+
if (splitdialog) {
|
|
876
|
+
splitdialog.updateFlatmapMinimap();
|
|
877
|
+
}
|
|
878
|
+
},
|
|
872
879
|
},
|
|
873
880
|
created: function () {
|
|
874
881
|
this._facets = [];
|
|
@@ -940,6 +947,7 @@ export default {
|
|
|
940
947
|
}
|
|
941
948
|
});
|
|
942
949
|
EventBus.on("OpenNewMap", type => {
|
|
950
|
+
this.updateFlatmapMinimap();
|
|
943
951
|
this.openNewMap(type);
|
|
944
952
|
});
|
|
945
953
|
EventBus.on("startHelp", () => {
|
|
@@ -28,7 +28,7 @@
|
|
|
28
28
|
:pathControls="true"
|
|
29
29
|
ref="flatmap"
|
|
30
30
|
@ready="flatmapReadyCall"
|
|
31
|
-
:displayMinimap="
|
|
31
|
+
:displayMinimap="displayMinimap"
|
|
32
32
|
:displayWarning="true"
|
|
33
33
|
:enableOpenMapUI="true"
|
|
34
34
|
:flatmapAPI="flatmapAPI"
|
|
@@ -75,6 +75,7 @@ export default {
|
|
|
75
75
|
data: function () {
|
|
76
76
|
return {
|
|
77
77
|
flatmapReady: false,
|
|
78
|
+
displayMinimap: false,
|
|
78
79
|
}
|
|
79
80
|
},
|
|
80
81
|
methods: {
|
|
@@ -25,7 +25,7 @@
|
|
|
25
25
|
@neuron-connection-feature-click="onNeuronConnectionFeatureClick"
|
|
26
26
|
:connectivityInfoSidebar="connectivityInfoSidebar"
|
|
27
27
|
ref="multiflatmap"
|
|
28
|
-
:displayMinimap="
|
|
28
|
+
:displayMinimap="displayMinimap"
|
|
29
29
|
:showStarInLegend="showStarInLegend"
|
|
30
30
|
:enableOpenMapUI="true"
|
|
31
31
|
:openMapOptions="openMapOptions"
|
|
@@ -392,6 +392,9 @@ export default {
|
|
|
392
392
|
featuredMarkers() {
|
|
393
393
|
return this.settingsStore.featuredMarkers;
|
|
394
394
|
},
|
|
395
|
+
displayMinimap() {
|
|
396
|
+
return this.settingsStore.displayMinimap;
|
|
397
|
+
},
|
|
395
398
|
},
|
|
396
399
|
watch: {
|
|
397
400
|
featuredMarkers: function (markers) {
|
|
@@ -79,6 +79,26 @@ export default {
|
|
|
79
79
|
this.connectivityFilterSources = this.connectivitiesStore.filterSources;
|
|
80
80
|
},
|
|
81
81
|
methods: {
|
|
82
|
+
toggleMinimap: function (option, prevState) {
|
|
83
|
+
if (this.multiflatmapRef) {
|
|
84
|
+
const currentFlatmap = this.multiflatmapRef.getCurrentFlatmap();
|
|
85
|
+
const mapImp = currentFlatmap?.mapImp;
|
|
86
|
+
|
|
87
|
+
if (mapImp) {
|
|
88
|
+
if (option === true) {
|
|
89
|
+
// Only create minimap when it is not created before or destroyed
|
|
90
|
+
if (prevState === false) {
|
|
91
|
+
const minimapOptions = mapImp.options?.minimap || { position: 'top-right' };
|
|
92
|
+
mapImp.createMinimap(minimapOptions);
|
|
93
|
+
currentFlatmap.addResizeButtonToMinimap();
|
|
94
|
+
currentFlatmap.minimapSmall = false;
|
|
95
|
+
}
|
|
96
|
+
} else {
|
|
97
|
+
mapImp.closeMinimap();
|
|
98
|
+
}
|
|
99
|
+
}
|
|
100
|
+
}
|
|
101
|
+
},
|
|
82
102
|
onConnectivityItemClose() {
|
|
83
103
|
if (this?.alive) {
|
|
84
104
|
if (this.multiflatmapRef) {
|
package/src/stores/settings.js
CHANGED
|
@@ -34,6 +34,7 @@ export const useSettingsStore = defineStore('settings', {
|
|
|
34
34
|
annotationSidebar: true,
|
|
35
35
|
allClosable: true,
|
|
36
36
|
offlineAnnotationEnabled: false,
|
|
37
|
+
displayMinimap: true,
|
|
37
38
|
globalSettings: {
|
|
38
39
|
displayMarkers: true, // comment out to hide in settings
|
|
39
40
|
// highlightConnectedPaths: false, // comment out to hide in settings
|
|
@@ -219,6 +220,9 @@ export const useSettingsStore = defineStore('settings', {
|
|
|
219
220
|
updateOfflineAnnotationEnabled(offlineAnnotationEnabled) {
|
|
220
221
|
this.offlineAnnotationEnabled = offlineAnnotationEnabled;
|
|
221
222
|
},
|
|
223
|
+
updateDisplayMinimap(displayMinimap) {
|
|
224
|
+
this.displayMinimap = displayMinimap;
|
|
225
|
+
},
|
|
222
226
|
updateGlobalSettings(globalSettings) {
|
|
223
227
|
for (const [key, value] of Object.entries(globalSettings)) {
|
|
224
228
|
this.globalSettings[key] = value;
|