made a keyboard shortcut to duplicate panel

This commit is contained in:
Patrick O'Carroll
2018-03-15 17:22:11 +01:00
parent 18e498e0ff
commit 1094dc32bc
@@ -178,6 +178,14 @@ export class KeybindingSrv {
}
});
// duplicate panel
this.bind('p d', () => {
if (dashboard.meta.focusPanelId && dashboard.meta.canEdit) {
let panelIndex = dashboard.getPanelInfoById(dashboard.meta.focusPanelId).index;
dashboard.duplicatePanel(dashboard.panels[panelIndex]);
}
});
// share panel
this.bind('p s', () => {
if (dashboard.meta.focusPanelId) {