* Organize viewports reducers * Organize viewports actions * Add local state to store dom node and remove hack * Comment usage of dom in vtk * Fix set of enabledElements * Fix warning in html viewport * Update docs for state * Add commandsmanager to commandsmodule * refactor: Shift ConnectedViewportDownloadForm to extension-cornerstone (#1224) * refactor: 💡 Shift ConnectedViewportDownloadForm to its own proj Shift ConnectedViewportDownloadForm to its own project and use local state to get enabledElement Closes: #1206 * Refactor connected component to cornerstone component * Remove builtin behaviour from toolbarrow
43 lines
1.1 KiB
JavaScript
43 lines
1.1 KiB
JavaScript
import init from './init.js';
|
|
import asyncComponent from './asyncComponent.js';
|
|
import commandsModule from './commandsModule.js';
|
|
import toolbarModule from './toolbarModule.js';
|
|
import CornerstoneViewportDownloadForm from './CornerstoneViewportDownloadForm';
|
|
|
|
const OHIFCornerstoneViewport = asyncComponent(() =>
|
|
import(
|
|
/* webpackChunkName: "OHIFCornerstoneViewport" */ './OHIFCornerstoneViewport.js'
|
|
)
|
|
);
|
|
|
|
/**
|
|
*
|
|
*/
|
|
export default {
|
|
/**
|
|
* Only required property. Should be a unique value across all extensions.
|
|
*/
|
|
id: 'cornerstone',
|
|
|
|
/**
|
|
*
|
|
*
|
|
* @param {object} [configuration={}]
|
|
* @param {object|array} [configuration.csToolsConfig] - Passed directly to `initCornerstoneTools`
|
|
*/
|
|
preRegistration({ servicesManager, configuration = {} }) {
|
|
init({ servicesManager, configuration });
|
|
},
|
|
getViewportModule() {
|
|
return OHIFCornerstoneViewport;
|
|
},
|
|
getToolbarModule() {
|
|
return toolbarModule;
|
|
},
|
|
getCommandsModule({ servicesManager }) {
|
|
return commandsModule({ servicesManager });
|
|
},
|
|
};
|
|
|
|
export { CornerstoneViewportDownloadForm };
|