hellfire 0.25.14 → 0.25.16

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/CHANGELOG.md CHANGED
@@ -2,6 +2,14 @@
2
2
 
3
3
  All notable changes to this project will be documented in this file. See [standard-version](https://github.com/conventional-changelog/standard-version) for commit guidelines.
4
4
 
5
+ ## [0.25.16](http://10.16.100.57/diffusion/115/paladin/compare/v0.25.15...v0.25.16) (2023-04-24)
6
+
7
+
8
+
9
+ ## [0.25.15](http://10.16.100.57/diffusion/115/paladin/compare/v0.25.14...v0.25.15) (2023-04-23)
10
+
11
+
12
+
5
13
  ## [0.25.14](http://10.16.100.57/diffusion/115/paladin/compare/v0.25.13...v0.25.14) (2023-04-20)
6
14
 
7
15
 
package/README.md CHANGED
@@ -144,6 +144,13 @@ toolSortChange: ()=> void
144
144
 
145
145
  传入工具栏自定义排序的回调函数(用于早期的单列工具栏)
146
146
 
147
+ <b>`disableUpDownKeyAction`</b>
148
+ ```
149
+ disableUpDownKeyAction: boolean
150
+ ```
151
+
152
+ 上下热键事件是否禁用
153
+
147
154
  ### DicomView提供给父组件调用的方法:
148
155
 
149
156
  <b>`addStudy(data)`</b>
package/dist/index.js CHANGED
@@ -1129,8 +1129,8 @@ var initialState$1 = {
1129
1129
  Cine: false,
1130
1130
  VRCenterPointShow: false,
1131
1131
  VRMode: OperationMode.Standard,
1132
- // 连续测量 手机端上关闭
1133
- continuousMeasure: !isMobile,
1132
+ // 连续测量 默认不开启
1133
+ continuousMeasure: false,
1134
1134
  Surgery: false,
1135
1135
  CentesisStart: false,
1136
1136
  CentesisEnd: false,
@@ -32541,6 +32541,7 @@ var AIAnalysisOverlayTool = /*#__PURE__*/function (_BaseAnnotationPlusTo) {
32541
32541
  simpleMode = _ref.simpleMode;
32542
32542
 
32543
32543
  this.simpleMode = simpleMode;
32544
+ this.aiResult = get$1('aiResult');
32544
32545
  }
32545
32546
  }, {
32546
32547
  key: "addMeasurement",
@@ -54688,6 +54689,33 @@ var DicomViewport = /*#__PURE__*/function (_Component) {
54688
54689
  });
54689
54690
  });
54690
54691
 
54692
+ defineProperty(assertThisInitialized(_this), "resetAIToolState", function () {
54693
+ // 先清除所有ai tool state数据
54694
+ var imageIds = _this.state.stack.imageIds;
54695
+
54696
+ for (var i = 0; i < imageIds.length; i++) {
54697
+ var aiToolState = _default$E.globalImageIdSpecificToolStateManager.getImageIdToolState(imageIds[i], 'AIAnalysisOverlay');
54698
+
54699
+ if (aiToolState && aiToolState.data && aiToolState.data.length > 0) {
54700
+ _default$E.globalImageIdSpecificToolStateManager.setImageIdToolState(imageIds[i], 'AIAnalysisOverlay', {
54701
+ data: []
54702
+ });
54703
+ }
54704
+ }
54705
+
54706
+ var config = {
54707
+ mouseButtonMask: 1,
54708
+ isTouchActive: true
54709
+ };
54710
+ _default$E.setToolDisabledForElement(_this.element, 'AIAnalysisOverlay', config);
54711
+ _default$E.setToolEnabledForElement(_this.element, 'AIAnalysisOverlay', {
54712
+ simpleMode: _this.props.showSimpleAIResult
54713
+ });
54714
+ _default$E.setToolActiveForElement(_this.element, 'AIAnalysisOverlay', config);
54715
+ var enableElement = cornerstone.getEnabledElement(_this.element);
54716
+ cornerstone.updateImage(enableElement.element, true);
54717
+ });
54718
+
54691
54719
  _this.mouseDownViewport = null; // 记录鼠标操作前的viewport,为了相对同步
54692
54720
  // 拷贝一份 使得作用域内stack的修改不污染外部的series
54693
54721
 
