@abi-software/mapintegratedvuer 1.6.1 → 1.6.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.
@@ -1,8 +1,8 @@
1
1
  import "vue";
2
- import { u as p, b as g, E as l, T as y, d as m, e as w } from "./index-D_VgD-w_.js";
2
+ import { u as p, b as g, E as l, T as y, c as m, d as w } from "./index-BGGZxwXr.js";
3
3
  import { mapStores as A } from "pinia";
4
4
  let c = 7, s = 5;
5
- const N = [
5
+ const v = [
6
6
  {
7
7
  id: "UBERON:0000948",
8
8
  name: "heart",
@@ -253,7 +253,7 @@ const N = [
253
253
  keyword: !0
254
254
  }
255
255
  ];
256
- function v(e) {
256
+ function N(e) {
257
257
  return e[0].toUpperCase() + e.substring(1);
258
258
  }
259
259
  const B = {
@@ -345,7 +345,7 @@ const B = {
345
345
  if (e == "MultiFlatmap" || e == "Flatmap")
346
346
  if (a.internalName = this.idNamePair[t.feature.models], t.eventType == "click")
347
347
  if (a.eventType = "selected", t.feature.type == "marker") {
348
- let d = this.idNamePair[t.feature.models], u = N.filter(
348
+ let d = this.idNamePair[t.feature.models], u = v.filter(
349
349
  (h) => h.id === t.feature.models
350
350
  );
351
351
  this.settingsStore.isFeaturedMarkerIdentifier(
@@ -369,7 +369,7 @@ const B = {
369
369
  else t.eventType == "mouseenter" && (a.eventType = "highlighted", n = !0);
370
370
  else e == "Scaffold" && (t && t[0] && ((((o = t[0].data) == null ? void 0 : o.id) === void 0 || ((r = t[0].data) == null ? void 0 : r.id) === "") && (t[0].data.id = (f = t[0].data) == null ? void 0 : f.group), a.internalName = t[0].data.id, t[0].data.lastActionOnMarker === !0 && (i = {
371
371
  type: "Facet",
372
- facet: v(t[0].data.id),
372
+ facet: N(t[0].data.id),
373
373
  facetPropPath: "anatomy.organ.category.name",
374
374
  term: "Anatomical structure"
375
375
  })), a.eventType = "selected", n = !0);
@@ -552,6 +552,9 @@ const B = {
552
552
  },
553
553
  onConnectivityInfoClose: function() {
554
554
  l.emit("connectivity-info-close");
555
+ },
556
+ onConnectivityGraphError: function(e) {
557
+ l.emit("connectivity-graph-error", e);
555
558
  }
556
559
  },
557
560
  data: function() {
@@ -1,12 +1,12 @@
1
- import { _ as c, $ as h, t as u, T as s, E as l } from "./index-D_VgD-w_.js";
2
- import { C as I } from "./ContentMixin-BTXCMWvE.js";
3
- import { D as y, Q as g } from "./style-ZSZlDMUI.js";
4
- import { resolveComponent as p, openBlock as r, createElementBlock as M, createVNode as v, createBlock as S, createCommentVNode as C } from "vue";
1
+ import { _ as d, K as h, t as u, T as r, E as l } from "./index-BGGZxwXr.js";
2
+ import { C as I } from "./ContentMixin-CWtYskLS.js";
3
+ import { D as v, Q as y } from "./style-CmiFzzZy.js";
4
+ import { resolveComponent as s, openBlock as p, createElementBlock as g, createVNode as M, createBlock as S, createCommentVNode as C } from "vue";
5
5
  const F = {
6
6
  name: "Flatmap",
7
- mixins: [I, y],
7
+ mixins: [I, v],
8
8
  components: {
9
- FlatmapVuer: g,
9
+ FlatmapVuer: y,
10
10
  HelpModeDialog: h
11
11
  },
12
12
  methods: {
@@ -25,17 +25,17 @@ const F = {
25
25
  },
26
26
  flatmaprResourceSelected: function(e, t) {
27
27
  if (this.resourceSelected(e, t), t.eventType === "click" && t.feature.type === "feature") {
28
- const o = {
28
+ const a = {
29
29
  label: t.label || "",
30
30
  id: t.feature.id || "",
31
31
  featureId: t.feature.featureId || "",
32
32
  taxonomy: t.taxonomy || "",
33
33
  resources: t.resource.join(", ")
34
- }, a = u(o);
35
- s.sendEvent({
34
+ }, n = u(a);
35
+ r.sendEvent({
36
36
  event: "interaction_event",
37
37
  event_name: "portal_maps_connectivity",
38
- category: a,
38
+ category: n,
39
39
  location: e + " " + this.$refs.flatmap.viewingMode
40
40
  });
41
41
  }
@@ -45,21 +45,21 @@ const F = {
45
45
  l.emit("mapImpProv", t), this.$emit("flatmap-provenance-ready", t), this.flatmapReadyForMarkerUpdates(e), l.emit("mapLoaded", e);
46
46
  },
47
47
  onPathwaySelectionChanged: function(e) {
48
- const { label: t, property: o, checked: a, selectionsTitle: n } = e;
49
- s.sendEvent({
48
+ const { label: t, property: a, checked: n, selectionsTitle: i } = e;
49
+ r.sendEvent({
50
50
  event: "interaction_event",
51
51
  event_name: "portal_maps_pathway_change",
52
- category: t + " [" + o + "] " + a,
53
- location: n
52
+ category: t + " [" + a + "] " + n,
53
+ location: i
54
54
  });
55
55
  },
56
56
  highlightFeatures: function(e) {
57
57
  let t = e.name;
58
- const o = this.$refs.flatmap.mapImp;
58
+ const a = this.$refs.flatmap.mapImp;
59
59
  if (t) {
60
- const a = o.search(t);
61
- a.featureIds[0] && o.highlightFeatures([
62
- o.modelForFeature(a.featureIds[0])
60
+ const n = a.search(t);
61
+ n.featureIds[0] && a.highlightFeatures([
62
+ a.modelForFeature(n.featureIds[0])
63
63
  ]);
64
64
  }
65
65
  },
@@ -67,22 +67,25 @@ const F = {
67
67
  * Append the list of suggested terms to suggestions
68
68
  */
69
69
  searchSuggestions: function(e, t) {
70
- e && this.$refs.flatmap.mapImp && this.$refs.flatmap.mapImp.search(e).__featureIds.forEach((a) => {
71
- const n = this.$refs.flatmap.mapImp.annotation(a);
72
- n && n.label && t.push(n.label);
73
- });
70
+ if (e && this.$refs.flatmap.mapImp) {
71
+ const a = this.$refs.flatmap.mapImp.search(e);
72
+ (a.__featureIds || a.featureIds).forEach((i) => {
73
+ const o = this.$refs.flatmap.mapImp.annotation(i);
74
+ o && o.label && t.push(o.label);
75
+ });
76
+ }
74
77
  },
75
78
  zoomToFeatures: function(e, t) {
76
- let o = e.name;
77
- const a = this.$refs.flatmap.mapImp;
78
- if (o) {
79
- const n = a.search(o);
80
- if (n.featureIds.length) {
81
- let i = a.modelForFeature(n.featureIds[0]);
82
- i ? (t && a.selectFeatures(i), a.zoomToFeatures(i)) : a.clearSearchResults();
79
+ let a = e.name;
80
+ const n = this.$refs.flatmap.mapImp;
81
+ if (a) {
82
+ const i = n.search(a);
83
+ if (i.featureIds.length) {
84
+ let o = n.modelForFeature(i.featureIds[0]);
85
+ o ? (t && n.selectFeatures(o), n.zoomToFeatures(o)) : n.clearSearchResults();
83
86
  }
84
87
  } else
85
- a.clearSearchResults();
88
+ n.clearSearchResults();
86
89
  },
87
90
  changeViewingMode: function(e) {
88
91
  this.$refs.flatmap.changeViewingMode(e);
@@ -94,26 +97,29 @@ const F = {
94
97
  }
95
98
  },
96
99
  mounted: function() {
97
- l.on("markerUpdate", () => {
100
+ l.on("annotation-close", (e) => {
101
+ const t = this.$refs.flatmap;
102
+ e != null && e.tabClose && t && this.$refs.flatmap.annotationEventCallback({}, { type: "aborted" });
103
+ }), l.on("markerUpdate", () => {
98
104
  this.flatmapMarkerUpdate(void 0);
99
105
  }), l.on("hoverUpdate", () => {
100
106
  this.mapHoverHighlight(this.$refs.flatmap.mapImp);
101
107
  }), l.on("show-connectivity", (e) => {
102
- const { featureIds: t, offset: o } = e, a = this.$refs.flatmap;
103
- a && a.moveMap(t, {
104
- offsetX: o ? -150 : 0,
108
+ const { featureIds: t, offset: a } = e, n = this.$refs.flatmap;
109
+ n && n.moveMap(t, {
110
+ offsetX: a ? -150 : 0,
105
111
  zoom: 4
106
112
  });
107
113
  });
108
114
  }
109
115
  }, w = { class: "viewer-container" };
110
- function $(e, t, o, a, n, i) {
111
- const m = p("FlatmapVuer"), f = p("HelpModeDialog");
112
- return r(), M("div", w, [
113
- v(m, {
116
+ function b(e, t, a, n, i, o) {
117
+ const m = s("FlatmapVuer"), f = s("HelpModeDialog");
118
+ return p(), g("div", w, [
119
+ M(m, {
114
120
  state: e.entry.state,
115
121
  entry: e.entry.resource,
116
- onResourceSelected: t[0] || (t[0] = (d) => i.flatmaprResourceSelected(e.entry.type, d)),
122
+ onResourceSelected: t[0] || (t[0] = (c) => o.flatmaprResourceSelected(e.entry.type, c)),
117
123
  onPanZoomCallback: e.flatmapPanZoomCallback,
118
124
  name: e.entry.resource,
119
125
  style: { height: "100%", width: "100%" },
@@ -125,21 +131,25 @@ function $(e, t, o, a, n, i) {
125
131
  onHelpModeLastItem: e.onHelpModeLastItem,
126
132
  onShownTooltip: e.onTooltipShown,
127
133
  onShownMapTooltip: e.onMapTooltipShown,
134
+ onAnnotationOpen: e.onAnnotationOpen,
135
+ onAnnotationClose: e.onAnnotationClose,
136
+ annotationSidebar: e.annotationSidebar,
128
137
  onConnectivityInfoOpen: e.onConnectivityInfoOpen,
129
138
  onConnectivityInfoClose: e.onConnectivityInfoClose,
139
+ onConnectivityGraphError: e.onConnectivityGraphError,
130
140
  connectivityInfoSidebar: e.connectivityInfoSidebar,
131
141
  pathControls: !0,
132
142
  ref: "flatmap",
133
- onReady: i.flatmapReadyCall,
143
+ onReady: o.flatmapReadyCall,
134
144
  displayMinimap: !1,
135
145
  displayWarning: !0,
136
146
  enableOpenMapUI: !0,
137
147
  flatmapAPI: e.flatmapAPI,
138
148
  sparcAPI: e.apiLocation,
139
149
  onOpenMap: e.openMap,
140
- onPathwaySelectionChanged: i.onPathwaySelectionChanged
141
- }, null, 8, ["state", "entry", "onPanZoomCallback", "name", "minZoom", "helpMode", "helpModeActiveItem", "helpModeDialog", "onHelpModeLastItem", "onShownTooltip", "onShownMapTooltip", "onConnectivityInfoOpen", "onConnectivityInfoClose", "connectivityInfoSidebar", "onReady", "flatmapAPI", "sparcAPI", "onOpenMap", "onPathwaySelectionChanged"]),
142
- e.helpMode && e.useHelpModeDialog ? (r(), S(f, {
150
+ onPathwaySelectionChanged: o.onPathwaySelectionChanged
151
+ }, null, 8, ["state", "entry", "onPanZoomCallback", "name", "minZoom", "helpMode", "helpModeActiveItem", "helpModeDialog", "onHelpModeLastItem", "onShownTooltip", "onShownMapTooltip", "onAnnotationOpen", "onAnnotationClose", "annotationSidebar", "onConnectivityInfoOpen", "onConnectivityInfoClose", "onConnectivityGraphError", "connectivityInfoSidebar", "onReady", "flatmapAPI", "sparcAPI", "onOpenMap", "onPathwaySelectionChanged"]),
152
+ e.helpMode && e.useHelpModeDialog ? (p(), S(f, {
143
153
  key: 0,
144
154
  ref: "flatmapHelp",
145
155
  flatmapRef: e.flatmapRef,
@@ -149,7 +159,7 @@ function $(e, t, o, a, n, i) {
149
159
  }, null, 8, ["flatmapRef", "lastItem", "onShowNext", "onFinishHelpMode"])) : C("", !0)
150
160
  ]);
151
161
  }
152
- const P = /* @__PURE__ */ c(F, [["render", $], ["__scopeId", "data-v-d49919d0"]]);
162
+ const R = /* @__PURE__ */ d(F, [["render", b], ["__scopeId", "data-v-7635fa9b"]]);
153
163
  export {
154
- P as default
164
+ R as default
155
165
  };
@@ -1,6 +1,6 @@
1
- import { C as r } from "./ContentMixin-BTXCMWvE.js";
1
+ import { C as r } from "./ContentMixin-CWtYskLS.js";
2
2
  import { openBlock as o, createElementBlock as t, createElementVNode as s } from "vue";
3
- import { _ as n } from "./index-D_VgD-w_.js";
3
+ import { _ as n } from "./index-BGGZxwXr.js";
4
4
  const a = {
5
5
  name: "Iframe",
6
6
  mixins: [r]
@@ -1,8 +1,8 @@
1
- import { _ as M, $ as I, a as C, g as S, E as r, t as F, T as f, c as u } from "./index-D_VgD-w_.js";
2
- import { C as k } from "./ContentMixin-BTXCMWvE.js";
3
- import { D as b, P as w } from "./style-ZSZlDMUI.js";
4
- import { resolveComponent as d, openBlock as h, createElementBlock as R, createVNode as H, createBlock as $, createCommentVNode as P } from "vue";
5
- const T = '<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>', g = (e) => {
1
+ import { _ as u, K as h, a as y, g, E as r, t as M, T as p } from "./index-BGGZxwXr.js";
2
+ import { C as v } from "./ContentMixin-CWtYskLS.js";
3
+ import { D as I, a as C } from "./style-CmiFzzZy.js";
4
+ import { resolveComponent as f, openBlock as c, createElementBlock as S, createVNode as F, createBlock as k, createCommentVNode as w } from "vue";
5
+ const b = '<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>', d = (e) => {
6
6
  const t = [
7
7
  {
8
8
  display: "Open AC Map",
@@ -28,21 +28,21 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
28
28
  break;
29
29
  }
30
30
  return t;
31
- }, L = {
31
+ }, R = {
32
32
  name: "MultiFlatmap",
33
- mixins: [k, b],
33
+ mixins: [v, I],
34
34
  components: {
35
- MultiFlatmapVuer: w,
36
- HelpModeDialog: I
35
+ MultiFlatmapVuer: C,
36
+ HelpModeDialog: h
37
37
  },
38
38
  data: function() {
39
39
  return {
40
40
  zoomLevel: 6,
41
41
  flatmapReady: !1,
42
- availableSpecies: C(),
42
+ availableSpecies: y(),
43
43
  scaffoldResource: {},
44
44
  showStarInLegend: !1,
45
- openMapOptions: g("Human Male")
45
+ openMapOptions: d("Human Male")
46
46
  };
47
47
  },
48
48
  methods: {
@@ -60,7 +60,7 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
60
60
  title: "View 3D scaffold",
61
61
  layout: "2horpanel",
62
62
  type: "SyncMap"
63
- } : (this.activeSpecies === "Human Male" || this.activeSpecies === "Human Female") && ("human" in this.scaffoldResource || (this.scaffoldResource.human = await S(this.apiLocation, "human")), e = {
63
+ } : (this.activeSpecies === "Human Male" || this.activeSpecies === "Human Female") && ("human" in this.scaffoldResource || (this.scaffoldResource.human = await g(this.apiLocation, "human")), e = {
64
64
  contextCardUrl: this.scaffoldResource.human.datasetInfo.contextCardUrl,
65
65
  discoverId: this.scaffoldResource.human.datasetInfo.discoverId,
66
66
  s3uri: this.scaffoldResource.human.datasetInfo.s3uri,
@@ -103,8 +103,8 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
103
103
  if (e && a.mapImp) {
104
104
  const n = a.mapImp.search(e);
105
105
  (n.__featureIds || n.featureIds).forEach((i) => {
106
- const l = a.mapImp.annotation(i);
107
- l && l.label && t.push(l.label);
106
+ const s = a.mapImp.annotation(i);
107
+ s && s.label && t.push(s.label);
108
108
  });
109
109
  }
110
110
  },
@@ -117,8 +117,8 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
117
117
  featureId: t.feature.featureId || "",
118
118
  taxonomy: t.taxonomy || "",
119
119
  resources: t.resource.join(", ")
120
- }, o = F(n);
121
- f.sendEvent({
120
+ }, o = M(n);
121
+ p.sendEvent({
122
122
  event: "interaction_event",
123
123
  event_name: "portal_maps_connectivity",
124
124
  category: o,
@@ -128,7 +128,7 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
128
128
  },
129
129
  onPathwaySelectionChanged: function(e) {
130
130
  const { label: t, property: a, checked: n, selectionsTitle: o } = e;
131
- f.sendEvent({
131
+ p.sendEvent({
132
132
  event: "interaction_event",
133
133
  event_name: "portal_maps_pathway_change",
134
134
  category: t + " [" + a + "] " + n,
@@ -136,7 +136,7 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
136
136
  });
137
137
  },
138
138
  onOpenPubmedUrl: function(e) {
139
- f.sendEvent({
139
+ p.sendEvent({
140
140
  event: "interaction_event",
141
141
  event_name: "portal_maps_pubmed_url",
142
142
  file_path: e,
@@ -149,12 +149,12 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
149
149
  handleSyncPanZoomEvent: function(e) {
150
150
  if (!this.mouseHovered && e.type !== this.entry.type) {
151
151
  const t = e.payload.zoom, a = e.payload.target, n = this.$el.clientHeight, o = this.$el.clientWidth, i = Math.max(o, n);
152
- let l = o / i / t;
153
- const s = n / i / t, p = [
154
- a[0] / 2 + 0.5 - l / 2,
155
- 0.5 - a[1] / 2 - s / 2
152
+ let s = o / i / t;
153
+ const l = n / i / t, m = [
154
+ a[0] / 2 + 0.5 - s / 2,
155
+ 0.5 - a[1] / 2 - l / 2
156
156
  ];
157
- this.$refs.multiflatmap.getCurrentFlatmap().mapImp.panZoomTo(p, [l, s]);
157
+ this.$refs.multiflatmap.getCurrentFlatmap().mapImp.panZoomTo(m, [s, l]);
158
158
  }
159
159
  },
160
160
  displayTooltip: function(e) {
@@ -188,7 +188,7 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
188
188
  }
189
189
  },
190
190
  flatmapChanged: async function(e) {
191
- this.activeSpecies = e, this.openMapOptions = g(e), this.$emit("species-changed", e), this.entry.state && this.entry.state.species === this.activeSpecies || this.syncMode == !0 && await this.toggleSyncMode(), this.updateProvCard(), this.onConnectivityInfoClose(), f.sendEvent({
191
+ this.activeSpecies = e, this.openMapOptions = d(e), this.$emit("species-changed", e), this.entry.state && this.entry.state.species === this.activeSpecies || this.syncMode == !0 && await this.toggleSyncMode(), this.updateProvCard(), this.onConnectivityInfoClose(), p.sendEvent({
192
192
  event: "interaction_event",
193
193
  event_name: "portal_maps_species_change",
194
194
  category: this.activeSpecies
@@ -232,15 +232,15 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
232
232
  let o = a;
233
233
  if (o || (o = this.getFlatmapImp()), o) {
234
234
  let i = document.createElement("div");
235
- i.innerHTML = T;
236
- const l = o.addMarker(e, {
235
+ i.innerHTML = b;
236
+ const s = o.addMarker(e, {
237
237
  element: i,
238
238
  className: "highlight-marker",
239
239
  cluster: !1
240
240
  });
241
241
  return this.settingsStore.updateFeaturedMarkerIdentifier({
242
242
  index: t,
243
- markerIdentifier: l
243
+ markerIdentifier: s
244
244
  }), !0;
245
245
  }
246
246
  return !1;
@@ -251,72 +251,8 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
251
251
  changeViewingMode: function(e) {
252
252
  this.$refs.multiflatmap.getCurrentFlatmap().changeViewingMode(e);
253
253
  },
254
- removeConnectivityTooltips: function() {
255
- const e = this.$refs.multiflatmap.getCurrentFlatmap();
256
- e != null && e.$el && e.$el.querySelectorAll(".flatmap-tooltip-popup").forEach((a) => a.remove());
257
- },
258
- createTooltipForConnectivity: function(e, t) {
259
- const a = document.createElement("div");
260
- a.classList.add("flatmap-feature-label"), e.forEach((n, o) => {
261
- const { label: i } = n;
262
- if (a.append(u(i)), o + 1 < e.length) {
263
- const l = document.createElement("hr");
264
- a.appendChild(l);
265
- }
266
- }), t.showPopup(
267
- e[0].featureId,
268
- a,
269
- {
270
- className: "custom-popup flatmap-tooltip-popup",
271
- positionAtLastClick: !1,
272
- preserveSelection: !0
273
- }
274
- );
275
- },
276
- emitConnectivityGraphError: function(e) {
277
- if (e.length) {
278
- const t = [...new Set(e)];
279
- let a = "";
280
- t.forEach((n, o) => {
281
- const { label: i } = n;
282
- a += o === 0 ? u(i) : i, t.length > 1 && (o + 2 === t.length ? a += " and " : o + 1 < t.length && (a += ", "));
283
- }), a += " cannot be found on the map!", r.emit("connectivity-graph-error", {
284
- data: a
285
- });
286
- }
287
- },
288
254
  showConnectivityTooltips: function(e) {
289
- const { connectivityInfo: t, data: a } = e, n = [], o = [], i = [], l = [];
290
- if (!a.length)
291
- this.removeConnectivityTooltips();
292
- else if (typeof a[0] == "object")
293
- a.forEach((s) => {
294
- o.push({
295
- id: s.id,
296
- label: s.name
297
- });
298
- });
299
- else
300
- for (let s = 0; s < a.length / 2; s++)
301
- o.push({
302
- id: a[s],
303
- label: a[s + a.length / 2]
304
- });
305
- if (t && t.featureId && n.push(...t.featureId), this.flatmapReady) {
306
- const s = this.$refs.multiflatmap.getCurrentFlatmap();
307
- s.mapImp && (o.forEach((p, A) => {
308
- const { id: c, label: y } = p, m = s.mapImp.search(c);
309
- if (m != null && m.results.length) {
310
- const v = m == null ? void 0 : m.results[0].featureId;
311
- i.push({
312
- featureId: v,
313
- id: c,
314
- label: y
315
- }), n.push(c);
316
- } else
317
- l.push(p);
318
- }), i.length ? this.createTooltipForConnectivity(i, s.mapImp) : (l.push(...o), this.removeConnectivityTooltips()), this.emitConnectivityGraphError(l), s.mapImp.zoomToFeatures(n, { noZoomIn: !0 }));
319
- }
255
+ this.flatmapReady && this.$refs.multiflatmap.getCurrentFlatmap().showConnectivityTooltips(e);
320
256
  }
321
257
  },
322
258
  computed: {
@@ -355,16 +291,16 @@ const T = '<svg width="72px" height="72px" viewBox="0 0 24 24" fill="yellow"><pa
355
291
  this.flatmapReady && this.mapHoverHighlight(this.$refs.multiflatmap.getCurrentFlatmap().mapImp);
356
292
  });
357
293
  }
358
- }, E = { class: "viewer-container" };
359
- function O(e, t, a, n, o, i) {
360
- const l = d("MultiFlatmapVuer"), s = d("HelpModeDialog");
361
- return h(), R("div", E, [
362
- H(l, {
294
+ }, H = { class: "viewer-container" };
295
+ function L(e, t, a, n, o, i) {
296
+ const s = f("MultiFlatmapVuer"), l = f("HelpModeDialog");
297
+ return c(), S("div", H, [
298
+ F(s, {
363
299
  availableSpecies: e.availableSpecies,
364
300
  onFlatmapChanged: i.flatmapChanged,
365
301
  onReady: i.multiFlatmapReady,
366
302
  state: e.entry.state,
367
- onResourceSelected: t[0] || (t[0] = (p) => i.flatmaprResourceSelected(e.entry.type, p)),
303
+ onResourceSelected: t[0] || (t[0] = (m) => i.flatmaprResourceSelected(e.entry.type, m)),
368
304
  style: { height: "100%", width: "100%" },
369
305
  initial: e.entry.resource,
370
306
  helpMode: e.helpMode,
@@ -378,6 +314,7 @@ function O(e, t, a, n, o, i) {
378
314
  annotationSidebar: e.annotationSidebar,
379
315
  onConnectivityInfoOpen: e.onConnectivityInfoOpen,
380
316
  onConnectivityInfoClose: e.onConnectivityInfoClose,
317
+ onConnectivityGraphError: e.onConnectivityGraphError,
381
318
  connectivityInfoSidebar: e.connectivityInfoSidebar,
382
319
  ref: "multiflatmap",
383
320
  displayMinimap: !0,
@@ -391,18 +328,18 @@ function O(e, t, a, n, o, i) {
391
328
  onFinishHelpMode: e.endHelp,
392
329
  onPathwaySelectionChanged: i.onPathwaySelectionChanged,
393
330
  onOpenPubmedUrl: i.onOpenPubmedUrl
394
- }, null, 8, ["availableSpecies", "onFlatmapChanged", "onReady", "state", "initial", "helpMode", "helpModeActiveItem", "helpModeDialog", "onHelpModeLastItem", "onShownTooltip", "onShownMapTooltip", "onAnnotationOpen", "onAnnotationClose", "annotationSidebar", "onConnectivityInfoOpen", "onConnectivityInfoClose", "connectivityInfoSidebar", "showStarInLegend", "openMapOptions", "flatmapAPI", "sparcAPI", "onPanZoomCallback", "onOpenMap", "onFinishHelpMode", "onPathwaySelectionChanged", "onOpenPubmedUrl"]),
395
- e.helpMode && e.useHelpModeDialog ? (h(), $(s, {
331
+ }, null, 8, ["availableSpecies", "onFlatmapChanged", "onReady", "state", "initial", "helpMode", "helpModeActiveItem", "helpModeDialog", "onHelpModeLastItem", "onShownTooltip", "onShownMapTooltip", "onAnnotationOpen", "onAnnotationClose", "annotationSidebar", "onConnectivityInfoOpen", "onConnectivityInfoClose", "onConnectivityGraphError", "connectivityInfoSidebar", "showStarInLegend", "openMapOptions", "flatmapAPI", "sparcAPI", "onPanZoomCallback", "onOpenMap", "onFinishHelpMode", "onPathwaySelectionChanged", "onOpenPubmedUrl"]),
332
+ e.helpMode && e.useHelpModeDialog ? (c(), k(l, {
396
333
  key: 0,
397
334
  ref: "multiflatmapHelp",
398
335
  multiflatmapRef: e.multiflatmapRef,
399
336
  lastItem: e.helpModeLastItem,
400
337
  onShowNext: e.onHelpModeShowNext,
401
338
  onFinishHelpMode: e.onFinishHelpMode
402
- }, null, 8, ["multiflatmapRef", "lastItem", "onShowNext", "onFinishHelpMode"])) : P("", !0)
339
+ }, null, 8, ["multiflatmapRef", "lastItem", "onShowNext", "onFinishHelpMode"])) : w("", !0)
403
340
  ]);
404
341
  }
405
- const Z = /* @__PURE__ */ M(L, [["render", O], ["__scopeId", "data-v-9e95f83d"]]);
342
+ const T = /* @__PURE__ */ u(R, [["render", L], ["__scopeId", "data-v-4282737c"]]);
406
343
  export {
407
- Z as default
344
+ T as default
408
345
  };
@@ -1,7 +1,7 @@
1
1
  import { y as o } from "./plotvuer-DSwGHaaa.js";
2
- import { C as a } from "./ContentMixin-BTXCMWvE.js";
2
+ import { C as a } from "./ContentMixin-CWtYskLS.js";
3
3
  import { resolveComponent as r, openBlock as n, createBlock as s } from "vue";
4
- import { _ as m } from "./index-D_VgD-w_.js";
4
+ import { _ as m } from "./index-BGGZxwXr.js";
5
5
  const p = {
6
6
  name: "Plot",
7
7
  mixins: [a],
@@ -1,5 +1,5 @@
1
- import { I as K1, R as Q1, w as ew, h as tw, N as iw, z as rw, _ as nw, $ as ow, E as Wu } from "./index-D_VgD-w_.js";
2
- import { C as aw } from "./ContentMixin-BTXCMWvE.js";
1
+ import { R as K1, U as Q1, w as ew, h as tw, q as iw, G as rw, _ as nw, K as ow, E as Wu } from "./index-BGGZxwXr.js";
2
+ import { C as aw } from "./ContentMixin-CWtYskLS.js";
3
3
  import { ref as Ae, defineComponent as Ie, computed as ce, openBlock as fe, createElementBlock as Ce, mergeProps as Pr, unref as H, renderSlot as qe, useAttrs as sw, useSlots as au, shallowRef as Pi, watch as Je, nextTick as _t, onMounted as ni, toRef as ki, createCommentVNode as Ve, Fragment as Gt, normalizeClass as Le, createElementVNode as ke, createBlock as He, withCtx as pe, resolveDynamicComponent as Fi, withModifiers as ui, createVNode as se, toDisplayString as wt, normalizeStyle as It, provide as pi, reactive as Yi, onActivated as lw, onUpdated as rp, inject as ct, onBeforeUnmount as sr, withDirectives as Bt, cloneVNode as cw, Text as o0, Comment as uw, Transition as hl, vShow as yi, readonly as a0, onDeactivated as hw, toHandlers as dw, withKeys as gr, createTextVNode as yt, createSlots as pw, toRefs as cn, getCurrentInstance as si, h as ba, renderList as rr, onUnmounted as s0, markRaw as Ai, watchEffect as l0, warn as fw, onBeforeMount as mw, toRaw as np, getCurrentScope as c0, onScopeDispose as u0, isRef as Ro, isVNode as Qh, Teleport as gw, resolveComponent as Ri, resolveDirective as vw, toHandlerKey as yw, vModelText as bw, createApp as xw, hasInjectionContext as ww, effectScope as _w, isReactive as op, pushScopeId as Mw, popScopeId as Sw } from "vue";
4
4
  const Kr = (i, e, { checkForDefaultPrevented: t = !0 } = {}) => (r) => {
5
5
  const n = i == null ? void 0 : i(r);
@@ -1,7 +1,7 @@
1
- import { C as Bc } from "./ContentMixin-BTXCMWvE.js";
1
+ import { C as Bc } from "./ContentMixin-CWtYskLS.js";
2
2
  import { ref as P, defineComponent as K, computed as g, openBlock as j, createElementBlock as L, mergeProps as rn, unref as d, renderSlot as te, useAttrs as Dc, useSlots as vs, shallowRef as $n, watch as ne, nextTick as Ae, onMounted as $e, toRef as ft, createCommentVNode as W, Fragment as qe, normalizeClass as z, createElementVNode as Z, createBlock as Y, withCtx as X, resolveDynamicComponent as mt, withModifiers as Re, createVNode as fe, toDisplayString as ze, normalizeStyle as Te, provide as at, reactive as vt, onActivated as Uc, onUpdated as hs, inject as me, onBeforeUnmount as Et, withDirectives as He, cloneVNode as qc, Text as ys, Comment as Hc, Transition as so, vShow as $t, readonly as Zc, onDeactivated as Kc, withKeys as Mt, createSlots as Wc, toRefs as On, getCurrentInstance as Ze, h as Rn, renderList as on, warn as Jc, onBeforeMount as Gc, onUnmounted as Yc, toRaw as gs, watchEffect as Qc, getCurrentScope as Xc, onScopeDispose as ep, isRef as bs, Teleport as tp, resolveComponent as Ct, resolveDirective as np, toHandlerKey as rp, createTextVNode as Yt, vModelText as op, pushScopeId as ap, popScopeId as ip, createApp as lp } from "vue";
3
3
  import { y as sp } from "./plotvuer-DSwGHaaa.js";
4
- import { _ as up } from "./index-D_VgD-w_.js";
4
+ import { _ as up } from "./index-BGGZxwXr.js";
5
5
  const It = (e, t, { checkForDefaultPrevented: n = !0 } = {}) => (r) => {
6
6
  const o = e == null ? void 0 : e(r);
7
7
  if (n === !1 || !o)