@abi-software/mapintegratedvuer 1.1.0-beta.5 → 1.1.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/README.md +15 -2
- package/dist/{ContentMixin-C35Jowvp.js → ContentMixin-mZX2duoM.js} +97 -61
- package/dist/Flatmap-9QQ19krS.js +146 -0
- package/dist/{Iframe-fcNscihB.js → Iframe-c0h0PhkG.js} +2 -2
- package/dist/{MultiFlatmap-BIT2tVyE.js → MultiFlatmap-ft_NGtN3.js} +82 -65
- package/dist/{Plot-B9xsWP2v.js → Plot-BmyzQ7ix.js} +2 -2
- package/dist/{Scaffold-DYoxAJI0.js → Scaffold-B7UCL6S4.js} +10924 -10527
- package/dist/{Simulation-s1KOrb80.js → Simulation-OLJ83BaS.js} +2 -2
- package/dist/{flatmapvuer-BM5z_95w.js → flatmapvuer-BAx-xO4L.js} +11714 -11457
- package/dist/{index-DIFC-Q9x.js → index-nmieCwQF.js} +4369 -4335
- package/dist/mapintegratedvuer.js +1 -1
- package/dist/mapintegratedvuer.umd.cjs +479 -479
- package/dist/style-UwGHggI4.js +62 -0
- package/dist/style.css +1 -1
- package/package.json +7 -4
- package/src/App.vue +10 -1
- package/src/components/ContentVuer.vue +10 -10
- package/src/components/FlatmapContextCard.vue +22 -10
- package/src/components/MapContent.vue +20 -2
- package/src/components/SplitDialog.vue +4 -4
- package/src/components/SplitFlow.vue +6 -9
- package/src/components/viewers/Flatmap.vue +50 -25
- package/src/components/viewers/MultiFlatmap.vue +59 -32
- package/src/components/viewers/Scaffold.vue +46 -24
- package/src/components.d.ts +0 -1
- package/src/mixins/ContentMixin.js +72 -3
- package/src/mixins/DynamicMarkerMixin.js +44 -25
- package/src/services/tagging.js +3 -4
- package/src/stores/settings.js +5 -1
- package/src/stores/splitFlow.js +42 -30
- package/dist/Flatmap-9P71mP5D.js +0 -128
- package/dist/style-B-Ps72EF.js +0 -50
@@ -1,9 +1,9 @@
|
|
1
|
-
import { _ as
|
2
|
-
import {
|
3
|
-
import { C as
|
4
|
-
import { D as
|
5
|
-
import { resolveComponent as
|
6
|
-
const
|
1
|
+
import { _ as c, a as h, g as M, E as l, t as g, T as p } from "./index-nmieCwQF.js";
|
2
|
+
import { D as y, B as v } from "./flatmapvuer-BAx-xO4L.js";
|
3
|
+
import { C as S } from "./ContentMixin-mZX2duoM.js";
|
4
|
+
import { D as I } from "./style-UwGHggI4.js";
|
5
|
+
import { resolveComponent as d, openBlock as f, createElementBlock as k, createVNode as C, createBlock as F, createCommentVNode as w } from "vue";
|
6
|
+
const R = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><path d="M11.0748 3.25583C11.4141 2.42845 12.5859 2.42845 12.9252 3.25583L14.6493 7.45955C14.793 7.80979 15.1221 8.04889 15.4995 8.07727L20.0303 8.41798C20.922 8.48504 21.2841 9.59942 20.6021 10.1778L17.1369 13.1166C16.8482 13.3614 16.7225 13.7483 16.8122 14.1161L17.8882 18.5304C18.1 19.3992 17.152 20.0879 16.3912 19.618L12.5255 17.2305C12.2034 17.0316 11.7966 17.0316 11.4745 17.2305L7.60881 19.618C6.84796 20.0879 5.90001 19.3992 6.1118 18.5304L7.18785 14.1161C7.2775 13.7483 7.1518 13.3614 6.86309 13.1166L3.3979 10.1778C2.71588 9.59942 3.07796 8.48504 3.96971 8.41798L8.50046 8.07727C8.87794 8.04889 9.20704 7.80979 9.35068 7.45955L11.0748 3.25583Z" stroke="#000000" stroke-width="2"/></svg>', u = (e) => {
|
7
7
|
const t = [
|
8
8
|
{
|
9
9
|
display: "Open AC Map",
|
@@ -29,20 +29,21 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
29
29
|
break;
|
30
30
|
}
|
31
31
|
return t;
|
32
|
-
},
|
32
|
+
}, b = {
|
33
33
|
name: "MultiFlatmap",
|
34
|
-
mixins: [
|
34
|
+
mixins: [S, I],
|
35
35
|
components: {
|
36
|
-
MultiFlatmapVuer: y
|
36
|
+
MultiFlatmapVuer: y,
|
37
|
+
HelpModeDialog: v
|
37
38
|
},
|
38
39
|
data: function() {
|
39
40
|
return {
|
40
41
|
zoomLevel: 6,
|
41
42
|
flatmapReady: !1,
|
42
|
-
availableSpecies:
|
43
|
+
availableSpecies: h(),
|
43
44
|
scaffoldResource: {},
|
44
45
|
showStarInLegend: !1,
|
45
|
-
openMapOptions:
|
46
|
+
openMapOptions: u("Rat")
|
46
47
|
};
|
47
48
|
},
|
48
49
|
methods: {
|
@@ -60,7 +61,7 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
60
61
|
title: "View 3D scaffold",
|
61
62
|
layout: "2horpanel",
|
62
63
|
type: "SyncMap"
|
63
|
-
} : (this.activeSpecies === "Human Male" || this.activeSpecies === "Human Female") && ("human" in this.scaffoldResource || (this.scaffoldResource.human = await
|
64
|
+
} : (this.activeSpecies === "Human Male" || this.activeSpecies === "Human Female") && ("human" in this.scaffoldResource || (this.scaffoldResource.human = await M(this.apiLocation, "human")), e = {
|
64
65
|
contextCardUrl: this.scaffoldResource.human.datasetInfo.contextCardUrl,
|
65
66
|
discoverId: this.scaffoldResource.human.datasetInfo.discoverId,
|
66
67
|
s3uri: this.scaffoldResource.human.datasetInfo.s3uri,
|
@@ -87,7 +88,7 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
87
88
|
payload: e,
|
88
89
|
type: this.entry.type
|
89
90
|
};
|
90
|
-
this.$emit("resource-selected", t);
|
91
|
+
this.flatmapMarkerZoomUpdate(!1, void 0), this.$emit("resource-selected", t);
|
91
92
|
}
|
92
93
|
},
|
93
94
|
/**
|
@@ -101,9 +102,9 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
101
102
|
*/
|
102
103
|
searchSuggestions: function(e, t) {
|
103
104
|
const a = this.$refs.multiflatmap.getCurrentFlatmap();
|
104
|
-
e && a.mapImp && a.mapImp.search(e).__featureIds.forEach((
|
105
|
-
const
|
106
|
-
|
105
|
+
e && a.mapImp && a.mapImp.search(e).__featureIds.forEach((o) => {
|
106
|
+
const s = a.mapImp.annotation(o);
|
107
|
+
s && s.label && t.push(s.label);
|
107
108
|
});
|
108
109
|
},
|
109
110
|
flatmaprResourceSelected: function(e, t) {
|
@@ -115,22 +116,22 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
115
116
|
featureId: t.feature.featureId || "",
|
116
117
|
taxonomy: t.taxonomy || "",
|
117
118
|
resources: t.resource.join(", ")
|
118
|
-
},
|
119
|
+
}, o = g(n);
|
119
120
|
p.sendEvent({
|
120
121
|
event: "interaction_event",
|
121
122
|
event_name: "portal_maps_connectivity",
|
122
|
-
category:
|
123
|
+
category: o,
|
123
124
|
location: e + " " + a.viewingMode
|
124
125
|
});
|
125
126
|
}
|
126
127
|
},
|
127
128
|
onPathwaySelectionChanged: function(e) {
|
128
|
-
const { label: t, property: a, checked: n, selectionsTitle:
|
129
|
+
const { label: t, property: a, checked: n, selectionsTitle: o } = e;
|
129
130
|
p.sendEvent({
|
130
131
|
event: "interaction_event",
|
131
132
|
event_name: "portal_maps_pathway_change",
|
132
133
|
category: t + " [" + a + "] " + n,
|
133
|
-
location:
|
134
|
+
location: o
|
134
135
|
});
|
135
136
|
},
|
136
137
|
onOpenPubmedUrl: function(e) {
|
@@ -146,13 +147,13 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
146
147
|
*/
|
147
148
|
handleSyncPanZoomEvent: function(e) {
|
148
149
|
if (!this.mouseHovered && e.type !== this.entry.type) {
|
149
|
-
const t = e.payload.zoom, a = e.payload.target, n = this.$el.clientHeight,
|
150
|
-
let
|
151
|
-
const
|
152
|
-
a[0] / 2 + 0.5 -
|
153
|
-
0.5 - a[1] / 2 -
|
150
|
+
const t = e.payload.zoom, a = e.payload.target, n = this.$el.clientHeight, o = this.$el.clientWidth, s = Math.max(o, n);
|
151
|
+
let i = o / s / t;
|
152
|
+
const r = n / s / t, m = [
|
153
|
+
a[0] / 2 + 0.5 - i / 2,
|
154
|
+
0.5 - a[1] / 2 - r / 2
|
154
155
|
];
|
155
|
-
this.$refs.multiflatmap.getCurrentFlatmap().mapImp.panZoomTo(
|
156
|
+
this.$refs.multiflatmap.getCurrentFlatmap().mapImp.panZoomTo(m, [i, r]), this.flatmapMarkerZoomUpdate(!1, void 0);
|
156
157
|
}
|
157
158
|
},
|
158
159
|
displayTooltip: function(e) {
|
@@ -165,8 +166,8 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
165
166
|
let a = e.name;
|
166
167
|
const n = this.$refs.multiflatmap.getCurrentFlatmap().mapImp;
|
167
168
|
if (a) {
|
168
|
-
const
|
169
|
-
|
169
|
+
const o = n.search(a);
|
170
|
+
o.featureIds.length > 0 ? (t && n.selectFeatures(o.featureIds), n.zoomToFeatures(o.featureIds)) : n.clearSearchResults();
|
170
171
|
} else
|
171
172
|
n.clearSearchResults();
|
172
173
|
},
|
@@ -186,7 +187,7 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
186
187
|
}
|
187
188
|
},
|
188
189
|
flatmapChanged: async function(e) {
|
189
|
-
this.activeSpecies = e, this.openMapOptions =
|
190
|
+
this.activeSpecies = e, this.openMapOptions = u(e), this.$emit("species-changed", e), this.entry.state && this.entry.state.species === this.activeSpecies || this.syncMode == !0 && await this.toggleSyncMode(), this.updateProvCard(), p.sendEvent({
|
190
191
|
event: "interaction_event",
|
191
192
|
event_name: "portal_maps_species_change",
|
192
193
|
category: this.activeSpecies
|
@@ -196,11 +197,11 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
196
197
|
if (e) {
|
197
198
|
e.enablePanZoomEvents(!0), this.flatmapReady = !0;
|
198
199
|
const t = e.mapImp;
|
199
|
-
this.
|
200
|
+
this.flatmapMarkerZoomUpdate(!0, t), this.updateProvCard();
|
200
201
|
}
|
201
202
|
},
|
202
203
|
getFlatmapImp: function() {
|
203
|
-
if (this.entry.type === "MultiFlatmap" && this.flatmapReady)
|
204
|
+
if (this.entry.type === "MultiFlatmap" && this.flatmapReady && this.$refs.multiflatmap)
|
204
205
|
return this.$refs.multiflatmap.getCurrentFlatmap().mapImp;
|
205
206
|
},
|
206
207
|
flatmapAreaSearch() {
|
@@ -225,18 +226,18 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
225
226
|
const n = this.settingsStore.featuredMarkerSpecies[t];
|
226
227
|
if (n && !this.activeSpecies.startsWith(n))
|
227
228
|
return !1;
|
228
|
-
let
|
229
|
-
if (
|
230
|
-
let
|
231
|
-
|
232
|
-
const
|
233
|
-
element:
|
229
|
+
let o = a;
|
230
|
+
if (o || (o = this.getFlatmapImp()), o) {
|
231
|
+
let s = document.createElement("div");
|
232
|
+
s.innerHTML = R;
|
233
|
+
const i = o.addMarker(e, {
|
234
|
+
element: s,
|
234
235
|
className: "highlight-marker",
|
235
236
|
cluster: !1
|
236
237
|
});
|
237
238
|
return this.settingsStore.updateFeaturedMarkerIdentifier({
|
238
239
|
index: t,
|
239
|
-
markerIdentifier:
|
240
|
+
markerIdentifier: i
|
240
241
|
}), !0;
|
241
242
|
}
|
242
243
|
return !1;
|
@@ -260,35 +261,51 @@ const C = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
|
|
260
261
|
},
|
261
262
|
mounted: function() {
|
262
263
|
this.getAvailableTerms(), this.getFeaturedDatasets(), l.on("markerUpdate", () => {
|
263
|
-
this.
|
264
|
+
this.flatmapMarkerZoomUpdate(!0, void 0);
|
264
265
|
});
|
265
266
|
}
|
266
|
-
};
|
267
|
-
function
|
268
|
-
const
|
269
|
-
return
|
270
|
-
|
271
|
-
|
272
|
-
|
273
|
-
|
274
|
-
|
275
|
-
|
276
|
-
|
277
|
-
|
278
|
-
|
279
|
-
|
280
|
-
|
281
|
-
|
282
|
-
|
283
|
-
|
284
|
-
|
285
|
-
|
286
|
-
|
287
|
-
|
288
|
-
|
289
|
-
|
267
|
+
}, H = { class: "viewer-container" };
|
268
|
+
function P(e, t, a, n, o, s) {
|
269
|
+
const i = d("MultiFlatmapVuer"), r = d("HelpModeDialog");
|
270
|
+
return f(), k("div", H, [
|
271
|
+
C(i, {
|
272
|
+
availableSpecies: e.availableSpecies,
|
273
|
+
onFlatmapChanged: s.flatmapChanged,
|
274
|
+
onReady: s.multiFlatmapReady,
|
275
|
+
state: e.entry.state,
|
276
|
+
onResourceSelected: t[0] || (t[0] = (m) => s.flatmaprResourceSelected(e.entry.type, m)),
|
277
|
+
style: { height: "100%", width: "100%" },
|
278
|
+
initial: e.entry.resource,
|
279
|
+
helpMode: e.helpMode,
|
280
|
+
helpModeActiveItem: e.helpModeActiveItem,
|
281
|
+
helpModeDialog: e.useHelpModeDialog,
|
282
|
+
onHelpModeLastItem: e.onHelpModeLastItem,
|
283
|
+
onShownTooltip: e.onTooltipShown,
|
284
|
+
onShownMapTooltip: e.onMapTooltipShown,
|
285
|
+
ref: "multiflatmap",
|
286
|
+
displayMinimap: !0,
|
287
|
+
showStarInLegend: e.showStarInLegend,
|
288
|
+
enableOpenMapUI: !0,
|
289
|
+
openMapOptions: e.openMapOptions,
|
290
|
+
flatmapAPI: e.flatmapAPI,
|
291
|
+
sparcAPI: e.apiLocation,
|
292
|
+
onPanZoomCallback: s.flatmapPanZoomCallback,
|
293
|
+
onOpenMap: e.openMap,
|
294
|
+
onFinishHelpMode: e.endHelp,
|
295
|
+
onPathwaySelectionChanged: s.onPathwaySelectionChanged,
|
296
|
+
onOpenPubmedUrl: s.onOpenPubmedUrl
|
297
|
+
}, null, 8, ["availableSpecies", "onFlatmapChanged", "onReady", "state", "initial", "helpMode", "helpModeActiveItem", "helpModeDialog", "onHelpModeLastItem", "onShownTooltip", "onShownMapTooltip", "showStarInLegend", "openMapOptions", "flatmapAPI", "sparcAPI", "onPanZoomCallback", "onOpenMap", "onFinishHelpMode", "onPathwaySelectionChanged", "onOpenPubmedUrl"]),
|
298
|
+
e.helpMode && e.useHelpModeDialog ? (f(), F(r, {
|
299
|
+
key: 0,
|
300
|
+
ref: "multiflatmapHelp",
|
301
|
+
multiflatmapRef: e.multiflatmapRef,
|
302
|
+
lastItem: e.helpModeLastItem,
|
303
|
+
onShowNext: e.onHelpModeShowNext,
|
304
|
+
onFinishHelpMode: e.onFinishHelpMode
|
305
|
+
}, null, 8, ["multiflatmapRef", "lastItem", "onShowNext", "onFinishHelpMode"])) : w("", !0)
|
306
|
+
]);
|
290
307
|
}
|
291
|
-
const
|
308
|
+
const A = /* @__PURE__ */ c(b, [["render", P], ["__scopeId", "data-v-35d3ec56"]]);
|
292
309
|
export {
|
293
|
-
|
310
|
+
A as default
|
294
311
|
};
|
@@ -1,7 +1,7 @@
|
|
1
1
|
import { C as o } from "./plotvuer-X4h-Lj3L.js";
|
2
|
-
import { C as a } from "./ContentMixin-
|
2
|
+
import { C as a } from "./ContentMixin-mZX2duoM.js";
|
3
3
|
import { resolveComponent as r, openBlock as n, createBlock as s } from "vue";
|
4
|
-
import { _ as m } from "./index-
|
4
|
+
import { _ as m } from "./index-nmieCwQF.js";
|
5
5
|
const p = {
|
6
6
|
name: "Plot",
|
7
7
|
mixins: [a],
|