2023-03-22 17:45:28 -04:00
|
|
|
const defaultContextMenu = {
|
|
|
|
|
id: 'measurementsContextMenu',
|
|
|
|
|
customizationType: 'ohif.contextMenu',
|
|
|
|
|
menus: [
|
|
|
|
|
// Get the items from the UI Customization for the menu name (and have a custom name)
|
|
|
|
|
{
|
|
|
|
|
id: 'forExistingMeasurement',
|
|
|
|
|
selector: ({ nearbyToolData }) => !!nearbyToolData,
|
|
|
|
|
items: [
|
|
|
|
|
{
|
|
|
|
|
label: 'Delete measurement',
|
|
|
|
|
commands: [
|
|
|
|
|
{
|
|
|
|
|
commandName: 'deleteMeasurement',
|
2024-04-16 11:04:48 -04:00
|
|
|
// we only have support for cornerstoneTools context menu since
|
|
|
|
|
// they are svg based
|
|
|
|
|
context: 'CORNERSTONE',
|
2023-03-22 17:45:28 -04:00
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
{
|
|
|
|
|
label: 'Add Label',
|
|
|
|
|
commands: [
|
|
|
|
|
{
|
|
|
|
|
commandName: 'setMeasurementLabel',
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
},
|
|
|
|
|
],
|
|
|
|
|
};
|
|
|
|
|
|
|
|
|
|
export default defaultContextMenu;
|