@ohif/app 3.8.0-beta.4 → 3.8.0-beta.40

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 (54) hide show
  1. package/dist/{12.bundle.3749796d3d0655f356e8.js → 12.bundle.9e88017f3ddf2beff33e.js} +9 -11
  2. package/dist/{125.bundle.253395f320b72180da63.js → 125.bundle.df666cb677e5a8982157.js} +4 -5
  3. package/dist/{663.bundle.3485d3509c179a19eead.js → 170.bundle.bd6352623584d0fa3a7a.js} +97 -89
  4. package/dist/{181.bundle.2ddc6f90740895a3949c.js → 181.bundle.d2fe517852935b82368b.js} +60 -72
  5. package/dist/181.css +1 -1
  6. package/dist/{370.bundle.8782c787fc0e3db12d96.js → 185.bundle.f22956063aa61238f9dd.js} +338 -209
  7. package/dist/{19.bundle.75decca183cfe0936af8.js → 19.bundle.4ba37e03536975e9c77a.js} +127 -136
  8. package/dist/{99.bundle.f444b466668c45a5768d.js → 199.bundle.fb364c1f691a86502269.js} +215 -162
  9. package/dist/{202.bundle.d3490836f71e001dd30f.js → 202.bundle.0ca2f2479d2578f539b0.js} +349 -332
  10. package/dist/20fc4c659b85ccd2a9c0.wasm +0 -0
  11. package/dist/{220.bundle.f7e1c96c94245e70f2be.js → 223.bundle.d4ac6ef2cfe47a9c4afc.js} +4422 -3671
  12. package/dist/{23.bundle.e008ad788170f2ed5569.js → 23.bundle.9d989522a6e4fdcb9c72.js} +1 -1
  13. package/dist/{250.bundle.8084960e3318cda37317.js → 250.bundle.ba94ff371388e395cd05.js} +21 -26
  14. package/dist/{281.bundle.adddd60d4c338f5cc6d1.js → 281.bundle.bf3628b634402bb00b8f.js} +23 -25
  15. package/dist/{359.bundle.968f29b5916b0fac14e1.js → 359.bundle.d94c8ff6581b97eb3362.js} +27 -30
  16. package/dist/{410.bundle.7ebf2894e1ede5a264fb.js → 410.bundle.c6bbb779d28413c9d827.js} +24 -28
  17. package/dist/{417.bundle.af0a207c29b109f84159.js → 417.bundle.5c66801d23d0e98c00e6.js} +2 -2
  18. package/dist/{451.bundle.9fd36f52ff69594f0669.js → 451.bundle.68a551a7d1746cf904cb.js} +28 -34
  19. package/dist/{82.bundle.ebdcc3ccc426053f83f1.js → 456.bundle.1ee8b3eddd2e996555a8.js} +1216 -663
  20. package/dist/{221.bundle.5188188cec50980afae4.js → 466.bundle.0fd07ba9cd6d097cc9a4.js} +128 -146
  21. package/dist/{471.bundle.b3d77b83b1593c09a504.js → 471.bundle.5809b10f75c8fc2f7167.js} +29 -35
  22. package/dist/{788.bundle.4b95e6b64d45fec4e1ac.js → 483.bundle.3b7bdf36e3fb4f879379.js} +131 -180
  23. package/dist/{757.bundle.ec8301d8e70d2b990f65.js → 485.bundle.5b6c33cc43d8f3470642.js} +9 -98
  24. package/dist/{506.bundle.fdead68decb348a84807.js → 506.bundle.2313610e171571ede93d.js} +13 -18
  25. package/dist/{530.bundle.a03b6f942ace3e1baa1e.js → 530.bundle.f904325ef4195d69ac0e.js} +10 -3
  26. package/dist/{613.bundle.f040e35c03fa3fe65d16.js → 613.bundle.b927b98afbf4e6a864f2.js} +29 -27
  27. package/dist/{774.bundle.4b2dc46a35012b898e1a.js → 661.bundle.949c984fe2f9f753b65c.js} +1851 -8944
  28. package/dist/{686.bundle.dccef1f36e4bc79bcc48.js → 686.bundle.62c827fe4f0d054c164e.js} +4 -5
  29. package/dist/{687.bundle.a46770cd4c472e87d57c.js → 687.bundle.bbf069720fbdcec4fa6b.js} +19 -35
  30. package/dist/{342.bundle.9624373301727ec2a70d.js → 738.bundle.0e213a835f03bb103c07.js} +776 -509
  31. package/dist/{814.bundle.93bb98785fdf1bffeb6f.js → 814.bundle.78a8878abbf22f92443c.js} +9 -11
  32. package/dist/{822.bundle.891f2e57b1b7bc2f4cb4.js → 822.bundle.f5ae3f366ce742fb060a.js} +14 -16
  33. package/dist/{886.bundle.4b3a7f2079d085fdbcb3.js → 886.bundle.4496fc7fb83b8c897d20.js} +20 -24
  34. package/dist/95.bundle.830304446bffa705883c.js +9002 -0
  35. package/dist/{236.bundle.c29fd0ec6b1f041b5e3e.js → 965.bundle.5b28f3053b33d21001f9.js} +104 -126
  36. package/dist/{app.bundle.6267cddde349bad128c2.js → app.bundle.3eb6ce1b33e0a2ec73cb.js} +183940 -60780
  37. package/dist/app.bundle.css +11 -11
  38. package/dist/cornerstoneDICOMImageLoader.min.js +1 -1
  39. package/dist/cornerstoneDICOMImageLoader.min.js.map +1 -1
  40. package/dist/{dicom-microscopy-viewer.bundle.2c146384eb9466d02ff8.js → dicom-microscopy-viewer.bundle.a7d5060eead13771e784.js} +1 -1
  41. package/dist/index.html +1 -1
  42. package/dist/{index.worker.e62ecca63f1a2e124230.worker.js → index.worker.64c896c4316fcd506666.worker.js} +2 -2
  43. package/dist/index.worker.64c896c4316fcd506666.worker.js.map +1 -0
  44. package/dist/serve.json +12 -0
  45. package/dist/sw.js +1 -1
  46. package/package.json +21 -21
  47. package/dist/604.bundle.a51f83e64004bca5f497.js +0 -1848
  48. package/dist/743.bundle.489f7df3a089d4d374e1.js +0 -78007
  49. package/dist/75788f12450d4c5ed494.wasm +0 -0
  50. package/dist/775.bundle.2285e7e0e67878948c0d.js +0 -1009
  51. package/dist/957.bundle.9ea4506963ef8b2d84ba.js +0 -30077
  52. package/dist/index.worker.e62ecca63f1a2e124230.worker.js.map +0 -1
  53. /package/dist/{82.css → 456.css} +0 -0
  54. /package/dist/{221.css → 466.css} +0 -0
