@cornerstonejs/tools 1.77.2 → 1.77.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.
package/package.json CHANGED
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "@cornerstonejs/tools",
3
- "version": "1.77.2",
3
+ "version": "1.77.3",
4
4
  "description": "Cornerstone3D Tools",
5
5
  "main": "src/index.ts",
6
6
  "types": "dist/types/index.d.ts",
@@ -29,7 +29,7 @@
29
29
  "webpack:watch": "webpack --mode development --progress --watch --config ./.webpack/webpack.dev.js"
30
30
  },
31
31
  "dependencies": {
32
- "@cornerstonejs/core": "^1.77.2",
32
+ "@cornerstonejs/core": "^1.77.3",
33
33
  "@icr/polyseg-wasm": "0.4.0",
34
34
  "@types/offscreencanvas": "2019.7.3",
35
35
  "comlink": "^4.4.1",
@@ -59,5 +59,5 @@
59
59
  "type": "individual",
60
60
  "url": "https://ohif.org/donate"
61
61
  },
62
- "gitHead": "f35943f80709a3ac0b262cfd8fa4281270936a44"
62
+ "gitHead": "a33572ac280ef5d42b56083161c020d04e4d30c2"
63
63
  }
@@ -54,27 +54,6 @@ import { CONSTANTS } from '@cornerstonejs/core';
54
54
 
55
55
  const { RENDERING_DEFAULTS } = CONSTANTS;
56
56
 
57
- // TODO: nested config is weird
58
- interface ToolConfiguration {
59
- configuration?: {
60
- getReferenceLineColor?: (viewportId: string) => string;
61
- getReferenceLineControllable?: (viewportId: string) => boolean;
62
- getReferenceLineDraggableRotatable?: (viewportId: string) => boolean;
63
- getReferenceLineSlabThicknessControlsOn?: (viewportId: string) => boolean;
64
- referenceLinesCenterGapRadius?: number;
65
- shadow?: boolean;
66
- autopan?: {
67
- enabled: boolean;
68
- panSize: number;
69
- };
70
- mobile?: {
71
- enabled: boolean;
72
- opacity: number;
73
- handleRadius: number;
74
- };
75
- };
76
- }
77
-
78
57
  interface CrosshairsAnnotation extends Annotation {
79
58
  data: {
80
59
  handles: {
@@ -142,7 +121,7 @@ class CrosshairsTool extends AnnotationTool {
142
121
  shadow: true,
143
122
  // renders a colored circle on top right of the viewports whose color
144
123
  // matches the color of the reference line
145
- viewportIndicators: true,
124
+ viewportIndicators: false,
146
125
 
147
126
  viewportIndicatorsConfig: {
148
127
  radius: 5,
@@ -1454,6 +1433,7 @@ class CrosshairsTool extends AnnotationTool {
1454
1433
  data.handles.rotationPoints = newRtpoints;
1455
1434
  data.handles.slabThicknessPoints = newStpoints;
1456
1435
 
1436
+ debugger;
1457
1437
  if (this.configuration.viewportIndicators) {
1458
1438
  const { viewportIndicatorsConfig } = this.configuration;
1459
1439
 
@@ -376,7 +376,7 @@ abstract class AnnotationTool extends AnnotationDisplayTool {
376
376
  if (viewport instanceof BaseVolumeViewport) {
377
377
  const volumeId = csUtils.getVolumeId(targetId);
378
378
  const volume = cache.getVolume(volumeId);
379
- return volume.scaling?.PT !== undefined;
379
+ return volume?.scaling?.PT !== undefined;
380
380
  }
381
381
  const scalingModule: Types.ScalingParameters | undefined =
382
382
  imageId && metaData.get('scalingModule', imageId);