@abi-software/mapintegratedvuer 1.9.2 → 1.9.3-beta.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-DO6jlHIh.js → ContentMixin-DXXhWj3L.js} +172 -161
- package/dist/{Flatmap-CY9MPW7I.js → Flatmap-DTJJHOZJ.js} +67 -40
- package/dist/{Iframe-XTSWvVQw.js → Iframe-BvIYJdxM.js} +2 -2
- package/dist/{MultiFlatmap-B7e2d6WK.js → MultiFlatmap-DYUAs7aa.js} +87 -59
- package/dist/{Plot-D3lEgm6I.js → Plot-B3waT3eW.js} +2 -2
- package/dist/Scaffold-D1SvYdhM.js +194 -0
- package/dist/{Simulation-CrPJ4_pw.js → Simulation-DEcCnsZ0.js} +2 -2
- package/dist/{index-BcpVBq1h.js → index-_BTFPzpV.js} +19889 -19974
- package/dist/mapintegratedvuer.js +1 -1
- package/dist/mapintegratedvuer.umd.cjs +226 -6059
- package/dist/style-DqJAtv3f.js +66 -0
- package/dist/style.css +1 -1
- package/package.json +7 -6
- package/src/App.vue +2 -0
- package/src/assets/header-icon.scss +2 -2
- package/src/components/ContentBar.vue +3 -0
- package/src/components/DialogToolbarContent.vue +434 -18
- package/src/components/MapContent.vue +24 -2
- package/src/components/SplitDialog.vue +71 -31
- package/src/components/SplitFlow.vue +140 -60
- package/src/components/viewers/Flatmap.vue +58 -16
- package/src/components/viewers/MultiFlatmap.vue +62 -8
- package/src/components/viewers/Scaffold.vue +24 -1
- package/src/components.d.ts +9 -0
- package/src/mixins/ContentMixin.js +58 -32
- package/src/stores/connectivities.js +59 -11
- package/src/stores/settings.js +15 -4
- package/src/stores/splitFlow.js +6 -6
- package/vite.bundle-build.js +5 -2
- package/dist/Scaffold-2Zg19azr.js +0 -43337
- package/dist/style-CIceSTeY.js +0 -104700
@@ -17,6 +17,7 @@
|
|
17
17
|
@shown-map-tooltip="onMapTooltipShown"
|
18
18
|
@annotation-open="onAnnotationOpen"
|
19
19
|
@annotation-close="onAnnotationClose"
|
20
|
+
@update-offline-annotation-enabled="updateOfflineAnnotationEnabled"
|
20
21
|
:annotationSidebar="annotationSidebar"
|
21
22
|
@connectivity-info-open="onConnectivityInfoOpen"
|
22
23
|
@connectivity-error="onConnectivityError"
|
@@ -29,12 +30,15 @@
|
|
29
30
|
:openMapOptions="openMapOptions"
|
30
31
|
:flatmapAPI="flatmapAPI"
|
31
32
|
:sparcAPI="apiLocation"
|
33
|
+
:showLocalSettings="showLocalSettings"
|
34
|
+
:showOpenMapButton="showOpenMapButton"
|
32
35
|
@pan-zoom-callback="flatmapPanZoomCallback"
|
33
36
|
@open-map="openMap"
|
34
37
|
@finish-help-mode="endHelp"
|
35
38
|
@pathway-selection-changed="onPathwaySelectionChanged"
|
36
39
|
@open-pubmed-url="onOpenPubmedUrl"
|
37
40
|
@mapmanager-loaded="onMapmanagerLoaded"
|
41
|
+
:showPathwayFilter="false"
|
38
42
|
/>
|
39
43
|
|
40
44
|
<HelpModeDialog
|
@@ -337,7 +341,8 @@ export default {
|
|
337
341
|
const flatmapImp = flatmap.mapImp;
|
338
342
|
this.flatmapMarkerUpdate(flatmapImp);
|
339
343
|
this.updateProvCard();
|
340
|
-
this.
|
344
|
+
this.updateSettings();
|
345
|
+
this.loadConnectivityExplorerConfig(flatmap);
|
341
346
|
EventBus.emit("mapLoaded", flatmap);
|
342
347
|
}
|
343
348
|
},
|
@@ -422,17 +427,36 @@ export default {
|
|
422
427
|
flatmap.changeViewingMode(modeName);
|
423
428
|
},
|
424
429
|
showConnectivityTooltips: function (payload) {
|
425
|
-
if (this.flatmapReady) {
|
430
|
+
if (this?.alive && this.flatmapReady) {
|
426
431
|
const flatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
427
432
|
flatmap.showConnectivityTooltips(payload);
|
428
433
|
}
|
429
434
|
},
|
430
435
|
changeConnectivitySource: function (payload) {
|
431
|
-
if (this.flatmapReady) {
|
436
|
+
if (this?.alive && this.flatmapReady) {
|
432
437
|
const flatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
433
438
|
flatmap.changeConnectivitySource(payload);
|
434
439
|
}
|
435
440
|
},
|
441
|
+
updateSettings: function () {
|
442
|
+
const {
|
443
|
+
backgroundDisplay,
|
444
|
+
viewingMode,
|
445
|
+
flightPathDisplay,
|
446
|
+
organsDisplay,
|
447
|
+
outlines,
|
448
|
+
} = this.settingsStore.globalSettings;
|
449
|
+
|
450
|
+
if (this.flatmapReady) {
|
451
|
+
const currentFlatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
452
|
+
|
453
|
+
currentFlatmap.changeViewingMode(viewingMode);
|
454
|
+
currentFlatmap.setFlightPath3D(flightPathDisplay);
|
455
|
+
currentFlatmap.setColour(organsDisplay);
|
456
|
+
currentFlatmap.setOutlines(outlines);
|
457
|
+
currentFlatmap.backgroundChangeCallback(backgroundDisplay);
|
458
|
+
}
|
459
|
+
},
|
436
460
|
},
|
437
461
|
computed: {
|
438
462
|
facetSpecies() {
|
@@ -459,7 +483,7 @@ export default {
|
|
459
483
|
this.getFeaturedDatasets();
|
460
484
|
|
461
485
|
EventBus.on('annotation-close', () => {
|
462
|
-
if (this.flatmapReady && this.$refs.multiflatmap) {
|
486
|
+
if (this?.alive && this.flatmapReady && this.$refs.multiflatmap) {
|
463
487
|
const currentFlatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
464
488
|
currentFlatmap.annotationEventCallback({}, { type: 'aborted' })
|
465
489
|
}
|
@@ -467,7 +491,7 @@ export default {
|
|
467
491
|
|
468
492
|
EventBus.on('show-connectivity', (payload) => {
|
469
493
|
const { featureIds, offset } = payload;
|
470
|
-
if (this.flatmapReady && this.$refs.multiflatmap) {
|
494
|
+
if (this?.alive && this.flatmapReady && this.$refs.multiflatmap) {
|
471
495
|
const currentFlatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
472
496
|
if (currentFlatmap) {
|
473
497
|
currentFlatmap.moveMap(featureIds, {
|
@@ -479,7 +503,7 @@ export default {
|
|
479
503
|
});
|
480
504
|
|
481
505
|
EventBus.on('show-reference-connectivities', (payload) => {
|
482
|
-
if (this.flatmapReady && this.$refs.multiflatmap) {
|
506
|
+
if (this?.alive && this.flatmapReady && this.$refs.multiflatmap) {
|
483
507
|
const currentFlatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
484
508
|
if (currentFlatmap) {
|
485
509
|
currentFlatmap.showConnectivitiesByReference(payload);
|
@@ -496,15 +520,45 @@ export default {
|
|
496
520
|
});
|
497
521
|
|
498
522
|
EventBus.on("markerUpdate", () => {
|
499
|
-
if (this.flatmapReady) {
|
523
|
+
if (this?.alive && this.flatmapReady) {
|
500
524
|
this.flatmapMarkerUpdate(this.$refs.multiflatmap.getCurrentFlatmap().mapImp);
|
501
525
|
}
|
502
526
|
});
|
503
527
|
EventBus.on("hoverUpdate", () => {
|
504
|
-
if (this.flatmapReady) {
|
528
|
+
if (this?.alive && this.flatmapReady) {
|
505
529
|
this.cardHoverHighlight();
|
506
530
|
}
|
507
531
|
});
|
532
|
+
EventBus.on('viewingModeUpdate', (payload) => {
|
533
|
+
if (this?.alive && this.flatmapReady) {
|
534
|
+
const currentFlatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
535
|
+
currentFlatmap.changeViewingMode(payload);
|
536
|
+
}
|
537
|
+
});
|
538
|
+
EventBus.on('flightPathUpdate', (payload) => {
|
539
|
+
if (this?.alive && this.flatmapReady) {
|
540
|
+
const currentFlatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
541
|
+
currentFlatmap.setFlightPath3D(payload);
|
542
|
+
}
|
543
|
+
});
|
544
|
+
EventBus.on('organsDisplayUpdate', (payload) => {
|
545
|
+
if (this?.alive && this.flatmapReady) {
|
546
|
+
const currentFlatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
547
|
+
currentFlatmap.setColour(payload);
|
548
|
+
}
|
549
|
+
});
|
550
|
+
EventBus.on('outlinesDisplayUpdate', (payload) => {
|
551
|
+
if (this?.alive && this.flatmapReady) {
|
552
|
+
const currentFlatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
553
|
+
currentFlatmap.setOutlines(payload);
|
554
|
+
}
|
555
|
+
});
|
556
|
+
EventBus.on('backgroundDisplayUpdate', (payload) => {
|
557
|
+
if (this?.alive && this.flatmapReady) {
|
558
|
+
const currentFlatmap = this.$refs.multiflatmap.getCurrentFlatmap();
|
559
|
+
currentFlatmap.backgroundChangeCallback(payload);
|
560
|
+
}
|
561
|
+
});
|
508
562
|
},
|
509
563
|
};
|
510
564
|
</script>
|
@@ -17,6 +17,7 @@
|
|
17
17
|
:helpModeDialog="useHelpModeDialog"
|
18
18
|
@annotation-open="onAnnotationOpen"
|
19
19
|
@annotation-close="onAnnotationClose"
|
20
|
+
@update-offline-annotation-enabled="updateOfflineAnnotationEnabled"
|
20
21
|
:annotationSidebar="annotationSidebar"
|
21
22
|
@help-mode-last-item="onHelpModeLastItem"
|
22
23
|
@shown-tooltip="onTooltipShown"
|
@@ -31,6 +32,8 @@
|
|
31
32
|
:markerCluster="true"
|
32
33
|
:markerLabels="markerLabels"
|
33
34
|
:flatmapAPI="flatmapAPI"
|
35
|
+
:showLocalSettings="showLocalSettings"
|
36
|
+
:showOpenMapButton="showOpenMapButton"
|
34
37
|
/>
|
35
38
|
|
36
39
|
<HelpModeDialog
|
@@ -139,6 +142,7 @@ export default {
|
|
139
142
|
if (this.entry.rotation) rotation = this.entry.rotation;
|
140
143
|
this.$refs.scaffold.toggleSyncControl(this.splitFlowStore.globalCallback, rotation);
|
141
144
|
if (this.splitFlowStore.syncMode) this.$refs.scaffold.fitWindow();
|
145
|
+
this.updateSettings();
|
142
146
|
}
|
143
147
|
EventBus.emit("mapLoaded", this.$refs.scaffold);
|
144
148
|
},
|
@@ -191,6 +195,15 @@ export default {
|
|
191
195
|
changeViewingMode: function (modeName) {
|
192
196
|
this.$refs.scaffold.changeViewingMode(modeName);
|
193
197
|
},
|
198
|
+
updateSettings: function () {
|
199
|
+
const {
|
200
|
+
backgroundDisplay,
|
201
|
+
viewingMode,
|
202
|
+
} = this.settingsStore.globalSettings;
|
203
|
+
|
204
|
+
this.$refs.scaffold.backgroundChangeCallback(backgroundDisplay);
|
205
|
+
this.$refs.scaffold.changeViewingMode(viewingMode);
|
206
|
+
},
|
194
207
|
},
|
195
208
|
computed: {
|
196
209
|
warningMessage: function() {
|
@@ -218,10 +231,20 @@ export default {
|
|
218
231
|
this.startHelp();
|
219
232
|
});
|
220
233
|
EventBus.on("hoverUpdate", () => {
|
221
|
-
if (this.scaffoldLoaded) {
|
234
|
+
if (this.scaffoldLoaded && this?.alive) {
|
222
235
|
this.cardHoverHighlight();
|
223
236
|
}
|
224
237
|
});
|
238
|
+
EventBus.on('backgroundDisplayUpdate', (payload) => {
|
239
|
+
if (this?.alive) {
|
240
|
+
this.$refs.scaffold.backgroundChangeCallback(payload);
|
241
|
+
}
|
242
|
+
});
|
243
|
+
EventBus.on('viewingModeUpdate', (payload) => {
|
244
|
+
if (this?.alive) {
|
245
|
+
this.$refs.scaffold.changeViewingMode(payload);
|
246
|
+
}
|
247
|
+
});
|
225
248
|
},
|
226
249
|
};
|
227
250
|
</script>
|
package/src/components.d.ts
CHANGED
@@ -19,14 +19,23 @@ declare module 'vue' {
|
|
19
19
|
ElCheckbox: typeof import('element-plus/es')['ElCheckbox']
|
20
20
|
ElCol: typeof import('element-plus/es')['ElCol']
|
21
21
|
ElContainer: typeof import('element-plus/es')['ElContainer']
|
22
|
+
ElDropdown: typeof import('element-plus/es')['ElDropdown']
|
23
|
+
ElDropdownItem: typeof import('element-plus/es')['ElDropdownItem']
|
24
|
+
ElDropdownMenu: typeof import('element-plus/es')['ElDropdownMenu']
|
22
25
|
ElHeader: typeof import('element-plus/es')['ElHeader']
|
23
26
|
ElIcon: typeof import('element-plus/es')['ElIcon']
|
24
27
|
ElIconArrowDown: typeof import('@element-plus/icons-vue')['ArrowDown']
|
25
28
|
ElIconArrowUp: typeof import('@element-plus/icons-vue')['ArrowUp']
|
29
|
+
ElIconCompass: typeof import('@element-plus/icons-vue')['Compass']
|
30
|
+
ElIconEditPen: typeof import('@element-plus/icons-vue')['EditPen']
|
31
|
+
ElIconMoreFilled: typeof import('@element-plus/icons-vue')['MoreFilled']
|
32
|
+
ElIconShare: typeof import('@element-plus/icons-vue')['Share']
|
26
33
|
ElInput: typeof import('element-plus/es')['ElInput']
|
27
34
|
ElMain: typeof import('element-plus/es')['ElMain']
|
28
35
|
ElOption: typeof import('element-plus/es')['ElOption']
|
29
36
|
ElPopover: typeof import('element-plus/es')['ElPopover']
|
37
|
+
ElRadio: typeof import('element-plus/es')['ElRadio']
|
38
|
+
ElRadioGroup: typeof import('element-plus/es')['ElRadioGroup']
|
30
39
|
ElRow: typeof import('element-plus/es')['ElRow']
|
31
40
|
ElSelect: typeof import('element-plus/es')['ElSelect']
|
32
41
|
ElSwitch: typeof import('element-plus/es')['ElSwitch']
|
@@ -35,6 +35,7 @@ export default {
|
|
35
35
|
default: false,
|
36
36
|
},
|
37
37
|
},
|
38
|
+
inject: ['showGlobalSettings', 'showOpenMapButton'],
|
38
39
|
computed: {
|
39
40
|
...mapStores(useSettingsStore, useSplitFlowStore, useConnectivitiesStore),
|
40
41
|
idNamePair() {
|
@@ -52,18 +53,38 @@ export default {
|
|
52
53
|
annotationSidebar() {
|
53
54
|
return this.settingsStore.annotationSidebar;
|
54
55
|
},
|
56
|
+
// Hide local settings if global settings are shown
|
57
|
+
showLocalSettings() {
|
58
|
+
return !this.showGlobalSettings;
|
59
|
+
},
|
60
|
+
},
|
61
|
+
beforeUnmount: function() {
|
62
|
+
this.alive = false;
|
55
63
|
},
|
56
64
|
mounted: function () {
|
57
|
-
EventBus.on("startHelp",
|
58
|
-
|
59
|
-
});
|
60
|
-
|
65
|
+
EventBus.on("startHelp", this.startHelp);
|
66
|
+
EventBus.on('connectivity-item-close', this.onConnectivityItemClose);
|
61
67
|
this.multiflatmapRef = this.$refs.multiflatmap;
|
62
68
|
this.flatmapRef = this.$refs.flatmap;
|
63
69
|
this.scaffoldRef = this.$refs.scaffold;
|
64
70
|
this.connectivityKnowledge = this.connectivitiesStore.globalConnectivities;
|
71
|
+
this.connectivityFilterOptions = this.connectivitiesStore.filterOptions;
|
72
|
+
this.connectivityFilterSources = this.connectivitiesStore.filterSources;
|
65
73
|
},
|
66
74
|
methods: {
|
75
|
+
onConnectivityItemClose() {
|
76
|
+
if (this?.alive) {
|
77
|
+
if (this.multiflatmapRef) {
|
78
|
+
const currentFlatmap = this.multiflatmapRef.getCurrentFlatmap();
|
79
|
+
if (currentFlatmap) {
|
80
|
+
currentFlatmap.closeTooltip();
|
81
|
+
}
|
82
|
+
}
|
83
|
+
if (this.flatmapRef) {
|
84
|
+
this.flatmapRef.closeTooltip();
|
85
|
+
}
|
86
|
+
}
|
87
|
+
},
|
67
88
|
toggleSyncMode: function () {
|
68
89
|
return;
|
69
90
|
},
|
@@ -405,10 +426,12 @@ export default {
|
|
405
426
|
return;
|
406
427
|
},
|
407
428
|
startHelp: function () {
|
408
|
-
if (this
|
409
|
-
this.
|
410
|
-
|
411
|
-
|
429
|
+
if (this?.alive) {
|
430
|
+
if (this.isInHelp === false) {
|
431
|
+
this.helpMode = true;
|
432
|
+
window.addEventListener("mousedown", this.checkEndHelpMouseDown);
|
433
|
+
this.isInHelp = true;
|
434
|
+
}
|
412
435
|
}
|
413
436
|
},
|
414
437
|
endHelp: function () {
|
@@ -520,7 +543,10 @@ export default {
|
|
520
543
|
if ((this.multiflatmapRef || this.flatmapRef) && flatmap) {
|
521
544
|
this.flatmapHighlight(flatmap, hoverAnatomies, hoverDOI, hoverConnectivity).then((paths) => {
|
522
545
|
try {
|
523
|
-
flatmap.
|
546
|
+
flatmap.showConnectivityTooltips({
|
547
|
+
connectivityInfo: { featureId: paths },
|
548
|
+
data: []
|
549
|
+
});
|
524
550
|
} catch (error) {
|
525
551
|
console.log(error)
|
526
552
|
// only for connectivity hover highlight
|
@@ -550,6 +576,9 @@ export default {
|
|
550
576
|
onAnnotationClose: function () {
|
551
577
|
EventBus.emit('annotation-close');
|
552
578
|
},
|
579
|
+
updateOfflineAnnotationEnabled: function (payload) {
|
580
|
+
EventBus.emit('update-offline-annotation-enabled', payload);
|
581
|
+
},
|
553
582
|
onConnectivityInfoOpen: function (connectivityInfoData) {
|
554
583
|
EventBus.emit('connectivity-info-open', connectivityInfoData);
|
555
584
|
},
|
@@ -559,42 +588,36 @@ export default {
|
|
559
588
|
onConnectivityInfoClose: function () {
|
560
589
|
EventBus.emit('connectivity-info-close');
|
561
590
|
},
|
562
|
-
|
591
|
+
loadConnectivityExplorerConfig: async function (flatmap) {
|
592
|
+
const flatmapImp = flatmap.mapImp;
|
563
593
|
const sckanVersion = getKnowledgeSource(flatmapImp);
|
564
594
|
const flatmapQueries = markRaw(new FlatmapQueries());
|
565
595
|
flatmapQueries.initialise(this.flatmapAPI);
|
566
596
|
const knowledge = await loadAndStoreKnowledge(flatmapImp, flatmapQueries);
|
567
597
|
const uuid = flatmapImp.uuid;
|
598
|
+
const pathways = flatmapImp.pathways;
|
568
599
|
|
569
600
|
if (!this.connectivityKnowledge[sckanVersion]) {
|
570
601
|
this.connectivityKnowledge[sckanVersion] = knowledge
|
571
602
|
.filter((item) => {
|
572
|
-
return
|
573
|
-
item.source === sckanVersion &&
|
574
|
-
item.connectivity?.length
|
575
|
-
);
|
603
|
+
return item.source === sckanVersion && item.connectivity?.length;
|
576
604
|
})
|
577
605
|
.sort((a, b) => a.label.localeCompare(b.label));
|
578
606
|
}
|
579
|
-
|
580
|
-
|
581
|
-
|
582
|
-
|
583
|
-
|
584
|
-
this.connectivityKnowledge[uuid] = knowledge
|
585
|
-
.filter((item) => {
|
586
|
-
return (
|
587
|
-
item.source === sckanVersion &&
|
588
|
-
item.connectivity?.length &&
|
589
|
-
item.id in pathsFromMap
|
590
|
-
);
|
591
|
-
})
|
592
|
-
.sort((a, b) => a.label.localeCompare(b.label));
|
607
|
+
if (!this.connectivityKnowledge[uuid]) {
|
608
|
+
const pathsFromMap = pathways ? pathways.paths : {};
|
609
|
+
this.connectivityKnowledge[uuid] = this.connectivityKnowledge[sckanVersion]
|
610
|
+
.filter((item) => item.id in pathsFromMap);
|
593
611
|
}
|
594
|
-
|
595
612
|
this.connectivitiesStore.updateGlobalConnectivities(this.connectivityKnowledge);
|
596
|
-
|
597
|
-
|
613
|
+
if (!this.connectivityFilterOptions[uuid]) {
|
614
|
+
this.connectivityFilterOptions[uuid] = await flatmap.getFilterOptions();
|
615
|
+
}
|
616
|
+
this.connectivitiesStore.updateFilterOptions(this.connectivityFilterOptions);
|
617
|
+
if (!this.connectivityFilterSources[uuid]) {
|
618
|
+
this.connectivityFilterSources[uuid] = flatmap.getFilterSources();
|
619
|
+
}
|
620
|
+
this.connectivitiesStore.updateFilterSources(this.connectivityFilterSources);
|
598
621
|
EventBus.emit('species-layout-connectivity-update');
|
599
622
|
},
|
600
623
|
},
|
@@ -618,7 +641,10 @@ export default {
|
|
618
641
|
isInHelp: false,
|
619
642
|
mapManager: undefined,
|
620
643
|
connectivityKnowledge: {},
|
621
|
-
|
644
|
+
connectivityFilterOptions: {},
|
645
|
+
connectivityFilterSources: {},
|
646
|
+
highlightDelay: undefined,
|
647
|
+
alive: true,
|
622
648
|
};
|
623
649
|
},
|
624
650
|
created: function () {
|
@@ -3,33 +3,81 @@ import { defineStore } from 'pinia';
|
|
3
3
|
export const useConnectivitiesStore = defineStore('connectivities', {
|
4
4
|
state: () => {
|
5
5
|
return {
|
6
|
-
globalConnectivities: {},
|
7
6
|
activeConnectivityKeys: [],
|
8
|
-
|
7
|
+
globalConnectivities: {},
|
8
|
+
filterOptions: {},
|
9
|
+
filterSources: {},
|
10
|
+
};
|
9
11
|
},
|
10
12
|
getters: {
|
11
13
|
getUniqueConnectivitiesByKeys: (state) => {
|
12
14
|
let combinedConnectivities = [];
|
13
15
|
state.activeConnectivityKeys.forEach((uuid) => {
|
14
|
-
if (uuid in state
|
15
|
-
const
|
16
|
-
combinedConnectivities.push(...
|
16
|
+
if (uuid in state['globalConnectivities']) {
|
17
|
+
const connectivities = state['globalConnectivities'][uuid];
|
18
|
+
combinedConnectivities.push(...connectivities);
|
17
19
|
}
|
18
20
|
});
|
19
|
-
|
20
21
|
const uniqueConnectivities = Array.from(
|
21
|
-
new Map(combinedConnectivities.map((item) => [item
|
22
|
+
new Map(combinedConnectivities.map((item) => [item['id'], item])).values()
|
22
23
|
);
|
23
|
-
|
24
24
|
return uniqueConnectivities;
|
25
25
|
},
|
26
|
+
getUniqueFilterOptionsByKeys: (state) => {
|
27
|
+
const uniqueFilterOptions = state.activeConnectivityKeys.reduce((acc, uuid) => {
|
28
|
+
const filters = state.filterOptions[uuid];
|
29
|
+
if (!filters) return acc;
|
30
|
+
|
31
|
+
for (const filter of filters) {
|
32
|
+
const existing = acc[filter.key];
|
33
|
+
|
34
|
+
if (!existing) {
|
35
|
+
acc[filter.key] = { ...filter };
|
36
|
+
} else {
|
37
|
+
const mergedChildren = [...existing.children, ...filter.children];
|
38
|
+
const uniqueChildren = Array.from(
|
39
|
+
new Map(mergedChildren.map(child => [child.key, child])).values()
|
40
|
+
);
|
41
|
+
existing.children = uniqueChildren;
|
42
|
+
}
|
43
|
+
}
|
44
|
+
|
45
|
+
return acc;
|
46
|
+
}, {});
|
47
|
+
return Object.values(uniqueFilterOptions);
|
48
|
+
},
|
49
|
+
getUniqueFilterSourcesByKeys: (state) => {
|
50
|
+
const uniqueFilterSources = state.activeConnectivityKeys.reduce((acc, uuid) => {
|
51
|
+
const filters = state.filterSources[uuid];
|
52
|
+
if (!filters) return acc;
|
53
|
+
|
54
|
+
for (const [filter, options] of Object.entries(filters)) {
|
55
|
+
if (!acc[filter]) acc[filter] = {};
|
56
|
+
|
57
|
+
for (const [option, ids] of Object.entries(options)) {
|
58
|
+
acc[filter][option] = acc[filter][option]
|
59
|
+
? Array.from(new Set([...acc[filter][option], ...ids]))
|
60
|
+
: [...ids];
|
61
|
+
}
|
62
|
+
}
|
63
|
+
|
64
|
+
return acc;
|
65
|
+
}, {});
|
66
|
+
return uniqueFilterSources;
|
67
|
+
},
|
26
68
|
},
|
27
69
|
actions: {
|
70
|
+
updateActiveConnectivityKeys(activeConnectivityKeys) {
|
71
|
+
this.activeConnectivityKeys = activeConnectivityKeys;
|
72
|
+
},
|
28
73
|
updateGlobalConnectivities(globalConnectivities) {
|
29
74
|
this.globalConnectivities = globalConnectivities;
|
30
75
|
},
|
31
|
-
|
32
|
-
this.
|
76
|
+
updateFilterOptions(filterOptions) {
|
77
|
+
this.filterOptions = filterOptions;
|
33
78
|
},
|
34
|
-
|
79
|
+
updateFilterSources(filterSources) {
|
80
|
+
this.filterSources = filterSources;
|
81
|
+
},
|
82
|
+
},
|
35
83
|
});
|
package/src/stores/settings.js
CHANGED
@@ -32,11 +32,17 @@ export const useSettingsStore = defineStore('settings', {
|
|
32
32
|
connectivityInfoSidebar: true,
|
33
33
|
annotationSidebar: true,
|
34
34
|
allClosable: true,
|
35
|
+
offlineAnnotationEnabled: false,
|
35
36
|
globalSettings: {
|
36
|
-
displayMarkers: true,
|
37
|
-
highlightConnectedPaths: false,
|
38
|
-
highlightDOIPaths: false, // comment out to hide in settings
|
39
|
-
interactiveMode: 'dataset', // dataset, connectivity, multiscale
|
37
|
+
displayMarkers: true, // comment out to hide in settings
|
38
|
+
// highlightConnectedPaths: false, // comment out to hide in settings
|
39
|
+
// highlightDOIPaths: false, // comment out to hide in settings
|
40
|
+
interactiveMode: 'dataset', // dataset, connectivity, multiscale // comment out to hide in settings
|
41
|
+
viewingMode: 'Exploration',
|
42
|
+
flightPathDisplay: false,
|
43
|
+
organsDisplay: true,
|
44
|
+
outlinesDisplay: true,
|
45
|
+
backgroundDisplay: 'white',
|
40
46
|
},
|
41
47
|
}
|
42
48
|
},
|
@@ -186,10 +192,15 @@ export const useSettingsStore = defineStore('settings', {
|
|
186
192
|
updateAllClosable(allClosable) {
|
187
193
|
this.allClosable = allClosable;
|
188
194
|
},
|
195
|
+
updateOfflineAnnotationEnabled(offlineAnnotationEnabled) {
|
196
|
+
this.offlineAnnotationEnabled = offlineAnnotationEnabled;
|
197
|
+
},
|
189
198
|
updateGlobalSettings(globalSettings) {
|
190
199
|
for (const [key, value] of Object.entries(globalSettings)) {
|
191
200
|
this.globalSettings[key] = value;
|
192
201
|
}
|
202
|
+
// add global settins to storage
|
203
|
+
localStorage.setItem('mapviewer.globalSettings', JSON.stringify(this.globalSettings));
|
193
204
|
},
|
194
205
|
}
|
195
206
|
});
|
package/src/stores/splitFlow.js
CHANGED
@@ -87,15 +87,16 @@ const autoAssignEntryIdsToPane = (entries, layout) => {
|
|
87
87
|
const invalidIdKeys = [];
|
88
88
|
for (const [key, value] of Object.entries(layout)) {
|
89
89
|
if (value.content) {
|
90
|
-
if (assignedIds.includes(value.id)) {
|
91
|
-
//id has got an assigned pane
|
92
|
-
//later
|
90
|
+
if ((1 > value.id) || assignedIds.includes(value.id)) {
|
91
|
+
//id has got an assigned pane or pane contains an invalid id,
|
92
|
+
//cache it and find one later
|
93
93
|
invalidIdKeys.push(key);
|
94
94
|
} else {
|
95
95
|
assignedIds.push(value.id);
|
96
96
|
}
|
97
97
|
}
|
98
98
|
}
|
99
|
+
|
99
100
|
invalidIdKeys.forEach((key) => {
|
100
101
|
let done = false;
|
101
102
|
for (let i = 0; i < entries.length && !done; i++) {
|
@@ -370,7 +371,7 @@ export const useSplitFlowStore = defineStore('splitFlow', {
|
|
370
371
|
availableId == 0; i++) {
|
371
372
|
//Find the first entry not currently in use
|
372
373
|
if ((payload.entries[i].id !== payload.id) &&
|
373
|
-
findKeyWithId(payload.entries[i].id) === undefined) {
|
374
|
+
findKeyWithId(this.customLayout, payload.entries[i].id) === undefined) {
|
374
375
|
availableId = payload.entries[i].id;
|
375
376
|
}
|
376
377
|
}
|
@@ -402,7 +403,7 @@ export const useSplitFlowStore = defineStore('splitFlow', {
|
|
402
403
|
}
|
403
404
|
const customLayout = newLayoutWithOrigInfo(
|
404
405
|
this.customLayout, this.activeView);
|
405
|
-
const key = findKeyWithId(customLayout, payload.id);
|
406
|
+
const key = findKeyWithId(this.customLayout, payload.id);
|
406
407
|
// The following move the entry id to the appropriate slot
|
407
408
|
// and remove the target id
|
408
409
|
switch (key) {
|
@@ -556,7 +557,6 @@ export const useSplitFlowStore = defineStore('splitFlow', {
|
|
556
557
|
this.customLayout[key] = value;
|
557
558
|
}
|
558
559
|
}
|
559
|
-
this.updateSplitPanels();
|
560
560
|
}
|
561
561
|
},
|
562
562
|
updateSplitPanels() {
|
package/vite.bundle-build.js
CHANGED
@@ -12,13 +12,16 @@ export default defineConfig((configEnv) => {
|
|
12
12
|
fileName: "mapintegratedvuer",
|
13
13
|
},
|
14
14
|
rollupOptions: {
|
15
|
-
external: ["vue", "pinia", "@abi-software/
|
15
|
+
external: ["vue", "pinia", "@abi-software/flatmapvuer", "@abi-software/plotvuer",
|
16
|
+
"@abi-software/scaffoldvuer", "@abi-software/simulationvuer"],
|
16
17
|
output: {
|
17
18
|
globals: {
|
18
19
|
vue: "Vue",
|
19
20
|
pinia: "pinia",
|
20
|
-
"@abi-software/
|
21
|
+
"@abi-software/flatmapvuer": "flatmapvuer",
|
21
22
|
"@abi-software/plotvuer": "plotvuer",
|
23
|
+
"@abi-software/scaffoldvuer": "scaffoldvuer",
|
24
|
+
"@abi-software/simulationvuer": "simulationvuer",
|
22
25
|
},
|
23
26
|
},
|
24
27
|
},
|