larvitar 3.8.5 → 3.8.7

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.
Files changed (27) hide show
  1. package/README.md +2 -2
  2. package/dist/imaging/MetaDataTypes.d.ts +1 -0
  3. package/dist/imaging/imageContours.d.ts +2 -1
  4. package/dist/imaging/imageUtils.d.ts +19 -2
  5. package/dist/imaging/postProcessing/applyKernel.d.ts +1 -1
  6. package/dist/imaging/tools/custom/BorderMagnifyTool.d.ts +0 -1
  7. package/dist/imaging/tools/custom/EllipticalRoiUSTool.d.ts +0 -1
  8. package/dist/imaging/tools/custom/FreehandRoiUSTool.d.ts +0 -1
  9. package/dist/imaging/tools/custom/LengthPlotTool.d.ts +0 -1
  10. package/dist/imaging/tools/custom/LengthUSTool.d.ts +0 -1
  11. package/dist/imaging/tools/custom/ManualLengthPlotTool.d.ts +0 -1
  12. package/dist/imaging/tools/custom/OverlayTool.d.ts +0 -1
  13. package/dist/imaging/tools/custom/RectangleRoiUSTool.d.ts +0 -1
  14. package/dist/imaging/tools/custom/WwwcRemoveRegionTool.d.ts +0 -1
  15. package/dist/imaging/tools/custom/contourTool.d.ts +0 -1
  16. package/dist/imaging/tools/custom/customMouseWheelScrollTool.d.ts +0 -1
  17. package/dist/imaging/tools/custom/diameterTool.d.ts +0 -1
  18. package/dist/imaging/tools/custom/editMaskTool.d.ts +0 -1
  19. package/dist/imaging/tools/custom/gspsTool.d.ts +0 -1
  20. package/dist/imaging/tools/custom/polylineScissorsTool.d.ts +0 -1
  21. package/dist/imaging/tools/custom/rectangleRoiOverlayTool.d.ts +0 -1
  22. package/dist/imaging/tools/custom/rotateTool.d.ts +0 -1
  23. package/dist/imaging/tools/custom/thresholdsBrushTool.d.ts +0 -1
  24. package/dist/imaging/tools/custom/watershedSegmentationTool.d.ts +0 -1
  25. package/dist/larvitar.js +1 -1
  26. package/dist/logger.d.ts +2 -2
  27. package/package.json +9 -6
package/README.md CHANGED
@@ -66,11 +66,11 @@ To start developing Larvitar or contribute to the project:
66
66
  ```
67
67
  2. **Install dependencies**:
68
68
  ```bash
69
- yarn install
69
+ npm ci
70
70
  ```
71
71
  3. **Start the development server**:
72
72
  ```bash
73
- yarn run dev
73
+ npm run dev
74
74
  ```
75
75
  4. **Open the development environment**:
76
76
  - Serve the examples folder using a static server (e.g., `http-server` or visual studio code live server).
@@ -3,6 +3,7 @@ export type ExtendedMetaDataTypes = MetaDataTypes & {
3
3
  };
4
4
  export declare const arrayTags: string[];
5
5
  export type MetaDataTypes = {
6
+ x52009229?: MetaDataTypes[];
6
7
  x52009230?: MetaDataTypes[];
7
8
  x50000020?: string;
8
9
  x20000010?: number;
@@ -15,4 +15,5 @@ import { Contours } from "./types";
15
15
  */
16
16
  export declare const parseContours: (contoursData: {
17
17
  [key: string]: Uint8Array;
18
- }, pointBatchSize: number, segmentationName: string, viewports?: Array<string>) => Contours;
18
+ }, // TODO-ts: check if this is correct @mronzoni
19
+ pointBatchSize: number, segmentationName: string, viewports?: Array<string>) => Contours;
@@ -115,11 +115,28 @@ export declare const getReslicedMetadata: (reslicedSeriesId: string, fromOrienta
115
115
  };
116
116
  currentImageIdIndex: number;
117
117
  };
118
- export declare const getVOIFromMetadata: (metadata: MetaData, renderOptionsVoi?: any) => {
118
+ /**
119
+ * Compute resliced metadata from a cornerstone data structure
120
+ * @instance
121
+ * @function getVOIFromMetadata
122
+ * @param {MetaData} metadata - The metadata of the image to be rendered
123
+ * @param {number} frameIndex - The frame index to be rendered
124
+ * @param {any} renderOptionsVoi - The render options VOI, if defined it will be used instead of the metadata values
125
+ * @return {Object} - VOI object with windowCenter and windowWidth
126
+ */
127
+ export declare const getVOIFromMetadata: (metadata: MetaData, frameIndex?: number, renderOptionsVoi?: any) => {
119
128
  windowCenter: any;
120
129
  windowWidth: any;
121
130
  };
122
- export declare const getFrameSequenceMammoVOI: (metadata: MetaData) => {
131
+ /**
132
+ * Compute resliced metadata from a cornerstone data structure
133
+ * @instance
134
+ * @function getFrameSequenceMammoVOI
135
+ * @param {MetaData} metadata - The metadata of the image to be rendered
136
+ * @param {number} frameIndex - The frame index to be rendered
137
+ * @return {Object} - VOI object with windowCenter and windowWidth
138
+ */
139
+ export declare const getFrameSequenceMammoVOI: (metadata: MetaData, frameIndex: number) => {
123
140
  windowCenter: number | number[] | undefined;
124
141
  windowWidth: number | number[] | undefined;
125
142
  } | null;
@@ -13,7 +13,7 @@ export declare const addCustomKernel: (name: string, config: KernelConfig) => vo
13
13
  * @returns {ConvolutionKernels} - CONVOLUTION_KERNELS object
14
14
  */
15
15
  export declare const getKernels: () => {
16
- [x: string]: KernelConfig;
16
+ [key: string]: KernelConfig;
17
17
  };
18
18
  /**
19
19
  * Apply convolution filter to DICOM image
@@ -1,7 +1,6 @@
1
1
  import { EventData } from "../types";
2
2
  declare const MagnifyTool: any;
3
3
  export default class BorderMagnifyTool extends MagnifyTool {
4
- static [x: string]: any;
5
4
  constructor(props?: {
6
5
  showBorders?: boolean;
7
6
  showInfo?: boolean;
@@ -9,7 +9,6 @@ import { Coords, EventData, MeasurementData, MeasurementMouseEvent } from "../ty
9
9
  * @extends Tools.Base.BaseAnnotationTool
10
10
  */
11
11
  export default class EllipticalRoiTool extends BaseAnnotationTool {
12
- static [x: string]: any;
13
12
  constructor(props?: {});
14
13
  createNewMeasurement(eventData: EventData): {
15
14
  visible: boolean;
@@ -92,7 +92,6 @@ import { HandlePosition, Rectangle, Stats } from "../types";
92
92
  * @extends Tools.Base.BaseAnnotationTool
93
93
  */
94
94
  export default class FreehandRoiTool extends BaseAnnotationTool {
95
- static [x: string]: any;
96
95
  private isMultiPartTool;
97
96
  private _drawing;
98
97
  private _dragging;
@@ -70,7 +70,6 @@ interface PlotlyData {
70
70
  * @extends cornerstoneTools.Base.BaseTool
71
71
  */
72
72
  export default class LengthPlotTool extends BaseAnnotationTool {
73
- static [x: string]: any;
74
73
  name: string;
75
74
  eventData?: EventData;
76
75
  datahandles?: Handles | null;
@@ -1,7 +1,6 @@
1
1
  declare const BaseAnnotationTool: any;
2
2
  import { MeasurementData, MeasurementMouseEvent, Coords, EventData } from "../types";
3
3
  export default class LengthTool extends BaseAnnotationTool {
4
- static [x: string]: any;
5
4
  constructor(props?: {});
6
5
  createNewMeasurement(eventData: EventData): {
7
6
  visible: boolean;
@@ -61,7 +61,6 @@ type PlotlyData = {
61
61
  * @extends Tools.Base.BaseAnnotationTool
62
62
  */
63
63
  export default class ManualLengthPlotTool extends BaseAnnotationTool {
64
- static [x: string]: any;
65
64
  name: string;
66
65
  eventData?: EventData;
67
66
  datahandles?: Handles;
@@ -17,7 +17,6 @@ interface ToolMouseEvent {
17
17
  * @extends Tools.Base.BaseTool
18
18
  */
19
19
  export default class OverlayTool extends BaseTool {
20
- static [x: string]: any;
21
20
  constructor(configuration?: {});
22
21
  enabledCallback(element: HTMLElement): void;
23
22
  disabledCallback(element: HTMLElement): void;
@@ -9,7 +9,6 @@ import { Coords, EventData, MeasurementData, MeasurementMouseEvent } from "../ty
9
9
  * @extends Tools.Base.BaseAnnotationTool
10
10
  */
11
11
  export default class RectangleRoiTool extends BaseAnnotationTool {
12
- static [x: string]: any;
13
12
  constructor(props?: {});
14
13
  createNewMeasurement(eventData: EventData): {
15
14
  visible: boolean;
@@ -9,7 +9,6 @@ declare const BaseAnnotationTool: any;
9
9
  * @extends Tools.Base.BaseTool
10
10
  */
11
11
  export default class WwwcRemoveRegionTool extends BaseAnnotationTool {
12
- static [x: string]: any;
13
12
  constructor(props?: {});
14
13
  createNewMeasurement(eventData: EventData): {
15
14
  computeMeasurements: any;
@@ -14,7 +14,6 @@ declare const BaseAnnotationTool: any;
14
14
  * @extends Tools.Base.BaseAnnotationTool
15
15
  */
16
16
  export declare class ContoursTool extends BaseAnnotationTool {
17
- static [x: string]: any;
18
17
  constructor(props?: {
19
18
  contoursParsedData?: ContourData;
20
19
  segmentationName?: string;
@@ -20,7 +20,6 @@ type ToolEventDetail = {
20
20
  };
21
21
  };
22
22
  export default class CustomMouseWheelScrollTool extends BaseTool {
23
- static [x: string]: any;
24
23
  currentMode: string;
25
24
  framesNumber: number;
26
25
  slicesnumber: number;
@@ -73,7 +73,6 @@ interface MeasurementEvent extends Event {
73
73
  * @extends Tools.Base.BaseAnnotationTool
74
74
  */
75
75
  export declare class DiameterTool extends BidirectionalTool {
76
- static [x: string]: any;
77
76
  name: string;
78
77
  isBeenModified: boolean;
79
78
  lastData: ToolData | null;
@@ -12,7 +12,6 @@ declare const BaseBrushTool: any;
12
12
  * @extends Tools.Base.BaseBrushTool
13
13
  */
14
14
  export declare class EditMaskTool extends BaseBrushTool {
15
- static [x: string]: any;
16
15
  constructor(props?: {
17
16
  mask?: MaskData;
18
17
  initCallback?: Function;
@@ -12,7 +12,6 @@ declare const BaseTool: any;
12
12
  * @extends Tools.Base.BaseTool
13
13
  */
14
14
  export default class GspsTool extends BaseTool {
15
- static [x: string]: any;
16
15
  name: string;
17
16
  toolAnnotations: ToolAnnotations;
18
17
  showAnnotations: boolean;
@@ -11,7 +11,6 @@ declare const BaseTool: any;
11
11
  * @extends Tools.Base.BaseTool
12
12
  */
13
13
  export default class PolylineScissorsTool extends BaseTool {
14
- static [x: string]: any;
15
14
  /** @inheritdoc */
16
15
  constructor(props?: {});
17
16
  }
@@ -9,7 +9,6 @@ declare const BaseAnnotationTool: any;
9
9
  * @extends Tools.Base.BaseAnnotationTool
10
10
  */
11
11
  export default class RectangleRoiOverlayTool extends BaseAnnotationTool {
12
- static [x: string]: any;
13
12
  constructor(props?: {});
14
13
  createNewMeasurement(eventData: EventData): {
15
14
  computeMeasurements: any;
@@ -9,7 +9,6 @@ declare const BaseTool: any;
9
9
  * @extends Tools.Base.BaseTool
10
10
  */
11
11
  export default class RotateTool extends BaseTool {
12
- static [x: string]: any;
13
12
  constructor(props?: {});
14
13
  touchDragCallback(evt: MeasurementMouseEvent): void;
15
14
  mouseDragCallback(evt: MeasurementMouseEvent): void;
@@ -14,7 +14,6 @@ declare const BaseBrushTool: any;
14
14
  * @extends Tools.Base.BaseBrushTool
15
15
  */
16
16
  export default class ThresholdsBrushTool extends BaseBrushTool {
17
- static [x: string]: any;
18
17
  constructor(props?: {});
19
18
  /**
20
19
  * Event handler for MOUSE_UP during the drawing event loop.
@@ -15,7 +15,6 @@ import { Series } from "../../types";
15
15
  * @extends Tools.Base.BaseBrushTool
16
16
  */
17
17
  export default class WSToggleTool extends BaseBrushTool {
18
- static [x: string]: any;
19
18
  private maskArray;
20
19
  private maskArrayCurrentImage;
21
20
  private dicomPixelData;