@abi-software/flatmap-viewer 2.4.1-b.2 → 2.4.1-b.4
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.rst +1 -1
- package/package.json +1 -1
- package/src/flatmap-viewer.js +5 -2
- package/src/interactions.js +1 -1
- package/src/pathways.js +4 -0
package/README.rst
CHANGED
|
@@ -38,7 +38,7 @@ The map server endpoint is specified as ``MAP_ENDPOINT`` in ``src/main.js``. It
|
|
|
38
38
|
Package Installation
|
|
39
39
|
====================
|
|
40
40
|
|
|
41
|
-
* ``npm install @abi-software/flatmap-viewer@2.4.1-b.
|
|
41
|
+
* ``npm install @abi-software/flatmap-viewer@2.4.1-b.4``
|
|
42
42
|
|
|
43
43
|
Documentation
|
|
44
44
|
-------------
|
package/package.json
CHANGED
package/src/flatmap-viewer.js
CHANGED
|
@@ -39,6 +39,7 @@ import {UserInteractions} from './interactions.js';
|
|
|
39
39
|
|
|
40
40
|
import {MinimapControl} from './controls/minimap.js';
|
|
41
41
|
import {NavigationControl} from './controls/controls.js';
|
|
42
|
+
import {APINATOMY_PATH_PREFIX} from './pathways';
|
|
42
43
|
|
|
43
44
|
import * as images from './images.js';
|
|
44
45
|
import * as utils from './utils.js';
|
|
@@ -542,7 +543,7 @@ class FlatMap
|
|
|
542
543
|
}
|
|
543
544
|
|
|
544
545
|
__updateFeatureIdMapEntry(propertyId, featureIdMap, featureId)
|
|
545
|
-
|
|
546
|
+
//============================================================
|
|
546
547
|
{
|
|
547
548
|
const featureIds = featureIdMap.get(propertyId);
|
|
548
549
|
if (featureIds) {
|
|
@@ -564,7 +565,9 @@ class FlatMap
|
|
|
564
565
|
} else {
|
|
565
566
|
this.__updateFeatureIdMapEntry(propertyId, featureIdMap, annotation.featureId);
|
|
566
567
|
}
|
|
567
|
-
} else if (missingId !== null
|
|
568
|
+
} else if (missingId !== null
|
|
569
|
+
&& 'models' in annotation
|
|
570
|
+
&& annotation.models.startsWith(APINATOMY_PATH_PREFIX)) {
|
|
568
571
|
this.__updateFeatureIdMapEntry(missingId, featureIdMap, annotation.featureId);
|
|
569
572
|
}
|
|
570
573
|
}
|
package/src/interactions.js
CHANGED
|
@@ -1226,7 +1226,7 @@ export class UserInteractions
|
|
|
1226
1226
|
markerElement.appendChild(markerIcon);
|
|
1227
1227
|
|
|
1228
1228
|
const markerPosition = this.__markerPosition(featureId, annotation);
|
|
1229
|
-
const marker = new maplibregl.Marker(markerElement)
|
|
1229
|
+
const marker = new maplibregl.Marker({marker: markerElement})
|
|
1230
1230
|
.setLngLat(markerPosition)
|
|
1231
1231
|
.addTo(this._map);
|
|
1232
1232
|
markerElement.addEventListener('mouseenter',
|
package/src/pathways.js
CHANGED
|
@@ -28,6 +28,10 @@ export const PATHWAYS_LAYER = 'pathways';
|
|
|
28
28
|
|
|
29
29
|
//==============================================================================
|
|
30
30
|
|
|
31
|
+
export const APINATOMY_PATH_PREFIX = 'ilxtr:';
|
|
32
|
+
|
|
33
|
+
//==============================================================================
|
|
34
|
+
|
|
31
35
|
const PATH_TYPES = [
|
|
32
36
|
{ type: "cns", label: "CNS", colour: "#9B1FC1"},
|
|
33
37
|
{ type: "intracardiac", label: "Local circuit neuron", colour: "#F19E38"},
|