@abi-software/mapintegratedvuer 1.21.1 → 1.22.0
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/README.md +23 -5
- package/assets/location-icon.html +33 -1
- package/assets/styleguide.css +18 -18
- package/cypress.config.js +7 -9
- package/dist/{ConnectivityGraph-CZMROk9r.js → ConnectivityGraph-BBZ3Dgat.js} +3 -3
- package/dist/{ContentMixin-Vn34n5t2.js → ContentMixin-B-O_IwPg.js} +16 -18
- package/dist/{DynamicMarkerMixin-BS6t7w_i.js → DynamicMarkerMixin-B9iqtP_f.js} +1 -1
- package/dist/{Flatmap-BejxA0uz.js → Flatmap-BoEFI50b.js} +4 -4
- package/dist/{Iframe-BWbhTjCR.js → Iframe-Slj-LQTF.js} +4 -4
- package/dist/{MultiFlatmap-nlmsH-Ib.js → MultiFlatmap-l6aBn6x3.js} +17 -5
- package/dist/{Plot-ChbPsDZX.js → Plot-CIhEip5b.js} +2 -2
- package/dist/{Scaffold-C6f7c7Ha.js → Scaffold-D5ZGCDvt.js} +4 -4
- package/dist/{Simulation-DcJScRYo.js → Simulation-C5o5DXRb.js} +2 -2
- package/dist/{connectivities-UXTqf7_0.js → connectivities-Br3MpoAv.js} +154 -95
- package/dist/index.html +9 -6
- package/dist/mapintegratedvuer.js +5506 -5582
- package/dist/mapintegratedvuer.umd.cjs +196 -196
- package/dist/style.css +1 -1
- package/eslint.config.js +39 -15
- package/package.json +12 -6
- package/public/index.html +9 -6
- package/src/App.vue +224 -255
- package/src/assets/_variables.scss +12 -10
- package/src/assets/header-icon.scss +8 -9
- package/src/assets/mapicon-species-style.css +10 -8
- package/src/assets/styles.scss +1 -1
- package/src/components/ContentBar.vue +99 -106
- package/src/components/ContentVuer.vue +36 -39
- package/src/components/ContextCard.vue +238 -199
- package/src/components/ContextHelp.vue +22 -26
- package/src/components/CustomSplitter.vue +32 -43
- package/src/components/DatasetHeader.vue +37 -41
- package/src/components/DialogToolbarContent.vue +292 -256
- package/src/components/FlatmapContextCard.vue +52 -57
- package/src/components/MapContent.vue +111 -87
- package/src/components/ResizeSensor.vue +8 -13
- package/src/components/SearchControls.vue +26 -35
- package/src/components/SimulatedData.js +196 -219
- package/src/components/SplitDialog.vue +139 -129
- package/src/components/SplitFlow.vue +433 -239
- package/src/components/index.js +1 -3
- package/src/components/scripts/simulation_data.js +393 -397
- package/src/components/scripts/utilities.js +108 -78
- package/src/components/viewers/CellDLViewer.vue +9 -9
- package/src/components/viewers/ConnectivityGraph.vue +9 -12
- package/src/components/viewers/Flatmap.vue +23 -25
- package/src/components/viewers/Iframe.vue +8 -10
- package/src/components/viewers/MultiFlatmap.vue +73 -69
- package/src/components/viewers/Plot.vue +6 -7
- package/src/components/viewers/Scaffold.vue +73 -63
- package/src/components/viewers/Simulation.vue +10 -15
- package/src/main.js +16 -21
- package/src/mixins/ContentMixin.js +208 -178
- package/src/mixins/DynamicMarkerMixin.js +14 -18
- package/src/mixins/RetrieveContextCardMixin.js +35 -30
- package/src/mixins/S3Bucket.vue +10 -13
- package/src/services/knowledgeMapping.js +53 -53
- package/src/services/tagging.js +4 -4
- package/src/stores/connectivities.js +46 -8
- package/src/stores/entries.js +7 -9
- package/src/stores/index.js +7 -7
- package/src/stores/settings.js +23 -31
- package/src/stores/splitFlow.js +395 -298
- package/vite.bundle-build.js +24 -26
- package/vite.config.js +22 -21
- package/vite.static-build.js +4 -4
- package/vitest.workspace.js +1 -3
- package/vuese-generator.js +47 -55
package/src/stores/settings.js
CHANGED
|
@@ -1,13 +1,11 @@
|
|
|
1
1
|
import { defineStore } from 'pinia';
|
|
2
2
|
|
|
3
|
-
/* eslint-disable no-alert, no-console */
|
|
4
|
-
|
|
5
3
|
export const useSettingsStore = defineStore('settings', {
|
|
6
4
|
state: () => {
|
|
7
5
|
return {
|
|
8
6
|
shareLink: undefined,
|
|
9
7
|
sparcApi: undefined,
|
|
10
|
-
algoliaIndex:
|
|
8
|
+
algoliaIndex: 'k-core_dev_published_time_desc',
|
|
11
9
|
algoliaKey: undefined,
|
|
12
10
|
algoliaId: undefined,
|
|
13
11
|
pennsieveApi: undefined,
|
|
@@ -46,38 +44,36 @@ export const useSettingsStore = defineStore('settings', {
|
|
|
46
44
|
backgroundDisplay: 'white',
|
|
47
45
|
connectionType: 'All', // 'Origin', 'Via', 'Destination', 'All
|
|
48
46
|
},
|
|
49
|
-
}
|
|
47
|
+
};
|
|
50
48
|
},
|
|
51
49
|
getters: {
|
|
52
|
-
isFeaturedMarkerIdentifier: state => identifier => {
|
|
50
|
+
isFeaturedMarkerIdentifier: (state) => (identifier) => {
|
|
53
51
|
// state.featuredMarkerIdentifiers can be nested array
|
|
54
52
|
const flatIds = state.featuredMarkerIdentifiers.flat(Infinity);
|
|
55
53
|
return flatIds.includes(identifier);
|
|
56
54
|
},
|
|
57
|
-
featuredMarkerDoi: state => identifier => {
|
|
58
|
-
const index = state.featuredMarkerIdentifiers.findIndex(
|
|
59
|
-
element => element == identifier
|
|
60
|
-
);
|
|
55
|
+
featuredMarkerDoi: (state) => (identifier) => {
|
|
56
|
+
const index = state.featuredMarkerIdentifiers.findIndex((element) => element == identifier);
|
|
61
57
|
return state.featuredMarkerDois[index];
|
|
62
58
|
},
|
|
63
|
-
getGlobalSettings: state => () => {
|
|
59
|
+
getGlobalSettings: (state) => () => {
|
|
64
60
|
const globalSettings = {};
|
|
65
61
|
for (const [key, value] of Object.entries(state.globalSettings)) {
|
|
66
62
|
globalSettings[key] = value;
|
|
67
63
|
}
|
|
68
64
|
return globalSettings;
|
|
69
65
|
},
|
|
70
|
-
getUpdatedGlobalSettingsKey: state => settings => {
|
|
66
|
+
getUpdatedGlobalSettingsKey: (state) => (settings) => {
|
|
71
67
|
let updatedSettings = [];
|
|
72
68
|
for (const [key, value] of Object.entries(settings)) {
|
|
73
69
|
const attribute = state.globalSettings[key];
|
|
74
|
-
if (attribute === undefined ||
|
|
70
|
+
if (attribute === undefined || attribute !== value) {
|
|
75
71
|
updatedSettings.push(key);
|
|
76
72
|
}
|
|
77
73
|
}
|
|
78
74
|
return updatedSettings;
|
|
79
75
|
},
|
|
80
|
-
hasAppliedFacets: state => facets => {
|
|
76
|
+
hasAppliedFacets: (state) => (facets) => {
|
|
81
77
|
for (const facet of facets) {
|
|
82
78
|
for (const appliedFacet of state.appliedFacets) {
|
|
83
79
|
if (facet && appliedFacet && facet.toLowerCase() === appliedFacet.toLowerCase()) {
|
|
@@ -86,7 +82,7 @@ export const useSettingsStore = defineStore('settings', {
|
|
|
86
82
|
}
|
|
87
83
|
}
|
|
88
84
|
return false;
|
|
89
|
-
}
|
|
85
|
+
},
|
|
90
86
|
},
|
|
91
87
|
actions: {
|
|
92
88
|
updateShareLink(newLink) {
|
|
@@ -134,7 +130,7 @@ export const useSettingsStore = defineStore('settings', {
|
|
|
134
130
|
},
|
|
135
131
|
updateFeaturedMarker(payload) {
|
|
136
132
|
const index = this.featuredDatasetIdentifiers.findIndex(
|
|
137
|
-
element => element == payload.identifier
|
|
133
|
+
(element) => element == payload.identifier,
|
|
138
134
|
);
|
|
139
135
|
this.featuredMarkers[index] = payload.marker;
|
|
140
136
|
this.featuredMarkerDois[index] = payload.doi;
|
|
@@ -144,9 +140,7 @@ export const useSettingsStore = defineStore('settings', {
|
|
|
144
140
|
this.featuredMarkerIdentifiers[payload.index] = payload.markerIdentifier;
|
|
145
141
|
},
|
|
146
142
|
resetFeaturedMarkerIdentifier() {
|
|
147
|
-
this.featuredMarkerIdentifiers = new Array(
|
|
148
|
-
this.featuredDatasetIdentifiers.length
|
|
149
|
-
);
|
|
143
|
+
this.featuredMarkerIdentifiers = new Array(this.featuredDatasetIdentifiers.length);
|
|
150
144
|
},
|
|
151
145
|
updateAppliedFacets(facetsIn) {
|
|
152
146
|
this.appliedFacets = facetsIn;
|
|
@@ -156,10 +150,10 @@ export const useSettingsStore = defineStore('settings', {
|
|
|
156
150
|
let facets = { species: [], gender: [], organ: [] };
|
|
157
151
|
//First add missing item
|
|
158
152
|
if (facetsIn) {
|
|
159
|
-
facetsIn.forEach(e => {
|
|
153
|
+
facetsIn.forEach((e) => {
|
|
160
154
|
switch (e.term.toLowerCase()) {
|
|
161
|
-
case
|
|
162
|
-
if (e.facet.toLowerCase() !==
|
|
155
|
+
case 'species':
|
|
156
|
+
if (e.facet.toLowerCase() !== 'show all') {
|
|
163
157
|
facets.species.push(e.facet);
|
|
164
158
|
if (!this.facets.species.includes(e.facet)) {
|
|
165
159
|
this.facets.species.push(e.facet);
|
|
@@ -168,18 +162,16 @@ export const useSettingsStore = defineStore('settings', {
|
|
|
168
162
|
this.facets.species = [];
|
|
169
163
|
}
|
|
170
164
|
break;
|
|
171
|
-
case
|
|
172
|
-
if (e.facet.toLowerCase() !==
|
|
165
|
+
case 'gender':
|
|
166
|
+
if (e.facet.toLowerCase() !== 'show all') {
|
|
173
167
|
facets.gender.push(e.facet);
|
|
174
|
-
if (!this.facets.species.includes(e.facet))
|
|
175
|
-
this.facets.gender.push(e.facet);
|
|
168
|
+
if (!this.facets.species.includes(e.facet)) this.facets.gender.push(e.facet);
|
|
176
169
|
}
|
|
177
170
|
break;
|
|
178
|
-
case
|
|
179
|
-
if (e.facet.toLowerCase() !==
|
|
171
|
+
case 'organ':
|
|
172
|
+
if (e.facet.toLowerCase() !== 'show all') {
|
|
180
173
|
facets.organ.push(e.facet);
|
|
181
|
-
if (!this.facets.species.includes(e.facet))
|
|
182
|
-
this.facets.organ.push(e.facet);
|
|
174
|
+
if (!this.facets.species.includes(e.facet)) this.facets.organ.push(e.facet);
|
|
183
175
|
}
|
|
184
176
|
break;
|
|
185
177
|
default:
|
|
@@ -188,7 +180,7 @@ export const useSettingsStore = defineStore('settings', {
|
|
|
188
180
|
});
|
|
189
181
|
//Remove item not in list
|
|
190
182
|
for (const [key, arr] of Object.entries(this.facets)) {
|
|
191
|
-
let i
|
|
183
|
+
let i;
|
|
192
184
|
for (i = arr.length - 1; i >= 0; i -= 1) {
|
|
193
185
|
const index = facets[key].indexOf(arr[i]);
|
|
194
186
|
if (index == -1) {
|
|
@@ -224,5 +216,5 @@ export const useSettingsStore = defineStore('settings', {
|
|
|
224
216
|
this.globalSettings[key] = value;
|
|
225
217
|
}
|
|
226
218
|
},
|
|
227
|
-
}
|
|
219
|
+
},
|
|
228
220
|
});
|