From 350f25eed339e5853e8d64ef19114429077d9018 Mon Sep 17 00:00:00 2001 From: Jaga Santagostino Date: Mon, 16 Mar 2020 08:22:08 +0100 Subject: [PATCH] changes from PR requests (#6880) Signed-off-by: Jaga Santagostino --- web/ui/react-app/src/pages/graph/Legend.tsx | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/web/ui/react-app/src/pages/graph/Legend.tsx b/web/ui/react-app/src/pages/graph/Legend.tsx index 991db94c2..8a4068897 100644 --- a/web/ui/react-app/src/pages/graph/Legend.tsx +++ b/web/ui/react-app/src/pages/graph/Legend.tsx @@ -23,12 +23,12 @@ export class Legend extends PureComponent { this.setState({ selectedIndexes: [] }); } } - handleSeriesSelect = (index: number) => (ev: any) => { + handleSeriesSelect = (index: number) => (ev: React.MouseEvent) => { // TODO: add proper event type const { selectedIndexes } = this.state; let selected = [index]; - if (ev.ctrlKey) { + if (ev.ctrlKey || ev.metaKey) { const { chartData } = this.props; if (selectedIndexes.includes(index)) { selected = selectedIndexes.filter(idx => idx !== index); @@ -68,7 +68,7 @@ export class Legend extends PureComponent { ))} {chartData.length > 1 && (
- Click: select series, CTRL + click: toggle multiple series + Click: select series, {navigator.platform.includes('Mac') ? 'CMD' : 'CTRL'} + click: toggle multiple series
)}