-
-
Notifications
You must be signed in to change notification settings - Fork 3.3k
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
feat(chartViewport): segmentation :: 4D chart viewport #3616
feat(chartViewport): segmentation :: 4D chart viewport #3616
Conversation
…fferent toolGroupId
package.json
Outdated
@@ -88,6 +88,7 @@ | |||
"copy-webpack-plugin": "^9.0.1", | |||
"cross-env": "^5.2.0", | |||
"css-loader": "^3.2.0", | |||
"d3": "^7.8.5", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
do we really need all of d3?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
We actually need 7 out of 30 packages. I will add only the required ones.
commandsManager: this._commandsManager, | ||
}; | ||
|
||
previousWorkflowStep?.onBeforeInactivate?.(appContext); |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
onBeforeInactivate is a bit odd, don't have suggestions though
function _updateSegmentationsDisplaySets(appContext) { | ||
const { servicesManager } = appContext; | ||
const { segmentationService } = servicesManager.services; | ||
|
||
const segmentations = segmentationService.getSegmentations(); | ||
const { seriesMetadata, instance } = _getInstanceFromSegmentations( | ||
segmentations | ||
); | ||
|
||
// An event is triggered after adding the instance and the displaySet is created | ||
DicomMetadataStore.addSeriesMetadata([seriesMetadata], true); | ||
DicomMetadataStore.addInstances([instance], true); | ||
} |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm surprised this exists here, why the sopHandler for the line chart should care about segmentation?
width: widthProp, | ||
height: heightProp, | ||
axis, | ||
series, |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I'm surpised there is a prop called series here... is this DICOM series?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
No, chart series similar to what you can find in lineChart.stories.mdx
|
||
const LineChartViewport = ({ displaySets }) => { | ||
const displaySet = displaySets[0]; | ||
const { axis: chartAxis, series: chartSeries } = displaySet.chartData; |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
again not sure if series is DICOM series or what
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
chartData
does not contain any DICOM related data but only label and points.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
see my comments please
Commit 38aab51 |
Commit 294bcfa |
Codecov Report
@@ Coverage Diff @@
## feat/preclinical-4d-base #3616 +/- ##
=========================================================
Coverage 42.75% 42.75%
=========================================================
Files 82 82
Lines 1450 1450
Branches 338 338
=========================================================
Hits 620 620
Misses 667 667
Partials 163 163 Continue to review full report in Codecov by Sentry.
|
"d3-array": "3", | ||
"d3-axis": "3", | ||
"d3-scale": "4", | ||
"d3-scale-chromatic": "3", | ||
"d3-selection": "3", | ||
"d3-shape": "3", | ||
"d3-zoom": "3", |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copied from D3/package.js
No description provided.