@ohif/app 3.7.0-beta.44 → 3.7.0-beta.47
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/dist/{12.bundle.e8a38369f1a90100362f.js → 12.bundle.76faa700f7041f616633.js} +2 -2
- package/dist/{128.bundle.c4be183e141214e291da.js → 128.bundle.1d35b17c905a58de8551.js} +4 -4
- package/dist/{150.bundle.7be19d85d4a4427162b9.js → 150.bundle.bf8bb9e4589aa2c5ae67.js} +73 -6
- package/dist/{181.bundle.f4289d6b1c5d35831e37.js → 181.bundle.234fef330d4fe6baca8b.js} +13 -7
- package/dist/{236.bundle.b8ef36ef4c5e4e5c3d2b.js → 236.bundle.e50df45b4c224feb736f.js} +30 -16
- package/dist/{250.bundle.ee4bcf159c4d610acc3e.js → 250.bundle.3bcee6d765a209281ddd.js} +24 -12
- package/dist/{281.bundle.d394ad2bcce3cf7b325f.js → 281.bundle.a36db013f04d30edeadd.js} +2 -2
- package/dist/{30.bundle.21b1175bc35138643825.js → 30.bundle.dec90afeb4103389b6a6.js} +12 -9
- package/dist/{348.bundle.fdc18553ec7c1b4f6a80.js → 348.bundle.05d78071808655babffe.js} +4 -4
- package/dist/{359.bundle.f3867a42352f85e846bb.js → 359.bundle.1014c161d9efbdb5de1b.js} +4 -4
- package/dist/{378.bundle.b7a073e9ed3fce6e27a5.js → 378.bundle.721605dbf67db521bacb.js} +8 -6
- package/dist/{410.bundle.8ae97aeddb3375a6d6c6.js → 410.bundle.b4ef419280ca863117d1.js} +4 -4
- package/dist/{869.bundle.6375669c18e0907b248d.js → 451.bundle.9941d9134fcf747d452a.js} +12 -63
- package/dist/{810.bundle.b8f43b6b094a0720e994.js → 471.bundle.c9e618aeda78362776aa.js} +10 -62
- package/dist/{506.bundle.65256204be221475de80.js → 506.bundle.ec535e59761e003bcd10.js} +71 -4
- package/dist/{663.bundle.5188b8ef1cd9a46373d9.js → 663.bundle.292fa73fd3daa7dbdaff.js} +31 -13
- package/dist/{678.bundle.5289463d7f419d56f8f1.js → 678.bundle.57db43d05d8bff8d65a5.js} +67 -25
- package/dist/{782.bundle.0b55dd2b0e7c80102eec.js → 782.bundle.8ed88caff947a2936dbe.js} +4 -4
- package/dist/{821.bundle.fcfa6ec47f096018c0e9.js → 789.bundle.cda7cca15a207b233d59.js} +363 -39
- package/dist/{814.bundle.9f6f3b71096482162688.js → 814.bundle.eae70c4682541d01a5cc.js} +2 -2
- package/dist/{822.bundle.34b66f1c1b27e7884df7.js → 822.bundle.0dabe6c2e028da05ac10.js} +2 -2
- package/dist/{886.bundle.1c9ef0b3494270b34bda.js → 886.bundle.68ef58774a6837f57631.js} +2 -2
- package/dist/{app.bundle.9c84ff949c1d4b8f555f.js → app.bundle.53b5b6c7ab421d7222bf.js} +892 -112
- package/dist/app.bundle.css +1 -1
- package/dist/index.html +1 -1
- package/dist/sw.js +1 -1
- package/package.json +18 -18
|
@@ -69,8 +69,8 @@ var react = __webpack_require__(43001);
|
|
|
69
69
|
// EXTERNAL MODULE: ../../../node_modules/prop-types/index.js
|
|
70
70
|
var prop_types = __webpack_require__(3827);
|
|
71
71
|
var prop_types_default = /*#__PURE__*/__webpack_require__.n(prop_types);
|
|
72
|
-
// EXTERNAL MODULE: ../../i18n/src/index.js +
|
|
73
|
-
var src = __webpack_require__(
|
|
72
|
+
// EXTERNAL MODULE: ../../i18n/src/index.js + 97 modules
|
|
73
|
+
var src = __webpack_require__(24908);
|
|
74
74
|
// EXTERNAL MODULE: ../../../node_modules/react-i18next/dist/es/index.js + 15 modules
|
|
75
75
|
var es = __webpack_require__(69190);
|
|
76
76
|
// EXTERNAL MODULE: ../node_modules/react-router-dom/dist/index.js
|
|
@@ -100,12 +100,12 @@ Compose.propTypes = {
|
|
|
100
100
|
components: (prop_types_default()).array,
|
|
101
101
|
children: (prop_types_default()).node.isRequired
|
|
102
102
|
};
|
|
103
|
-
// EXTERNAL MODULE: ../../ui/src/index.js +
|
|
104
|
-
var ui_src = __webpack_require__(
|
|
103
|
+
// EXTERNAL MODULE: ../../ui/src/index.js + 456 modules
|
|
104
|
+
var ui_src = __webpack_require__(60082);
|
|
105
105
|
// EXTERNAL MODULE: ./state/index.js + 1 modules
|
|
106
106
|
var state = __webpack_require__(62657);
|
|
107
|
-
// EXTERNAL MODULE: ../../core/src/index.ts +
|
|
108
|
-
var core_src = __webpack_require__(
|
|
107
|
+
// EXTERNAL MODULE: ../../core/src/index.ts + 104 modules
|
|
108
|
+
var core_src = __webpack_require__(24966);
|
|
109
109
|
// EXTERNAL MODULE: ../node_modules/react-router/dist/index.js
|
|
110
110
|
var react_router_dist = __webpack_require__(85066);
|
|
111
111
|
// EXTERNAL MODULE: ./hooks/useSearchParams.ts
|
|
@@ -957,8 +957,8 @@ function WorkList(_ref) {
|
|
|
957
957
|
};
|
|
958
958
|
});
|
|
959
959
|
const hasStudies = numOfStudies > 0;
|
|
960
|
-
const versionNumber = "3.7.0-beta.
|
|
961
|
-
const commitHash = "
|
|
960
|
+
const versionNumber = "3.7.0-beta.47";
|
|
961
|
+
const commitHash = "5302e5b62be22eb503d4fe067b435f7934284c39";
|
|
962
962
|
const menuOptions = [{
|
|
963
963
|
title: t('Header:About'),
|
|
964
964
|
icon: 'info',
|
|
@@ -1600,7 +1600,9 @@ function ViewerViewportGrid(props) {
|
|
|
1600
1600
|
measurement,
|
|
1601
1601
|
isConsumed
|
|
1602
1602
|
} = _ref3;
|
|
1603
|
-
if (isConsumed)
|
|
1603
|
+
if (isConsumed) {
|
|
1604
|
+
return;
|
|
1605
|
+
}
|
|
1604
1606
|
// This occurs when no viewport has elected to consume the event
|
|
1605
1607
|
// so we need to change layouts into a layout which can consume
|
|
1606
1608
|
// the event.
|
|
@@ -1719,7 +1721,9 @@ function ViewerViewportGrid(props) {
|
|
|
1719
1721
|
return displaySet.needsRerendering;
|
|
1720
1722
|
});
|
|
1721
1723
|
const onInteractionHandler = event => {
|
|
1722
|
-
if (isActive)
|
|
1724
|
+
if (isActive) {
|
|
1725
|
+
return;
|
|
1726
|
+
}
|
|
1723
1727
|
if (event) {
|
|
1724
1728
|
event.preventDefault();
|
|
1725
1729
|
event.stopPropagation();
|
|
@@ -1821,8 +1825,12 @@ function _getViewportComponent(displaySets, viewportComponents, uiNotificationSe
|
|
|
1821
1825
|
*/
|
|
1822
1826
|
const compare = function (a, b) {
|
|
1823
1827
|
let defaultCompare = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : 0;
|
|
1824
|
-
if (a === b)
|
|
1825
|
-
|
|
1828
|
+
if (a === b) {
|
|
1829
|
+
return defaultCompare;
|
|
1830
|
+
}
|
|
1831
|
+
if (a < b) {
|
|
1832
|
+
return 1;
|
|
1833
|
+
}
|
|
1826
1834
|
return -1;
|
|
1827
1835
|
};
|
|
1828
1836
|
|
|
@@ -1856,7 +1864,9 @@ const getStudiesfromDisplaySets = displaysets => {
|
|
|
1856
1864
|
* in the original order, as specified.
|
|
1857
1865
|
*/
|
|
1858
1866
|
const getStudiesFromUIDs = studyUids => {
|
|
1859
|
-
if (!studyUids?.length)
|
|
1867
|
+
if (!studyUids?.length) {
|
|
1868
|
+
return;
|
|
1869
|
+
}
|
|
1860
1870
|
return studyUids.map(uid => core_src.DicomMetadataStore.getStudy(uid));
|
|
1861
1871
|
};
|
|
1862
1872
|
|
|
@@ -1889,7 +1899,7 @@ modes.push("@ohif/mode-microscopy");
|
|
|
1889
1899
|
async function loadModule(module) {
|
|
1890
1900
|
if (typeof module !== 'string') return module;
|
|
1891
1901
|
if (module === "@ohif/extension-default") {
|
|
1892
|
-
const imported = await Promise.all(/* import() */[__webpack_require__.e(604), __webpack_require__.e(417), __webpack_require__.e(
|
|
1902
|
+
const imported = await Promise.all(/* import() */[__webpack_require__.e(604), __webpack_require__.e(417), __webpack_require__.e(789), __webpack_require__.e(579)]).then(__webpack_require__.bind(__webpack_require__, 1789));
|
|
1893
1903
|
return imported.default;
|
|
1894
1904
|
}
|
|
1895
1905
|
if (module === "@ohif/extension-cornerstone") {
|
|
@@ -2633,7 +2643,9 @@ async function appInit(appConfigOrFunc, defaultExtensions, defaultModes) {
|
|
|
2633
2643
|
const modesById = new Set();
|
|
2634
2644
|
for (let i = 0; i < loadedModes.length; i++) {
|
|
2635
2645
|
let mode = loadedModes[i];
|
|
2636
|
-
if (!mode)
|
|
2646
|
+
if (!mode) {
|
|
2647
|
+
continue;
|
|
2648
|
+
}
|
|
2637
2649
|
const {
|
|
2638
2650
|
id
|
|
2639
2651
|
} = mode;
|
|
@@ -2644,10 +2656,14 @@ async function appInit(appConfigOrFunc, defaultExtensions, defaultModes) {
|
|
|
2644
2656
|
modeConfiguration
|
|
2645
2657
|
});
|
|
2646
2658
|
}
|
|
2647
|
-
if (modesById.has(id))
|
|
2659
|
+
if (modesById.has(id)) {
|
|
2660
|
+
continue;
|
|
2661
|
+
}
|
|
2648
2662
|
// Prevent duplication
|
|
2649
2663
|
modesById.add(id);
|
|
2650
|
-
if (!mode || typeof mode !== 'object')
|
|
2664
|
+
if (!mode || typeof mode !== 'object') {
|
|
2665
|
+
continue;
|
|
2666
|
+
}
|
|
2651
2667
|
appConfig.loadedModes.push(mode);
|
|
2652
2668
|
}
|
|
2653
2669
|
// Hack alert - don't touch the original modes definition,
|
|
@@ -3224,8 +3240,17 @@ const guid = () => {
|
|
|
3224
3240
|
|
|
3225
3241
|
"use strict";
|
|
3226
3242
|
/* harmony export */ __webpack_require__.d(__webpack_exports__, {
|
|
3227
|
-
/* harmony export */
|
|
3243
|
+
/* harmony export */ M6: () => (/* binding */ constructableModalities),
|
|
3244
|
+
/* harmony export */ NB: () => (/* binding */ _isSameOrientation),
|
|
3245
|
+
/* harmony export */ Xn: () => (/* binding */ _getPerpendicularDistance),
|
|
3246
|
+
/* harmony export */ ZP: () => (/* binding */ isDisplaySetReconstructable),
|
|
3247
|
+
/* harmony export */ bg: () => (/* binding */ _getSpacingIssue),
|
|
3248
|
+
/* harmony export */ e1: () => (/* binding */ reconstructionIssues),
|
|
3249
|
+
/* harmony export */ hu: () => (/* binding */ hasPixelMeasurements),
|
|
3250
|
+
/* harmony export */ kN: () => (/* binding */ hasPosition),
|
|
3251
|
+
/* harmony export */ sb: () => (/* binding */ hasOrientation)
|
|
3228
3252
|
/* harmony export */ });
|
|
3253
|
+
/* unused harmony export isNMReconstructable */
|
|
3229
3254
|
/* harmony import */ var _toNumber__WEBPACK_IMPORTED_MODULE_0__ = __webpack_require__(94972);
|
|
3230
3255
|
/* harmony import */ var _sortInstancesByPosition__WEBPACK_IMPORTED_MODULE_1__ = __webpack_require__(87425);
|
|
3231
3256
|
|
|
@@ -3349,6 +3374,7 @@ function processSingleframe(instances) {
|
|
|
3349
3374
|
}
|
|
3350
3375
|
}
|
|
3351
3376
|
let missingFrames = 0;
|
|
3377
|
+
let averageSpacingBetweenFrames;
|
|
3352
3378
|
|
|
3353
3379
|
// Check if frame spacing is approximately equal within a spacingTolerance.
|
|
3354
3380
|
// If spacing is on a uniform grid but we are missing frames,
|
|
@@ -3362,7 +3388,7 @@ function processSingleframe(instances) {
|
|
|
3362
3388
|
value: false
|
|
3363
3389
|
};
|
|
3364
3390
|
}
|
|
3365
|
-
|
|
3391
|
+
averageSpacingBetweenFrames = _getPerpendicularDistance(firstImagePositionPatient, lastIpp) / (instances.length - 1);
|
|
3366
3392
|
let previousImagePositionPatient = firstImagePositionPatient;
|
|
3367
3393
|
for (let i = 1; i < instances.length; i++) {
|
|
3368
3394
|
const instance = instances[i];
|
|
@@ -3385,14 +3411,14 @@ function processSingleframe(instances) {
|
|
|
3385
3411
|
}
|
|
3386
3412
|
return {
|
|
3387
3413
|
value: true,
|
|
3388
|
-
|
|
3414
|
+
averageSpacingBetweenFrames
|
|
3389
3415
|
};
|
|
3390
3416
|
}
|
|
3391
3417
|
function _isSameOrientation(iop1, iop2) {
|
|
3392
3418
|
if (iop1 === undefined || !iop2 === undefined) {
|
|
3393
3419
|
return;
|
|
3394
3420
|
}
|
|
3395
|
-
return Math.abs(iop1[0] - iop2[0]) < iopTolerance && Math.abs(iop1[1] - iop2[1]) < iopTolerance && Math.abs(iop1[2] - iop2[2]) < iopTolerance;
|
|
3421
|
+
return Math.abs(iop1[0] - iop2[0]) < iopTolerance && Math.abs(iop1[1] - iop2[1]) < iopTolerance && Math.abs(iop1[2] - iop2[2]) < iopTolerance && Math.abs(iop1[3] - iop2[3]) < iopTolerance && Math.abs(iop1[4] - iop2[4]) < iopTolerance && Math.abs(iop1[5] - iop2[5]) < iopTolerance;
|
|
3396
3422
|
}
|
|
3397
3423
|
|
|
3398
3424
|
/**
|
|
@@ -3430,6 +3456,7 @@ const reconstructionIssues = {
|
|
|
3430
3456
|
IRREGULAR_SPACING: 'irregularspacing'
|
|
3431
3457
|
};
|
|
3432
3458
|
|
|
3459
|
+
|
|
3433
3460
|
/***/ }),
|
|
3434
3461
|
|
|
3435
3462
|
/***/ 11835:
|
|
@@ -3449,7 +3476,9 @@ const imagesTypes = [_sopClassDictionary__WEBPACK_IMPORTED_MODULE_0__/* .sopClas
|
|
|
3449
3476
|
* @returns {boolean} - true if it has image data
|
|
3450
3477
|
*/
|
|
3451
3478
|
const isImage = SOPClassUID => {
|
|
3452
|
-
if (!SOPClassUID)
|
|
3479
|
+
if (!SOPClassUID) {
|
|
3480
|
+
return false;
|
|
3481
|
+
}
|
|
3453
3482
|
return imagesTypes.indexOf(SOPClassUID) !== -1;
|
|
3454
3483
|
};
|
|
3455
3484
|
|
|
@@ -3620,7 +3649,7 @@ function toNumber(val) {
|
|
|
3620
3649
|
|
|
3621
3650
|
/***/ }),
|
|
3622
3651
|
|
|
3623
|
-
/***/
|
|
3652
|
+
/***/ 24908:
|
|
3624
3653
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
3625
3654
|
|
|
3626
3655
|
"use strict";
|
|
@@ -6945,7 +6974,7 @@ const detectionOptions = {
|
|
|
6945
6974
|
}
|
|
6946
6975
|
});
|
|
6947
6976
|
;// CONCATENATED MODULE: ../../i18n/package.json
|
|
6948
|
-
const package_namespaceObject = JSON.parse('{"i8":"3.7.0-beta.
|
|
6977
|
+
const package_namespaceObject = JSON.parse('{"i8":"3.7.0-beta.46"}');
|
|
6949
6978
|
;// CONCATENATED MODULE: ../../i18n/src/utils.js
|
|
6950
6979
|
const languagesMap = {
|
|
6951
6980
|
ar: 'Arabic',
|
|
@@ -7052,6 +7081,8 @@ const StudyList_namespaceObject = JSON.parse('{"AccessionNumber":"Accession #","
|
|
|
7052
7081
|
const en_US_UserPreferencesModal_namespaceObject = JSON.parse('{"Cancel":"$t(Buttons:Cancel)","No hotkeys found":"No hotkeys are configured for this application. Hotkeys can be configured in the application\'s app-config.js file.","Reset to Defaults":"$t(Buttons:Reset to Defaults)","ResetDefaultMessage":"Preferences successfully reset to default. <br /> You must <strong>Save</strong> to perform this action.","Save":"$t(Buttons:Save)","SaveMessage":"Preferences saved","User Preferences":"User Preferences"}');
|
|
7053
7082
|
;// CONCATENATED MODULE: ../../i18n/src/locales/en-US/ViewportDownloadForm.json
|
|
7054
7083
|
const ViewportDownloadForm_namespaceObject = JSON.parse('{"emptyFilenameError":"The file name cannot be empty.","fileType":"File Type","filename":"File Name","formTitle":"Please specify the dimensions, filename, and desired type for the output image.","imageHeight":"Image height (px)","imagePreview":"Image Preview","imageWidth":"Image width (px)","keepAspectRatio":"Keep aspect ratio","loadingPreview":"Loading Image Preview...","minHeightError":"The minimum valid height is 100px.","minWidthError":"The minimum valid width is 100px.","showAnnotations":"Show Annotations"}');
|
|
7084
|
+
;// CONCATENATED MODULE: ../../i18n/src/locales/en-US/Messages.json
|
|
7085
|
+
const Messages_namespaceObject = JSON.parse('{"1":"No valid instances found in series.","2":"DisplaySet has missing position information.","3":"DisplaySet is not a reconstructable 3D volume.","4":"Multi frame displaySet don\'t have pixel measurement information.","5":"Multi frame displaySet don\'t have orientation information.","6":"Multi frame displaySet don\'t have position information.","7":"DisplaySet has missing frames.","8":"DisplaySet has irregular spacing.","9":"DisplaySet has inconsistent dimensions between frames.","10":"DisplaySet has frames with inconsistent number of components.","11":"DisplaySet has frames with inconsistent orientations.","12":"DisplaySet has inconsistent position information."}');
|
|
7055
7086
|
;// CONCATENATED MODULE: ../../i18n/src/locales/en-US/index.js
|
|
7056
7087
|
|
|
7057
7088
|
|
|
@@ -7065,6 +7096,7 @@ const ViewportDownloadForm_namespaceObject = JSON.parse('{"emptyFilenameError":"
|
|
|
7065
7096
|
|
|
7066
7097
|
|
|
7067
7098
|
|
|
7099
|
+
|
|
7068
7100
|
/* harmony default export */ const en_US = ({
|
|
7069
7101
|
'en-US': {
|
|
7070
7102
|
AboutModal: AboutModal_namespaceObject,
|
|
@@ -7078,7 +7110,8 @@ const ViewportDownloadForm_namespaceObject = JSON.parse('{"emptyFilenameError":"
|
|
|
7078
7110
|
StudyBrowser: StudyBrowser_namespaceObject,
|
|
7079
7111
|
StudyList: StudyList_namespaceObject,
|
|
7080
7112
|
UserPreferencesModal: en_US_UserPreferencesModal_namespaceObject,
|
|
7081
|
-
ViewportDownloadForm: ViewportDownloadForm_namespaceObject
|
|
7113
|
+
ViewportDownloadForm: ViewportDownloadForm_namespaceObject,
|
|
7114
|
+
Messages: Messages_namespaceObject
|
|
7082
7115
|
}
|
|
7083
7116
|
});
|
|
7084
7117
|
;// CONCATENATED MODULE: ../../i18n/src/locales/es/AboutModal.json
|
|
@@ -7217,6 +7250,8 @@ const pt_BR_Header_namespaceObject = JSON.parse('{"About":"Quem somos","Back to
|
|
|
7217
7250
|
const pt_BR_UserPreferencesModal_namespaceObject = JSON.parse('{"Cancel":"Cancelar","Reset to Defaults":"$t(Common:Reset) para Padrão","ResetDefaultMessage":"Preferências resetadas com sucesso. <br /> Você deve <strong>Salvar</strong> para que essa ação seja realizada.","Save":"Salvar","SaveMessage":"Preferências salvas","User Preferences":"Preferências do Usuário"}');
|
|
7218
7251
|
;// CONCATENATED MODULE: ../../i18n/src/locales/pt-BR/MeasurementTable.json
|
|
7219
7252
|
const pt_BR_MeasurementTable_namespaceObject = JSON.parse('{"Export":"Exportar","Create Report":"Criar relatório"}');
|
|
7253
|
+
;// CONCATENATED MODULE: ../../i18n/src/locales/pt-BR/Messages.json
|
|
7254
|
+
const pt_BR_Messages_namespaceObject = JSON.parse('{"1":"Série sem imagens.","2":"Série nao possui informação de posição.","3":"Serie não é reconstruível.","4":"Série nulti frame não possui informação de medidas.","5":"Série multi frame não possui informação de orientação.","6":"Série multi frame não possui informação de posição.","7":"Série não possui algumas imagens.","8":"Série possui espaçamento irregular.","9":"Série possui dimensões inconsistentes entre frames.","10":"Série possui frames com componentes inconsistentes.","11":"Série possui frames com orientações inconsistentes.","12":"Série possui informação de posição inconsistentes."}');
|
|
7220
7255
|
;// CONCATENATED MODULE: ../../i18n/src/locales/pt-BR/index.js
|
|
7221
7256
|
|
|
7222
7257
|
|
|
@@ -7226,6 +7261,7 @@ const pt_BR_MeasurementTable_namespaceObject = JSON.parse('{"Export":"Exportar",
|
|
|
7226
7261
|
|
|
7227
7262
|
|
|
7228
7263
|
|
|
7264
|
+
|
|
7229
7265
|
/* harmony default export */ const pt_BR = ({
|
|
7230
7266
|
'pt-BR': {
|
|
7231
7267
|
AboutModal: pt_BR_AboutModal_namespaceObject,
|
|
@@ -7235,7 +7271,8 @@ const pt_BR_MeasurementTable_namespaceObject = JSON.parse('{"Export":"Exportar",
|
|
|
7235
7271
|
DatePicker: pt_BR_DatePicker_namespaceObject,
|
|
7236
7272
|
Header: pt_BR_Header_namespaceObject,
|
|
7237
7273
|
UserPreferencesModal: pt_BR_UserPreferencesModal_namespaceObject,
|
|
7238
|
-
MeasurementTable: pt_BR_MeasurementTable_namespaceObject
|
|
7274
|
+
MeasurementTable: pt_BR_MeasurementTable_namespaceObject,
|
|
7275
|
+
Messages: pt_BR_Messages_namespaceObject
|
|
7239
7276
|
}
|
|
7240
7277
|
});
|
|
7241
7278
|
;// CONCATENATED MODULE: ../../i18n/src/locales/vi/Buttons.json
|
|
@@ -8257,6 +8294,31 @@ sortingActiveUp.defaultProps = {
|
|
|
8257
8294
|
height: "16",
|
|
8258
8295
|
viewBox: "0 0 9 16"
|
|
8259
8296
|
};
|
|
8297
|
+
var statusAlertWarning = function statusAlertWarning(props) {
|
|
8298
|
+
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("svg", props, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("g", {
|
|
8299
|
+
fill: "none",
|
|
8300
|
+
fillRule: "evenodd"
|
|
8301
|
+
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("path", {
|
|
8302
|
+
d: "M16 7.863a8.118 8.118 0 0 1-8 8.138 7.881 7.881 0 0 1-8-7.86A8.118 8.118 0 0 1 8 0a7.882 7.882 0 0 1 8 7.862z",
|
|
8303
|
+
fill: "#E3C33A"
|
|
8304
|
+
}), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("g", {
|
|
8305
|
+
stroke: "#000",
|
|
8306
|
+
strokeLinecap: "round",
|
|
8307
|
+
strokeLinejoin: "round"
|
|
8308
|
+
}, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("path", {
|
|
8309
|
+
strokeWidth: "2.5",
|
|
8310
|
+
d: "M8 7.432V3.34"
|
|
8311
|
+
}), /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("path", {
|
|
8312
|
+
d: "M7.993 12.34a.178.178 0 0 0-.175.186c.004.1.085.178.184.179h0a.179.179 0 0 0 .175-.186.184.184 0 0 0-.177-.178h-.004",
|
|
8313
|
+
strokeWidth: "3"
|
|
8314
|
+
}))));
|
|
8315
|
+
};
|
|
8316
|
+
statusAlertWarning.defaultProps = {
|
|
8317
|
+
width: "16",
|
|
8318
|
+
height: "16.002",
|
|
8319
|
+
viewBox: "0 0 16 16.002",
|
|
8320
|
+
xmlns: "http://www.w3.org/2000/svg"
|
|
8321
|
+
};
|
|
8260
8322
|
var statusAlert = function statusAlert(props) {
|
|
8261
8323
|
return /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("svg", props, /*#__PURE__*/react__WEBPACK_IMPORTED_MODULE_0__.createElement("g", {
|
|
8262
8324
|
fill: "none",
|
|
@@ -10056,6 +10118,7 @@ const ICONS = {
|
|
|
10056
10118
|
'sorting-active-down': sortingActiveDown,
|
|
10057
10119
|
'sorting-active-up': sortingActiveUp,
|
|
10058
10120
|
'status-alert': statusAlert,
|
|
10121
|
+
'status-alert-warning': statusAlertWarning,
|
|
10059
10122
|
'status-locked': statusLocked,
|
|
10060
10123
|
'status-tracked': statusTracked,
|
|
10061
10124
|
'status-untracked': statusUntracked,
|
|
@@ -10327,7 +10390,7 @@ Typography.propTypes = {
|
|
|
10327
10390
|
|
|
10328
10391
|
/***/ }),
|
|
10329
10392
|
|
|
10330
|
-
/***/
|
|
10393
|
+
/***/ 60082:
|
|
10331
10394
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
10332
10395
|
|
|
10333
10396
|
"use strict";
|
|
@@ -17415,10 +17478,12 @@ function CineProvider(_ref) {
|
|
|
17415
17478
|
isPlaying = undefined
|
|
17416
17479
|
} = action.payload;
|
|
17417
17480
|
const cines = state.cines;
|
|
17418
|
-
if (!cines[id])
|
|
17419
|
-
id
|
|
17420
|
-
|
|
17421
|
-
|
|
17481
|
+
if (!cines[id]) {
|
|
17482
|
+
cines[id] = {
|
|
17483
|
+
id,
|
|
17484
|
+
...DEFAULT_CINE
|
|
17485
|
+
};
|
|
17486
|
+
}
|
|
17422
17487
|
cines[id].frameRate = frameRate || cines[id].frameRate;
|
|
17423
17488
|
cines[id].isPlaying = isPlaying !== undefined ? isPlaying : cines[id].isPlaying;
|
|
17424
17489
|
return {
|
|
@@ -17782,8 +17847,8 @@ ViewportDialogProvider.propTypes = {
|
|
|
17782
17847
|
// EXTERNAL MODULE: ../../../node_modules/lodash.isequal/index.js
|
|
17783
17848
|
var lodash_isequal = __webpack_require__(10311);
|
|
17784
17849
|
var lodash_isequal_default = /*#__PURE__*/__webpack_require__.n(lodash_isequal);
|
|
17785
|
-
// EXTERNAL MODULE: ../../core/src/index.ts +
|
|
17786
|
-
var src = __webpack_require__(
|
|
17850
|
+
// EXTERNAL MODULE: ../../core/src/index.ts + 104 modules
|
|
17851
|
+
var src = __webpack_require__(24966);
|
|
17787
17852
|
;// CONCATENATED MODULE: ../../ui/src/utils/viewportLabels.ts
|
|
17788
17853
|
const viewportLabels = ['A', 'B', 'C', 'D', 'E', 'F', 'G', 'H', 'I', 'J', 'K', 'L', 'M', 'N', 'O', 'P', 'Q', 'R', 'S', 'T', 'U', 'V', 'W', 'X', 'Y', 'Z'];
|
|
17789
17854
|
/* harmony default export */ const utils_viewportLabels = (viewportLabels);
|
|
@@ -17922,7 +17987,9 @@ function ViewportGridProvider(_ref) {
|
|
|
17922
17987
|
// Have the initial id set contain all viewports not updated here
|
|
17923
17988
|
const viewportIdSet = new Set();
|
|
17924
17989
|
viewports.forEach((viewport, index) => {
|
|
17925
|
-
if (!viewport.viewportId)
|
|
17990
|
+
if (!viewport.viewportId) {
|
|
17991
|
+
return;
|
|
17992
|
+
}
|
|
17926
17993
|
const isUpdated = payload.find(newViewport => newViewport.viewportIndex === index);
|
|
17927
17994
|
if (isUpdated) {
|
|
17928
17995
|
return;
|
|
@@ -18001,7 +18068,9 @@ function ViewportGridProvider(_ref) {
|
|
|
18001
18068
|
activeViewportIndexToSet = pos;
|
|
18002
18069
|
}
|
|
18003
18070
|
const viewport = findOrCreateViewport(pos, positionId, options);
|
|
18004
|
-
if (!viewport)
|
|
18071
|
+
if (!viewport) {
|
|
18072
|
+
continue;
|
|
18073
|
+
}
|
|
18005
18074
|
viewport.positionId = positionId;
|
|
18006
18075
|
// Create a new viewport object as it is getting updated here
|
|
18007
18076
|
// and it is part of the read only state
|
|
@@ -42056,11 +42125,13 @@ const ListMenu = _ref => {
|
|
|
42056
42125
|
item,
|
|
42057
42126
|
selectedIndex: index
|
|
42058
42127
|
});
|
|
42059
|
-
if (item.onClick)
|
|
42060
|
-
|
|
42061
|
-
|
|
42062
|
-
|
|
42063
|
-
|
|
42128
|
+
if (item.onClick) {
|
|
42129
|
+
item.onClick({
|
|
42130
|
+
...item,
|
|
42131
|
+
index,
|
|
42132
|
+
isSelected
|
|
42133
|
+
});
|
|
42134
|
+
}
|
|
42064
42135
|
};
|
|
42065
42136
|
return /*#__PURE__*/react.createElement("div", {
|
|
42066
42137
|
className: classnames_default()(flex, theme, 'cursor-pointer'),
|
|
@@ -42538,6 +42609,520 @@ StudyItem.propTypes = {
|
|
|
42538
42609
|
;// CONCATENATED MODULE: ../../ui/src/components/StudyItem/index.js
|
|
42539
42610
|
|
|
42540
42611
|
/* harmony default export */ const components_StudyItem = (StudyItem_StudyItem);
|
|
42612
|
+
;// CONCATENATED MODULE: ../../ui/src/components/Tooltip/PortalTooltipCard.tsx
|
|
42613
|
+
|
|
42614
|
+
|
|
42615
|
+
const FG_SIZE = 8;
|
|
42616
|
+
const BG_SIZE = 9;
|
|
42617
|
+
|
|
42618
|
+
/**
|
|
42619
|
+
* A portal based tooltip card component.
|
|
42620
|
+
*
|
|
42621
|
+
* This component has been repurposed and modified
|
|
42622
|
+
* for OHIF usage: https://github.com/romainberger/react-portal-tooltip
|
|
42623
|
+
*/
|
|
42624
|
+
class PortalTooltipCard extends react.Component {
|
|
42625
|
+
constructor() {
|
|
42626
|
+
super(...arguments);
|
|
42627
|
+
this.state = {
|
|
42628
|
+
hover: false,
|
|
42629
|
+
width: 0,
|
|
42630
|
+
height: 0
|
|
42631
|
+
};
|
|
42632
|
+
this.offscreenDifference = 0;
|
|
42633
|
+
this.margin = 15;
|
|
42634
|
+
this.defaultArrowStyle = {
|
|
42635
|
+
color: '#090c29',
|
|
42636
|
+
// primary-dark
|
|
42637
|
+
borderColor: 'rgba(58, 63, 153, 1)' // secondary-light
|
|
42638
|
+
};
|
|
42639
|
+
this.rootRef = /*#__PURE__*/react.createRef();
|
|
42640
|
+
this.handleMouseEnter = () => {
|
|
42641
|
+
this.props.active && this.props.useHover && this.setState({
|
|
42642
|
+
hover: true
|
|
42643
|
+
});
|
|
42644
|
+
};
|
|
42645
|
+
this.handleMouseLeave = () => {
|
|
42646
|
+
this.setState({
|
|
42647
|
+
hover: false
|
|
42648
|
+
});
|
|
42649
|
+
};
|
|
42650
|
+
}
|
|
42651
|
+
getGlobalStyle() {
|
|
42652
|
+
if (!this.props.parentEl) {
|
|
42653
|
+
return {
|
|
42654
|
+
display: 'none'
|
|
42655
|
+
};
|
|
42656
|
+
}
|
|
42657
|
+
const style = {
|
|
42658
|
+
position: 'absolute',
|
|
42659
|
+
//padding: '5px',
|
|
42660
|
+
background: 'bg-primary-dark',
|
|
42661
|
+
//boxShadow: '0 0 4px rgba(0,0,0,.3)',
|
|
42662
|
+
borderRadius: '3px',
|
|
42663
|
+
//opacity: this.state.hover || this.props.active ? 1 : 0,
|
|
42664
|
+
visibility: this.state.hover || this.props.active ? 'visible' : 'hidden',
|
|
42665
|
+
zIndex: 50,
|
|
42666
|
+
...this.getStyle(this.props.position, this.props.arrow)
|
|
42667
|
+
};
|
|
42668
|
+
return this.mergeStyle(style, this.props.style.style);
|
|
42669
|
+
}
|
|
42670
|
+
getBaseArrowStyle() {
|
|
42671
|
+
return {
|
|
42672
|
+
position: 'absolute',
|
|
42673
|
+
content: '""'
|
|
42674
|
+
};
|
|
42675
|
+
}
|
|
42676
|
+
getArrowStyle() {
|
|
42677
|
+
let fgStyle = this.getBaseArrowStyle();
|
|
42678
|
+
let bgStyle = this.getBaseArrowStyle();
|
|
42679
|
+
fgStyle.zIndex = 60;
|
|
42680
|
+
bgStyle.zIndex = 55;
|
|
42681
|
+
let arrowStyle = {
|
|
42682
|
+
...this.defaultArrowStyle,
|
|
42683
|
+
...this.props.style.arrowStyle
|
|
42684
|
+
};
|
|
42685
|
+
let bgBorderColor = arrowStyle.borderColor ? arrowStyle.borderColor : 'transparent';
|
|
42686
|
+
let fgColorBorder = `10px solid ${arrowStyle.color}`;
|
|
42687
|
+
let fgTransBorder = `${FG_SIZE}px solid transparent`;
|
|
42688
|
+
let bgColorBorder = `12px solid ${bgBorderColor}`;
|
|
42689
|
+
let bgTransBorder = `${BG_SIZE}px solid transparent`;
|
|
42690
|
+
let {
|
|
42691
|
+
position,
|
|
42692
|
+
arrow
|
|
42693
|
+
} = this.props;
|
|
42694
|
+
if (position === 'left' || position === 'right') {
|
|
42695
|
+
fgStyle.top = '50%';
|
|
42696
|
+
fgStyle.borderTop = fgTransBorder;
|
|
42697
|
+
fgStyle.borderBottom = fgTransBorder;
|
|
42698
|
+
fgStyle.marginTop = -7;
|
|
42699
|
+
bgStyle.borderTop = bgTransBorder;
|
|
42700
|
+
bgStyle.borderBottom = bgTransBorder;
|
|
42701
|
+
bgStyle.top = '50%';
|
|
42702
|
+
bgStyle.marginTop = -8;
|
|
42703
|
+
if (position === 'left') {
|
|
42704
|
+
fgStyle.right = -10;
|
|
42705
|
+
fgStyle.borderLeft = fgColorBorder;
|
|
42706
|
+
bgStyle.right = -11;
|
|
42707
|
+
bgStyle.borderLeft = bgColorBorder;
|
|
42708
|
+
} else {
|
|
42709
|
+
fgStyle.left = -9;
|
|
42710
|
+
fgStyle.borderRight = fgColorBorder;
|
|
42711
|
+
bgStyle.left = -11;
|
|
42712
|
+
bgStyle.borderRight = bgColorBorder;
|
|
42713
|
+
}
|
|
42714
|
+
if (arrow === 'top') {
|
|
42715
|
+
fgStyle.top = this.margin;
|
|
42716
|
+
bgStyle.top = this.margin;
|
|
42717
|
+
}
|
|
42718
|
+
if (arrow === 'bottom') {
|
|
42719
|
+
fgStyle.top = null;
|
|
42720
|
+
fgStyle.bottom = this.margin - 7;
|
|
42721
|
+
bgStyle.top = null;
|
|
42722
|
+
bgStyle.bottom = this.margin - 8;
|
|
42723
|
+
}
|
|
42724
|
+
} else {
|
|
42725
|
+
fgStyle.left = Math.round(this.state.width / 2 - FG_SIZE);
|
|
42726
|
+
fgStyle.borderLeft = fgTransBorder;
|
|
42727
|
+
fgStyle.borderRight = fgTransBorder;
|
|
42728
|
+
fgStyle.marginLeft = 0;
|
|
42729
|
+
bgStyle.left = fgStyle.left - 1;
|
|
42730
|
+
bgStyle.borderLeft = bgTransBorder;
|
|
42731
|
+
bgStyle.borderRight = bgTransBorder;
|
|
42732
|
+
bgStyle.marginLeft = 0;
|
|
42733
|
+
if (position === 'top') {
|
|
42734
|
+
fgStyle.bottom = -10;
|
|
42735
|
+
fgStyle.borderTop = fgColorBorder;
|
|
42736
|
+
bgStyle.bottom = -11;
|
|
42737
|
+
bgStyle.borderTop = bgColorBorder;
|
|
42738
|
+
} else {
|
|
42739
|
+
fgStyle.top = -10;
|
|
42740
|
+
fgStyle.borderBottom = fgColorBorder;
|
|
42741
|
+
bgStyle.top = -11;
|
|
42742
|
+
bgStyle.borderBottom = bgColorBorder;
|
|
42743
|
+
}
|
|
42744
|
+
if (arrow === 'right') {
|
|
42745
|
+
fgStyle.left = null;
|
|
42746
|
+
fgStyle.right = this.margin + 1 - FG_SIZE;
|
|
42747
|
+
bgStyle.left = null;
|
|
42748
|
+
bgStyle.right = this.margin - FG_SIZE;
|
|
42749
|
+
}
|
|
42750
|
+
if (arrow === 'left') {
|
|
42751
|
+
fgStyle.left = this.margin + 1 - FG_SIZE;
|
|
42752
|
+
bgStyle.left = this.margin - FG_SIZE;
|
|
42753
|
+
}
|
|
42754
|
+
}
|
|
42755
|
+
let {
|
|
42756
|
+
color,
|
|
42757
|
+
borderColor,
|
|
42758
|
+
...propsArrowStyle
|
|
42759
|
+
} = this.props.style.arrowStyle;
|
|
42760
|
+
const state = {
|
|
42761
|
+
fgStyle: this.mergeStyle(fgStyle, propsArrowStyle),
|
|
42762
|
+
bgStyle: this.mergeStyle(bgStyle, propsArrowStyle)
|
|
42763
|
+
};
|
|
42764
|
+
if (this.offscreenDifference > 0) {
|
|
42765
|
+
if (state.fgStyle.top >= 0 || state.fgStyle.top < 0) {
|
|
42766
|
+
state.fgStyle.top += this.offscreenDifference;
|
|
42767
|
+
}
|
|
42768
|
+
if (state.bgStyle.top >= 0 || state.bgStyle.top < 0) {
|
|
42769
|
+
state.bgStyle.top += this.offscreenDifference;
|
|
42770
|
+
}
|
|
42771
|
+
if (typeof state.fgStyle.top === 'string') {
|
|
42772
|
+
state.fgStyle.top = `calc(${state.fgStyle.top} + ${this.offscreenDifference}px)`;
|
|
42773
|
+
}
|
|
42774
|
+
if (typeof state.bgStyle.top === 'string') {
|
|
42775
|
+
state.bgStyle.top = `calc(${state.bgStyle.top} + ${this.offscreenDifference}px)`;
|
|
42776
|
+
}
|
|
42777
|
+
}
|
|
42778
|
+
return state;
|
|
42779
|
+
}
|
|
42780
|
+
mergeStyle(style, theme) {
|
|
42781
|
+
if (theme) {
|
|
42782
|
+
let {
|
|
42783
|
+
position,
|
|
42784
|
+
top,
|
|
42785
|
+
left,
|
|
42786
|
+
right,
|
|
42787
|
+
bottom,
|
|
42788
|
+
marginLeft,
|
|
42789
|
+
marginRight,
|
|
42790
|
+
...validTheme
|
|
42791
|
+
} = theme;
|
|
42792
|
+
return {
|
|
42793
|
+
...style,
|
|
42794
|
+
...validTheme
|
|
42795
|
+
};
|
|
42796
|
+
}
|
|
42797
|
+
return style;
|
|
42798
|
+
}
|
|
42799
|
+
getStyle(position, arrow) {
|
|
42800
|
+
let alignOffset = 0;
|
|
42801
|
+
let parent = this.props.parentEl;
|
|
42802
|
+
let align = this.props.align;
|
|
42803
|
+
let tooltipPosition = parent.getBoundingClientRect();
|
|
42804
|
+
let scrollY = window.scrollY !== undefined ? window.scrollY : window.pageYOffset;
|
|
42805
|
+
let scrollX = window.scrollX !== undefined ? window.scrollX : window.pageXOffset;
|
|
42806
|
+
let top = scrollY + tooltipPosition.top;
|
|
42807
|
+
let left = scrollX + tooltipPosition.left;
|
|
42808
|
+
let style = {};
|
|
42809
|
+
if (this.rootRef.current) {
|
|
42810
|
+
const newHeight = this.rootRef.current.offsetHeight / 2;
|
|
42811
|
+
const bottomPosition = tooltipPosition.bottom + newHeight;
|
|
42812
|
+
const isOffscreen = tooltipPosition.bottom + newHeight > window.innerHeight;
|
|
42813
|
+
const offscreenDifference = bottomPosition - window.innerHeight;
|
|
42814
|
+
if (isOffscreen) {
|
|
42815
|
+
const padding = 3;
|
|
42816
|
+
top -= offscreenDifference;
|
|
42817
|
+
this.offscreenDifference = Math.min(Math.max(offscreenDifference, 0), newHeight - parent.getBoundingClientRect().height / 2 - padding);
|
|
42818
|
+
} else {
|
|
42819
|
+
this.offscreenDifference = 0;
|
|
42820
|
+
}
|
|
42821
|
+
}
|
|
42822
|
+
const parentSize = {
|
|
42823
|
+
width: parent.offsetWidth,
|
|
42824
|
+
height: parent.offsetHeight
|
|
42825
|
+
};
|
|
42826
|
+
|
|
42827
|
+
// fix for svg
|
|
42828
|
+
if (!parent.offsetHeight && parent.getBoundingClientRect) {
|
|
42829
|
+
parentSize.width = parent.getBoundingClientRect().width;
|
|
42830
|
+
parentSize.height = parent.getBoundingClientRect().height;
|
|
42831
|
+
}
|
|
42832
|
+
if (align === 'left') {
|
|
42833
|
+
alignOffset = -parentSize.width / 2 + FG_SIZE;
|
|
42834
|
+
} else if (align === 'right') {
|
|
42835
|
+
alignOffset = parentSize.width / 2 - FG_SIZE;
|
|
42836
|
+
}
|
|
42837
|
+
const stylesFromPosition = {
|
|
42838
|
+
left: () => {
|
|
42839
|
+
style.top = top + parentSize.height / 2 - this.state.height / 2;
|
|
42840
|
+
style.left = left - this.state.width - this.margin;
|
|
42841
|
+
},
|
|
42842
|
+
right: () => {
|
|
42843
|
+
style.top = top + parentSize.height / 2 - this.state.height / 2;
|
|
42844
|
+
style.left = left + parentSize.width + this.margin;
|
|
42845
|
+
},
|
|
42846
|
+
top: () => {
|
|
42847
|
+
style.left = left - this.state.width / 2 + parentSize.width / 2 + alignOffset;
|
|
42848
|
+
style.top = top - this.state.height - this.margin;
|
|
42849
|
+
},
|
|
42850
|
+
bottom: () => {
|
|
42851
|
+
style.left = left - this.state.width / 2 + parentSize.width / 2 + alignOffset;
|
|
42852
|
+
style.top = top + parentSize.height + this.margin;
|
|
42853
|
+
}
|
|
42854
|
+
};
|
|
42855
|
+
const stylesFromArrow = {
|
|
42856
|
+
left: () => {
|
|
42857
|
+
style.left = left + parentSize.width / 2 - this.margin + alignOffset;
|
|
42858
|
+
},
|
|
42859
|
+
right: () => {
|
|
42860
|
+
style.left = left - this.state.width + parentSize.width / 2 + this.margin + alignOffset;
|
|
42861
|
+
},
|
|
42862
|
+
top: () => {
|
|
42863
|
+
style.top = top + parentSize.height / 2 - this.margin;
|
|
42864
|
+
},
|
|
42865
|
+
bottom: () => {
|
|
42866
|
+
style.top = top + parentSize.height / 2 - this.state.height + this.margin;
|
|
42867
|
+
}
|
|
42868
|
+
};
|
|
42869
|
+
executeFunctionIfExist(stylesFromPosition, position);
|
|
42870
|
+
executeFunctionIfExist(stylesFromArrow, arrow);
|
|
42871
|
+
return style;
|
|
42872
|
+
}
|
|
42873
|
+
checkWindowPosition(style, arrowStyle) {
|
|
42874
|
+
if (this.props.position === 'top' || this.props.position === 'bottom') {
|
|
42875
|
+
if (style.left < 0) {
|
|
42876
|
+
const parent = this.props.parentEl;
|
|
42877
|
+
if (parent) {
|
|
42878
|
+
const tooltipWidth = this.state.width;
|
|
42879
|
+
let bgStyleRight = arrowStyle.bgStyle.right;
|
|
42880
|
+
// For arrow = center
|
|
42881
|
+
if (!bgStyleRight) {
|
|
42882
|
+
bgStyleRight = tooltipWidth / 2 - BG_SIZE;
|
|
42883
|
+
}
|
|
42884
|
+
const newBgRight = Math.round(bgStyleRight - style.left + this.margin);
|
|
42885
|
+
arrowStyle = {
|
|
42886
|
+
...arrowStyle,
|
|
42887
|
+
bgStyle: {
|
|
42888
|
+
...arrowStyle.bgStyle,
|
|
42889
|
+
right: newBgRight,
|
|
42890
|
+
left: null
|
|
42891
|
+
},
|
|
42892
|
+
fgStyle: {
|
|
42893
|
+
...arrowStyle.fgStyle,
|
|
42894
|
+
right: newBgRight + 1,
|
|
42895
|
+
left: null
|
|
42896
|
+
}
|
|
42897
|
+
};
|
|
42898
|
+
}
|
|
42899
|
+
style.left = this.margin;
|
|
42900
|
+
} else {
|
|
42901
|
+
let rightOffset = style.left + this.state.width - window.innerWidth;
|
|
42902
|
+
if (rightOffset > 0) {
|
|
42903
|
+
let originalLeft = style.left;
|
|
42904
|
+
style.left = window.innerWidth - this.state.width - this.margin;
|
|
42905
|
+
arrowStyle.fgStyle.marginLeft += originalLeft - style.left;
|
|
42906
|
+
arrowStyle.bgStyle.marginLeft += originalLeft - style.left;
|
|
42907
|
+
}
|
|
42908
|
+
}
|
|
42909
|
+
}
|
|
42910
|
+
return {
|
|
42911
|
+
style,
|
|
42912
|
+
arrowStyle
|
|
42913
|
+
};
|
|
42914
|
+
}
|
|
42915
|
+
componentDidMount() {
|
|
42916
|
+
this.updateSize();
|
|
42917
|
+
}
|
|
42918
|
+
componentDidUpdate(prevProps, prevState) {
|
|
42919
|
+
if (this.props !== prevProps) {
|
|
42920
|
+
this.updateSize();
|
|
42921
|
+
}
|
|
42922
|
+
}
|
|
42923
|
+
updateSize() {
|
|
42924
|
+
const newWidth = this.rootRef.current.offsetWidth;
|
|
42925
|
+
const newHeight = this.rootRef.current.offsetHeight;
|
|
42926
|
+
if (newWidth !== this.state.width || newHeight !== this.state.height) {
|
|
42927
|
+
this.setState({
|
|
42928
|
+
width: newWidth,
|
|
42929
|
+
height: newHeight
|
|
42930
|
+
});
|
|
42931
|
+
}
|
|
42932
|
+
}
|
|
42933
|
+
render() {
|
|
42934
|
+
let {
|
|
42935
|
+
style,
|
|
42936
|
+
arrowStyle
|
|
42937
|
+
} = this.checkWindowPosition(this.getGlobalStyle(), this.getArrowStyle());
|
|
42938
|
+
return /*#__PURE__*/react.createElement("div", {
|
|
42939
|
+
style: style,
|
|
42940
|
+
onMouseEnter: this.handleMouseEnter,
|
|
42941
|
+
onMouseLeave: this.handleMouseLeave,
|
|
42942
|
+
ref: this.rootRef
|
|
42943
|
+
}, this.props.arrow ? /*#__PURE__*/react.createElement("div", null, /*#__PURE__*/react.createElement("span", {
|
|
42944
|
+
style: arrowStyle.fgStyle
|
|
42945
|
+
}), /*#__PURE__*/react.createElement("span", {
|
|
42946
|
+
style: arrowStyle.bgStyle
|
|
42947
|
+
})) : null, this.props.children);
|
|
42948
|
+
}
|
|
42949
|
+
}
|
|
42950
|
+
PortalTooltipCard.propTypes = {
|
|
42951
|
+
active: (prop_types_default()).bool,
|
|
42952
|
+
position: prop_types_default().oneOf(['top', 'right', 'bottom', 'left']),
|
|
42953
|
+
arrow: prop_types_default().oneOf([null, 'center', 'top', 'right', 'bottom', 'left']),
|
|
42954
|
+
align: prop_types_default().oneOf([null, 'center', 'right', 'left']),
|
|
42955
|
+
style: (prop_types_default()).object,
|
|
42956
|
+
useHover: (prop_types_default()).bool
|
|
42957
|
+
};
|
|
42958
|
+
PortalTooltipCard.defaultProps = {
|
|
42959
|
+
active: false,
|
|
42960
|
+
position: 'right',
|
|
42961
|
+
arrow: null,
|
|
42962
|
+
align: null,
|
|
42963
|
+
style: {
|
|
42964
|
+
style: {},
|
|
42965
|
+
arrowStyle: {}
|
|
42966
|
+
},
|
|
42967
|
+
useHover: true
|
|
42968
|
+
};
|
|
42969
|
+
const executeFunctionIfExist = (object, key) => {
|
|
42970
|
+
if (Object.prototype.hasOwnProperty.call(object, key)) {
|
|
42971
|
+
object[key]();
|
|
42972
|
+
}
|
|
42973
|
+
};
|
|
42974
|
+
;// CONCATENATED MODULE: ../../ui/src/components/Tooltip/PortalTooltip.tsx
|
|
42975
|
+
function PortalTooltip_extends() { PortalTooltip_extends = Object.assign ? Object.assign.bind() : function (target) { for (var i = 1; i < arguments.length; i++) { var source = arguments[i]; for (var key in source) { if (Object.prototype.hasOwnProperty.call(source, key)) { target[key] = source[key]; } } } return target; }; return PortalTooltip_extends.apply(this, arguments); }
|
|
42976
|
+
|
|
42977
|
+
|
|
42978
|
+
|
|
42979
|
+
|
|
42980
|
+
const portalNodes = {};
|
|
42981
|
+
|
|
42982
|
+
/**
|
|
42983
|
+
* A portal based tooltip component.
|
|
42984
|
+
*
|
|
42985
|
+
* This component has been repurposed and modified
|
|
42986
|
+
* for OHIF usage: https://github.com/romainberger/react-portal-tooltip
|
|
42987
|
+
*/
|
|
42988
|
+
class PortalTooltip extends react.Component {
|
|
42989
|
+
createPortal() {
|
|
42990
|
+
portalNodes[this.props.group] = {
|
|
42991
|
+
node: document.createElement('div'),
|
|
42992
|
+
timeout: false
|
|
42993
|
+
};
|
|
42994
|
+
portalNodes[this.props.group].node.className = 'ToolTipPortal';
|
|
42995
|
+
document.body.appendChild(portalNodes[this.props.group].node);
|
|
42996
|
+
}
|
|
42997
|
+
renderPortal(props) {
|
|
42998
|
+
if (!portalNodes[this.props.group]) {
|
|
42999
|
+
this.createPortal();
|
|
43000
|
+
}
|
|
43001
|
+
let {
|
|
43002
|
+
parent,
|
|
43003
|
+
...other
|
|
43004
|
+
} = props;
|
|
43005
|
+
let parentEl = typeof parent === 'string' ? document.querySelector(parent) : parent;
|
|
43006
|
+
react_dom.render( /*#__PURE__*/react.createElement(PortalTooltipCard, PortalTooltip_extends({
|
|
43007
|
+
parentEl: parentEl
|
|
43008
|
+
}, other)), portalNodes[this.props.group].node);
|
|
43009
|
+
}
|
|
43010
|
+
componentDidMount() {
|
|
43011
|
+
if (!this.props.active) {
|
|
43012
|
+
return;
|
|
43013
|
+
}
|
|
43014
|
+
this.renderPortal(this.props);
|
|
43015
|
+
}
|
|
43016
|
+
componentWillReceiveProps(nextProps) {
|
|
43017
|
+
if (!portalNodes[this.props.group] && !nextProps.active || !this.props.active && !nextProps.active) {
|
|
43018
|
+
return;
|
|
43019
|
+
}
|
|
43020
|
+
let props = {
|
|
43021
|
+
...nextProps
|
|
43022
|
+
};
|
|
43023
|
+
let newProps = {
|
|
43024
|
+
...nextProps
|
|
43025
|
+
};
|
|
43026
|
+
if (portalNodes[this.props.group] && portalNodes[this.props.group].timeout) {
|
|
43027
|
+
clearTimeout(portalNodes[this.props.group].timeout);
|
|
43028
|
+
}
|
|
43029
|
+
if (this.props.active && !props.active) {
|
|
43030
|
+
newProps.active = true;
|
|
43031
|
+
portalNodes[this.props.group].timeout = setTimeout(() => {
|
|
43032
|
+
props.active = false;
|
|
43033
|
+
this.renderPortal(props);
|
|
43034
|
+
}, this.props.tooltipTimeout);
|
|
43035
|
+
}
|
|
43036
|
+
this.renderPortal(newProps);
|
|
43037
|
+
}
|
|
43038
|
+
componentWillUnmount() {
|
|
43039
|
+
if (portalNodes[this.props.group]) {
|
|
43040
|
+
react_dom.unmountComponentAtNode(portalNodes[this.props.group].node);
|
|
43041
|
+
clearTimeout(portalNodes[this.props.group].timeout);
|
|
43042
|
+
try {
|
|
43043
|
+
document.body.removeChild(portalNodes[this.props.group].node);
|
|
43044
|
+
} catch (e) {}
|
|
43045
|
+
portalNodes[this.props.group] = null;
|
|
43046
|
+
}
|
|
43047
|
+
}
|
|
43048
|
+
render() {
|
|
43049
|
+
return null;
|
|
43050
|
+
}
|
|
43051
|
+
}
|
|
43052
|
+
PortalTooltip.propTypes = {
|
|
43053
|
+
parent: prop_types_default().oneOfType([(prop_types_default()).string, (prop_types_default()).object]).isRequired,
|
|
43054
|
+
active: (prop_types_default()).bool,
|
|
43055
|
+
group: (prop_types_default()).string,
|
|
43056
|
+
tooltipTimeout: (prop_types_default()).number
|
|
43057
|
+
};
|
|
43058
|
+
PortalTooltip.defaultProps = {
|
|
43059
|
+
active: false,
|
|
43060
|
+
group: 'main',
|
|
43061
|
+
tooltipTimeout: 0
|
|
43062
|
+
};
|
|
43063
|
+
;// CONCATENATED MODULE: ../../ui/src/components/DisplaySetMessageListTooltip/DisplaySetMessageListTooltip.tsx
|
|
43064
|
+
|
|
43065
|
+
|
|
43066
|
+
|
|
43067
|
+
|
|
43068
|
+
|
|
43069
|
+
|
|
43070
|
+
/**
|
|
43071
|
+
* Displays a tooltip with a list of messages of a displaySet
|
|
43072
|
+
* @param param0
|
|
43073
|
+
* @returns
|
|
43074
|
+
*/
|
|
43075
|
+
const DisplaySetMessageListTooltip = _ref => {
|
|
43076
|
+
let {
|
|
43077
|
+
messages,
|
|
43078
|
+
id
|
|
43079
|
+
} = _ref;
|
|
43080
|
+
const {
|
|
43081
|
+
t
|
|
43082
|
+
} = (0,es/* useTranslation */.$G)('Messages');
|
|
43083
|
+
const [isOpen, setIsOpen] = (0,react.useState)(false);
|
|
43084
|
+
if (messages.size()) {
|
|
43085
|
+
return /*#__PURE__*/react.createElement(react.Fragment, null, /*#__PURE__*/react.createElement(Icon/* default */.Z, {
|
|
43086
|
+
id: id,
|
|
43087
|
+
onMouseOver: () => setIsOpen(true),
|
|
43088
|
+
onFocus: () => setIsOpen(true),
|
|
43089
|
+
onMouseOut: () => setIsOpen(false),
|
|
43090
|
+
onBlur: () => setIsOpen(false),
|
|
43091
|
+
name: "status-alert-warning"
|
|
43092
|
+
}), /*#__PURE__*/react.createElement(PortalTooltip, {
|
|
43093
|
+
active: isOpen,
|
|
43094
|
+
position: "right",
|
|
43095
|
+
arrow: "center",
|
|
43096
|
+
parent: `#${id}`
|
|
43097
|
+
}, /*#__PURE__*/react.createElement("div", {
|
|
43098
|
+
className: "bg-primary-dark border border-secondary-light text-white text-base rounded text-left max-w-40"
|
|
43099
|
+
}, /*#__PURE__*/react.createElement("div", {
|
|
43100
|
+
className: "break-normal text-base text-blue-300 font-bold",
|
|
43101
|
+
style: {
|
|
43102
|
+
marginLeft: '12px',
|
|
43103
|
+
marginTop: '12px'
|
|
43104
|
+
}
|
|
43105
|
+
}, "DisplaySet Messages"), /*#__PURE__*/react.createElement("ol", {
|
|
43106
|
+
style: {
|
|
43107
|
+
marginLeft: '12px'
|
|
43108
|
+
}
|
|
43109
|
+
}, messages.messages.map((message, index) => /*#__PURE__*/react.createElement("li", {
|
|
43110
|
+
style: {
|
|
43111
|
+
marginTop: '6px',
|
|
43112
|
+
marginBottom: '6px'
|
|
43113
|
+
},
|
|
43114
|
+
key: index
|
|
43115
|
+
}, index + 1, ". ", t(message.id)))))));
|
|
43116
|
+
}
|
|
43117
|
+
return /*#__PURE__*/react.createElement(react.Fragment, null);
|
|
43118
|
+
};
|
|
43119
|
+
DisplaySetMessageListTooltip.propTypes = {
|
|
43120
|
+
messages: (prop_types_default()).object
|
|
43121
|
+
};
|
|
43122
|
+
/* harmony default export */ const DisplaySetMessageListTooltip_DisplaySetMessageListTooltip = (DisplaySetMessageListTooltip);
|
|
43123
|
+
;// CONCATENATED MODULE: ../../ui/src/components/DisplaySetMessageListTooltip/index.js
|
|
43124
|
+
|
|
43125
|
+
/* harmony default export */ const components_DisplaySetMessageListTooltip = (DisplaySetMessageListTooltip_DisplaySetMessageListTooltip);
|
|
42541
43126
|
;// CONCATENATED MODULE: ../../ui/src/components/Thumbnail/Thumbnail.tsx
|
|
42542
43127
|
|
|
42543
43128
|
|
|
@@ -42546,6 +43131,7 @@ StudyItem.propTypes = {
|
|
|
42546
43131
|
|
|
42547
43132
|
|
|
42548
43133
|
|
|
43134
|
+
|
|
42549
43135
|
/**
|
|
42550
43136
|
* Display a thumbnail for a display set.
|
|
42551
43137
|
*/
|
|
@@ -42559,6 +43145,7 @@ const Thumbnail = _ref => {
|
|
|
42559
43145
|
seriesNumber,
|
|
42560
43146
|
numInstances,
|
|
42561
43147
|
countIcon,
|
|
43148
|
+
messages,
|
|
42562
43149
|
dragData,
|
|
42563
43150
|
isActive,
|
|
42564
43151
|
onClick,
|
|
@@ -42607,7 +43194,10 @@ const Thumbnail = _ref => {
|
|
|
42607
43194
|
}, /*#__PURE__*/react.createElement(Icon/* default */.Z, {
|
|
42608
43195
|
name: countIcon || 'group-layers',
|
|
42609
43196
|
className: "w-3 mr-2"
|
|
42610
|
-
}), ` ${numInstances}`)
|
|
43197
|
+
}), ` ${numInstances}`), /*#__PURE__*/react.createElement(components_DisplaySetMessageListTooltip, {
|
|
43198
|
+
messages: messages,
|
|
43199
|
+
id: `display-set-tooltip-${seriesNumber}`
|
|
43200
|
+
})), /*#__PURE__*/react.createElement("div", {
|
|
42611
43201
|
className: "text-base text-white break-all"
|
|
42612
43202
|
}, description)));
|
|
42613
43203
|
};
|
|
@@ -42630,6 +43220,7 @@ Thumbnail.propTypes = {
|
|
|
42630
43220
|
description: (prop_types_default()).string.isRequired,
|
|
42631
43221
|
seriesNumber: StringNumber.isRequired,
|
|
42632
43222
|
numInstances: (prop_types_default()).number.isRequired,
|
|
43223
|
+
messages: (prop_types_default()).object,
|
|
42633
43224
|
isActive: (prop_types_default()).bool.isRequired,
|
|
42634
43225
|
onClick: (prop_types_default()).func.isRequired,
|
|
42635
43226
|
onDoubleClick: (prop_types_default()).func.isRequired
|
|
@@ -42660,6 +43251,7 @@ const ThumbnailNoImage = _ref => {
|
|
|
42660
43251
|
onDoubleClick,
|
|
42661
43252
|
canReject,
|
|
42662
43253
|
onReject,
|
|
43254
|
+
messages,
|
|
42663
43255
|
dragData,
|
|
42664
43256
|
isActive
|
|
42665
43257
|
} = _ref;
|
|
@@ -42699,7 +43291,16 @@ const ThumbnailNoImage = _ref => {
|
|
|
42699
43291
|
className: "px-3 text-lg text-white rounded-sm bg-primary-main"
|
|
42700
43292
|
}, modality)), /*#__PURE__*/react.createElement("span", {
|
|
42701
43293
|
className: "ml-4 text-base text-blue-300"
|
|
42702
|
-
}, seriesDate)
|
|
43294
|
+
}, seriesDate), messages?.size() ? /*#__PURE__*/react.createElement("div", null, /*#__PURE__*/react.createElement(components_Tooltip, {
|
|
43295
|
+
position: "left",
|
|
43296
|
+
tight: true,
|
|
43297
|
+
content: /*#__PURE__*/react.createElement("div", {
|
|
43298
|
+
className: "text-left max-w-40"
|
|
43299
|
+
}, messages.thumbnailContents())
|
|
43300
|
+
}, /*#__PURE__*/react.createElement(Icon/* default */.Z, {
|
|
43301
|
+
name: "notifications-warning",
|
|
43302
|
+
className: "w-3 h-3"
|
|
43303
|
+
}))) : /*#__PURE__*/react.createElement(react.Fragment, null)), /*#__PURE__*/react.createElement("div", {
|
|
42703
43304
|
className: "flex flex-row"
|
|
42704
43305
|
}, canReject && /*#__PURE__*/react.createElement(Icon/* default */.Z, {
|
|
42705
43306
|
name: "old-trash",
|
|
@@ -42732,6 +43333,7 @@ ThumbnailNoImage.propTypes = {
|
|
|
42732
43333
|
seriesDate: (prop_types_default()).string.isRequired,
|
|
42733
43334
|
onClick: (prop_types_default()).func.isRequired,
|
|
42734
43335
|
onDoubleClick: (prop_types_default()).func.isRequired,
|
|
43336
|
+
messages: (prop_types_default()).object,
|
|
42735
43337
|
isActive: (prop_types_default()).bool.isRequired
|
|
42736
43338
|
};
|
|
42737
43339
|
/* harmony default export */ const ThumbnailNoImage_ThumbnailNoImage = (ThumbnailNoImage);
|
|
@@ -42756,6 +43358,7 @@ const ThumbnailTracked = _ref => {
|
|
|
42756
43358
|
seriesNumber,
|
|
42757
43359
|
numInstances,
|
|
42758
43360
|
countIcon,
|
|
43361
|
+
messages,
|
|
42759
43362
|
dragData,
|
|
42760
43363
|
onClick,
|
|
42761
43364
|
onDoubleClick,
|
|
@@ -42827,6 +43430,7 @@ const ThumbnailTracked = _ref => {
|
|
|
42827
43430
|
dragData: dragData,
|
|
42828
43431
|
description: description,
|
|
42829
43432
|
seriesNumber: seriesNumber,
|
|
43433
|
+
messages: messages,
|
|
42830
43434
|
numInstances: numInstances,
|
|
42831
43435
|
countIcon: countIcon,
|
|
42832
43436
|
isActive: isActive,
|
|
@@ -42858,6 +43462,7 @@ ThumbnailTracked.propTypes = {
|
|
|
42858
43462
|
onClickUntrack: (prop_types_default()).func.isRequired,
|
|
42859
43463
|
viewportIdentificator: (prop_types_default()).array,
|
|
42860
43464
|
isTracked: (prop_types_default()).bool,
|
|
43465
|
+
messages: (prop_types_default()).object,
|
|
42861
43466
|
isActive: (prop_types_default()).bool.isRequired
|
|
42862
43467
|
};
|
|
42863
43468
|
/* harmony default export */ const ThumbnailTracked_ThumbnailTracked = (ThumbnailTracked);
|
|
@@ -42898,6 +43503,7 @@ const ThumbnailList = _ref => {
|
|
|
42898
43503
|
canReject,
|
|
42899
43504
|
onReject,
|
|
42900
43505
|
imageSrc,
|
|
43506
|
+
messages,
|
|
42901
43507
|
imageAltText
|
|
42902
43508
|
} = _ref2;
|
|
42903
43509
|
const isActive = activeDisplaySetInstanceUIDs.includes(displaySetInstanceUID);
|
|
@@ -42913,6 +43519,7 @@ const ThumbnailList = _ref => {
|
|
|
42913
43519
|
countIcon: countIcon,
|
|
42914
43520
|
imageSrc: imageSrc,
|
|
42915
43521
|
imageAltText: imageAltText,
|
|
43522
|
+
messages: messages,
|
|
42916
43523
|
viewportIdentificator: viewportIdentificator,
|
|
42917
43524
|
isActive: isActive,
|
|
42918
43525
|
onClick: () => onThumbnailClick(displaySetInstanceUID),
|
|
@@ -42929,6 +43536,7 @@ const ThumbnailList = _ref => {
|
|
|
42929
43536
|
countIcon: countIcon,
|
|
42930
43537
|
imageSrc: imageSrc,
|
|
42931
43538
|
imageAltText: imageAltText,
|
|
43539
|
+
messages: messages,
|
|
42932
43540
|
viewportIdentificator: viewportIdentificator,
|
|
42933
43541
|
isTracked: isTracked,
|
|
42934
43542
|
isActive: isActive,
|
|
@@ -42944,6 +43552,7 @@ const ThumbnailList = _ref => {
|
|
|
42944
43552
|
dragData: dragData,
|
|
42945
43553
|
modality: modality,
|
|
42946
43554
|
modalityTooltip: _getModalityTooltip(modality),
|
|
43555
|
+
messages: messages,
|
|
42947
43556
|
seriesDate: seriesDate,
|
|
42948
43557
|
description: description,
|
|
42949
43558
|
canReject: canReject,
|
|
@@ -44133,7 +44742,9 @@ const Viewport_Viewport = _ref => {
|
|
|
44133
44742
|
value: 1
|
|
44134
44743
|
}],
|
|
44135
44744
|
onSubmit: value => {
|
|
44136
|
-
if (typeof window !== 'undefined')
|
|
44745
|
+
if (typeof window !== 'undefined') {
|
|
44746
|
+
window.alert(value);
|
|
44747
|
+
}
|
|
44137
44748
|
}
|
|
44138
44749
|
})), /*#__PURE__*/react.createElement("div", {
|
|
44139
44750
|
className: "w-full h-full",
|
|
@@ -46125,7 +46736,7 @@ function _getImageOrientationPatient(image) {
|
|
|
46125
46736
|
|
|
46126
46737
|
/***/ }),
|
|
46127
46738
|
|
|
46128
|
-
/***/
|
|
46739
|
+
/***/ 24966:
|
|
46129
46740
|
/***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
|
|
46130
46741
|
|
|
46131
46742
|
"use strict";
|
|
@@ -46137,6 +46748,8 @@ __webpack_require__.d(__webpack_exports__, {
|
|
|
46137
46748
|
wQ: () => (/* reexport */ services_CustomizationService),
|
|
46138
46749
|
DICOMWeb: () => (/* reexport */ src_DICOMWeb),
|
|
46139
46750
|
DicomMetadataStore: () => (/* reexport */ services_DicomMetadataStore),
|
|
46751
|
+
Lt: () => (/* reexport */ DisplaySetMessage),
|
|
46752
|
+
iK: () => (/* reexport */ DisplaySetMessageList),
|
|
46140
46753
|
iY: () => (/* reexport */ services_DisplaySetService),
|
|
46141
46754
|
W$: () => (/* reexport */ ExtensionManager),
|
|
46142
46755
|
hy: () => (/* reexport */ services_HangingProtocolService),
|
|
@@ -47938,7 +48551,9 @@ class DisplaySetService extends PubSubService {
|
|
|
47938
48551
|
this._broadcastEvent(DisplaySetService_EVENTS.DISPLAY_SET_SERIES_METADATA_INVALIDATED, displaySetInstanceUID);
|
|
47939
48552
|
}
|
|
47940
48553
|
deleteDisplaySet(displaySetInstanceUID) {
|
|
47941
|
-
if (!displaySetInstanceUID)
|
|
48554
|
+
if (!displaySetInstanceUID) {
|
|
48555
|
+
return;
|
|
48556
|
+
}
|
|
47942
48557
|
const {
|
|
47943
48558
|
activeDisplaySets,
|
|
47944
48559
|
activeDisplaySetsMap
|
|
@@ -48012,7 +48627,9 @@ class DisplaySetService extends PubSubService {
|
|
|
48012
48627
|
}
|
|
48013
48628
|
// This means that all instances already existed or got added to
|
|
48014
48629
|
// existing display sets, and had an invalidated event fired
|
|
48015
|
-
if (!instances.length)
|
|
48630
|
+
if (!instances.length) {
|
|
48631
|
+
return allDisplaySets;
|
|
48632
|
+
}
|
|
48016
48633
|
}
|
|
48017
48634
|
if (!instances.length) {
|
|
48018
48635
|
// Everything is already added - this is just an update caused
|
|
@@ -48025,7 +48642,9 @@ class DisplaySetService extends PubSubService {
|
|
|
48025
48642
|
// The instances array still contains some instances, so try
|
|
48026
48643
|
// creating additional display sets using the sop class handler
|
|
48027
48644
|
displaySets = handler.getDisplaySetsFromSeries(instances);
|
|
48028
|
-
if (!displaySets || !displaySets.length)
|
|
48645
|
+
if (!displaySets || !displaySets.length) {
|
|
48646
|
+
continue;
|
|
48647
|
+
}
|
|
48029
48648
|
|
|
48030
48649
|
// applying hp-defined viewport settings to the displaysets
|
|
48031
48650
|
displaySets.forEach(ds => {
|
|
@@ -48076,9 +48695,57 @@ DisplaySetService.REGISTRATION = {
|
|
|
48076
48695
|
return new DisplaySetService();
|
|
48077
48696
|
}
|
|
48078
48697
|
};
|
|
48698
|
+
;// CONCATENATED MODULE: ../../core/src/services/DisplaySetService/DisplaySetMessage.ts
|
|
48699
|
+
/**
|
|
48700
|
+
* Defines a displaySet message, that could be any pf the potential problems of a displaySet
|
|
48701
|
+
*/
|
|
48702
|
+
class DisplaySetMessage {
|
|
48703
|
+
constructor(id) {
|
|
48704
|
+
this.id = void 0;
|
|
48705
|
+
this.id = id;
|
|
48706
|
+
}
|
|
48707
|
+
}
|
|
48708
|
+
/**
|
|
48709
|
+
* Defines a list of displaySet messages
|
|
48710
|
+
*/
|
|
48711
|
+
DisplaySetMessage.CODES = {
|
|
48712
|
+
NO_VALID_INSTANCES: 1,
|
|
48713
|
+
NO_POSITION_INFORMATION: 2,
|
|
48714
|
+
NOT_RECONSTRUCTABLE: 3,
|
|
48715
|
+
MULTIFRAME_NO_PIXEL_MEASUREMENTS: 4,
|
|
48716
|
+
MULTIFRAME_NO_ORIENTATION: 5,
|
|
48717
|
+
MULTIFRAME_NO_POSITION_INFORMATION: 6,
|
|
48718
|
+
MISSING_FRAMES: 7,
|
|
48719
|
+
IRREGULAR_SPACING: 8,
|
|
48720
|
+
INCONSISTENT_DIMENSIONS: 9,
|
|
48721
|
+
INCONSISTENT_COMPONENTS: 10,
|
|
48722
|
+
INCONSISTENT_ORIENTATIONS: 11,
|
|
48723
|
+
INCONSISTENT_POSITION_INFORMATION: 12
|
|
48724
|
+
};
|
|
48725
|
+
class DisplaySetMessageList {
|
|
48726
|
+
constructor() {
|
|
48727
|
+
this.messages = [];
|
|
48728
|
+
}
|
|
48729
|
+
addMessage(messageId) {
|
|
48730
|
+
const message = new DisplaySetMessage(messageId);
|
|
48731
|
+
this.messages.push(message);
|
|
48732
|
+
}
|
|
48733
|
+
size() {
|
|
48734
|
+
return this.messages.length;
|
|
48735
|
+
}
|
|
48736
|
+
includesMessage(messageId) {
|
|
48737
|
+
return this.messages.some(message => message.id === messageId);
|
|
48738
|
+
}
|
|
48739
|
+
includesAllMessages(messageIdList) {
|
|
48740
|
+
return messageIdList.every(messageId => this.include(messageId));
|
|
48741
|
+
}
|
|
48742
|
+
}
|
|
48743
|
+
|
|
48079
48744
|
;// CONCATENATED MODULE: ../../core/src/services/DisplaySetService/index.ts
|
|
48080
48745
|
|
|
48746
|
+
|
|
48081
48747
|
/* harmony default export */ const services_DisplaySetService = (DisplaySetService);
|
|
48748
|
+
|
|
48082
48749
|
// EXTERNAL MODULE: ../../../node_modules/lodash.merge/index.js
|
|
48083
48750
|
var lodash_merge = __webpack_require__(12178);
|
|
48084
48751
|
var lodash_merge_default = /*#__PURE__*/__webpack_require__.n(lodash_merge);
|
|
@@ -48134,7 +48801,9 @@ class ToolbarService extends PubSubService {
|
|
|
48134
48801
|
* called with {...commandOptions,...options}
|
|
48135
48802
|
*/
|
|
48136
48803
|
recordInteraction(interaction, options) {
|
|
48137
|
-
if (!interaction)
|
|
48804
|
+
if (!interaction) {
|
|
48805
|
+
return;
|
|
48806
|
+
}
|
|
48138
48807
|
const commandsManager = this._commandsManager;
|
|
48139
48808
|
const {
|
|
48140
48809
|
groupId,
|
|
@@ -48406,13 +49075,19 @@ const addUniqueIndex = (arr, key, viewports, isUpdatingSameViewport) => {
|
|
|
48406
49075
|
}
|
|
48407
49076
|
};
|
|
48408
49077
|
const getLutId = ds => {
|
|
48409
|
-
if (!ds || !ds.options)
|
|
48410
|
-
|
|
49078
|
+
if (!ds || !ds.options) {
|
|
49079
|
+
return DEFAULT;
|
|
49080
|
+
}
|
|
49081
|
+
if (ds.options.id) {
|
|
49082
|
+
return ds.options.id;
|
|
49083
|
+
}
|
|
48411
49084
|
const arr = Object.entries(ds.options).map(_ref => {
|
|
48412
49085
|
let [key, val] = _ref;
|
|
48413
49086
|
return `${key}=${val}`;
|
|
48414
49087
|
});
|
|
48415
|
-
if (!arr.length)
|
|
49088
|
+
if (!arr.length) {
|
|
49089
|
+
return DEFAULT;
|
|
49090
|
+
}
|
|
48416
49091
|
return arr.join(JOIN_STR);
|
|
48417
49092
|
};
|
|
48418
49093
|
/**
|
|
@@ -48461,7 +49136,9 @@ const getLutId = ds => {
|
|
|
48461
49136
|
* @returns PresentationIds
|
|
48462
49137
|
*/
|
|
48463
49138
|
const getPresentationIds = (viewport, viewports) => {
|
|
48464
|
-
if (!viewport)
|
|
49139
|
+
if (!viewport) {
|
|
49140
|
+
return;
|
|
49141
|
+
}
|
|
48465
49142
|
const {
|
|
48466
49143
|
viewportOptions,
|
|
48467
49144
|
displaySetInstanceUIDs,
|
|
@@ -48477,7 +49154,9 @@ const getPresentationIds = (viewport, viewports) => {
|
|
|
48477
49154
|
const lutId = getLutId(displaySetOptions[0]);
|
|
48478
49155
|
const lutPresentationArr = [lutId];
|
|
48479
49156
|
const positionPresentationArr = [orientation || 'acquisition'];
|
|
48480
|
-
if (id)
|
|
49157
|
+
if (id) {
|
|
49158
|
+
positionPresentationArr.push(id);
|
|
49159
|
+
}
|
|
48481
49160
|
for (const uid of displaySetInstanceUIDs) {
|
|
48482
49161
|
positionPresentationArr.push(uid);
|
|
48483
49162
|
lutPresentationArr.push(uid);
|
|
@@ -48896,7 +49575,9 @@ var validate_default = /*#__PURE__*/__webpack_require__.n(validate);
|
|
|
48896
49575
|
if (includedValues.length === 0) {
|
|
48897
49576
|
return `${key} must include at least one of the following values: ${testValue.join(', ')}`;
|
|
48898
49577
|
}
|
|
48899
|
-
} else
|
|
49578
|
+
} else {
|
|
49579
|
+
return `${key} ${testValue} must be an array`;
|
|
49580
|
+
}
|
|
48900
49581
|
// else if (!value.includes(testValue)) {
|
|
48901
49582
|
// return `${key} ${value} must include ${testValue}`;
|
|
48902
49583
|
// }
|
|
@@ -48933,7 +49614,9 @@ var validate_default = /*#__PURE__*/__webpack_require__.n(validate);
|
|
|
48933
49614
|
if (includedValues.length > 0) {
|
|
48934
49615
|
return `${key} must not include the following value: ${includedValues}`;
|
|
48935
49616
|
}
|
|
48936
|
-
} else
|
|
49617
|
+
} else {
|
|
49618
|
+
return `${key} ${testValue} must be an array`;
|
|
49619
|
+
}
|
|
48937
49620
|
};
|
|
48938
49621
|
// Ignore case contains.
|
|
48939
49622
|
// options testValue MUST be in lower case already, otherwise it won't match
|
|
@@ -49211,7 +49894,9 @@ var validate_default = /*#__PURE__*/__webpack_require__.n(validate);
|
|
|
49211
49894
|
if (value === undefined || value < min || value > max) {
|
|
49212
49895
|
return `${key} with value ${value} must be between ${min} and ${max}`;
|
|
49213
49896
|
}
|
|
49214
|
-
} else
|
|
49897
|
+
} else {
|
|
49898
|
+
return `${key} must be an array of length 2`;
|
|
49899
|
+
}
|
|
49215
49900
|
};
|
|
49216
49901
|
(validate_default()).validators.notNull = value => value === null || value === undefined ? 'Value is null' : undefined;
|
|
49217
49902
|
const getTestValue = options => {
|
|
@@ -49601,7 +50286,9 @@ class ObjectPath {
|
|
|
49601
50286
|
;// CONCATENATED MODULE: ../../core/src/utils/absoluteUrl.js
|
|
49602
50287
|
const absoluteUrl = path => {
|
|
49603
50288
|
let absolutePath = '/';
|
|
49604
|
-
if (!path)
|
|
50289
|
+
if (!path) {
|
|
50290
|
+
return absolutePath;
|
|
50291
|
+
}
|
|
49605
50292
|
|
|
49606
50293
|
// TODO: Find another way to get root url
|
|
49607
50294
|
const absoluteUrl = window.location.origin;
|
|
@@ -49742,15 +50429,19 @@ function makeDeferred() {
|
|
|
49742
50429
|
function makeCancelable(thenable) {
|
|
49743
50430
|
let isCanceled = false;
|
|
49744
50431
|
const promise = Promise.resolve(thenable).then(function (result) {
|
|
49745
|
-
if (isCanceled)
|
|
49746
|
-
|
|
49747
|
-
|
|
50432
|
+
if (isCanceled) {
|
|
50433
|
+
throw Object.freeze({
|
|
50434
|
+
isCanceled
|
|
50435
|
+
});
|
|
50436
|
+
}
|
|
49748
50437
|
return result;
|
|
49749
50438
|
}, function (error) {
|
|
49750
|
-
if (isCanceled)
|
|
49751
|
-
|
|
49752
|
-
|
|
49753
|
-
|
|
50439
|
+
if (isCanceled) {
|
|
50440
|
+
throw Object.freeze({
|
|
50441
|
+
isCanceled,
|
|
50442
|
+
error
|
|
50443
|
+
});
|
|
50444
|
+
}
|
|
49754
50445
|
throw error;
|
|
49755
50446
|
});
|
|
49756
50447
|
return Object.assign(Object.create(promise), {
|
|
@@ -50510,7 +51201,9 @@ function getOverallProgress(list) {
|
|
|
50510
51201
|
status.total++;
|
|
50511
51202
|
if (isValidProgress(task.progress)) {
|
|
50512
51203
|
status.partial += task.progress;
|
|
50513
|
-
if (task.progress === 1.0 && task.failed)
|
|
51204
|
+
if (task.progress === 1.0 && task.failed) {
|
|
51205
|
+
status.failures++;
|
|
51206
|
+
}
|
|
50514
51207
|
}
|
|
50515
51208
|
task = task.next;
|
|
50516
51209
|
}
|
|
@@ -50723,12 +51416,16 @@ function debounce(func, wait, immediate) {
|
|
|
50723
51416
|
args = arguments;
|
|
50724
51417
|
var later = function () {
|
|
50725
51418
|
timeout = null;
|
|
50726
|
-
if (!immediate)
|
|
51419
|
+
if (!immediate) {
|
|
51420
|
+
func.apply(context, args);
|
|
51421
|
+
}
|
|
50727
51422
|
};
|
|
50728
51423
|
var callNow = immediate && !timeout;
|
|
50729
51424
|
clearTimeout(timeout);
|
|
50730
51425
|
timeout = setTimeout(later, wait);
|
|
50731
|
-
if (callNow)
|
|
51426
|
+
if (callNow) {
|
|
51427
|
+
func.apply(context, args);
|
|
51428
|
+
}
|
|
50732
51429
|
};
|
|
50733
51430
|
}
|
|
50734
51431
|
/* harmony default export */ const utils_debounce = (debounce);
|
|
@@ -50888,7 +51585,9 @@ function subscribeToNextViewportGridChange(viewportGridService, gridChangeCallba
|
|
|
50888
51585
|
;// CONCATENATED MODULE: ../../core/src/utils/splitComma.ts
|
|
50889
51586
|
/** Splits a list of stirngs by commas within the strings */
|
|
50890
51587
|
const splitComma = strings => {
|
|
50891
|
-
if (!strings)
|
|
51588
|
+
if (!strings) {
|
|
51589
|
+
return null;
|
|
51590
|
+
}
|
|
50892
51591
|
for (let i = 0; i < strings.length; i++) {
|
|
50893
51592
|
const comma = strings[i].indexOf(',');
|
|
50894
51593
|
if (comma !== -1) {
|
|
@@ -50908,7 +51607,9 @@ const splitComma = strings => {
|
|
|
50908
51607
|
const getSplitParam = function (lowerCaseKey) {
|
|
50909
51608
|
let params = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : new URLSearchParams(window.location.search);
|
|
50910
51609
|
const sourceKey = [...params.keys()].find(it => it.toLowerCase() === lowerCaseKey);
|
|
50911
|
-
if (!sourceKey)
|
|
51610
|
+
if (!sourceKey) {
|
|
51611
|
+
return;
|
|
51612
|
+
}
|
|
50912
51613
|
return splitComma(params.getAll(sourceKey));
|
|
50913
51614
|
};
|
|
50914
51615
|
|
|
@@ -50977,7 +51678,7 @@ const utils = {
|
|
|
50977
51678
|
progressTrackingUtils: utils_progressTrackingUtils,
|
|
50978
51679
|
isLowPriorityModality: isLowPriorityModality/* default */.Z,
|
|
50979
51680
|
isImage: isImage/* isImage */.O,
|
|
50980
|
-
isDisplaySetReconstructable: isDisplaySetReconstructable/* default */.
|
|
51681
|
+
isDisplaySetReconstructable: isDisplaySetReconstructable/* default */.ZP,
|
|
50981
51682
|
debounce: utils_debounce,
|
|
50982
51683
|
roundNumber: roundNumber,
|
|
50983
51684
|
downloadCSVReport: downloadCSVReport,
|
|
@@ -51001,7 +51702,9 @@ const isDisplaySetFromUrl = displaySet => {
|
|
|
51001
51702
|
const params = new URLSearchParams(window.location.search);
|
|
51002
51703
|
const initialSeriesInstanceUID = getSplitParam('initialseriesinstanceuid', params);
|
|
51003
51704
|
const initialSOPInstanceUID = getSplitParam('initialsopinstanceuid', params);
|
|
51004
|
-
if (!initialSeriesInstanceUID && !initialSOPInstanceUID)
|
|
51705
|
+
if (!initialSeriesInstanceUID && !initialSOPInstanceUID) {
|
|
51706
|
+
return false;
|
|
51707
|
+
}
|
|
51005
51708
|
const isSeriesMatch = !initialSeriesInstanceUID || initialSeriesInstanceUID.some(seriesUID => displaySet.SeriesInstanceUID === seriesUID);
|
|
51006
51709
|
const isSopMatch = !initialSOPInstanceUID || displaySet.instances?.some?.(instance => initialSOPInstanceUID.some(sopUID => sopUID === instance.SOPInstanceUID));
|
|
51007
51710
|
return isSeriesMatch && isSopMatch;
|
|
@@ -51012,9 +51715,13 @@ const isDisplaySetFromUrl = displaySet => {
|
|
|
51012
51715
|
*/
|
|
51013
51716
|
function sopInstanceLocation(displaySets) {
|
|
51014
51717
|
const displaySet = displaySets?.[0];
|
|
51015
|
-
if (!displaySet)
|
|
51718
|
+
if (!displaySet) {
|
|
51719
|
+
return;
|
|
51720
|
+
}
|
|
51016
51721
|
const initialSOPInstanceUID = getSplitParam('initialsopinstanceuid');
|
|
51017
|
-
if (!initialSOPInstanceUID)
|
|
51722
|
+
if (!initialSOPInstanceUID) {
|
|
51723
|
+
return;
|
|
51724
|
+
}
|
|
51018
51725
|
const index = displaySet.instances.findIndex(instance => initialSOPInstanceUID.includes(instance.SOPInstanceUID));
|
|
51019
51726
|
// Need to return in the initial position specified format.
|
|
51020
51727
|
return index === -1 ? undefined : {
|
|
@@ -51025,7 +51732,7 @@ function sopInstanceLocation(displaySets) {
|
|
|
51025
51732
|
;// CONCATENATED MODULE: ../../core/src/services/HangingProtocolService/custom-attribute/numberOfDisplaySetsWithImages.ts
|
|
51026
51733
|
/* harmony default export */ const numberOfDisplaySetsWithImages = ((study, extraData) => {
|
|
51027
51734
|
const ret = extraData?.displaySets?.filter(ds => ds.numImageFrames > 0)?.length;
|
|
51028
|
-
console.log(
|
|
51735
|
+
console.log('number of display sets with images', ret);
|
|
51029
51736
|
return ret;
|
|
51030
51737
|
});
|
|
51031
51738
|
;// CONCATENATED MODULE: ../../core/src/services/HangingProtocolService/custom-attribute/seriesDescriptionsFromDisplaySets.ts
|
|
@@ -51080,7 +51787,9 @@ class HangingProtocolService extends PubSubService {
|
|
|
51080
51787
|
const {
|
|
51081
51788
|
Modality
|
|
51082
51789
|
} = curr;
|
|
51083
|
-
if (Modality && prev.indexOf(Modality) == -1)
|
|
51790
|
+
if (Modality && prev.indexOf(Modality) == -1) {
|
|
51791
|
+
prev.push(Modality);
|
|
51792
|
+
}
|
|
51084
51793
|
return prev;
|
|
51085
51794
|
}, [])
|
|
51086
51795
|
},
|
|
@@ -51172,7 +51881,9 @@ class HangingProtocolService extends PubSubService {
|
|
|
51172
51881
|
* protocolId, stageIndex, stageId and activeStudyUID
|
|
51173
51882
|
*/
|
|
51174
51883
|
getState() {
|
|
51175
|
-
if (!this.protocol)
|
|
51884
|
+
if (!this.protocol) {
|
|
51885
|
+
return;
|
|
51886
|
+
}
|
|
51176
51887
|
return {
|
|
51177
51888
|
protocolId: this.protocol.id,
|
|
51178
51889
|
stageIndex: this.stageIndex,
|
|
@@ -51228,8 +51939,12 @@ class HangingProtocolService extends PubSubService {
|
|
|
51228
51939
|
* @returns protocol - the protocol with the given id
|
|
51229
51940
|
*/
|
|
51230
51941
|
getProtocolById(protocolId) {
|
|
51231
|
-
if (!protocolId)
|
|
51232
|
-
|
|
51942
|
+
if (!protocolId) {
|
|
51943
|
+
return;
|
|
51944
|
+
}
|
|
51945
|
+
if (protocolId === this.protocol?.id) {
|
|
51946
|
+
return this.protocol;
|
|
51947
|
+
}
|
|
51233
51948
|
const protocol = this.protocols.get(protocolId);
|
|
51234
51949
|
if (!protocol) {
|
|
51235
51950
|
throw new Error(`No protocol ${protocolId} found`);
|
|
@@ -51616,8 +52331,12 @@ class HangingProtocolService extends PubSubService {
|
|
|
51616
52331
|
if (Array.isArray(options)) {
|
|
51617
52332
|
return options.map(option => this.getComputedOptions(option, displaySetUIDs));
|
|
51618
52333
|
}
|
|
51619
|
-
if (options === null)
|
|
51620
|
-
|
|
52334
|
+
if (options === null) {
|
|
52335
|
+
return options;
|
|
52336
|
+
}
|
|
52337
|
+
if (typeof options !== 'object') {
|
|
52338
|
+
return options;
|
|
52339
|
+
}
|
|
51621
52340
|
|
|
51622
52341
|
// If options is an object with a custom attribute, compute a new options object
|
|
51623
52342
|
if (options.custom) {
|
|
@@ -51751,7 +52470,9 @@ class HangingProtocolService extends PubSubService {
|
|
|
51751
52470
|
if (stageId) {
|
|
51752
52471
|
for (let i = 0; i < stages.length; i++) {
|
|
51753
52472
|
const stage = stages[i];
|
|
51754
|
-
if (stage.id === stageId && stage.status !== 'disabled')
|
|
52473
|
+
if (stage.id === stageId && stage.status !== 'disabled') {
|
|
52474
|
+
return i;
|
|
52475
|
+
}
|
|
51755
52476
|
}
|
|
51756
52477
|
return;
|
|
51757
52478
|
}
|
|
@@ -51761,7 +52482,9 @@ class HangingProtocolService extends PubSubService {
|
|
|
51761
52482
|
}
|
|
51762
52483
|
let firstNotDisabled;
|
|
51763
52484
|
for (let i = 0; i < stages.length; i++) {
|
|
51764
|
-
if (stages[i].status === 'enabled')
|
|
52485
|
+
if (stages[i].status === 'enabled') {
|
|
52486
|
+
return i;
|
|
52487
|
+
}
|
|
51765
52488
|
if (firstNotDisabled === undefined && stages[i].status !== 'disabled') {
|
|
51766
52489
|
firstNotDisabled = i;
|
|
51767
52490
|
}
|
|
@@ -51825,7 +52548,9 @@ class HangingProtocolService extends PubSubService {
|
|
|
51825
52548
|
if (stageId !== undefined) {
|
|
51826
52549
|
return protocol.stages.findIndex(it => it.id === stageId);
|
|
51827
52550
|
}
|
|
51828
|
-
if (stageIndex !== undefined)
|
|
52551
|
+
if (stageIndex !== undefined) {
|
|
52552
|
+
return stageIndex;
|
|
52553
|
+
}
|
|
51829
52554
|
return 0;
|
|
51830
52555
|
}
|
|
51831
52556
|
|
|
@@ -51865,7 +52590,9 @@ class HangingProtocolService extends PubSubService {
|
|
|
51865
52590
|
const protocol = this.protocol;
|
|
51866
52591
|
const stage = protocol.stages[stageIdx];
|
|
51867
52592
|
const defaultViewport = stage.defaultViewport || protocol.defaultViewport;
|
|
51868
|
-
if (!defaultViewport)
|
|
52593
|
+
if (!defaultViewport) {
|
|
52594
|
+
return;
|
|
52595
|
+
}
|
|
51869
52596
|
const useViewport = {
|
|
51870
52597
|
...defaultViewport
|
|
51871
52598
|
};
|
|
@@ -51961,8 +52688,12 @@ class HangingProtocolService extends PubSubService {
|
|
|
51961
52688
|
}
|
|
51962
52689
|
findDeduplicatedMatchDetails(matchDetails, offset) {
|
|
51963
52690
|
let options = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : {};
|
|
51964
|
-
if (!matchDetails)
|
|
51965
|
-
|
|
52691
|
+
if (!matchDetails) {
|
|
52692
|
+
return;
|
|
52693
|
+
}
|
|
52694
|
+
if (offset === 0) {
|
|
52695
|
+
return matchDetails;
|
|
52696
|
+
}
|
|
51966
52697
|
const {
|
|
51967
52698
|
matchingScores = []
|
|
51968
52699
|
} = matchDetails;
|
|
@@ -51970,7 +52701,9 @@ class HangingProtocolService extends PubSubService {
|
|
|
51970
52701
|
const {
|
|
51971
52702
|
inDisplay
|
|
51972
52703
|
} = options;
|
|
51973
|
-
if (!inDisplay)
|
|
52704
|
+
if (!inDisplay) {
|
|
52705
|
+
return matchDetails;
|
|
52706
|
+
}
|
|
51974
52707
|
for (let i = 0; i < matchDetails.matchingScores.length; i++) {
|
|
51975
52708
|
if (inDisplay.indexOf(matchDetails.matchingScores[i].displaySetInstanceUID) === -1) {
|
|
51976
52709
|
const match = matchDetails.matchingScores[i];
|
|
@@ -51989,12 +52722,16 @@ class HangingProtocolService extends PubSubService {
|
|
|
51989
52722
|
} : undefined;
|
|
51990
52723
|
}
|
|
51991
52724
|
validateDisplaySetSelectMatch(match, id, displaySetUID) {
|
|
51992
|
-
if (match.displaySetInstanceUID === displaySetUID)
|
|
52725
|
+
if (match.displaySetInstanceUID === displaySetUID) {
|
|
52726
|
+
return;
|
|
52727
|
+
}
|
|
51993
52728
|
if (!match.matchingScores) {
|
|
51994
52729
|
throw new Error('No matchingScores found in ' + match);
|
|
51995
52730
|
}
|
|
51996
52731
|
for (const subMatch of match.matchingScores) {
|
|
51997
|
-
if (subMatch.displaySetInstanceUID === displaySetUID)
|
|
52732
|
+
if (subMatch.displaySetInstanceUID === displaySetUID) {
|
|
52733
|
+
return;
|
|
52734
|
+
}
|
|
51998
52735
|
}
|
|
51999
52736
|
throw new Error(`Reused viewport details ${id} with ds ${displaySetUID} not valid`);
|
|
52000
52737
|
}
|
|
@@ -52153,7 +52890,9 @@ class HangingProtocolService extends PubSubService {
|
|
|
52153
52890
|
const matchActiveOnly = this.protocol.numberOfPriorsReferenced === -1;
|
|
52154
52891
|
this.studies.forEach(study => {
|
|
52155
52892
|
// Skip non-active if active only
|
|
52156
|
-
if (matchActiveOnly && this.activeStudy !== study)
|
|
52893
|
+
if (matchActiveOnly && this.activeStudy !== study) {
|
|
52894
|
+
return;
|
|
52895
|
+
}
|
|
52157
52896
|
const studyDisplaySets = this.displaySets.filter(it => it.StudyInstanceUID === study.StudyInstanceUID);
|
|
52158
52897
|
const studyMatchDetails = this.protocolEngine.findMatch(study, studyMatchingRules, {
|
|
52159
52898
|
studies: this.studies,
|
|
@@ -52445,8 +53184,12 @@ const CustomizationService_EVENTS = {
|
|
|
52445
53184
|
GLOBAL_CUSTOMIZATION_MODIFIED: 'event::CustomizationService:globalModified'
|
|
52446
53185
|
};
|
|
52447
53186
|
const flattenNestedStrings = (strs, ret) => {
|
|
52448
|
-
if (!ret)
|
|
52449
|
-
|
|
53187
|
+
if (!ret) {
|
|
53188
|
+
ret = {};
|
|
53189
|
+
}
|
|
53190
|
+
if (!strs) {
|
|
53191
|
+
return ret;
|
|
53192
|
+
}
|
|
52450
53193
|
if (Array.isArray(strs)) {
|
|
52451
53194
|
for (const val of strs) {
|
|
52452
53195
|
flattenNestedStrings(val, ret);
|
|
@@ -52517,7 +53260,9 @@ class CustomizationService extends PubSubService {
|
|
|
52517
53260
|
this.extensionManager.registeredExtensionIds.forEach(extensionId => {
|
|
52518
53261
|
const key = `${extensionId}.customizationModule.default`;
|
|
52519
53262
|
const defaultCustomizations = this.findExtensionValue(key);
|
|
52520
|
-
if (!defaultCustomizations)
|
|
53263
|
+
if (!defaultCustomizations) {
|
|
53264
|
+
return;
|
|
53265
|
+
}
|
|
52521
53266
|
const {
|
|
52522
53267
|
value
|
|
52523
53268
|
} = defaultCustomizations;
|
|
@@ -52576,11 +53321,15 @@ class CustomizationService extends PubSubService {
|
|
|
52576
53321
|
* type into the new type, allowing default behaviour to be configured.
|
|
52577
53322
|
*/
|
|
52578
53323
|
transform(customization) {
|
|
52579
|
-
if (!customization)
|
|
53324
|
+
if (!customization) {
|
|
53325
|
+
return customization;
|
|
53326
|
+
}
|
|
52580
53327
|
const {
|
|
52581
53328
|
customizationType
|
|
52582
53329
|
} = customization;
|
|
52583
|
-
if (!customizationType)
|
|
53330
|
+
if (!customizationType) {
|
|
53331
|
+
return customization;
|
|
53332
|
+
}
|
|
52584
53333
|
const parent = this.getCustomization(customizationType);
|
|
52585
53334
|
const result = parent ? Object.assign(Object.create(parent), customization) : customization;
|
|
52586
53335
|
// Execute an nested type information
|
|
@@ -52634,7 +53383,9 @@ class CustomizationService extends PubSubService {
|
|
|
52634
53383
|
addReference(value) {
|
|
52635
53384
|
let isGlobal = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
|
52636
53385
|
let id = arguments.length > 2 ? arguments[2] : undefined;
|
|
52637
|
-
if (!value)
|
|
53386
|
+
if (!value) {
|
|
53387
|
+
return;
|
|
53388
|
+
}
|
|
52638
53389
|
if (typeof value === 'string') {
|
|
52639
53390
|
const extensionValue = this.findExtensionValue(value);
|
|
52640
53391
|
// The child of a reference is only a set of references when an array,
|
|
@@ -52655,7 +53406,9 @@ class CustomizationService extends PubSubService {
|
|
|
52655
53406
|
*/
|
|
52656
53407
|
addReferences(references) {
|
|
52657
53408
|
let isGlobal = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : true;
|
|
52658
|
-
if (!references)
|
|
53409
|
+
if (!references) {
|
|
53410
|
+
return;
|
|
53411
|
+
}
|
|
52659
53412
|
if (Array.isArray(references)) {
|
|
52660
53413
|
references.forEach(item => {
|
|
52661
53414
|
this.addReference(item, isGlobal);
|
|
@@ -53445,7 +54198,9 @@ class CommandsManager {
|
|
|
53445
54198
|
* the commandOptions specified in the base.
|
|
53446
54199
|
*/
|
|
53447
54200
|
run(toRun, options) {
|
|
53448
|
-
if (!toRun)
|
|
54201
|
+
if (!toRun) {
|
|
54202
|
+
return;
|
|
54203
|
+
}
|
|
53449
54204
|
const commands = Array.isArray(toRun) && toRun || toRun.commandName && [toRun] || Array.isArray(toRun.commands) && toRun.commands;
|
|
53450
54205
|
if (!commands) {
|
|
53451
54206
|
console.log("Command isn't runnable", toRun);
|
|
@@ -53909,14 +54664,18 @@ function fetchPaletteColorLookupTableData(item, tag, descriptorTag) {
|
|
|
53909
54664
|
PaletteColorLookupTableUID
|
|
53910
54665
|
} = item;
|
|
53911
54666
|
const paletteData = item[tag];
|
|
53912
|
-
if (paletteData === undefined && PaletteColorLookupTableUID === undefined)
|
|
54667
|
+
if (paletteData === undefined && PaletteColorLookupTableUID === undefined) {
|
|
54668
|
+
return;
|
|
54669
|
+
}
|
|
53913
54670
|
// performance optimization - read UID and cache by UID
|
|
53914
54671
|
return _getPaletteColor(item[tag], item[descriptorTag]);
|
|
53915
54672
|
}
|
|
53916
54673
|
function _getPaletteColor(paletteColorLookupTableData, lutDescriptor) {
|
|
53917
54674
|
const numLutEntries = lutDescriptor[0];
|
|
53918
54675
|
const bits = lutDescriptor[2];
|
|
53919
|
-
if (!paletteColorLookupTableData)
|
|
54676
|
+
if (!paletteColorLookupTableData) {
|
|
54677
|
+
return undefined;
|
|
54678
|
+
}
|
|
53920
54679
|
const arrayBufferToPaletteColorLUT = arraybuffer => {
|
|
53921
54680
|
const lut = [];
|
|
53922
54681
|
if (bits === 16) {
|
|
@@ -54378,7 +55137,9 @@ class MetadataProvider {
|
|
|
54378
55137
|
return;
|
|
54379
55138
|
}
|
|
54380
55139
|
getUIDsFromImageID(imageId) {
|
|
54381
|
-
if (!imageId)
|
|
55140
|
+
if (!imageId) {
|
|
55141
|
+
throw new Error('MetadataProvider::Empty imageId');
|
|
55142
|
+
}
|
|
54382
55143
|
// TODO: adding csiv here is not really correct. Probably need to use
|
|
54383
55144
|
// metadataProvider.addImageIdToUIDs(imageId, {
|
|
54384
55145
|
// StudyInstanceUID,
|
|
@@ -54491,10 +55252,18 @@ function getAttribute(element, defaultValue) {
|
|
|
54491
55252
|
function convertToInt(input) {
|
|
54492
55253
|
function padFour(input) {
|
|
54493
55254
|
const l = input.length;
|
|
54494
|
-
if (l
|
|
54495
|
-
|
|
54496
|
-
|
|
54497
|
-
if (l
|
|
55255
|
+
if (l === 0) {
|
|
55256
|
+
return '0000';
|
|
55257
|
+
}
|
|
55258
|
+
if (l === 1) {
|
|
55259
|
+
return '000' + input;
|
|
55260
|
+
}
|
|
55261
|
+
if (l === 2) {
|
|
55262
|
+
return '00' + input;
|
|
55263
|
+
}
|
|
55264
|
+
if (l === 3) {
|
|
55265
|
+
return '0' + input;
|
|
55266
|
+
}
|
|
54498
55267
|
return input;
|
|
54499
55268
|
}
|
|
54500
55269
|
let output = '';
|
|
@@ -54671,7 +55440,9 @@ const errorHandler = {
|
|
|
54671
55440
|
function getNestedObject(shallowObject) {
|
|
54672
55441
|
const nestedObject = {};
|
|
54673
55442
|
for (let key in shallowObject) {
|
|
54674
|
-
if (!shallowObject.hasOwnProperty(key))
|
|
55443
|
+
if (!shallowObject.hasOwnProperty(key)) {
|
|
55444
|
+
continue;
|
|
55445
|
+
}
|
|
54675
55446
|
const value = shallowObject[key];
|
|
54676
55447
|
const propertyArray = key.split('.');
|
|
54677
55448
|
let currentObject = nestedObject;
|
|
@@ -54695,7 +55466,9 @@ function getShallowObject(nestedObject) {
|
|
|
54695
55466
|
const shallowObject = {};
|
|
54696
55467
|
const putValues = (baseKey, nestedObject, resultObject) => {
|
|
54697
55468
|
for (let key in nestedObject) {
|
|
54698
|
-
if (!nestedObject.hasOwnProperty(key))
|
|
55469
|
+
if (!nestedObject.hasOwnProperty(key)) {
|
|
55470
|
+
continue;
|
|
55471
|
+
}
|
|
54699
55472
|
let currentKey = baseKey ? `${baseKey}.${key}` : key;
|
|
54700
55473
|
const currentValue = nestedObject[key];
|
|
54701
55474
|
if (typeof currentValue === 'object') {
|
|
@@ -55175,6 +55948,7 @@ const IWebApiDataSource = {
|
|
|
55175
55948
|
|
|
55176
55949
|
|
|
55177
55950
|
|
|
55951
|
+
|
|
55178
55952
|
const src_hotkeys = {
|
|
55179
55953
|
...src_utils.hotkeys,
|
|
55180
55954
|
defaults: {
|
|
@@ -55315,7 +56089,9 @@ const compareSeriesDateTime = (a, b) => {
|
|
|
55315
56089
|
const defaultSeriesSort = (a, b) => {
|
|
55316
56090
|
const seriesNumberA = a.SeriesNumber ?? a.seriesNumber;
|
|
55317
56091
|
const seriesNumberB = b.SeriesNumber ?? b.seriesNumber;
|
|
55318
|
-
if (seriesNumberA === seriesNumberB)
|
|
56092
|
+
if (seriesNumberA === seriesNumberB) {
|
|
56093
|
+
return compareSeriesDateTime(a, b);
|
|
56094
|
+
}
|
|
55319
56095
|
return seriesNumberA - seriesNumberB;
|
|
55320
56096
|
};
|
|
55321
56097
|
|
|
@@ -55358,7 +56134,11 @@ const sortingCriteria = {
|
|
|
55358
56134
|
const sortStudySeries = function (series) {
|
|
55359
56135
|
let seriesSortingCriteria = arguments.length > 1 && arguments[1] !== undefined ? arguments[1] : seriesSortCriteria.default;
|
|
55360
56136
|
let sortFunction = arguments.length > 2 && arguments[2] !== undefined ? arguments[2] : null;
|
|
55361
|
-
if (typeof sortFunction === 'function')
|
|
56137
|
+
if (typeof sortFunction === 'function') {
|
|
56138
|
+
return sortFunction(series);
|
|
56139
|
+
} else {
|
|
56140
|
+
return series.sort(seriesSortingCriteria);
|
|
56141
|
+
}
|
|
55362
56142
|
};
|
|
55363
56143
|
|
|
55364
56144
|
/**
|
|
@@ -152791,7 +153571,7 @@ var selectOrdinal = function selectOrdinal() {
|
|
|
152791
153571
|
/******/ // This function allow to reference async chunks
|
|
152792
153572
|
/******/ __webpack_require__.u = (chunkId) => {
|
|
152793
153573
|
/******/ // return url for filenames based on template
|
|
152794
|
-
/******/ return "" + (chunkId === 18 ? "dicom-microscopy-viewer" : chunkId) + ".bundle." + {"12":"
|
|
153574
|
+
/******/ return "" + (chunkId === 18 ? "dicom-microscopy-viewer" : chunkId) + ".bundle." + {"12":"76faa700f7041f616633","18":"44f7fedc03a58d5911d1","23":"e008ad788170f2ed5569","30":"dec90afeb4103389b6a6","125":"1ae4c6313c31cd0502cc","128":"1d35b17c905a58de8551","150":"bf8bb9e4589aa2c5ae67","181":"234fef330d4fe6baca8b","202":"ac1e5e25d4daf54581b1","220":"f7e1c96c94245e70f2be","236":"e50df45b4c224feb736f","250":"3bcee6d765a209281ddd","281":"a36db013f04d30edeadd","348":"05d78071808655babffe","359":"1014c161d9efbdb5de1b","378":"721605dbf67db521bacb","410":"b4ef419280ca863117d1","417":"720dc8f3a6e99f378aa9","451":"9941d9134fcf747d452a","471":"c9e618aeda78362776aa","506":"ec535e59761e003bcd10","579":"8fc434a0c13d3f662d42","604":"a51f83e64004bca5f497","663":"292fa73fd3daa7dbdaff","677":"ec5f2b4707db33bd4d8e","678":"57db43d05d8bff8d65a5","686":"70565410179f1e7d22e6","754":"8a16fc8ad21fe00c2e15","774":"8ba82ee206266eb2da5e","775":"2285e7e0e67878948c0d","782":"8ed88caff947a2936dbe","789":"cda7cca15a207b233d59","814":"eae70c4682541d01a5cc","822":"0dabe6c2e028da05ac10","886":"68ef58774a6837f57631","925":"a2f1103d968c53a2b8fb"}[chunkId] + ".js";
|
|
152795
153575
|
/******/ };
|
|
152796
153576
|
/******/ })();
|
|
152797
153577
|
/******/
|
|
@@ -153085,10 +153865,10 @@ var selectOrdinal = function selectOrdinal() {
|
|
|
153085
153865
|
/******/ 822
|
|
153086
153866
|
/******/ ],
|
|
153087
153867
|
/******/ "150": [
|
|
153088
|
-
/******/
|
|
153868
|
+
/******/ 451
|
|
153089
153869
|
/******/ ],
|
|
153090
153870
|
/******/ "506": [
|
|
153091
|
-
/******/
|
|
153871
|
+
/******/ 471
|
|
153092
153872
|
/******/ ],
|
|
153093
153873
|
/******/ "663": [
|
|
153094
153874
|
/******/ 886
|