@@ -1,4 +1,4 @@
1
- (self["webpackChunk"] = self["webpackChunk"] || []).push([[202],{
1
+ (globalThis["webpackChunk"] = globalThis["webpackChunk"] || []).push([[202],{
2
2
 
3
3
  /***/ 91202:
4
4
  /***/ ((__unused_webpack_module, __webpack_exports__, __webpack_require__) => {
@@ -24,354 +24,354 @@
24
24
 
25
25
 
26
26
 
27
- function _iterableToArrayLimit(arr, i) {
28
- var _i = null == arr ? null : "undefined" != typeof Symbol && arr[Symbol.iterator] || arr["@@iterator"];
29
- if (null != _i) {
30
- var _s,
31
- _e,
32
- _x,
33
- _r,
34
- _arr = [],
35
- _n = !0,
36
- _d = !1;
27
+ function _iterableToArrayLimit(r, l) {
28
+ var t = null == r ? null : "undefined" != typeof Symbol && r[Symbol.iterator] || r["@@iterator"];
29
+ if (null != t) {
30
+ var e,
31
+ n,
32
+ i,
33
+ u,
34
+ a = [],
35
+ f = !0,
36
+ o = !1;
37
37
  try {
38
- if (_x = (_i = _i.call(arr)).next, 0 === i) {
39
- if (Object(_i) !== _i) return;
40
- _n = !1;
41
- } else for (; !(_n = (_s = _x.call(_i)).done) && (_arr.push(_s.value), _arr.length !== i); _n = !0);
42
- } catch (err) {
43
- _d = !0, _e = err;
38
+ if (i = (t = t.call(r)).next, 0 === l) {
39
+ if (Object(t) !== t) return;
40
+ f = !1;
41
+ } else for (; !(f = (e = i.call(t)).done) && (a.push(e.value), a.length !== l); f = !0);
42
+ } catch (r) {
43
+ o = !0, n = r;
44
44
  } finally {
45
45
  try {
46
- if (!_n && null != _i.return && (_r = _i.return(), Object(_r) !== _r)) return;
46
+ if (!f && null != t.return && (u = t.return(), Object(u) !== u)) return;
47
47
  } finally {
48
- if (_d) throw _e;
48
+ if (o) throw n;
49
49
  }
50
50
  }
51
- return _arr;
51
+ return a;
52
52
  }
53
53
  }
54
- function ownKeys(object, enumerableOnly) {
55
- var keys = Object.keys(object);
54
+ function ownKeys(e, r) {
55
+ var t = Object.keys(e);
56
56
  if (Object.getOwnPropertySymbols) {
57
- var symbols = Object.getOwnPropertySymbols(object);
58
- enumerableOnly && (symbols = symbols.filter(function (sym) {
59
- return Object.getOwnPropertyDescriptor(object, sym).enumerable;
60
- })), keys.push.apply(keys, symbols);
57
+ var o = Object.getOwnPropertySymbols(e);
58
+ r && (o = o.filter(function (r) {
59
+ return Object.getOwnPropertyDescriptor(e, r).enumerable;
60
+ })), t.push.apply(t, o);
61
61
  }
62
- return keys;
62
+ return t;
63
63
  }
64
- function _objectSpread2(target) {
65
- for (var i = 1; i < arguments.length; i++) {
66
- var source = null != arguments[i] ? arguments[i] : {};
67
- i % 2 ? ownKeys(Object(source), !0).forEach(function (key) {
68
- _defineProperty(target, key, source[key]);
69
- }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(target, Object.getOwnPropertyDescriptors(source)) : ownKeys(Object(source)).forEach(function (key) {
70
- Object.defineProperty(target, key, Object.getOwnPropertyDescriptor(source, key));
64
+ function _objectSpread2(e) {
65
+ for (var r = 1; r < arguments.length; r++) {
66
+ var t = null != arguments[r] ? arguments[r] : {};
67
+ r % 2 ? ownKeys(Object(t), !0).forEach(function (r) {
68
+ _defineProperty(e, r, t[r]);
69
+ }) : Object.getOwnPropertyDescriptors ? Object.defineProperties(e, Object.getOwnPropertyDescriptors(t)) : ownKeys(Object(t)).forEach(function (r) {
70
+ Object.defineProperty(e, r, Object.getOwnPropertyDescriptor(t, r));
71
71
  });
72
72
  }
73
- return target;
73
+ return e;
74
74
  }
75
75
  function _regeneratorRuntime() {
76
76
  _regeneratorRuntime = function () {
77
- return exports;
77
+ return e;
78
78
  };
79
- var exports = {},
80
- Op = Object.prototype,
81
- hasOwn = Op.hasOwnProperty,
82
- defineProperty = Object.defineProperty || function (obj, key, desc) {
83
- obj[key] = desc.value;
79
+ var t,
80
+ e = {},
81
+ r = Object.prototype,
82
+ n = r.hasOwnProperty,
83
+ o = Object.defineProperty || function (t, e, r) {
84
+ t[e] = r.value;
84
85
  },
85
- $Symbol = "function" == typeof Symbol ? Symbol : {},
86
- iteratorSymbol = $Symbol.iterator || "@@iterator",
87
- asyncIteratorSymbol = $Symbol.asyncIterator || "@@asyncIterator",
88
- toStringTagSymbol = $Symbol.toStringTag || "@@toStringTag";
89
- function define(obj, key, value) {
90
- return Object.defineProperty(obj, key, {
91
- value: value,
86
+ i = "function" == typeof Symbol ? Symbol : {},
87
+ a = i.iterator || "@@iterator",
88
+ c = i.asyncIterator || "@@asyncIterator",
89
+ u = i.toStringTag || "@@toStringTag";
90
+ function define(t, e, r) {
91
+ return Object.defineProperty(t, e, {
92
+ value: r,
92
93
  enumerable: !0,
93
94
  configurable: !0,
94
95
  writable: !0
95
- }), obj[key];
96
+ }), t[e];
96
97
  }
97
98
  try {
98
99
  define({}, "");
99
- } catch (err) {
100
- define = function (obj, key, value) {
101
- return obj[key] = value;
100
+ } catch (t) {
101
+ define = function (t, e, r) {
102
+ return t[e] = r;
102
103
  };
103
104
  }
104
- function wrap(innerFn, outerFn, self, tryLocsList) {
105
- var protoGenerator = outerFn && outerFn.prototype instanceof Generator ? outerFn : Generator,
106
- generator = Object.create(protoGenerator.prototype),
107
- context = new Context(tryLocsList || []);
108
- return defineProperty(generator, "_invoke", {
109
- value: makeInvokeMethod(innerFn, self, context)
110
- }), generator;
105
+ function wrap(t, e, r, n) {
106
+ var i = e && e.prototype instanceof Generator ? e : Generator,
107
+ a = Object.create(i.prototype),
108
+ c = new Context(n || []);
109
+ return o(a, "_invoke", {
110
+ value: makeInvokeMethod(t, r, c)
111
+ }), a;
111
112
  }
112
- function tryCatch(fn, obj, arg) {
113
+ function tryCatch(t, e, r) {
113
114
  try {
114
115
  return {
115
116
  type: "normal",
116
- arg: fn.call(obj, arg)
117
+ arg: t.call(e, r)
117
118
  };
118
- } catch (err) {
119
+ } catch (t) {
119
120
  return {
120
121
  type: "throw",
121
- arg: err
122
+ arg: t
122
123
  };
123
124
  }
124
125
  }
125
- exports.wrap = wrap;
126
- var ContinueSentinel = {};
126
+ e.wrap = wrap;
127
+ var h = "suspendedStart",
128
+ l = "suspendedYield",
129
+ f = "executing",
130
+ s = "completed",
131
+ y = {};
127
132
  function Generator() {}
128
133
  function GeneratorFunction() {}
129
134
  function GeneratorFunctionPrototype() {}
130
- var IteratorPrototype = {};
131
- define(IteratorPrototype, iteratorSymbol, function () {
135
+ var p = {};
136
+ define(p, a, function () {
132
137
  return this;
133
138
  });
134
- var getProto = Object.getPrototypeOf,
135
- NativeIteratorPrototype = getProto && getProto(getProto(values([])));
136
- NativeIteratorPrototype && NativeIteratorPrototype !== Op && hasOwn.call(NativeIteratorPrototype, iteratorSymbol) && (IteratorPrototype = NativeIteratorPrototype);
137
- var Gp = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(IteratorPrototype);
138
- function defineIteratorMethods(prototype) {
139
- ["next", "throw", "return"].forEach(function (method) {
140
- define(prototype, method, function (arg) {
141
- return this._invoke(method, arg);
139
+ var d = Object.getPrototypeOf,
140
+ v = d && d(d(values([])));
141
+ v && v !== r && n.call(v, a) && (p = v);
142
+ var g = GeneratorFunctionPrototype.prototype = Generator.prototype = Object.create(p);
143
+ function defineIteratorMethods(t) {
144
+ ["next", "throw", "return"].forEach(function (e) {
145
+ define(t, e, function (t) {
146
+ return this._invoke(e, t);
142
147
  });
143
148
  });
144
149
  }
145
- function AsyncIterator(generator, PromiseImpl) {
146
- function invoke(method, arg, resolve, reject) {
147
- var record = tryCatch(generator[method], generator, arg);
148
- if ("throw" !== record.type) {
149
- var result = record.arg,
150
- value = result.value;
151
- return value && "object" == typeof value && hasOwn.call(value, "__await") ? PromiseImpl.resolve(value.__await).then(function (value) {
152
- invoke("next", value, resolve, reject);
153
- }, function (err) {
154
- invoke("throw", err, resolve, reject);
155
- }) : PromiseImpl.resolve(value).then(function (unwrapped) {
156
- result.value = unwrapped, resolve(result);
157
- }, function (error) {
158
- return invoke("throw", error, resolve, reject);
150
+ function AsyncIterator(t, e) {
151
+ function invoke(r, o, i, a) {
152
+ var c = tryCatch(t[r], t, o);
153
+ if ("throw" !== c.type) {
154
+ var u = c.arg,
155
+ h = u.value;
156
+ return h && "object" == typeof h && n.call(h, "__await") ? e.resolve(h.__await).then(function (t) {
157
+ invoke("next", t, i, a);
158
+ }, function (t) {
159
+ invoke("throw", t, i, a);
160
+ }) : e.resolve(h).then(function (t) {
161
+ u.value = t, i(u);
162
+ }, function (t) {
163
+ return invoke("throw", t, i, a);
159
164
  });
160
165
  }
161
- reject(record.arg);
166
+ a(c.arg);
162
167
  }
163
- var previousPromise;
164
- defineProperty(this, "_invoke", {
165
- value: function (method, arg) {
168
+ var r;
169
+ o(this, "_invoke", {
170
+ value: function (t, n) {
166
171
  function callInvokeWithMethodAndArg() {
167
- return new PromiseImpl(function (resolve, reject) {
168
- invoke(method, arg, resolve, reject);
172
+ return new e(function (e, r) {
173
+ invoke(t, n, e, r);
169
174
  });
170
175
  }
171
- return previousPromise = previousPromise ? previousPromise.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
176
+ return r = r ? r.then(callInvokeWithMethodAndArg, callInvokeWithMethodAndArg) : callInvokeWithMethodAndArg();
172
177
  }
173
178
  });
174
179
  }
175
- function makeInvokeMethod(innerFn, self, context) {
176
- var state = "suspendedStart";
177
- return function (method, arg) {
178
- if ("executing" === state) throw new Error("Generator is already running");
179
- if ("completed" === state) {
180
- if ("throw" === method) throw arg;
181
- return doneResult();
180
+ function makeInvokeMethod(e, r, n) {
181
+ var o = h;
182
+ return function (i, a) {
183
+ if (o === f) throw new Error("Generator is already running");
184
+ if (o === s) {
185
+ if ("throw" === i) throw a;
186
+ return {
187
+ value: t,
188
+ done: !0
189
+ };
182
190
  }
183
- for (context.method = method, context.arg = arg;;) {
184
- var delegate = context.delegate;
185
- if (delegate) {
186
- var delegateResult = maybeInvokeDelegate(delegate, context);
187
- if (delegateResult) {
188
- if (delegateResult === ContinueSentinel) continue;
189
- return delegateResult;
191
+ for (n.method = i, n.arg = a;;) {
192
+ var c = n.delegate;
193
+ if (c) {
194
+ var u = maybeInvokeDelegate(c, n);
195
+ if (u) {
196
+ if (u === y) continue;
197
+ return u;
190
198
  }
191
199
  }
192
- if ("next" === context.method) context.sent = context._sent = context.arg;else if ("throw" === context.method) {
193
- if ("suspendedStart" === state) throw state = "completed", context.arg;
194
- context.dispatchException(context.arg);
195
- } else "return" === context.method && context.abrupt("return", context.arg);
196
- state = "executing";
197
- var record = tryCatch(innerFn, self, context);
198
- if ("normal" === record.type) {
199
- if (state = context.done ? "completed" : "suspendedYield", record.arg === ContinueSentinel) continue;
200
+ if ("next" === n.method) n.sent = n._sent = n.arg;else if ("throw" === n.method) {
201
+ if (o === h) throw o = s, n.arg;
202
+ n.dispatchException(n.arg);
203
+ } else "return" === n.method && n.abrupt("return", n.arg);
204
+ o = f;
205
+ var p = tryCatch(e, r, n);
206
+ if ("normal" === p.type) {
207
+ if (o = n.done ? s : l, p.arg === y) continue;
200
208
  return {
201
- value: record.arg,
202
- done: context.done
209
+ value: p.arg,
210
+ done: n.done
203
211
  };
204
212
  }
205
- "throw" === record.type && (state = "completed", context.method = "throw", context.arg = record.arg);
213
+ "throw" === p.type && (o = s, n.method = "throw", n.arg = p.arg);
206
214
  }
207
215
  };
208
216
  }
209
- function maybeInvokeDelegate(delegate, context) {
210
- var methodName = context.method,
211
- method = delegate.iterator[methodName];
212
- if (undefined === method) return context.delegate = null, "throw" === methodName && delegate.iterator.return && (context.method = "return", context.arg = undefined, maybeInvokeDelegate(delegate, context), "throw" === context.method) || "return" !== methodName && (context.method = "throw", context.arg = new TypeError("The iterator does not provide a '" + methodName + "' method")), ContinueSentinel;
213
- var record = tryCatch(method, delegate.iterator, context.arg);
214
- if ("throw" === record.type) return context.method = "throw", context.arg = record.arg, context.delegate = null, ContinueSentinel;
215
- var info = record.arg;
216
- return info ? info.done ? (context[delegate.resultName] = info.value, context.next = delegate.nextLoc, "return" !== context.method && (context.method = "next", context.arg = undefined), context.delegate = null, ContinueSentinel) : info : (context.method = "throw", context.arg = new TypeError("iterator result is not an object"), context.delegate = null, ContinueSentinel);
217
- }
218
- function pushTryEntry(locs) {
219
- var entry = {
220
- tryLoc: locs[0]
217
+ function maybeInvokeDelegate(e, r) {
218
+ var n = r.method,
219
+ o = e.iterator[n];
220
+ if (o === t) return r.delegate = null, "throw" === n && e.iterator.return && (r.method = "return", r.arg = t, maybeInvokeDelegate(e, r), "throw" === r.method) || "return" !== n && (r.method = "throw", r.arg = new TypeError("The iterator does not provide a '" + n + "' method")), y;
221
+ var i = tryCatch(o, e.iterator, r.arg);
222
+ if ("throw" === i.type) return r.method = "throw", r.arg = i.arg, r.delegate = null, y;
223
+ var a = i.arg;
224
+ return a ? a.done ? (r[e.resultName] = a.value, r.next = e.nextLoc, "return" !== r.method && (r.method = "next", r.arg = t), r.delegate = null, y) : a : (r.method = "throw", r.arg = new TypeError("iterator result is not an object"), r.delegate = null, y);
225
+ }
226
+ function pushTryEntry(t) {
227
+ var e = {
228
+ tryLoc: t[0]
221
229
  };
222
- 1 in locs && (entry.catchLoc = locs[1]), 2 in locs && (entry.finallyLoc = locs[2], entry.afterLoc = locs[3]), this.tryEntries.push(entry);
230
+ 1 in t && (e.catchLoc = t[1]), 2 in t && (e.finallyLoc = t[2], e.afterLoc = t[3]), this.tryEntries.push(e);
223
231
  }
224
- function resetTryEntry(entry) {
225
- var record = entry.completion || {};
226
- record.type = "normal", delete record.arg, entry.completion = record;
232
+ function resetTryEntry(t) {
233
+ var e = t.completion || {};
234
+ e.type = "normal", delete e.arg, t.completion = e;
227
235
  }
228
- function Context(tryLocsList) {
236
+ function Context(t) {
229
237
  this.tryEntries = [{
230
238
  tryLoc: "root"
231
- }], tryLocsList.forEach(pushTryEntry, this), this.reset(!0);
232
- }
233
- function values(iterable) {
234
- if (iterable) {
235
- var iteratorMethod = iterable[iteratorSymbol];
236
- if (iteratorMethod) return iteratorMethod.call(iterable);
237
- if ("function" == typeof iterable.next) return iterable;
238
- if (!isNaN(iterable.length)) {
239
- var i = -1,
240
- next = function next() {
241
- for (; ++i < iterable.length;) if (hasOwn.call(iterable, i)) return next.value = iterable[i], next.done = !1, next;
242
- return next.value = undefined, next.done = !0, next;
239
+ }], t.forEach(pushTryEntry, this), this.reset(!0);
240
+ }
241
+ function values(e) {
242
+ if (e || "" === e) {
243
+ var r = e[a];
244
+ if (r) return r.call(e);
245
+ if ("function" == typeof e.next) return e;
246
+ if (!isNaN(e.length)) {
247
+ var o = -1,
248
+ i = function next() {
249
+ for (; ++o < e.length;) if (n.call(e, o)) return next.value = e[o], next.done = !1, next;
250
+ return next.value = t, next.done = !0, next;
243
251
  };
244
- return next.next = next;
252
+ return i.next = i;
245
253
  }
246
254
  }
247
- return {
248
- next: doneResult
249
- };
255
+ throw new TypeError(typeof e + " is not iterable");
250
256
  }
251
- function doneResult() {
252
- return {
253
- value: undefined,
254
- done: !0
255
- };
256
- }
257
- return GeneratorFunction.prototype = GeneratorFunctionPrototype, defineProperty(Gp, "constructor", {
257
+ return GeneratorFunction.prototype = GeneratorFunctionPrototype, o(g, "constructor", {
258
258
  value: GeneratorFunctionPrototype,
259
259
  configurable: !0
260
- }), defineProperty(GeneratorFunctionPrototype, "constructor", {
260
+ }), o(GeneratorFunctionPrototype, "constructor", {
261
261
  value: GeneratorFunction,
262
262
  configurable: !0
263
- }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, toStringTagSymbol, "GeneratorFunction"), exports.isGeneratorFunction = function (genFun) {
264
- var ctor = "function" == typeof genFun && genFun.constructor;
265
- return !!ctor && (ctor === GeneratorFunction || "GeneratorFunction" === (ctor.displayName || ctor.name));
266
- }, exports.mark = function (genFun) {
267
- return Object.setPrototypeOf ? Object.setPrototypeOf(genFun, GeneratorFunctionPrototype) : (genFun.__proto__ = GeneratorFunctionPrototype, define(genFun, toStringTagSymbol, "GeneratorFunction")), genFun.prototype = Object.create(Gp), genFun;
268
- }, exports.awrap = function (arg) {
263
+ }), GeneratorFunction.displayName = define(GeneratorFunctionPrototype, u, "GeneratorFunction"), e.isGeneratorFunction = function (t) {
264
+ var e = "function" == typeof t && t.constructor;
265
+ return !!e && (e === GeneratorFunction || "GeneratorFunction" === (e.displayName || e.name));
266
+ }, e.mark = function (t) {
267
+ return Object.setPrototypeOf ? Object.setPrototypeOf(t, GeneratorFunctionPrototype) : (t.__proto__ = GeneratorFunctionPrototype, define(t, u, "GeneratorFunction")), t.prototype = Object.create(g), t;
268
+ }, e.awrap = function (t) {
269
269
  return {
270
- __await: arg
270
+ __await: t
271
271
  };
272
- }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, asyncIteratorSymbol, function () {
272
+ }, defineIteratorMethods(AsyncIterator.prototype), define(AsyncIterator.prototype, c, function () {
273
273
  return this;
274
- }), exports.AsyncIterator = AsyncIterator, exports.async = function (innerFn, outerFn, self, tryLocsList, PromiseImpl) {
275
- void 0 === PromiseImpl && (PromiseImpl = Promise);
276
- var iter = new AsyncIterator(wrap(innerFn, outerFn, self, tryLocsList), PromiseImpl);
277
- return exports.isGeneratorFunction(outerFn) ? iter : iter.next().then(function (result) {
278
- return result.done ? result.value : iter.next();
274
+ }), e.AsyncIterator = AsyncIterator, e.async = function (t, r, n, o, i) {
275
+ void 0 === i && (i = Promise);
276
+ var a = new AsyncIterator(wrap(t, r, n, o), i);
277
+ return e.isGeneratorFunction(r) ? a : a.next().then(function (t) {
278
+ return t.done ? t.value : a.next();
279
279
  });
280
- }, defineIteratorMethods(Gp), define(Gp, toStringTagSymbol, "Generator"), define(Gp, iteratorSymbol, function () {
280
+ }, defineIteratorMethods(g), define(g, u, "Generator"), define(g, a, function () {
281
281
  return this;
282
- }), define(Gp, "toString", function () {
282
+ }), define(g, "toString", function () {
283
283
  return "[object Generator]";
284
- }), exports.keys = function (val) {
285
- var object = Object(val),
286
- keys = [];
287
- for (var key in object) keys.push(key);
288
- return keys.reverse(), function next() {
289
- for (; keys.length;) {
290
- var key = keys.pop();
291
- if (key in object) return next.value = key, next.done = !1, next;
284
+ }), e.keys = function (t) {
285
+ var e = Object(t),
286
+ r = [];
287
+ for (var n in e) r.push(n);
288
+ return r.reverse(), function next() {
289
+ for (; r.length;) {
290
+ var t = r.pop();
291
+ if (t in e) return next.value = t, next.done = !1, next;
292
292
  }
293
293
  return next.done = !0, next;
294
294
  };
295
- }, exports.values = values, Context.prototype = {
295
+ }, e.values = values, Context.prototype = {
296
296
  constructor: Context,
297
- reset: function (skipTempReset) {
298
- if (this.prev = 0, this.next = 0, this.sent = this._sent = undefined, this.done = !1, this.delegate = null, this.method = "next", this.arg = undefined, this.tryEntries.forEach(resetTryEntry), !skipTempReset) for (var name in this) "t" === name.charAt(0) && hasOwn.call(this, name) && !isNaN(+name.slice(1)) && (this[name] = undefined);
297
+ reset: function (e) {
298
+ if (this.prev = 0, this.next = 0, this.sent = this._sent = t, this.done = !1, this.delegate = null, this.method = "next", this.arg = t, this.tryEntries.forEach(resetTryEntry), !e) for (var r in this) "t" === r.charAt(0) && n.call(this, r) && !isNaN(+r.slice(1)) && (this[r] = t);
299
299
  },
300
300
  stop: function () {
301
301
  this.done = !0;
302
- var rootRecord = this.tryEntries[0].completion;
303
- if ("throw" === rootRecord.type) throw rootRecord.arg;
302
+ var t = this.tryEntries[0].completion;
303
+ if ("throw" === t.type) throw t.arg;
304
304
  return this.rval;
305
305
  },
306
- dispatchException: function (exception) {
307
- if (this.done) throw exception;
308
- var context = this;
309
- function handle(loc, caught) {
310
- return record.type = "throw", record.arg = exception, context.next = loc, caught && (context.method = "next", context.arg = undefined), !!caught;
306
+ dispatchException: function (e) {
307
+ if (this.done) throw e;
308
+ var r = this;
309
+ function handle(n, o) {
310
+ return a.type = "throw", a.arg = e, r.next = n, o && (r.method = "next", r.arg = t), !!o;
311
311
  }
312
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
313
- var entry = this.tryEntries[i],
314
- record = entry.completion;
315
- if ("root" === entry.tryLoc) return handle("end");
316
- if (entry.tryLoc <= this.prev) {
317
- var hasCatch = hasOwn.call(entry, "catchLoc"),
318
- hasFinally = hasOwn.call(entry, "finallyLoc");
319
- if (hasCatch && hasFinally) {
320
- if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0);
321
- if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc);
322
- } else if (hasCatch) {
323
- if (this.prev < entry.catchLoc) return handle(entry.catchLoc, !0);
312
+ for (var o = this.tryEntries.length - 1; o >= 0; --o) {
313
+ var i = this.tryEntries[o],
314
+ a = i.completion;
315
+ if ("root" === i.tryLoc) return handle("end");
316
+ if (i.tryLoc <= this.prev) {
317
+ var c = n.call(i, "catchLoc"),
318
+ u = n.call(i, "finallyLoc");
319
+ if (c && u) {
320
+ if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
321
+ if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
322
+ } else if (c) {
323
+ if (this.prev < i.catchLoc) return handle(i.catchLoc, !0);
324
324
  } else {
325
- if (!hasFinally) throw new Error("try statement without catch or finally");
326
- if (this.prev < entry.finallyLoc) return handle(entry.finallyLoc);
325
+ if (!u) throw new Error("try statement without catch or finally");
326
+ if (this.prev < i.finallyLoc) return handle(i.finallyLoc);
327
327
  }
328
328
  }
329
329
  }
330
330
  },
331
- abrupt: function (type, arg) {
332
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
333
- var entry = this.tryEntries[i];
334
- if (entry.tryLoc <= this.prev && hasOwn.call(entry, "finallyLoc") && this.prev < entry.finallyLoc) {
335
- var finallyEntry = entry;
331
+ abrupt: function (t, e) {
332
+ for (var r = this.tryEntries.length - 1; r >= 0; --r) {
333
+ var o = this.tryEntries[r];
334
+ if (o.tryLoc <= this.prev && n.call(o, "finallyLoc") && this.prev < o.finallyLoc) {
335
+ var i = o;
336
336
  break;
337
337
  }
338
338
  }
339
- finallyEntry && ("break" === type || "continue" === type) && finallyEntry.tryLoc <= arg && arg <= finallyEntry.finallyLoc && (finallyEntry = null);
340
- var record = finallyEntry ? finallyEntry.completion : {};
341
- return record.type = type, record.arg = arg, finallyEntry ? (this.method = "next", this.next = finallyEntry.finallyLoc, ContinueSentinel) : this.complete(record);
339
+ i && ("break" === t || "continue" === t) && i.tryLoc <= e && e <= i.finallyLoc && (i = null);
340
+ var a = i ? i.completion : {};
341
+ return a.type = t, a.arg = e, i ? (this.method = "next", this.next = i.finallyLoc, y) : this.complete(a);
342
342
  },
343
- complete: function (record, afterLoc) {
344
- if ("throw" === record.type) throw record.arg;
345
- return "break" === record.type || "continue" === record.type ? this.next = record.arg : "return" === record.type ? (this.rval = this.arg = record.arg, this.method = "return", this.next = "end") : "normal" === record.type && afterLoc && (this.next = afterLoc), ContinueSentinel;
343
+ complete: function (t, e) {
344
+ if ("throw" === t.type) throw t.arg;
345
+ return "break" === t.type || "continue" === t.type ? this.next = t.arg : "return" === t.type ? (this.rval = this.arg = t.arg, this.method = "return", this.next = "end") : "normal" === t.type && e && (this.next = e), y;
346
346
  },
347
- finish: function (finallyLoc) {
348
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
349
- var entry = this.tryEntries[i];
350
- if (entry.finallyLoc === finallyLoc) return this.complete(entry.completion, entry.afterLoc), resetTryEntry(entry), ContinueSentinel;
347
+ finish: function (t) {
348
+ for (var e = this.tryEntries.length - 1; e >= 0; --e) {
349
+ var r = this.tryEntries[e];
350
+ if (r.finallyLoc === t) return this.complete(r.completion, r.afterLoc), resetTryEntry(r), y;
351
351
  }
352
352
  },
353
- catch: function (tryLoc) {
354
- for (var i = this.tryEntries.length - 1; i >= 0; --i) {
355
- var entry = this.tryEntries[i];
356
- if (entry.tryLoc === tryLoc) {
357
- var record = entry.completion;
358
- if ("throw" === record.type) {
359
- var thrown = record.arg;
360
- resetTryEntry(entry);
353
+ catch: function (t) {
354
+ for (var e = this.tryEntries.length - 1; e >= 0; --e) {
355
+ var r = this.tryEntries[e];
356
+ if (r.tryLoc === t) {
357
+ var n = r.completion;
358
+ if ("throw" === n.type) {
359
+ var o = n.arg;
360
+ resetTryEntry(r);
361
361
  }
362
- return thrown;
362
+ return o;
363
363
  }
364
364
  }
365
365
  throw new Error("illegal catch attempt");
366
366
  },
367
- delegateYield: function (iterable, resultName, nextLoc) {
367
+ delegateYield: function (e, r, n) {
368
368
  return this.delegate = {
369
- iterator: values(iterable),
370
- resultName: resultName,
371
- nextLoc: nextLoc
372
- }, "next" === this.method && (this.arg = undefined), ContinueSentinel;
369
+ iterator: values(e),
370
+ resultName: r,
371
+ nextLoc: n
372
+ }, "next" === this.method && (this.arg = t), y;
373
373
  }
374
- }, exports;
374
+ }, e;
375
375
  }
376
376
  function asyncGeneratorStep(gen, resolve, reject, _next, _throw, key, arg) {
377
377
  try {
@@ -2774,9 +2774,7 @@ function findReferenceSourceImageId(multiframe, frameSegment, imageIds, metadata
2774
2774
  return imageId;
2775
2775
  }
2776
2776
  var frameSourceImageSequence = undefined;
2777
- if (SourceImageSequence && SourceImageSequence.length !== 0) {
2778
- frameSourceImageSequence = SourceImageSequence[frameSegment];
2779
- } else if (PerFrameFunctionalGroup.DerivationImageSequence) {
2777
+ if (PerFrameFunctionalGroup.DerivationImageSequence) {
2780
2778
  var DerivationImageSequence = PerFrameFunctionalGroup.DerivationImageSequence;
2781
2779
  if (Array.isArray(DerivationImageSequence)) {
2782
2780
  if (DerivationImageSequence.length !== 0) {
@@ -2795,6 +2793,9 @@ function findReferenceSourceImageId(multiframe, frameSegment, imageIds, metadata
2795
2793
  }
2796
2794
  }
2797
2795
  }
2796
+ } else if (SourceImageSequence && SourceImageSequence.length !== 0) {
2797
+ console.warn("DerivationImageSequence not present, using SourceImageSequence assuming SEG has the same geometry as the source image.");
2798
+ frameSourceImageSequence = SourceImageSequence[frameSegment];
2798
2799
  }
2799
2800
  if (frameSourceImageSequence) {
2800
2801
  imageId = getImageIdOfSourceImageBySourceImageSequence(frameSourceImageSequence, sopUIDImageIdIndexMap);
@@ -2834,32 +2835,33 @@ function checkSEGsOverlapping(pixelData, multiframe, imageIds, validOrientations
2834
2835
 
2835
2836
  var frameSegmentsMapping = new Map();
2836
2837
  var _loop3 = function _loop3() {
2837
- var segmentIndex = getSegmentIndex(multiframe, frameSegment);
2838
- if (segmentIndex === undefined) {
2839
- console.warn("Could not retrieve the segment index for frame segment " + frameSegment + ", skipping this frame.");
2840
- return "continue";
2841
- }
2842
- var imageId = findReferenceSourceImageId(multiframe, frameSegment, imageIds, metadataProvider, tolerance, sopUIDImageIdIndexMap);
2843
- if (!imageId) {
2844
- console.warn("Image not present in stack, can't import frame : " + frameSegment + ".");
2845
- return "continue";
2846
- }
2847
- var imageIdIndex = imageIds.findIndex(function (element) {
2848
- return element === imageId;
2849
- });
2850
- if (frameSegmentsMapping.has(imageIdIndex)) {
2851
- var segmentArray = frameSegmentsMapping.get(imageIdIndex);
2852
- if (!segmentArray.includes(frameSegment)) {
2853
- segmentArray.push(frameSegment);
2854
- frameSegmentsMapping.set(imageIdIndex, segmentArray);
2838
+ var segmentIndex = getSegmentIndex(multiframe, frameSegment);
2839
+ if (segmentIndex === undefined) {
2840
+ console.warn("Could not retrieve the segment index for frame segment " + frameSegment + ", skipping this frame.");
2841
+ return 0; // continue
2855
2842
  }
2856
- } else {
2857
- frameSegmentsMapping.set(imageIdIndex, [frameSegment]);
2858
- }
2859
- };
2843
+ var imageId = findReferenceSourceImageId(multiframe, frameSegment, imageIds, metadataProvider, tolerance, sopUIDImageIdIndexMap);
2844
+ if (!imageId) {
2845
+ console.warn("Image not present in stack, can't import frame : " + frameSegment + ".");
2846
+ return 0; // continue
2847
+ }
2848
+ var imageIdIndex = imageIds.findIndex(function (element) {
2849
+ return element === imageId;
2850
+ });
2851
+ if (frameSegmentsMapping.has(imageIdIndex)) {
2852
+ var segmentArray = frameSegmentsMapping.get(imageIdIndex);
2853
+ if (!segmentArray.includes(frameSegment)) {
2854
+ segmentArray.push(frameSegment);
2855
+ frameSegmentsMapping.set(imageIdIndex, segmentArray);
2856
+ }
2857
+ } else {
2858
+ frameSegmentsMapping.set(imageIdIndex, [frameSegment]);
2859
+ }
2860
+ },
2861
+ _ret;
2860
2862
  for (var frameSegment = 0; frameSegment < groupsLen; ++frameSegment) {
2861
- var _ret = _loop3();
2862
- if (_ret === "continue") continue;
2863
+ _ret = _loop3();
2864
+ if (_ret === 0) continue;
2863
2865
  }
2864
2866
  var _iterator = _createForOfIteratorHelper(frameSegmentsMapping.entries()),
2865
2867
  _step;
@@ -2927,77 +2929,78 @@ function insertOverlappingPixelDataPlanar(segmentsOnFrame, segmentsOnFrameArray,
2927
2929
  var numberOfSegs = multiframe.SegmentSequence.length;
2928
2930
  for (var segmentIndexToProcess = 1; segmentIndexToProcess <= numberOfSegs; ++segmentIndexToProcess) {
2929
2931
  var _loop4 = function _loop4(_i2) {
2930
- var PerFrameFunctionalGroups = PerFrameFunctionalGroupsSequence[_i2];
2931
- var segmentIndex = getSegmentIndex(multiframe, _i2);
2932
- if (segmentIndex === undefined) {
2933
- throw new Error("Could not retrieve the segment index. Aborting segmentation loading.");
2934
- }
2935
- if (segmentIndex !== segmentIndexToProcess) {
2936
- i = _i2;
2937
- return "continue";
2938
- }
2939
- var ImageOrientationPatientI = sharedImageOrientationPatient || PerFrameFunctionalGroups.PlaneOrientationSequence.ImageOrientationPatient;
2940
-
2941
- // Since we moved to the chunks approach, we need to read the data
2942
- // and handle scenarios where the portion of data is in one chunk
2943
- // and the other portion is in another chunk
2944
- var view = readFromUnpackedChunks(pixelData, _i2 * sliceLength, sliceLength);
2945
- var pixelDataI2D = ndarray__WEBPACK_IMPORTED_MODULE_2___default()(view, [Rows, Columns]);
2946
- var alignedPixelDataI = alignPixelDataWithSourceData(pixelDataI2D, ImageOrientationPatientI, validOrientations, tolerance);
2947
- if (!alignedPixelDataI) {
2948
- throw new Error("Individual SEG frames are out of plane with respect to the first SEG frame. " + "This is not yet supported. Aborting segmentation loading.");
2949
- }
2950
- var imageId = findReferenceSourceImageId(multiframe, _i2, imageIds, metadataProvider, tolerance, sopUIDImageIdIndexMap);
2951
- if (!imageId) {
2952
- console.warn("Image not present in stack, can't import frame : " + _i2 + ".");
2953
- i = _i2;
2954
- return "continue";
2955
- }
2956
- var sourceImageMetadata = metadataProvider.get("instance", imageId);
2957
- if (Rows !== sourceImageMetadata.Rows || Columns !== sourceImageMetadata.Columns) {
2958
- throw new Error("Individual SEG frames have different geometry dimensions (Rows and Columns) " + "respect to the source image reference frame. This is not yet supported. " + "Aborting segmentation loading. ");
2959
- }
2960
- var imageIdIndex = imageIds.findIndex(function (element) {
2961
- return element === imageId;
2962
- });
2963
- var byteOffset = sliceLength * imageIdIndex * TypedArrayConstructor.BYTES_PER_ELEMENT;
2964
- var labelmap2DView = new TypedArrayConstructor(tempBuffer, byteOffset, sliceLength);
2965
- var data = alignedPixelDataI.data;
2966
- var segmentOnFrame = false;
2967
- for (var j = 0, len = alignedPixelDataI.data.length; j < len; ++j) {
2968
- if (data[j]) {
2969
- if (labelmap2DView[j] !== 0) {
2970
- m++;
2971
- if (m >= M) {
2972
- labelmapBufferArray[m] = new ArrayBuffer(arrayBufferLength);
2973
- segmentsOnFrameArray[m] = [];
2974
- M++;
2932
+ var PerFrameFunctionalGroups = PerFrameFunctionalGroupsSequence[_i2];
2933
+ var segmentIndex = getSegmentIndex(multiframe, _i2);
2934
+ if (segmentIndex === undefined) {
2935
+ throw new Error("Could not retrieve the segment index. Aborting segmentation loading.");
2936
+ }
2937
+ if (segmentIndex !== segmentIndexToProcess) {
2938
+ i = _i2;
2939
+ return 0; // continue
2940
+ }
2941
+ var ImageOrientationPatientI = sharedImageOrientationPatient || PerFrameFunctionalGroups.PlaneOrientationSequence.ImageOrientationPatient;
2942
+
2943
+ // Since we moved to the chunks approach, we need to read the data
2944
+ // and handle scenarios where the portion of data is in one chunk
2945
+ // and the other portion is in another chunk
2946
+ var view = readFromUnpackedChunks(pixelData, _i2 * sliceLength, sliceLength);
2947
+ var pixelDataI2D = ndarray__WEBPACK_IMPORTED_MODULE_2___default()(view, [Rows, Columns]);
2948
+ var alignedPixelDataI = alignPixelDataWithSourceData(pixelDataI2D, ImageOrientationPatientI, validOrientations, tolerance);
2949
+ if (!alignedPixelDataI) {
2950
+ throw new Error("Individual SEG frames are out of plane with respect to the first SEG frame. " + "This is not yet supported. Aborting segmentation loading.");
2951
+ }
2952
+ var imageId = findReferenceSourceImageId(multiframe, _i2, imageIds, metadataProvider, tolerance, sopUIDImageIdIndexMap);
2953
+ if (!imageId) {
2954
+ console.warn("Image not present in stack, can't import frame : " + _i2 + ".");
2955
+ i = _i2;
2956
+ return 0; // continue
2957
+ }
2958
+ var sourceImageMetadata = metadataProvider.get("instance", imageId);
2959
+ if (Rows !== sourceImageMetadata.Rows || Columns !== sourceImageMetadata.Columns) {
2960
+ throw new Error("Individual SEG frames have different geometry dimensions (Rows and Columns) " + "respect to the source image reference frame. This is not yet supported. " + "Aborting segmentation loading. ");
2961
+ }
2962
+ var imageIdIndex = imageIds.findIndex(function (element) {
2963
+ return element === imageId;
2964
+ });
2965
+ var byteOffset = sliceLength * imageIdIndex * TypedArrayConstructor.BYTES_PER_ELEMENT;
2966
+ var labelmap2DView = new TypedArrayConstructor(tempBuffer, byteOffset, sliceLength);
2967
+ var data = alignedPixelDataI.data;
2968
+ var segmentOnFrame = false;
2969
+ for (var j = 0, len = alignedPixelDataI.data.length; j < len; ++j) {
2970
+ if (data[j]) {
2971
+ if (labelmap2DView[j] !== 0) {
2972
+ m++;
2973
+ if (m >= M) {
2974
+ labelmapBufferArray[m] = new ArrayBuffer(arrayBufferLength);
2975
+ segmentsOnFrameArray[m] = [];
2976
+ M++;
2977
+ }
2978
+ tempBuffer = labelmapBufferArray[m].slice(0);
2979
+ tempSegmentsOnFrame = lodash_clonedeep__WEBPACK_IMPORTED_MODULE_3___default()(segmentsOnFrameArray[m]);
2980
+ _i2 = 0;
2981
+ break;
2982
+ } else {
2983
+ labelmap2DView[j] = segmentIndex;
2984
+ segmentOnFrame = true;
2975
2985
  }
2976
- tempBuffer = labelmapBufferArray[m].slice(0);
2977
- tempSegmentsOnFrame = lodash_clonedeep__WEBPACK_IMPORTED_MODULE_3___default()(segmentsOnFrameArray[m]);
2978
- _i2 = 0;
2979
- break;
2980
- } else {
2981
- labelmap2DView[j] = segmentIndex;
2982
- segmentOnFrame = true;
2983
2986
  }
2984
2987
  }
2985
- }
2986
- if (segmentOnFrame) {
2987
- if (!tempSegmentsOnFrame[imageIdIndex]) {
2988
- tempSegmentsOnFrame[imageIdIndex] = [];
2989
- }
2990
- tempSegmentsOnFrame[imageIdIndex].push(segmentIndex);
2991
- if (!segmentsOnFrame[imageIdIndex]) {
2992
- segmentsOnFrame[imageIdIndex] = [];
2988
+ if (segmentOnFrame) {
2989
+ if (!tempSegmentsOnFrame[imageIdIndex]) {
2990
+ tempSegmentsOnFrame[imageIdIndex] = [];
2991
+ }
2992
+ tempSegmentsOnFrame[imageIdIndex].push(segmentIndex);
2993
+ if (!segmentsOnFrame[imageIdIndex]) {
2994
+ segmentsOnFrame[imageIdIndex] = [];
2995
+ }
2996
+ segmentsOnFrame[imageIdIndex].push(segmentIndex);
2993
2997
  }
2994
- segmentsOnFrame[imageIdIndex].push(segmentIndex);
2995
- }
2996
- i = _i2;
2997
- };
2998
+ i = _i2;
2999
+ },
3000
+ _ret2;
2998
3001
  for (var i = 0, groupsLen = PerFrameFunctionalGroupsSequence.length; i < groupsLen; ++i) {
2999
- var _ret2 = _loop4(i);
3000
- if (_ret2 === "continue") continue;
3002
+ _ret2 = _loop4(i);
3003
+ if (_ret2 === 0) continue;
3001
3004
  }
3002
3005
  labelmapBufferArray[m] = tempBuffer.slice(0);
3003
3006
  segmentsOnFrameArray[m] = lodash_clonedeep__WEBPACK_IMPORTED_MODULE_3___default()(tempSegmentsOnFrame);
@@ -3567,6 +3570,8 @@ LOSS OF USE, DATA OR PROFITS, WHETHER IN AN ACTION OF CONTRACT, NEGLIGENCE OR
3567
3570
  OTHER TORTIOUS ACTION, ARISING OUT OF OR IN CONNECTION WITH THE USE OR
3568
3571
  PERFORMANCE OF THIS SOFTWARE.
3569
3572
  ***************************************************************************** */
3573
+ /* global Reflect, Promise, SuppressedError, Symbol */
3574
+
3570
3575
  var __assign = function () {
3571
3576
  __assign = Object.assign || function __assign(t) {
3572
3577
  for (var s, i = 1, n = arguments.length; i < n; i++) {
@@ -3586,6 +3591,10 @@ function __spreadArray(to, from, pack) {
3586
3591
  }
3587
3592
  return to.concat(ar || Array.prototype.slice.call(from));
3588
3593
  }
3594
+ typeof SuppressedError === "function" ? SuppressedError : function (error, suppressed, message) {
3595
+ var e = new Error(message);
3596
+ return e.name = "SuppressedError", e.error = error, e.suppressed = suppressed, e;
3597
+ };
3589
3598
 
3590
3599
  var CORNERSTONE_3D_TAG = "Cornerstone3DTools@^0.1.0";
3591
3600
 
@@ -3807,6 +3816,7 @@ var MeasurementReport = /** @class */ (function () {
3807
3816
  var REPORT = "Imaging Measurements";
3808
3817
  var GROUP = "Measurement Group";
3809
3818
  var TRACKING_IDENTIFIER = "Tracking Identifier";
3819
+ var TRACKING_UNIQUE_IDENTIFIER = "Tracking Unique Identifier";
3810
3820
  // Identify the Imaging Measurements
3811
3821
  var imagingMeasurementContent = toArray(dataset.ContentSequence).find(codeMeaningEquals(REPORT));
3812
3822
  // Retrieve the Measurements themselves
@@ -3828,12 +3838,19 @@ var MeasurementReport = /** @class */ (function () {
3828
3838
  TRACKING_IDENTIFIER;
3829
3839
  });
3830
3840
  var TrackingIdentifierValue_1 = TrackingIdentifierGroup.TextValue;
3841
+ var TrackingUniqueIdentifierGroup = measurementGroupContentSequence.find(function (contentItem) {
3842
+ return contentItem.ConceptNameCodeSequence.CodeMeaning ===
3843
+ TRACKING_UNIQUE_IDENTIFIER;
3844
+ });
3845
+ var TrackingUniqueIdentifierValue = TrackingUniqueIdentifierGroup === null || TrackingUniqueIdentifierGroup === void 0 ? void 0 : TrackingUniqueIdentifierGroup.UID;
3831
3846
  var toolClass = ((_a = hooks === null || hooks === void 0 ? void 0 : hooks.getToolClass) === null || _a === void 0 ? void 0 : _a.call(hooks, measurementGroup, dataset, registeredToolClasses)) ||
3832
3847
  registeredToolClasses.find(function (tc) {
3833
3848
  return tc.isValidCornerstoneTrackingIdentifier(TrackingIdentifierValue_1);
3834
3849
  });
3835
3850
  if (toolClass) {
3836
3851
  var measurement = toolClass.getMeasurementData(measurementGroup, sopInstanceUIDToImageIdMap, imageToWorldCoords, metadata);
3852
+ measurement.TrackingUniqueIdentifier =
3853
+ TrackingUniqueIdentifierValue;
3837
3854
  console.log("=== ".concat(toolClass.toolType, " ==="));
3838
3855
  console.log(measurement);
3839
3856
  measurementData[toolClass.toolType].push(measurement);