diff --git a/client/src/app/App.js b/client/src/app/App.js index 8110f1fc7e..b2d551c962 100644 --- a/client/src/app/App.js +++ b/client/src/app/App.js @@ -1945,6 +1945,11 @@ export class App extends PureComponent { return this.emitWithTab(type, activeTab, payload); } + if (action === 'open-variables-panel') { + const { panel } = this.state.layout; + return panel.open ? this.closePanel() : this.openPanel('variable-outline'); + } + const tab = this.tabRef.current; return tab.triggerAction(action, options); diff --git a/client/src/app/tabs/bpmn/getBpmnWindowMenu.js b/client/src/app/tabs/bpmn/getBpmnWindowMenu.js index 7c6c4d364b..55edc04408 100644 --- a/client/src/app/tabs/bpmn/getBpmnWindowMenu.js +++ b/client/src/app/tabs/bpmn/getBpmnWindowMenu.js @@ -11,7 +11,8 @@ export default function getBpmnWindowMenu(state) { return [ ...getZoomEntries(state), - ...getPropertiesPanelEntries(state) + ...getPropertiesPanelEntries(state), + ...getVariableEntries(state) ]; } @@ -51,3 +52,12 @@ function getPropertiesPanelEntries({ propertiesPanel }) { action: 'resetProperties' } ] : []; } + +function getVariableEntries({ variablePanel }) { + return variablePanel ? [ { + label: 'Toggle Variables Tab', + accelerator: 'CommandOrControl+Shift+V', + action: 'open-variables-panel' + } + ] : []; +} diff --git a/client/src/app/tabs/cloud-bpmn/BpmnEditor.js b/client/src/app/tabs/cloud-bpmn/BpmnEditor.js index 9cab0ce7ed..0a2025fcbb 100644 --- a/client/src/app/tabs/cloud-bpmn/BpmnEditor.js +++ b/client/src/app/tabs/cloud-bpmn/BpmnEditor.js @@ -432,7 +432,8 @@ export class BpmnEditor extends CachedComponent { setColor: !!selectionLength, spaceTool: !inputActive, undo: commandStack.canUndo(), - zoom: true + zoom: true, + variablePanel: true }; // ensure backwards compatibility