fix: Handle optional ContentSequence for NUM content items (#5703)

* fix: SR validation

* Adding links to cs3d

* Update to dcmjs 0.48.0

* Update package files to include updated adapter

* Update package files

---------

Co-authored-by: Bill Wallace <wayfarer3130@gmail.com>
Co-authored-by: arul-trenser <arul.mozhi@trenser.com>
This commit is contained in:
Devu-trenser 2026-01-27 20:43:55 +05:30 committed by GitHub
parent b69abf25ee
commit 6dedf5573e
No known key found for this signature in database
GPG Key ID: B5690EEEBB952194

View File

@ -637,15 +637,20 @@ function _processNonGeometricallyDefinedMeasurement(mergedContentSequence) {
NUMContentItems.forEach(item => {
const { ConceptNameCodeSequence, ContentSequence, MeasuredValueSequence } = item;
const { ValueType } = ContentSequence;
if (ValueType !== 'SCOORD' && ValueType !== 'SCOORD3D') {
console.warn(`Graphic ${ValueType} not currently supported, skipping annotation.`);
return;
}
// Handle spatial reference ONLY if ContentSequence exists
if (ContentSequence) {
const { ValueType } = ContentSequence;
const coords = _getCoordsFromSCOORDOrSCOORD3D(ContentSequence);
if (coords) {
measurement.coords.push(coords);
if (ValueType !== 'SCOORD' && ValueType !== 'SCOORD3D') {
console.warn(`Graphic ${ValueType} not currently supported, skipping annotation.`);
return;
}
const coords = _getCoordsFromSCOORDOrSCOORD3D(ContentSequence);
if (coords) {
measurement.coords.push(coords);
}
}
if (MeasuredValueSequence) {