Commit Graph

927 Commits

Author SHA1 Message Date
Alireza
8c32023694
chore(demo): update demo data (#3425)
* chore(demo): update demo data

* fix sm

* fix netlify
2023-05-29 10:38:19 -04:00
Alireza
c7bcf1134d
fix(staticwado): SM and RT and update the server with new data (#3422)
* fix bugs for the RT for the new demo

* fix SM with the static-wado server

* remove thumbnail from tmtv

* migration guide

* fix stability for the rt struct

* apply review comments

* add loading indicator to SM

* pdf works

* try to fix relative bulkData

* fix the rest

* fix preflight for the SM

* fix typo

* apply review comments

* yarn lock
2023-05-29 09:04:49 -04:00
Igor Octaviano
b684d80426
fix(DicomTagBrowser): Fix parsing problems that was limiting nested tags rendering (#3306)
* fix(DicomTagBrowser): Fix parsing problems that was limiting nested tags rendering

* Added a progress indicator when switching to a list of more than 1000 rows.

* Switched to using react-window to virtualize the dicom tag browser window.

* Added filtering to the DICOM tag browser with a new search UI widget.
Lots of tweaks and updates to the look-and-feel.

* Removed unused import.

* PR feedback including some UI tweaks.

* More PR feedback.

---------

Co-authored-by: Igor Octaviano <igor.octaviano@radicalimaging.com>
Co-authored-by: Joe Boccanfuso <joe.boccanfuso@radicalimaging.com>
2023-05-26 11:42:25 -04:00
M.D
217b330d7b
fix(request): Cross origin issue with fetching image and video (#3416)
* Cross origin issue when
- rendering thumbnails from prerendered url
- playing videos

* empty commit to trigger CI/CD check

* empty commit to trigger CI/CD check
2023-05-26 08:32:00 -04:00
M.D
770c677394
fix(microscopy): viewport's overview panel - zoom marker (#3415)
* fix microscopy viewport's overview panel - zoom marker

* comment
2023-05-23 21:20:32 -04:00
Joe Boccanfuso
685520acab
feat(command): Added command and hotkey binding for navigate to next and previous display set. (#3409)
* fix(command): Added command and hotkey binding for navigate to next and previous display set.

* Centralized the sorting (function) of display sets since at least three
areas sort display sets: hanging protocols, study/thumbnail browser and
updateViewportDisplaySet command.

* Renamed some methods for clarity.

* Scrolling active thumbnail into view for an updateViewportDisplaySet

* Added a null check.

* Added check to minimize thumbnail scrolling.
2023-05-23 15:03:55 -04:00
Alireza
4a17177d81
chore(bump): use cornerstone 3d 1.x (#3414)
* chore(bump): use cornerstone 3d 1.x

* yarn lock
2023-05-22 15:26:18 -04:00
Joe Boccanfuso
c0fd4416ed
fix(Measurement): fixed line dashing of measurements in various scenarios (#3407)
* fix(Measurement): fixed line dashing of measurements in various scenarios

For a StackViewport simply rely on the SeriesInstanceUID being part of the
tracked measurements or not.

For a VolumeViewport first check the image id of the current image in the viewport
and then check the SeriesInstanceUID (like for a StackViewport) if an id is returned.
To reliably get the id of the current image, listen for the VOLUME_VIEWPORT_NEW_VOLUME event.

* Changes for PR comments.
2023-05-18 20:59:33 -04:00
Mateus Freira dos Santos
f2004aee9e
fix(headers): Add all extra headers to WADO image loader (#3405) 2023-05-18 13:04:14 -04:00
Joe Boccanfuso
856538537d
fix(Video): Added fallback checks for DICOM video (#3402)
* fix(Video): Added fallback checks for DICOM video
Added some docs for video, pdf and upload.

* Added separate headings for DICOM PDF, DICOM Video and DICOM Upload in the docs.

* Updated docs for singlepart data source configuration.
2023-05-17 16:50:27 -04:00
Joe Boccanfuso
052653f3b2
fix(Image Download): various bug fixes for image download (#3396)
- prevent non-cornerstone viewports from showing the image download dialogue
- passing the rendering engine id to ToolGroup.addViewport
- fixed the keep/dismiss aspect feature
2023-05-16 14:50:34 -04:00
Alireza
1881ce5cbc
feat(custom displayOptions): add custom options to every level of hp (#3372)
* feat(custom displayOptions): add custom options to every level of hanging protocols

* move set preset down to cornerstone3d

* works

* fix tmtv based on new api

* fix unit test

* close

* review1

* upgrade packages

* update packages

* apply review comments

* recursive call

* less copy

* apply review comments

* fix e2e tests

* apply review comments

* revert

* apply review comments

* apply review comments

---------

Co-authored-by: Bill Wallace <wayfarer3130@gmail.com>
2023-05-16 13:07:37 -04:00
Joe Boccanfuso
045e54aa02
fix(Measurement): Use dashed lines for measurments of viewports where getCurrentImageId returns undefined (#3392)
* fix(Measurement): Use dashed lines for measurments of viewports where getCurrentImageId returns undefined

* Updated cornerstone3d packages

* Fixed code comment.

* Removed unused imports.
2023-05-16 10:02:10 -04:00
Joe Boccanfuso
52eb0edd6f
fix(dicomlocal): navigate /local to the work list and /localbasic to the (basic) viewer (#3389)
* fix(dicomlocal): navigate /local to the work list and /localbasic to the (basic) viewer
For TMTV, consider both the forward and back slash separator for modalities.

* Fix to TMTV isValidMode method.

* PR feedback:
- replace forward slashes with back slashes for modalities in the WorkList instead of in the Mode.

* Added query.series to DicomLocalDataSource.
2023-05-15 16:23:53 -04:00
Ashish Narnoli
af8bb27575
feat: query string dynamic app config (#3391)
* feat: query string dynamic app config

* fix: bug fix and couple of very small improvements
2023-05-15 14:52:48 -04:00
Bill Wallace
d5c5951e57
fix(SR): KO series being displayed in browser list (#3382)
* fix: KO series being displayed in browser list

* fix sr for volume viewports

* move highlight labelmap to RAF

* remove commented code

* fix the hydration bug for the SR

* apply review comments

* revert the key images for sr

* Remove some obsolete changes

* set initial image for sr instead of jump

* Remove viewportType stack

---------

Co-authored-by: Alireza <ar.sedghi@gmail.com>
2023-05-15 08:23:13 -04:00
Joe Boccanfuso
4172d0427b
fix(Measurements): in MeasurementService keep a separate set of unmapped measurements (#3385)
* fix(Measurements): return {} instead of undefined for getSOPInstanceAttributes

* PR feedback:
- separated measurements from non-acquisition plane
- reverted to previous behaviour of returning undefined in getSOPInstanceAttributes

* Added unit tests for unmapped measurements.

* PR feedback: added comments to the unmappedMeasurement used in the unit tests.
2023-05-12 16:24:00 -04:00
Alireza
4fd81b5cd2
fix(local): fix modalities not showing in local (#3388)
* fix various bugs

* revert back docusaurus for styling issues
2023-05-12 15:04:19 -04:00
Alireza
84cb709b44
feat(panel and auth): fix study panel to not rely on priors and add token param to url (#3381)
* fix: multiframe

* fix the unnecessary use of prior since some servers dont like it

* add authentication via token in url

* add data citation

* add resources

* upgrade packages

* yarn lock

* apply review comments
2023-05-11 10:01:33 -04:00
Joe Boccanfuso
8eaa1877fd
fix(DICOM PDF and Video): fixes for local DICOM load and remote data sources (#3374)
* fix(DICOM PDF and Video)
- added retrieve.directURL for local DICOM load data source; it returns a data URL
- fixed various checks for video using transfer syntaxes and SOP class UID with number of frames
- added call to 'rendered' endpoint for those data sources that support it; others get BulkDataURI

* Added DOC (PDF) and OT (for video in particular) to list of non-image thumbnail modalities.

* Fixed broken e2e tests.
2023-05-10 12:42:48 -04:00
Joe Boccanfuso
98d966514a
fix(Measurements): edit measurement while SEG loaded (#3375) 2023-05-09 12:15:26 -04:00
Alireza
2f355fa158
fix(cli): better support for external modules and toolGroups in templates (#3364)
* choe(modes, components): improved readability

This commit includes changes to improve performance in the basic-dev-mode and Thumbnail components.
Additionally, a change in the webpack configuration file was made to ignore ".min.js.map" files.
The defaultDataSourceName was also added to several configuration files, and whiteLabeling code was removed
from the local_orthanc configuration file.

* fix(cli): better path management and add dependencies

* better docs

* add default tool group to the templates

* add review comments

* apply review comments

* try to fix test

* fix thumbnail in tests
2023-05-08 15:49:28 -04:00
Pedro H. Köhler
285dff31c5
chore(packages): bump deps to fix vulnerabilities (#3366) 2023-05-08 14:04:39 -04:00
Alireza
969e7698fa
chore(bump cs3d): bump package and add caching to webpack (#3353)
* chore(bump cs3d): bump package and add caching to webpack

* remove test for now
2023-05-03 12:30:02 -04:00
Joe Boccanfuso
0f85b1a681
fix(DICOM Upload): Decreased the minimum height for the upload dialog contents to better fit some laptops. (#3347) 2023-05-02 09:24:53 -04:00
David Smith
0e3491d6bb
feat(proxy datasource): JSON server configuration launch (#2791)
* feat: delegating dicom web proxy datasource

* fix: configurably allow WADO image loader to issue preflight OPTIONS request

* Added documentation and fixed up some error handling from PR review

* review comments changes

* another small code review fix
2023-05-01 12:58:53 -04:00
Bill Wallace
b5b936b53e
fix(jump): Jump to measurement wasn't jumping when presentation already existed (#3318)
* fix: Jump to measurement after presentation store

* Fix initial load of DICOM SR

* Fix measurement highlight issues

* Clear measurements changed to array

* Fix merge issues

* PR comments

* Removed unused formatting.  Change to single event

* Fix the unit test

* PR review comments

* refactor(viewport): simplify imports, align destructuring

Simplify import statements by removing unused imports, organize existing imports, and align destructured imports consistently across the component.

---------
2023-05-01 12:54:33 -04:00
Joe Boccanfuso
66f6e3eade
feat(DICOM Upload): Added new DICOM upload dialogue launched from the worklist page (#3326)
* feat(DICOM Upload)
OHIF #3297
- DicomWebDataSource.store.dicom now accepts an ArrayBuffer of data sets to store
- DicomWebDataSource.store.dicom now also accepts optional callbacks to track upload and an AbortSignal object to cancel upload
- Added DicomFileUploader class that performs and tracks the upload of a DICOM file
- Added various UI pieces for the upload: DicomUpload, DicomUploadProgress, DicomUploadProgressItem
- ProgressLoadingBar was extracted from LoadingIndicatorProgress so it can be reused
- Modal dialogues can now optionally prevent an outside click from closing the Modal

* Passing an XMLHttpRequest to the dataSource.store.dicom method instead of callbacks and AbortSignal.
Cleanup of various UI pieces to minimize code and increase readability.

* Made the DicomUpload component a customization module exported by the cornerstone extension.

* Exposed a copy of the data source configuration via the IWebApiDataSource interface.
Added dicomUploadEnabled to a data source's configuration.

* Code clean up.

* Upgraded the dicomweb-client version to one that provides the ability to
pass a custom HTTP request. DICOM upload uses that custom HTTP request
to track progress and cancel requests.

* Distinguished between failed and cancelled uploads.

* Allow no selection in the upload dialogue.
Fixed the styling of various progress information so that everything aligns.

* Switched from cornerstone wado image loader to cornerstone dicom image loader for DICOM upload.

* Added special cancelled icon to differentiate from failed.

* Added a bit of spacing between the upload progress bar and percentage.

* Fixed minor issue with upload rejection.

* Performance improvement for cancel all uploads:
- use React memo for each upload item progress (row)
- do not await each request of a cancel all

* Fixed various padding/spacing for the DICOM upload drop zone component.
Changed the border dashing for the DICOM upload drop zone to be a background image gradient.
Added hover and active effects to the 'Cancel All Uploads' text.
2023-04-28 16:13:47 -04:00
Alireza
f377153b60
fix(viewportDialog): viewportDialoge not appearing in non-tracked viewports (#3071)
* fix: viewportdialoge not appearing in non-tracked viewports

* feat(viewports): Introduce useViewportDialog and remove deprecated API

This commit introduces the `useViewportDialog` hook and replaces the deprecated `viewportDialogApi` with the new `viewportDialogState`. Additionally, the notifications in `OHIFCornerstoneRTViewport` and `OHIFCornerstoneViewport` have been removed. Finally, the `CinePlayer` component now accepts optional parameters.

* fix tests
2023-04-28 11:06:03 -04:00
Alireza
c9d3c08cb6
feat(cst): Add new command to get nearby annotation tools (#3327)
* feat(cst): Add new command to get nearby annotation tools
This commit adds a new command `getNearbyAnnotation` to the `commandsModule.ts` file that identifies nearby annotation tools excluding Crosshairs and ReferenceLines. It also removes an unused mapping to `Crosshairs` in `initMeasurementService.js` and changes the command run in `findNearbyToolData.ts` to `getNearbyAnnotation`.

* perf(cornerstone): Improve performance by optimizing tools

Removes unnecessary imports to improve app's performance. Changes how annotations are detected on the `commandsModule.js` file by fetching the `isAnnotation` property of the tool instance if available. Updates `CrosshairsTool` and `ReferenceLinesTool` to not be annotations anymore. Adjusts the `localhost` URL ports for the `dcm4chee-arc` service interface on `local_dcm4chee.js` to allow for more efficient server communication.

* feat(cornerstone): Add CornerstoneServices type and ToolGroupService.getToolGroup to get tool group by ID or active viewport

This commit introduces the new CornerstoneServices interface to the code and adds the ToolGroupService.getToolGroup method, which can retrieve a specific tool group by ID or from the active viewport. The older _getToolGroup method has also been removed from commandsModule. When no tool group ID is provided, this method now retrieves the tool group from the currently active viewport with the help of getActiveViewportEnabledElement. Additionally, the required reference to @ohif/core has been removed.
2023-04-28 10:14:14 -04:00
M.D
075008c674
feat(microscopy): add dicom microscopy extension and mode (#3247)
* skeleton for dicom-microscopy extension

* skeleton for microscopy mode

* [feat] ported @radicalimaging/microscopy-dicom to OHIF's default extension

* [feat] ported microscopy mode from private repo

* added new definitions to the package.json

* webpack configuration update for microscopy extension

* register new icons for microscopy tools

* fixes to the microscopy extension and mode

* trivial error fix - typescript type import error

* link microscopy extension with default OHIF app plugin config

* demo config fix

* fix logs

* remove unsed imports

* [fix] loading of microscopy

* [fix] webworker script loading, normalizing denaturalized dataset

* found the latest version of dicom-microscopy-viewer that works with current OHIF extension : 0.35.2

* hide thumbnail pane by default, as we have issues with

* comments

* remove unused code

* [feat] microscopy - annotation selection

* [feat] microscopy - edit annotation label

* wip

* [bugfix] dicom-microscopy tool

* [bugfix] dicom microscopy annotations

* [fix] mixed-content blocking caused by BulkDataURI

* [fix] microscopy measurements panel - center button

* [fix] microscopy measurements panel - styling

* [fix] microscopy - controls

* fix local loading of microscopy

* fix local loading of dicom microscopy

* fix typo - indexof to indexOf

* [fix] remove unused icons

* remove commented out lines from webpack configuration

* platform/viewer/public/config/default.js - revert accidental changes

* [refactor] redirecting to microscopy mode on Local mode

* attribution to DMV and SLIM viewer

* [fix] code review feedbacks

* fix thumbnails

* [fix] microscopy - fix old publisher.publish() to PubSubService._broadcastEvent()

* [fix] interactions, webpack config, roi selection

* [feat] microscopy - remove select tool  from UI

* microscopy author

* [fix] saving and loading SR

* [bugfix] - missing publish() function in MicroscopyService, replace with _broadcastEvent

* remove author section from readme

* refactor SR saving feature

* fix webpack config after merge

* [bugfix] repeated import

* fix e2e

* webpack configuration

* hide "Create report" button for microscopy
2023-04-27 20:53:52 -04:00
Joe Boccanfuso
51cb0519fc
fix(Browser history): fixed NPE when navigating a study via browser history and history navigation is now available via the navigateHistory command (#3337)
* fix(Browser history):
- fixed an NPE when navigating to a different study via the URL
- exposed browser history navigation via a command

* Added documentation for the navigateHistory command.
Moved the history object from UI to viewer.
2023-04-27 10:46:23 -04:00
Alireza
eea0ed487b
feat(dicomImageLoader): replace wado image loader with the new library (#3339)
* use new dicom image loader instead of cswil

new dicom image loader fails

update dicom image loader

update yarn lock

modify webpack

* update webpack

* fix webpack

* update package versions

* update package versions
2023-04-26 20:55:56 -04:00
Alireza
66863281c4
feat(RT): add dicom RT support via volume viewports (#3310)
* feat: initial RT support

* make the segmentation service work with representation data

* feat: make segmentation service work with representations

* fix rtss vis

* fix: rt hydration

* fix the rendering of rt names

* fix imports

* refactor: Modify status and click handling for hydration of RTStructures

Modify status and click handling for hydration of RTStructures by renaming `onPillClick` to `onStatusClick` in `OHIFCornerstoneRTViewport.tsx` and `_getStatusComponent.tsx` files. Also, update initial segmentation configurations in `PanelSegmentation.tsx` and simplify configuration changes and values for segmentation service in `SegmentationService.ts`. Finally, remove console debug in `CornerstoneViewportService.ts`.

* wip for highlighting contours

* refactor rt displayset code

* review code update

* update cornerstone dependencies

* refactor: Update license year, version number, and minor code cleanup

This commit updates the license year in several files, updates the version number in package.json, and contains minor code cleanup in two files.

* add bulkdataURI retrieve for RT

* fix package version

* apply review comments

* apply review comments

* apply review comments

* feat(panels): refactor and streamline segmentation configuration and inputs

Rewrote state hooks and streamlined the configuration input for `PanelSegmentation` to be more verbose and reusable. Included several new input types, including the `InputRange` component which now shows a fixed floating value based on the step provided. The `SegmentationConfig` component now works with dynamic values controlled by `initialConfig`. These changes should improve function usability and make the code more maintainable going forward.

* fix various bugs

* fix contour delete by upgrade cs3d version

* feat(viewport, inputNumber, segmentationConfig, orthanc): Implement minimum and maximum values for input number components, and useBulkDataURI for Orthanc configuration. Compare measurement view planes with absolute viewport view planes in Cornerstone viewport.

* update yarn lock
2023-04-26 12:21:08 -04:00
Bill Wallace
69d8e6a191
fix(SR): When loading DICOM SR, only one measurement is shown with no way to show others (#3228)
* fix: Make the cornerstone sR viewport show all measurements

* PR fixes

* PR fixes

* Add a DICOM SR hanging protocol

* Duplicate the hanging protocol for seg as well

* PR requested change

* PR requested changes

* PR fixes plus merge update fixes

* PR fixes and integration test fix

* PR - documentation
2023-04-25 17:25:10 -04:00
Bill Wallace
c508a2b6bc
feat: Add a new hanging protocol @ohif/mn (#3305)
* feat: Add a new hanging protocol @ohif/mn

* Add @ohif/seg example

* PR comments and a couple more fixes to make things cleaner

* PR comment

* Added an example to cause the PR checks to rerun
2023-04-18 11:55:25 -04:00
Bill Wallace
6cf271d006
fix: Service consistency typing (#3309)
* Use more consistent type/structure for services

* Fix restoring SR so the tests described work

* One more typed service

* Added types for the Cornerstone library

* Couple more type fixes
2023-04-18 11:17:50 -04:00
M.D
47c25f4364
feat(measurements): add CircleROI Tool (#3211)
* [refactor] measurement service mapping files - rename to .ts files

* [fix] RectangleROI - measurement service mapping _getReport() function - tool name fix

* [feat] added CircleROI tool from updated cornerstone3D

* [refactor] fix for typescript strong typing warnings

* [feat] cornerstone-dicom-sr extension - added CircleROI tool

* [feat] added toolbar button for CircleROI tool

* [doc] doc updates for CircleROI tool

* [update] library - dcmjs to 0.29.5

* [fix] roundNumber() function when given strings

* [fix] refactor after upgrading conerstonejs library 0.49.0

* yarn.lock file change
2023-04-17 08:23:03 -04:00
dxlin
1173e7de6c
fix(ROIThreshold): fix setWeight not updating properly for ROIThreshold panel (#3315) 2023-04-06 14:05:46 -04:00
Bill Wallace
d3da969d23
fix(viewport): Initial blank image on SR/SEG initial display (#3304)
* fix: Blank display area on initial DICOM SR load

* Docs

* Fix a NPE
2023-04-05 17:26:51 -04:00
Ibrahim
b5aa5df575
fix(SRTool): Ellipse Display for DICOMSR Tool (#3307) 2023-04-05 15:09:09 -04:00
Ouwen Huang
af50815ebb
fix(crosshairs): suppressed error for crosshair (#3237) 2023-04-05 14:29:20 -04:00
Bill Wallace
50ed96ff73
feat(URL): add param for initial series and sop uids to display (#3265)
* feat: Allow navigating to a specified series and sop instance

This was a feature in OHIF v2, so adding it to v3, albeit with new
parameters.

feat: Allow comma separated as well as repeated args params

* docs

* Test fixes

* feat: Navigate to SOP selected - PR fixes

* Updated docs

* PR fixes
2023-04-05 12:59:56 -04:00
rodrigobasilio2022
226244a26c
feat(multiframe): enhanced support for multiframe dicom (#3164)
* Changes in cswil version and multiframe

* Minor changes

* wip

* Adding support for NM multiframe images

* Applying PR suggestions

* fixing package versions

* Restoring default.js config file

* Check if NM subtype is reconstructable

* Restore default.js values

* refactore code

* feat: add flag for strict zspacing

---------

Co-authored-by: Alireza <ar.sedghi@gmail.com>
2023-03-31 22:21:16 -04:00
Bill Wallace
5e42a42b5f
fix(viewports): The display of linked viewports during drag and drop has a race (#3286)
* fix: The display of linked viewports during drag and drop has a race

* PR review comments

* fix: Segmentation display two up

* Removing console logs

* Fix the blank viewport can have stuff added to it

* Fix the null name on HP module

* Fix the navigate to initial image

* Fix the nth interleave loader

* Fix the unit tests

* PR comments - docs mostly

* fix: Exception thrown on change displayset after double click
2023-03-31 11:58:48 -04:00
Alireza
ca3b83b2b6
feat(tmtv): add more stages to pt/ct (#3290)
* feat(tmtv): add more stages to pt/ct

* make error stage change to info

* apply review comments
2023-03-30 10:01:48 -04:00
Joe Boccanfuso
d5ff590dfc
feat(DoubleClick): double click a viewport to one up and back (#3285)
* feat(DoubleClick): double click a viewport to one up and back

Added a toggleOneUp command that puts the active viewport into a 1x1 grid layout
and it toggles out of 'one-up' by restoring its saved 'toggleOneUpViewportGridStore'
from the StateSyncService.
Added double click customization for the Cornerstone extension with the
default double click handling being the toggleOneUp command.
Added a cypress test for the double click functionality.

* PR feedback:
- tracked viewport measurements no longer show as dashed when toggling one up
- disallowed double clicking near a measurement
- updated cornerstone3D dependencies to fix double click of TMTV and volume viewport 3D
- created ViewportGridService.getLayoutOptionsFromState

* Updated the ViewportGridService docs.

* Switched to using 'cornerstoneViewportClickCommands' and consistency with the context menu clicks.
2023-03-29 15:39:51 -04:00
Alireza
4734b3bac6
fix(volumeLoad): should not have missing slices when loading (#3287)
* fix(volumeLoad): should not have missing slices when loading

* add review comments
2023-03-29 09:40:22 -04:00
Bill Wallace
b2128976a3
Fix/hp validate match offset 2 (#3279)
* fix: Validate provided display sets other than 0

* Build fix
2023-03-28 11:18:33 -04:00
Joe Boccanfuso
ed7ded05db
fix(Volume3DViewport): Replacing the volume 3D viewport with another reconstructable series (#3281)
* fix(Volume3DViewport) - Replacing the volume 3D viewport with another reconstructable series fails
- updated cornerstone3D core package dependency
- checked for null presentations when setting presentations
- added viewportIndex as a dependency for enabling and disabling an OHIFCornerstoneViewport

* PR feedback - removed viewportIndex useEffect dependency for enabling/disabling OHIFCornerstoneViewport
2023-03-27 15:03:16 -04:00