@ohif/app 3.13.0-beta.116 → 3.13.0-beta.117

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 (47) hide show
  1. package/dist/{1206.bundle.47f070e2254d128c.js → 1206.bundle.e04ca1efe6f987ba.js} +1 -1
  2. package/dist/1483.bundle.ab1e3a882b58eb79.js +470 -0
  3. package/dist/{1602.bundle.097ec19e8e61516f.js → 1602.bundle.ea4c1b43123dd2b3.js} +2 -2
  4. package/dist/{7701.bundle.945445d6681ddd20.js → 2343.bundle.48839e1b3fa4505e.js} +990 -7
  5. package/dist/{3500.bundle.1e063b7b4910d6cf.js → 3500.bundle.da69a02594beccc8.js} +1 -1
  6. package/dist/{3760.bundle.6c7eeb4b7f1583ca.js → 3760.bundle.e406b1c3fadf2a3b.js} +2 -2
  7. package/dist/{5448.bundle.1e50777e4c4e122a.js → 5448.bundle.5686ebb99c379f64.js} +1 -1
  8. package/dist/{5696.bundle.9f0366ad867385bc.js → 5696.bundle.4e44ce1f590134eb.js} +7 -4
  9. package/dist/{5910.bundle.5561806884c95754.js → 5910.bundle.0f19608f3e76859b.js} +2 -2
  10. package/dist/{419.bundle.9d0e6a72e1e3a17b.js → 6749.bundle.8c3dd9258f09df24.js} +288 -62
  11. package/dist/{7248.bundle.f761b21f343d4b9f.js → 7248.bundle.11ec7ee7e10b0a34.js} +2 -2
  12. package/dist/{7295.bundle.4d4b6de4d2bb8856.js → 7499.bundle.0f065214db09a60b.js} +502 -5
  13. package/dist/{781.bundle.efb0a6981676cebb.js → 781.bundle.3c1a02ca26d4565a.js} +2 -2
  14. package/dist/{8423.bundle.5d1b3092bc9562c9.js → 8423.bundle.f8e7d0f1eba7e178.js} +2 -2
  15. package/dist/8492.bundle.de58afbc98ce7972.js +504 -0
  16. package/dist/8595.css +2 -0
  17. package/dist/{899.bundle.e786f8dfb66d74ca.js → 899.bundle.50c16f860acbc848.js} +2 -2
  18. package/dist/{9068.bundle.cd36fcb4e15a153e.js → 9068.bundle.95f1e638ef694ea9.js} +2 -2
  19. package/dist/{9402.bundle.6549cc304496cd5c.js → 9402.bundle.6a8a324e963b4099.js} +2 -2
  20. package/dist/{9415.bundle.2a970c71de4014bf.js → 9415.bundle.20fee612b3b3dbfd.js} +2 -2
  21. package/dist/{9437.bundle.0fff227a859992ea.js → 9437.bundle.f3f5aff637471ac4.js} +107 -123
  22. package/dist/app-config.js +1 -1
  23. package/dist/{app.bundle.55057e411d635dc3.js → app.bundle.a73ad7e598640adf.js} +203 -36
  24. package/dist/customizations/index.html +400 -0
  25. package/dist/customizations/segmentation/segmentationAnnotationTools.jsonc +48 -0
  26. package/dist/customizations/segmentation/segmentationEditing.jsonc +59 -0
  27. package/dist/customizations/{ctPresets.jsonc → tools/ctPresets.jsonc} +1 -1
  28. package/dist/customizations/{measurementLabels.jsonc → tools/measurementLabels.jsonc} +1 -1
  29. package/dist/customizations/{smoothRotate.jsonc → tools/smoothRotate.jsonc} +1 -1
  30. package/dist/customizations/veterinary/veterinary.jsonc +5 -0
  31. package/dist/customizations/{veterinaryOverlay.jsonc → veterinary/veterinaryOverlay.jsonc} +3 -3
  32. package/dist/customizations/{patientBirthDate.jsonc → worklist/patientBirthDate.jsonc} +2 -2
  33. package/dist/index.html +1 -1
  34. package/dist/sw.js +1 -1
  35. package/package.json +5 -5
  36. package/dist/4834.bundle.a91450199d0f45e4.js +0 -900
  37. package/dist/6001.bundle.0789789db5410764.js +0 -1529
  38. package/dist/customizations/veterinary.jsonc +0 -5
  39. /package/dist/{100.bundle.ac04a425c0851574.js → 100.bundle.ec5ee3b5f479a217.js} +0 -0
  40. /package/dist/{1180.bundle.c19c443fe8d26719.js → 1180.bundle.9bed26c1a1e75389.js} +0 -0
  41. /package/dist/{2779.bundle.dca036a18399be96.js → 2779.bundle.2a225a69fb65c30d.js} +0 -0
  42. /package/dist/{4556.bundle.b705ab15473128c7.js → 4556.bundle.735ccc9efdad0052.js} +0 -0
  43. /package/dist/{4683.bundle.5d12928efa9f70f4.js → 4683.bundle.e5d3182f0f4347af.js} +0 -0
  44. /package/dist/{7295.css → 8492.css} +0 -0
  45. /package/dist/{8832.bundle.ede981706cac8e15.js → 8832.bundle.1cb57aab32daeab8.js} +0 -0
  46. /package/dist/{9116.bundle.225e003c28c550c1.js → 9116.bundle.fffb2ff349a3c452.js} +0 -0
  47. /package/dist/{9290.bundle.a18c40b82772a3c6.js → 9290.bundle.82cf4e74ab3fa20a.js} +0 -0
