-
Notifications
You must be signed in to change notification settings - Fork 37
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(viewer.js): Add bidirectional and ellipse annotations #72
base: master
Are you sure you want to change the base?
feat(viewer.js): Add bidirectional and ellipse annotations #72
Conversation
igoroctaviano
commented
Nov 25, 2021
- Adds Ellipse and Bidirectional annotations
- Adds optical path fix / img type changes by @wayfarer3130
@hackermd I'm creating this PR as a draft because there's probably a ton of changes necessary to get this one merged. There's a new presentation state property in the ROI that you can ignore. It was used to store coordinates of the textbox. |
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.
@igoroctaviano this looks really great and the functionality would be very useful to have in the library. I didn't yet delve into the implementations details, but only glanced over the changes to the public API and the coding style.
Some initial comments:
- Please format the code according to our coding style guidelines based on standard. You can use
npm run lint
andnpm run fmt
. - We will need to find a different way of change the style without passing OpenLayers objects via the public API of the viewer.
I will take a closer look at the implementation of the markups and conduct a more comprehensive review next week.
|
||
import _MarkupManager from './markups/_MarkupManager' | ||
import _MarkupManager from "./markups/_MarkupManager"; |
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.
Could you please revert these stylistic changes? They complicate the code review and are not in compliance with the coding style of the library (see Coding Style section in CONTRIBUTING).
new dcmjs.sr.coding.CodedConcept({ | ||
meaning: "Long Axis", | ||
value: "G-A185", | ||
schemeDesignator: "SRT", | ||
}), | ||
new dcmjs.sr.coding.CodedConcept({ | ||
meaning: "Short Axis", | ||
value: "G-A186", | ||
schemeDesignator: "SRT", |
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.
Please use SCT
rather than SRT
codes.
meaning: "AREA", | ||
value: "G-D7FE", | ||
schemeDesignator: "SRT", |
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.
Please use SCT
rather than SRT
codes.
|
||
const addOrUpdateMeasurement = (feature, measurement) => { |
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.
This should probably be a private function, too.
const addOrUpdateMeasurement = (feature, measurement) => { | |
const _addOrUpdateMeasurement = (feature, measurement) => { |
* @param {number[]} styleOptions.fill.color - RGBA color of the body | ||
* @param {object} styleOptions.image - Style options for image | ||
*/ | ||
setFeatureStyle (feature, styleOptions, optSilent = false) { |
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.
The public API of the viewer should not expose any of the underlying OpenLayers types. We will need to be abstract this.
Quality Gate failedFailed conditions See analysis details on SonarQube Cloud Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE |