@cornerstonejs/core 1.66.4 → 1.66.5

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/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cornerstonejs/core",
3
- "version": "1.66.4",
3
+ "version": "1.66.5",
4
4
  "description": "",
5
5
  "main": "src/index.ts",
6
6
  "types": "dist/types/index.d.ts",
@@ -47,5 +47,5 @@
47
47
  "type": "individual",
48
48
  "url": "https://ohif.org/donate"
49
49
  },
50
- "gitHead": "4d12d9d2ecf38805e7c9ca7e93bf36372bfe85ff"
50
+ "gitHead": "23c01d5231da3a5283a0d042e4eb5abac3aed44e"
51
51
  }
@@ -863,7 +863,9 @@ abstract class BaseVolumeViewport extends Viewport implements IVolumeViewport {
863
863
  const colormapsVTK = vtkColorMaps.rgbPresetNames.map((presetName) =>
864
864
  vtkColorMaps.getPresetByName(presetName)
865
865
  );
866
- const colormapsCS3D = getColormapNames().map((colormapName) => getColormap(colormapName));
866
+ const colormapsCS3D = getColormapNames().map((colormapName) =>
867
+ getColormap(colormapName)
868
+ );
867
869
  const colormaps = colormapsVTK.concat(colormapsCS3D);
868
870
  const matchedColormap = colormaps.find((colormap) => {
869
871
  const { RGBPoints: presetRGBPoints } = colormap;
@@ -1563,7 +1565,8 @@ abstract class BaseVolumeViewport extends Viewport implements IVolumeViewport {
1563
1565
 
1564
1566
  sliceIndex ??= this.getCurrentImageIdIndex();
1565
1567
  const { viewPlaneNormal, focalPoint } = this.getCamera();
1566
- return `volumeId:${volumeId}?sliceIndex=${sliceIndex}&viewPlaneNormal=${viewPlaneNormal.join(
1568
+ const querySeparator = volumeId.indexOf('?') > -1 ? '&' : '?';
1569
+ return `volumeId:${volumeId}${querySeparator}sliceIndex=${sliceIndex}&viewPlaneNormal=${viewPlaneNormal.join(
1567
1570
  ','
1568
1571
  )}&focalPoint=${focalPoint.join(',')}`;
1569
1572
  }
@@ -66,8 +66,8 @@ export default function getTargetVolumeAndSpacingInNormalDir(
66
66
 
67
67
  // If a volumeId is defined, set that volume as the target
68
68
  if (targetVolumeId) {
69
- const imageVolumeIndex = imageVolumes.findIndex(
70
- (iv) => iv.volumeId === targetVolumeId
69
+ const imageVolumeIndex = imageVolumes.findIndex((iv) =>
70
+ iv.volumeId.includes(targetVolumeId)
71
71
  );
72
72
 
73
73
  const imageVolume = imageVolumes[imageVolumeIndex];