cornerstoneTools icon indicating copy to clipboard operation
cornerstoneTools copied to clipboard

Default tool configuration is overwritten by custom configuration passed to constructor

Open evren217 opened this issue 8 years ago • 2 comments

I think we should merge default and custom configuration objects. See: https://github.com/cornerstonejs/cornerstoneTools/blob/vNext/src/tools/ReferenceLinesTool.js#L31

evren217 avatar Nov 29 '18 20:11 evren217

A possible solution could be: Make the BaseTool handle the merge of configurations (similar with ReactJS Components)

  • create a static object with a protected name, maybe: defaultConfiguration.
  • constructor should pass whatever it receives to super (BaseTool)
  • BaseTool should get defaultConfiguration and configuration and merge it correctly.

galelis avatar Nov 29 '18 20:11 galelis

:tada: This issue has been resolved in version 3.9.0 :tada:

The release is available on:

Your semantic-release bot :package::rocket:

dannyrb avatar May 11 '19 00:05 dannyrb