From a80d36eafa6a087cd7a2fa6884e7c5d28fc96a0d Mon Sep 17 00:00:00 2001 From: Daniel Date: Sun, 2 Mar 2025 18:27:41 +1100 Subject: [PATCH] feat: add cell selection on space click --- src/dashboard/Data/Browser/DataBrowser.react.js | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/src/dashboard/Data/Browser/DataBrowser.react.js b/src/dashboard/Data/Browser/DataBrowser.react.js index b769d3942d..67f56e4566 100644 --- a/src/dashboard/Data/Browser/DataBrowser.react.js +++ b/src/dashboard/Data/Browser/DataBrowser.react.js @@ -419,6 +419,15 @@ export default class DataBrowser extends React.Component { e.preventDefault(); } break; + case 32: // Space + // Only handle space if not editing and there's a current row selected + if (!this.state.editing && this.state.current?.row >= 0) { + const rowId = this.props.data[this.state.current.row].id; + const isSelected = this.props.selection[rowId]; + this.props.selectRow(rowId, !isSelected); + e.preventDefault(); + } + break; } }