@@ -1,900 +0,0 @@
1
- "use strict";
2
- (globalThis["rspackChunk"] = globalThis["rspackChunk"] || []).push([[4834], {
3
- 74137(__unused_rspack_module, __webpack_exports__, __webpack_require__) {
4
-
5
- // EXPORTS
6
- __webpack_require__.d(__webpack_exports__, {
7
- "default": () => (/* binding */ tmtv_src)
8
- });
9
-
10
- // EXTERNAL MODULE: ../../core/src/index.ts + 75 modules
11
- var src = __webpack_require__(50679);
12
- ;// CONCATENATED MODULE: ../../../modes/tmtv/src/constants.ts
13
- const MIN_SEGMENTATION_DRAWING_RADIUS = 0.5;
14
- const MAX_SEGMENTATION_DRAWING_RADIUS = 99.5;
15
- ;// CONCATENATED MODULE: ../../../modes/tmtv/src/initToolGroups.js
16
-
17
- const toolGroupIds = {
18
- CT: 'ctToolGroup',
19
- PT: 'ptToolGroup',
20
- Fusion: 'fusionToolGroup',
21
- MIP: 'mipToolGroup',
22
- default: 'default'
23
- };
24
- function _initToolGroups(toolNames, Enums, toolGroupService, commandsManager) {
25
- const tools = {
26
- active: [{
27
- toolName: toolNames.WindowLevel,
28
- bindings: [{
29
- mouseButton: Enums.MouseBindings.Primary
30
- }]
31
- }, {
32
- toolName: toolNames.Pan,
33
- bindings: [{
34
- mouseButton: Enums.MouseBindings.Auxiliary
35
- }]
36
- }, {
37
- toolName: toolNames.Zoom,
38
- bindings: [{
39
- mouseButton: Enums.MouseBindings.Secondary
40
- }, {
41
- numTouchPoints: 2
42
- }]
43
- }, {
44
- toolName: toolNames.StackScroll,
45
- bindings: [{
46
- mouseButton: Enums.MouseBindings.Wheel
47
- }, {
48
- numTouchPoints: 3
49
- }]
50
- }],
51
- passive: [{
52
- toolName: toolNames.Length
53
- }, {
54
- toolName: toolNames.SegmentBidirectional
55
- }, {
56
- toolName: toolNames.ArrowAnnotate,
57
- configuration: {
58
- getTextCallback: (callback, eventDetails) => {
59
- commandsManager.runCommand('arrowTextCallback', {
60
- callback,
61
- eventDetails
62
- });
63
- },
64
- changeTextCallback: (data, eventDetails, callback) => {
65
- commandsManager.runCommand('arrowTextCallback', {
66
- callback,
67
- data,
68
- eventDetails
69
- });
70
- }
71
- }
72
- }, {
73
- toolName: toolNames.Bidirectional
74
- }, {
75
- toolName: toolNames.DragProbe
76
- }, {
77
- toolName: toolNames.Probe
78
- }, {
79
- toolName: toolNames.EllipticalROI
80
- }, {
81
- toolName: toolNames.RectangleROI
82
- }, {
83
- toolName: toolNames.StackScroll
84
- }, {
85
- toolName: toolNames.Angle
86
- }, {
87
- toolName: toolNames.CobbAngle
88
- }, {
89
- toolName: toolNames.Magnify
90
- }, {
91
- toolName: 'CircularBrush',
92
- parentTool: 'Brush',
93
- configuration: {
94
- activeStrategy: 'FILL_INSIDE_CIRCLE',
95
- minRadius: (/* inlined export .MIN_SEGMENTATION_DRAWING_RADIUS */0.5),
96
- maxRadius: (/* inlined export .MAX_SEGMENTATION_DRAWING_RADIUS */99.5)
97
- }
98
- }, {
99
- toolName: 'CircularEraser',
100
- parentTool: 'Brush',
101
- configuration: {
102
- activeStrategy: 'ERASE_INSIDE_CIRCLE',
103
- minRadius: (/* inlined export .MIN_SEGMENTATION_DRAWING_RADIUS */0.5),
104
- maxRadius: (/* inlined export .MAX_SEGMENTATION_DRAWING_RADIUS */99.5)
105
- }
106
- }, {
107
- toolName: 'SphereBrush',
108
- parentTool: 'Brush',
109
- configuration: {
110
- activeStrategy: 'FILL_INSIDE_SPHERE',
111
- minRadius: (/* inlined export .MIN_SEGMENTATION_DRAWING_RADIUS */0.5),
112
- maxRadius: (/* inlined export .MAX_SEGMENTATION_DRAWING_RADIUS */99.5)
113
- }
114
- }, {
115
- toolName: 'SphereEraser',
116
- parentTool: 'Brush',
117
- configuration: {
118
- activeStrategy: 'ERASE_INSIDE_SPHERE',
119
- minRadius: (/* inlined export .MIN_SEGMENTATION_DRAWING_RADIUS */0.5),
120
- maxRadius: (/* inlined export .MAX_SEGMENTATION_DRAWING_RADIUS */99.5)
121
- }
122
- }, {
123
- toolName: 'ThresholdCircularBrush',
124
- parentTool: 'Brush',
125
- configuration: {
126
- activeStrategy: 'THRESHOLD_INSIDE_CIRCLE',
127
- minRadius: (/* inlined export .MIN_SEGMENTATION_DRAWING_RADIUS */0.5),
128
- maxRadius: (/* inlined export .MAX_SEGMENTATION_DRAWING_RADIUS */99.5)
129
- }
130
- }, {
131
- toolName: 'ThresholdSphereBrush',
132
- parentTool: 'Brush',
133
- configuration: {
134
- activeStrategy: 'THRESHOLD_INSIDE_SPHERE',
135
- minRadius: (/* inlined export .MIN_SEGMENTATION_DRAWING_RADIUS */0.5),
136
- maxRadius: (/* inlined export .MAX_SEGMENTATION_DRAWING_RADIUS */99.5)
137
- }
138
- }, {
139
- toolName: 'ThresholdCircularBrushDynamic',
140
- parentTool: 'Brush',
141
- configuration: {
142
- activeStrategy: 'THRESHOLD_INSIDE_CIRCLE',
143
- // preview: {
144
- // enabled: true,
145
- // },
146
- threshold: {
147
- isDynamic: true,
148
- dynamicRadius: 3
149
- },
150
- minRadius: (/* inlined export .MIN_SEGMENTATION_DRAWING_RADIUS */0.5),
151
- maxRadius: (/* inlined export .MAX_SEGMENTATION_DRAWING_RADIUS */99.5)
152
- }
153
- }],
154
- enabled: [],
155
- disabled: [{
156
- toolName: toolNames.Crosshairs,
157
- bindings: [{
158
- mouseButton: Enums.MouseBindings.Primary,
159
- modifierKey: Enums.KeyboardBindings.Shift
160
- }],
161
- configuration: {
162
- disableOnPassive: true,
163
- autoPan: {
164
- enabled: false,
165
- panSize: 10
166
- }
167
- }
168
- }]
169
- };
170
- toolGroupService.createToolGroupAndAddTools(toolGroupIds.CT, tools);
171
- toolGroupService.createToolGroupAndAddTools(toolGroupIds.PT, {
172
- active: tools.active,
173
- passive: [...tools.passive, {
174
- toolName: 'RectangleROIStartEndThreshold'
175
- }],
176
- enabled: tools.enabled,
177
- disabled: tools.disabled
178
- });
179
- toolGroupService.createToolGroupAndAddTools(toolGroupIds.Fusion, tools);
180
- toolGroupService.createToolGroupAndAddTools(toolGroupIds.default, tools);
181
- const mipTools = {
182
- active: [{
183
- toolName: toolNames.VolumeRotate,
184
- bindings: [{
185
- mouseButton: Enums.MouseBindings.Wheel
186
- }],
187
- configuration: {
188
- rotateIncrementDegrees: 5
189
- }
190
- }, {
191
- toolName: toolNames.MipJumpToClick,
192
- configuration: {
193
- toolGroupId: toolGroupIds.PT
194
- },
195
- bindings: [{
196
- mouseButton: Enums.MouseBindings.Primary
197
- }]
198
- }],
199
- enabled: [{
200
- toolName: toolNames.OrientationMarker,
201
- configuration: {
202
- orientationWidget: {
203
- viewportCorner: 'BOTTOM_LEFT'
204
- }
205
- }
206
- }]
207
- };
208
- toolGroupService.createToolGroupAndAddTools(toolGroupIds.MIP, mipTools);
209
- }
210
- function initToolGroups(toolNames, Enums, toolGroupService, commandsManager) {
211
- _initToolGroups(toolNames, Enums, toolGroupService, commandsManager);
212
- }
213
- /* export default */ const src_initToolGroups = (initToolGroups);
214
- // EXTERNAL MODULE: ../../../node_modules/i18next/dist/esm/i18next.js + 22 modules
215
- var i18next = __webpack_require__(26104);
216
- ;// CONCATENATED MODULE: ../../../modes/tmtv/src/toolbarButtons.ts
217
-
218
-
219
-
220
- const setToolActiveToolbar = {
221
- commandName: 'setToolActiveToolbar',
222
- commandOptions: {
223
- toolGroupIds: [toolGroupIds.CT, toolGroupIds.PT, toolGroupIds.Fusion]
224
- }
225
- };
226
- const toolbarButtons = [{
227
- id: 'MeasurementTools',
228
- uiType: 'ohif.toolButtonList',
229
- props: {
230
- buttonSection: true
231
- }
232
- }, {
233
- id: 'SegmentationTools',
234
- uiType: 'ohif.toolBoxButton',
235
- props: {
236
- buttonSection: true
237
- }
238
- }, {
239
- id: 'BrushTools',
240
- uiType: 'ohif.toolBoxButtonGroup',
241
- props: {
242
- buttonSection: true
243
- }
244
- }, {
245
- id: 'AdvancedRenderingControls',
246
- uiType: 'ohif.advancedRenderingControls',
247
- props: {
248
- buttonSection: true
249
- }
250
- }, {
251
- id: 'modalityLoadBadge',
252
- uiType: 'ohif.modalityLoadBadge',
253
- props: {
254
- icon: 'Status',
255
- label: i18next/* ["default"].t */.A.t('Buttons:Status'),
256
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Status'),
257
- evaluate: {
258
- name: 'evaluate.modalityLoadBadge',
259
- hideWhenDisabled: true
260
- }
261
- }
262
- }, {
263
- id: 'Colorbar',
264
- uiType: 'ohif.colorbar',
265
- props: {
266
- type: 'tool',
267
- label: i18next/* ["default"].t */.A.t('Buttons:Colorbar')
268
- }
269
- }, {
270
- id: 'navigationComponent',
271
- uiType: 'ohif.navigationComponent',
272
- props: {
273
- icon: 'Navigation',
274
- label: i18next/* ["default"].t */.A.t('Buttons:Navigation'),
275
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Navigate between segments/measurements and manage their visibility'),
276
- evaluate: {
277
- name: 'evaluate.navigationComponent',
278
- hideWhenDisabled: true
279
- }
280
- }
281
- }, {
282
- id: 'windowLevelMenuEmbedded',
283
- uiType: 'ohif.windowLevelMenuEmbedded',
284
- props: {
285
- icon: 'WindowLevel',
286
- label: i18next/* ["default"].t */.A.t('Buttons:Window Level'),
287
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Adjust window/level presets and customize image contrast settings'),
288
- evaluate: {
289
- name: 'evaluate.windowLevelMenuEmbedded',
290
- hideWhenDisabled: true
291
- }
292
- }
293
- }, {
294
- id: 'trackingStatus',
295
- uiType: 'ohif.trackingStatus',
296
- props: {
297
- icon: 'TrackingStatus',
298
- label: i18next/* ["default"].t */.A.t('Buttons:Tracking Status'),
299
- tooltip: i18next/* ["default"].t */.A.t('Buttons:View and manage tracking status of measurements and annotations'),
300
- evaluate: {
301
- name: 'evaluate.trackingStatus',
302
- hideWhenDisabled: true
303
- }
304
- }
305
- }, {
306
- id: 'Length',
307
- uiType: 'ohif.toolButton',
308
- props: {
309
- icon: 'tool-length',
310
- label: i18next/* ["default"].t */.A.t('Buttons:Length'),
311
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Length Tool'),
312
- commands: setToolActiveToolbar,
313
- evaluate: 'evaluate.cornerstoneTool'
314
- }
315
- }, {
316
- id: 'Bidirectional',
317
- uiType: 'ohif.toolButton',
318
- props: {
319
- icon: 'tool-bidirectional',
320
- label: i18next/* ["default"].t */.A.t('Buttons:Bidirectional'),
321
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Bidirectional Tool'),
322
- commands: setToolActiveToolbar,
323
- evaluate: 'evaluate.cornerstoneTool'
324
- }
325
- }, {
326
- id: 'ArrowAnnotate',
327
- uiType: 'ohif.toolButton',
328
- props: {
329
- icon: 'tool-annotate',
330
- label: i18next/* ["default"].t */.A.t('Buttons:Arrow Annotate'),
331
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Arrow Annotate Tool'),
332
- commands: setToolActiveToolbar,
333
- evaluate: 'evaluate.cornerstoneTool'
334
- }
335
- }, {
336
- id: 'EllipticalROI',
337
- uiType: 'ohif.toolButton',
338
- props: {
339
- icon: 'tool-ellipse',
340
- label: i18next/* ["default"].t */.A.t('Buttons:Ellipse'),
341
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Ellipse Tool'),
342
- commands: setToolActiveToolbar,
343
- evaluate: 'evaluate.cornerstoneTool'
344
- }
345
- }, {
346
- id: 'Zoom',
347
- uiType: 'ohif.toolButton',
348
- props: {
349
- icon: 'tool-zoom',
350
- label: i18next/* ["default"].t */.A.t('Buttons:Zoom'),
351
- commands: setToolActiveToolbar,
352
- evaluate: 'evaluate.cornerstoneTool'
353
- }
354
- }, {
355
- id: 'WindowLevel',
356
- uiType: 'ohif.toolButton',
357
- props: {
358
- icon: 'tool-window-level',
359
- label: i18next/* ["default"].t */.A.t('Buttons:Window Level'),
360
- commands: setToolActiveToolbar,
361
- evaluate: 'evaluate.cornerstoneTool'
362
- }
363
- }, {
364
- id: 'Crosshairs',
365
- uiType: 'ohif.toolButton',
366
- props: {
367
- icon: 'tool-crosshair',
368
- label: i18next/* ["default"].t */.A.t('Buttons:Crosshairs'),
369
- commands: setToolActiveToolbar,
370
- evaluate: 'evaluate.cornerstoneTool'
371
- }
372
- }, {
373
- id: 'Pan',
374
- uiType: 'ohif.toolButton',
375
- props: {
376
- icon: 'tool-move',
377
- label: i18next/* ["default"].t */.A.t('Buttons:Pan'),
378
- commands: setToolActiveToolbar,
379
- evaluate: 'evaluate.cornerstoneTool'
380
- }
381
- }, {
382
- id: 'RectangleROIStartEndThreshold',
383
- uiType: 'ohif.toolBoxButton',
384
- props: {
385
- icon: 'tool-create-threshold',
386
- label: i18next/* ["default"].t */.A.t('Buttons:Rectangle ROI Threshold'),
387
- commands: setToolActiveToolbar,
388
- evaluate: ['evaluate.cornerstone.segmentation', {
389
- name: 'evaluate.cornerstoneTool',
390
- disabledText: i18next/* ["default"].t */.A.t('Buttons:Select the PT Axial to enable this tool')
391
- }],
392
- options: 'tmtv.RectangleROIThresholdOptions'
393
- }
394
- }, {
395
- id: 'Brush',
396
- uiType: 'ohif.toolButton',
397
- props: {
398
- icon: 'icon-tool-brush',
399
- label: i18next/* ["default"].t */.A.t('Buttons:Brush'),
400
- evaluate: [{
401
- name: 'evaluate.cornerstone.segmentation',
402
- toolNames: ['CircularBrush', 'SphereBrush'],
403
- disabledText: i18next/* ["default"].t */.A.t('Buttons:Create new segmentation to enable this tool.')
404
- }, {
405
- name: 'evaluate.cornerstone.segmentation.synchronizeDrawingRadius',
406
- radiusOptionId: 'brush-radius'
407
- }],
408
- options: [{
409
- name: i18next/* ["default"].t */.A.t('Buttons:Radius (mm)'),
410
- id: 'brush-radius',
411
- type: 'range',
412
- explicitRunOnly: true,
413
- min: (/* inlined export .MIN_SEGMENTATION_DRAWING_RADIUS */0.5),
414
- max: (/* inlined export .MAX_SEGMENTATION_DRAWING_RADIUS */99.5),
415
- step: 0.5,
416
- value: 25,
417
- commands: {
418
- commandName: 'setBrushSize',
419
- commandOptions: {
420
- toolNames: ['CircularBrush', 'SphereBrush']
421
- }
422
- }
423
- }, {
424
- name: i18next/* ["default"].t */.A.t('Buttons:Shape'),
425
- type: 'radio',
426
- id: 'brush-mode',
427
- value: 'CircularBrush',
428
- values: [{
429
- value: 'CircularBrush',
430
- label: i18next/* ["default"].t */.A.t('Buttons:Circle')
431
- }, {
432
- value: 'SphereBrush',
433
- label: i18next/* ["default"].t */.A.t('Buttons:Sphere')
434
- }],
435
- commands: 'setToolActiveToolbar'
436
- }]
437
- }
438
- }, {
439
- id: 'Eraser',
440
- uiType: 'ohif.toolButton',
441
- props: {
442
- icon: 'icon-tool-eraser',
443
- label: i18next/* ["default"].t */.A.t('Buttons:Eraser'),
444
- evaluate: [{
445
- name: 'evaluate.cornerstone.segmentation',
446
- toolNames: ['CircularEraser', 'SphereEraser']
447
- }, {
448
- name: 'evaluate.cornerstone.segmentation.synchronizeDrawingRadius',
449
- radiusOptionId: 'eraser-radius'
450
- }],
451
- options: [{
452
- name: i18next/* ["default"].t */.A.t('Buttons:Radius (mm)'),
453
- id: 'eraser-radius',
454
- type: 'range',
455
- explicitRunOnly: true,
456
- min: (/* inlined export .MIN_SEGMENTATION_DRAWING_RADIUS */0.5),
457
- max: (/* inlined export .MAX_SEGMENTATION_DRAWING_RADIUS */99.5),
458
- step: 0.5,
459
- value: 25,
460
- commands: {
461
- commandName: 'setBrushSize',
462
- commandOptions: {
463
- toolNames: ['CircularEraser', 'SphereEraser']
464
- }
465
- }
466
- }, {
467
- name: i18next/* ["default"].t */.A.t('Buttons:Shape'),
468
- type: 'radio',
469
- id: 'eraser-mode',
470
- value: 'CircularEraser',
471
- values: [{
472
- value: 'CircularEraser',
473
- label: i18next/* ["default"].t */.A.t('Buttons:Circle')
474
- }, {
475
- value: 'SphereEraser',
476
- label: i18next/* ["default"].t */.A.t('Buttons:Sphere')
477
- }],
478
- commands: 'setToolActiveToolbar'
479
- }]
480
- }
481
- }, {
482
- id: 'Threshold',
483
- uiType: 'ohif.toolButton',
484
- props: {
485
- icon: 'icon-tool-threshold',
486
- label: i18next/* ["default"].t */.A.t('Buttons:Threshold Tool'),
487
- evaluate: [{
488
- name: 'evaluate.cornerstone.segmentation',
489
- toolNames: ['ThresholdCircularBrush', 'ThresholdSphereBrush', 'ThresholdCircularBrushDynamic']
490
- }, {
491
- name: 'evaluate.cornerstone.segmentation.synchronizeDrawingRadius',
492
- radiusOptionId: 'threshold-radius'
493
- }],
494
- options: [{
495
- name: i18next/* ["default"].t */.A.t('Buttons:Radius (mm)'),
496
- id: 'threshold-radius',
497
- type: 'range',
498
- explicitRunOnly: true,
499
- min: (/* inlined export .MIN_SEGMENTATION_DRAWING_RADIUS */0.5),
500
- max: (/* inlined export .MAX_SEGMENTATION_DRAWING_RADIUS */99.5),
501
- step: 0.5,
502
- value: 25,
503
- commands: {
504
- commandName: 'setBrushSize',
505
- commandOptions: {
506
- toolNames: ['ThresholdCircularBrush', 'ThresholdSphereBrush', 'ThresholdCircularBrushDynamic']
507
- }
508
- }
509
- }, {
510
- name: i18next/* ["default"].t */.A.t('Buttons:Threshold'),
511
- type: 'radio',
512
- id: 'dynamic-mode',
513
- value: 'ThresholdRange',
514
- values: [{
515
- value: 'ThresholdDynamic',
516
- label: i18next/* ["default"].t */.A.t('Buttons:Dynamic')
517
- }, {
518
- value: 'ThresholdRange',
519
- label: i18next/* ["default"].t */.A.t('Buttons:Range')
520
- }],
521
- commands: ({
522
- value,
523
- commandsManager
524
- }) => {
525
- if (value === 'ThresholdDynamic') {
526
- commandsManager.run('setToolActive', {
527
- toolName: 'ThresholdCircularBrushDynamic'
528
- });
529
- } else {
530
- commandsManager.run('setToolActive', {
531
- toolName: 'ThresholdCircularBrush'
532
- });
533
- }
534
- }
535
- }, {
536
- name: i18next/* ["default"].t */.A.t('Buttons:Shape'),
537
- type: 'radio',
538
- id: 'eraser-mode',
539
- value: 'ThresholdCircularBrush',
540
- values: [{
541
- value: 'ThresholdCircularBrush',
542
- label: i18next/* ["default"].t */.A.t('Buttons:Circle')
543
- }, {
544
- value: 'ThresholdSphereBrush',
545
- label: i18next/* ["default"].t */.A.t('Buttons:Sphere')
546
- }],
547
- condition: ({
548
- options
549
- }) => options.find(option => option.id === 'dynamic-mode').value === 'ThresholdRange',
550
- commands: 'setToolActiveToolbar'
551
- }, {
552
- name: i18next/* ["default"].t */.A.t('ROIThresholdConfiguration:ThresholdRange'),
553
- type: 'double-range',
554
- id: 'threshold-range',
555
- min: 0,
556
- max: 50,
557
- step: 0.5,
558
- value: [2.5, 50],
559
- condition: ({
560
- options
561
- }) => options.find(option => option.id === 'dynamic-mode').value === 'ThresholdRange',
562
- commands: {
563
- commandName: 'setThresholdRange',
564
- commandOptions: {
565
- toolNames: ['ThresholdCircularBrush', 'ThresholdSphereBrush']
566
- }
567
- }
568
- }]
569
- }
570
- }, {
571
- id: 'dataOverlayMenu',
572
- uiType: 'ohif.dataOverlayMenu',
573
- props: {
574
- icon: 'ViewportViews',
575
- label: i18next/* ["default"].t */.A.t('Buttons:Data Overlay'),
576
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Configure data overlay options and manage foreground/background display sets'),
577
- evaluate: 'evaluate.dataOverlayMenu'
578
- }
579
- }, {
580
- id: 'orientationMenu',
581
- uiType: 'ohif.orientationMenu',
582
- props: {
583
- icon: 'OrientationSwitch',
584
- label: i18next/* ["default"].t */.A.t('Buttons:Orientation'),
585
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Change viewport orientation between axial, sagittal, coronal and reformat planes'),
586
- evaluate: {
587
- name: 'evaluate.orientationMenu'
588
- // hideWhenDisabled: true,
589
- }
590
- }
591
- }, {
592
- id: 'windowLevelMenu',
593
- uiType: 'ohif.windowLevelMenu',
594
- props: {
595
- icon: 'WindowLevel',
596
- label: i18next/* ["default"].t */.A.t('Buttons:Window Level'),
597
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Adjust window/level presets and customize image contrast settings'),
598
- evaluate: 'evaluate.windowLevelMenu'
599
- }
600
- }, {
601
- id: 'voiManualControlMenu',
602
- uiType: 'ohif.voiManualControlMenu',
603
- props: {
604
- icon: 'WindowLevelAdvanced',
605
- label: i18next/* ["default"].t */.A.t('Buttons:Advanced Window Level'),
606
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Advanced window/level settings with manual controls and presets'),
607
- evaluate: 'evaluate.voiManualControlMenu'
608
- }
609
- }, {
610
- id: 'thresholdMenu',
611
- uiType: 'ohif.thresholdMenu',
612
- props: {
613
- icon: 'Threshold',
614
- label: i18next/* ["default"].t */.A.t('Buttons:Threshold'),
615
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Image threshold settings'),
616
- evaluate: {
617
- name: 'evaluate.thresholdMenu',
618
- hideWhenDisabled: true
619
- }
620
- }
621
- }, {
622
- id: 'opacityMenu',
623
- uiType: 'ohif.opacityMenu',
624
- props: {
625
- icon: 'Opacity',
626
- label: i18next/* ["default"].t */.A.t('Buttons:Opacity'),
627
- tooltip: i18next/* ["default"].t */.A.t('Buttons:Image opacity settings'),
628
- evaluate: {
629
- name: 'evaluate.opacityMenu',
630
- hideWhenDisabled: true
631
- }
632
- }
633
- }];
634
- /* export default */ const src_toolbarButtons = (toolbarButtons);
635
- ;// CONCATENATED MODULE: ../../../modes/tmtv/package.json
636
- var package_namespaceObject = JSON.parse('{"UU":"@ohif/mode-tmtv"}')
637
- ;// CONCATENATED MODULE: ../../../modes/tmtv/src/id.js
638
-
639
- const id = package_namespaceObject.UU;
640
-
641
- ;// CONCATENATED MODULE: ../../../modes/tmtv/src/utils/setCrosshairsConfiguration.js
642
-
643
- function setCrosshairsConfiguration(matches, toolNames, toolGroupService, displaySetService) {
644
- const matchDetails = matches.get('ctDisplaySet');
645
- if (!matchDetails) {
646
- return;
647
- }
648
- const {
649
- SeriesInstanceUID
650
- } = matchDetails;
651
- const displaySets = displaySetService.getDisplaySetsForSeries(SeriesInstanceUID);
652
- const toolConfig = toolGroupService.getToolConfiguration(toolGroupIds.Fusion, toolNames.Crosshairs);
653
- const crosshairsConfig = {
654
- ...toolConfig,
655
- filterActorUIDsToSetSlabThickness: [displaySets[0].displaySetInstanceUID]
656
- };
657
- toolGroupService.setToolConfiguration(toolGroupIds.Fusion, toolNames.Crosshairs, crosshairsConfig);
658
- }
659
- ;// CONCATENATED MODULE: ../../../modes/tmtv/src/utils/setFusionActiveVolume.js
660
-
661
- function setFusionActiveVolume(matches, toolNames, toolGroupService, displaySetService) {
662
- const matchDetails = matches.get('ptDisplaySet');
663
- const matchDetails2 = matches.get('ctDisplaySet');
664
- if (!matchDetails) {
665
- return;
666
- }
667
- const {
668
- SeriesInstanceUID
669
- } = matchDetails;
670
- const displaySets = displaySetService.getDisplaySetsForSeries(SeriesInstanceUID);
671
- if (!displaySets || displaySets.length === 0) {
672
- return;
673
- }
674
- const wlToolConfig = toolGroupService.getToolConfiguration(toolGroupIds.Fusion, toolNames.WindowLevel);
675
- const ellipticalToolConfig = toolGroupService.getToolConfiguration(toolGroupIds.Fusion, toolNames.EllipticalROI);
676
-
677
- // Todo: this should not take into account the loader id
678
- const volumeId = `cornerstoneStreamingImageVolume:${displaySets[0].displaySetInstanceUID}`;
679
- const {
680
- SeriesInstanceUID: SeriesInstanceUID2
681
- } = matchDetails2;
682
- const ctDisplaySets = displaySetService.getDisplaySetsForSeries(SeriesInstanceUID2);
683
- const ctVolumeId = `cornerstoneStreamingImageVolume:${ctDisplaySets[0].displaySetInstanceUID}`;
684
- const windowLevelConfig = {
685
- ...wlToolConfig,
686
- volumeId: ctVolumeId
687
- };
688
- const ellipticalROIConfig = {
689
- ...ellipticalToolConfig,
690
- volumeId
691
- };
692
- toolGroupService.setToolConfiguration(toolGroupIds.Fusion, toolNames.WindowLevel, windowLevelConfig);
693
- toolGroupService.setToolConfiguration(toolGroupIds.Fusion, toolNames.EllipticalROI, ellipticalROIConfig);
694
- }
695
- ;// CONCATENATED MODULE: ../../../modes/tmtv/src/index.ts
696
-
697
-
698
-
699
-
700
-
701
-
702
-
703
- const {
704
- MetadataProvider
705
- } = src/* .classes */.Ly;
706
- const ohif = {
707
- layout: '@ohif/extension-default.layoutTemplateModule.viewerLayout',
708
- sopClassHandler: '@ohif/extension-default.sopClassHandlerModule.stack',
709
- thumbnailList: '@ohif/extension-default.panelModule.seriesList'
710
- };
711
- const cs3d = {
712
- viewport: '@ohif/extension-cornerstone.viewportModule.cornerstone',
713
- segPanel: '@ohif/extension-cornerstone.panelModule.panelSegmentationNoHeader',
714
- measurements: '@ohif/extension-cornerstone.panelModule.measurements'
715
- };
716
- const tmtv = {
717
- hangingProtocol: '@ohif/extension-tmtv.hangingProtocolModule.ptCT',
718
- petSUV: '@ohif/extension-tmtv.panelModule.petSUV',
719
- tmtv: '@ohif/extension-tmtv.panelModule.tmtv'
720
- };
721
- const extensionDependencies = {
722
- // Can derive the versions at least process.env.from npm_package_version
723
- '@ohif/extension-default': '^3.0.0',
724
- '@ohif/extension-cornerstone': '^3.0.0',
725
- '@ohif/extension-cornerstone-dicom-seg': '^3.0.0',
726
- '@ohif/extension-tmtv': '^3.0.0'
727
- };
728
- const unsubscriptions = [];
729
- function modeFactory({
730
- modeConfiguration
731
- }) {
732
- return {
733
- // TODO: We're using this as a route segment
734
- // We should not be.
735
- id: id,
736
- routeName: 'tmtv',
737
- displayName: i18next/* ["default"].t */.A.t('Modes:Total Metabolic Tumor Volume'),
738
- /**
739
- * Lifecycle hooks
740
- */
741
- onModeEnter: ({
742
- servicesManager,
743
- extensionManager,
744
- commandsManager
745
- }) => {
746
- const {
747
- toolbarService,
748
- toolGroupService,
749
- customizationService,
750
- hangingProtocolService,
751
- displaySetService
752
- } = servicesManager.services;
753
- const utilityModule = extensionManager.getModuleEntry('@ohif/extension-cornerstone.utilityModule.tools');
754
- const {
755
- toolNames,
756
- Enums
757
- } = utilityModule.exports;
758
-
759
- // Init Default and SR ToolGroups
760
- src_initToolGroups(toolNames, Enums, toolGroupService, commandsManager);
761
- const {
762
- unsubscribe
763
- } = toolGroupService.subscribe(toolGroupService.EVENTS.VIEWPORT_ADDED, () => {
764
- // For fusion toolGroup we need to add the volumeIds for the crosshairs
765
- // since in the fusion viewport we don't want both PT and CT to render MIP
766
- // when slabThickness is modified
767
- const {
768
- displaySetMatchDetails
769
- } = hangingProtocolService.getMatchDetails();
770
- setCrosshairsConfiguration(displaySetMatchDetails, toolNames, toolGroupService, displaySetService);
771
- setFusionActiveVolume(displaySetMatchDetails, toolNames, toolGroupService, displaySetService);
772
- });
773
- unsubscriptions.push(unsubscribe);
774
- toolbarService.register(src_toolbarButtons);
775
- toolbarService.updateSection(toolbarService.sections.primary, ['MeasurementTools', 'Zoom', 'Pan', 'WindowLevel', 'Crosshairs']);
776
- toolbarService.updateSection(toolbarService.sections.viewportActionMenu.topLeft, ['orientationMenu', 'dataOverlayMenu']);
777
- toolbarService.updateSection(toolbarService.sections.viewportActionMenu.bottomMiddle, ['AdvancedRenderingControls']);
778
- toolbarService.updateSection('AdvancedRenderingControls', ['windowLevelMenuEmbedded', 'voiManualControlMenu', 'Colorbar', 'opacityMenu', 'thresholdMenu']);
779
- toolbarService.updateSection(toolbarService.sections.viewportActionMenu.topRight, ['modalityLoadBadge', 'trackingStatus', 'navigationComponent']);
780
- toolbarService.updateSection(toolbarService.sections.viewportActionMenu.bottomLeft, ['windowLevelMenu']);
781
- toolbarService.updateSection('MeasurementTools', ['Length', 'Bidirectional', 'ArrowAnnotate', 'EllipticalROI']);
782
- toolbarService.updateSection('ROIThresholdToolbox', ['SegmentationTools']);
783
- toolbarService.updateSection('SegmentationTools', ['RectangleROIStartEndThreshold', 'BrushTools']);
784
- toolbarService.updateSection('BrushTools', ['Brush', 'Eraser', 'Threshold']);
785
- customizationService.setCustomizations({
786
- 'panelSegmentation.tableMode': {
787
- $set: 'expanded'
788
- },
789
- 'panelSegmentation.onSegmentationAdd': {
790
- $set: () => {
791
- commandsManager.run('createNewLabelmapFromPT');
792
- }
793
- }
794
- });
795
-
796
- // For the hanging protocol we need to decide on the window level
797
- // based on whether the SUV is corrected or not, hence we can't hard
798
- // code the window level in the hanging protocol but we add a custom
799
- // attribute to the hanging protocol that will be used to get the
800
- // window level based on the metadata
801
- hangingProtocolService.addCustomAttribute('getPTVOIRange', 'get PT VOI based on corrected or not', props => {
802
- const ptDisplaySet = props.find(imageSet => imageSet.Modality === 'PT');
803
- if (!ptDisplaySet) {
804
- return;
805
- }
806
- const {
807
- imageId
808
- } = ptDisplaySet.images[0];
809
- const imageIdScalingFactor = MetadataProvider.get('scalingModule', imageId);
810
- const isSUVAvailable = imageIdScalingFactor && imageIdScalingFactor.suvbw;
811
- if (isSUVAvailable) {
812
- return {
813
- windowWidth: 5,
814
- windowCenter: 2.5
815
- };
816
- }
817
- return;
818
- });
819
- },
820
- onModeExit: ({
821
- servicesManager
822
- }) => {
823
- const {
824
- toolGroupService,
825
- syncGroupService,
826
- segmentationService,
827
- cornerstoneViewportService,
828
- uiDialogService,
829
- uiModalService
830
- } = servicesManager.services;
831
- unsubscriptions.forEach(unsubscribe => unsubscribe());
832
- uiDialogService.hideAll();
833
- uiModalService.hide();
834
- toolGroupService.destroy();
835
- syncGroupService.destroy();
836
- segmentationService.destroy();
837
- cornerstoneViewportService.destroy();
838
- },
839
- validationTags: {
840
- study: [],
841
- series: []
842
- },
843
- isValidMode: ({
844
- modalities,
845
- study
846
- }) => {
847
- const modalities_list = modalities.split('\\');
848
- const invalidModalities = ['SM'];
849
- const isValid = modalities_list.includes('CT') && study.mrn !== 'M1' && modalities_list.includes('PT') && !invalidModalities.some(modality => modalities_list.includes(modality)) &&
850
- // This is study is a 4D study with PT and CT and not a 3D study for the tmtv
851
- // mode, until we have a better way to identify 4D studies we will use the
852
- // StudyInstanceUID to identify the study
853
- // Todo: when we add the 4D mode which comes with a mechanism to identify
854
- // 4D studies we can use that
855
- study.studyInstanceUid !== '1.3.6.1.4.1.12842.1.1.14.3.20220915.105557.468.2963630849';
856
-
857
- // there should be both CT and PT modalities and the modality should not be SM
858
- return {
859
- valid: isValid,
860
- description: 'The mode requires both PT and CT series in the study'
861
- };
862
- },
863
- routes: [{
864
- path: 'tmtv',
865
- /*init: ({ servicesManager, extensionManager }) => {
866
- //defaultViewerRouteInit
867
- },*/
868
- layoutTemplate: () => {
869
- return {
870
- id: ohif.layout,
871
- props: {
872
- leftPanels: [ohif.thumbnailList],
873
- leftPanelResizable: true,
874
- leftPanelClosed: true,
875
- rightPanels: [tmtv.tmtv, tmtv.petSUV],
876
- rightPanelResizable: true,
877
- viewports: [{
878
- namespace: cs3d.viewport,
879
- displaySetsToDisplay: [ohif.sopClassHandler]
880
- }]
881
- }
882
- };
883
- }
884
- }],
885
- extensions: extensionDependencies,
886
- hangingProtocol: tmtv.hangingProtocol,
887
- sopClassHandlers: [ohif.sopClassHandler],
888
- ...modeConfiguration
889
- };
890
- }
891
- const mode = {
892
- id: id,
893
- modeFactory,
894
- extensionDependencies
895
- };
896
- /* export default */ const tmtv_src = (mode);
897
-
898
- },
899
-
900
- }]);