@@ -55367,30 +55395,19 @@ var DicomViewport = /*#__PURE__*/function (_Component) {
55367
55395
  var _aiResult = get$1('aiResult');
55368
55396
 
55369
55397
  if (_aiResult) {
55370
- // 先清除所有ai tool state数据
55371
- var imageIds = this.state.stack.imageIds;
55372
-
55373
- for (var i = 0; i < imageIds.length; i++) {
55374
- var aiToolState = _default$E.globalImageIdSpecificToolStateManager.getImageIdToolState(imageIds[i], 'AIAnalysisOverlay');
55375
-
55376
- if (aiToolState && aiToolState.data && aiToolState.data.length > 0) {
55377
- _default$E.globalImageIdSpecificToolStateManager.setImageIdToolState(imageIds[i], 'AIAnalysisOverlay', {
55378
- data: []
55379
- });
55380
- }
55381
- }
55382
-
55383
- _default$E.setToolEnabledForElement(this.element, 'AIAnalysisOverlay', {
55384
- simpleMode: this.props.showSimpleAIResult
55385
- });
55386
-
55387
- var _enableElement = cornerstone.getEnabledElement(this.element);
55388
-
55389
- cornerstone.updateImage(_enableElement.element, true);
55398
+ this.resetAIToolState();
55390
55399
  }
55391
55400
 
55392
55401
  break;
55393
55402
 
55403
+ case JSON.stringify(prevProps.aiResult) !== JSON.stringify(this.props.aiResult):
55404
+ // 滚动条的ai标记更新
55405
+ this.checkAITipInCustomScroll({
55406
+ stack: this.state.stack
55407
+ });
55408
+ this.resetAIToolState();
55409
+ break;
55410
+
55394
55411
  case prevProps.ReferencePosition !== this.props.ReferencePosition:
55395
55412
  this.initReferencePosition();
55396
55413
 
@@ -56117,7 +56134,8 @@ var DicomLayout = /*#__PURE__*/function (_Component) {
56117
56134
  showAIResult: _this2.props.showAIResult,
56118
56135
  showSimpleAIResult: _this2.props.showSimpleAIResult,
56119
56136
  onResizeEmit: _this2.props.onResizeEmit,
56120
- onClickDomErrorReRenderButton: _this2.props.onClickDomErrorReRenderButton
56137
+ onClickDomErrorReRenderButton: _this2.props.onClickDomErrorReRenderButton,
56138
+ aiResult: _this2.props.aiResult
56121
56139
  });
56122
56140
  }));
56123
56141
  })), showVerticalScroll && /*#__PURE__*/React__default.createElement("div", {
@@ -59635,7 +59653,7 @@ var DicomView = /*#__PURE__*/function (_Component) {
59635
59653
  }
59636
59654
 
59637
59655
  if (JSON.stringify(nextProps.aiResult) !== JSON.stringify(this.props.aiResult)) {
59638
- if (nextProps.aiResult && nextProps.aiResult.inspectionDetails && nextProps.aiResult.inspectionDetails.length > 0) {
59656
+ if (nextProps.aiResult && nextProps.aiResult.inspectionDetails) {
59639
59657
  console.log('添加联动 -> ai 变化');
59640
59658
  set$1('aiResult', nextProps.aiResult.inspectionDetails);
59641
59659
  }
@@ -60009,6 +60027,7 @@ var DicomView = /*#__PURE__*/function (_Component) {
60009
60027
  series: this.props.series,
60010
60028
  showAIResult: this.props.showAIResult,
60011
60029
  showSimpleAIResult: this.props.showSimpleAIResult,
60030
+ aiResult: this.props.aiResult,
60012
60031
  onResizeEmit: this.props.onResizeEmit
60013
60032
  }), viewMode === '2D' && this.props.mode === 'imageMode' && /*#__PURE__*/React__default.createElement(_default$19, {
60014
60033
  onResizeEmit: this.props.onResizeEmit
@@ -60307,6 +60326,11 @@ var mergeProps$p = function mergeProps(propsFromState, propsFromDispatch, ownPro
60307
60326
  }
60308
60327
  },
60309
60328
  IMAGE_MODE_UP: function IMAGE_MODE_UP() {
60329
+ if (ownProps.disableUpDownKeyAction) {
60330
+ // disableUpDownKeyAction 禁用上下键
60331
+ return;
60332
+ }
60333
+
60310
60334
  if (threeDMode) {
60311
60335
  return;
60312
60336
  }
@@ -60331,6 +60355,11 @@ var mergeProps$p = function mergeProps(propsFromState, propsFromDispatch, ownPro
60331
60355
  }
60332
60356
  },
60333
60357
  IMAGE_MODE_DOWN: function IMAGE_MODE_DOWN() {
60358
+ if (ownProps.disableUpDownKeyAction) {
60359
+ // disableUpDownKeyAction 禁用上下键
60360
+ return;
60361
+ }
60362
+
60334
60363
  if (threeDMode) {
60335
60364
  return;
60336
60365
  }